Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

X3D serializer: Material RGB colors #1232

Merged
merged 6 commits into from
Apr 22, 2023
Merged

X3D serializer: Material RGB colors #1232

merged 6 commits into from
Apr 22, 2023

Conversation

andreasplesch
Copy link
Contributor

@andreasplesch andreasplesch commented Apr 20, 2023

All Submissions:

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same update/change?
  • Does your submission pass tests?

fixes #1231

some additional cleanup as suggested by standardx.

@andreasplesch andreasplesch changed the title X3D serializer X3D serializer: Material RGB colors Apr 20, 2023
@z3dev z3dev requested review from z3dev, platypii and hrgdavor April 20, 2023 22:42
@andreasplesch
Copy link
Contributor Author

I will be glad to address any review comments.

hrgdavor
hrgdavor previously approved these changes Apr 21, 2023
Copy link
Contributor

@hrgdavor hrgdavor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good :)

@@ -177,7 +177,7 @@ const convertAppearance = (object, options) => {
const colorRGB = object.color.slice(0, 3)
const diffuseColor = colorRGB.join(' ')
const emissiveColor = colorRGB.join(' ')
const transparency = object.color[3]
const transparency = 1.0 - object.color[3]
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for the late change. I had never pushed this correction.

Copy link
Member

@z3dev z3dev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@andreasplesch thanks again for these changes.

its nice to have someone else looking at this code, and making improvements.

@z3dev z3dev merged commit cc99548 into jscad:master Apr 22, 2023
@andreasplesch
Copy link
Contributor Author

Thanks, no problem.

@andreasplesch andreasplesch deleted the x3d branch April 22, 2023 14:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

x3d serializer: Material colors should be RGB, not RGBA
3 participants