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

Fix encode call for Blender 3.5 #214

Merged
merged 2 commits into from
Apr 20, 2023
Merged

Fix encode call for Blender 3.5 #214

merged 2 commits into from
Apr 20, 2023

Conversation

keianhzo
Copy link
Contributor

@keianhzo keianhzo commented Mar 30, 2023

ExportImage.encode has changed it's signature in the Blender 3.5 glTF exporter. This PR adds 3.5.0 testing support and fixes the encoding issue.

@keianhzo keianhzo added this to the 1.2.0 milestone Mar 30, 2023
@keianhzo keianhzo self-assigned this Mar 30, 2023
if mime_type == "image/vnd.radiance":
return self.encode_from_image_hdr(self.blender_image())
return super().encode(mime_type)
if bpy.app.version < (3, 5, 0):
Copy link
Contributor

Choose a reason for hiding this comment

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

It looks like this changed in 3.4 KhronosGroup/glTF-Blender-IO@9af5fad

Copy link
Contributor Author

Choose a reason for hiding this comment

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

That commit was part of the 3.5.0 milestone: KhronosGroup/glTF-Blender-IO#1794
It wasn't there when 3.4.0 was tagged AFAIK.

Copy link
Contributor

Choose a reason for hiding this comment

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

I can confirm that this is only needed for 3.5

@keianhzo keianhzo modified the milestones: 1.2.0, 1.1.1 Apr 17, 2023
Copy link
Contributor

@Exairnous Exairnous left a comment

Choose a reason for hiding this comment

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

LGTM

@keianhzo keianhzo merged commit 3f50104 into master Apr 20, 2023
Copy link
Contributor

@hrithikwins hrithikwins left a comment

Choose a reason for hiding this comment

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

.

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.

4 participants