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 compilation without image format features #1381

Merged

Conversation

jakobhellermann
Copy link
Contributor

The Texture::convert function previously was only compiled when
one of the image format features (png, jpeg etc.) were enabled.
The bevy_sprite crate needs this function though, which led
to compilation errors when using cargo check --no-default-features --features render.

Now the convert function has no features and the texture_to_image
and image_to_texture utilites functions are in an unconditionally
compiled module.

The `Texture::convert` function previously was only compiled when
one of the image format features (`png`, `jpeg` etc.) were enabled.
The `bevy_sprite` crate needs this function though, which led
to compilation errors when using `cargo check --no-default-features
--features render`.

Now the `convert` function has no features and the `texture_to_image`
and `image_to_texture` utilites functions are in an unconditionally
compiled module.
@cart
Copy link
Member

cart commented Feb 2, 2021

Nice catch. Thanks!

@cart cart merged commit 4796ea8 into bevyengine:master Feb 2, 2021
@jakobhellermann jakobhellermann deleted the fix-compile-no-image-features branch February 22, 2021 09:14
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.

2 participants