woelper / oculante

A fast and simple image viewer / editor for many operating systems
https://github.com/woelper/oculante
MIT License
878 stars 41 forks source link

DDS BC7, cubemaps, volume maps, or texture arrays #155

Open VidhosticeSDK opened 1 year ago

VidhosticeSDK commented 1 year ago

Hello, would it be possible to implement support for additional BC7 compression formats and file types cubemaps, volume maps, or texture arrays? (https://github.com/microsoft/DirectXTex)

woelper commented 1 year ago

Hey! Thanks! I am using https://gitlab.com/mechaxl/dds-rs for decoding. It says "Support for cubemaps and volumes, as well as DX10 is planned". Unfortunately the library has not been updated for some time. If you come across a better Rust library or binding that has better features let me know!

Quackdoc commented 1 year ago

Not currently possible now as far as I know, but it may be possible to use image2 at some point which uses openimageio, but it doesn't currently bundle openimageio, and the current openimageio-rs crate is massively outdated. so you are relying on native libraries, which might be fine for osx and linux, but is largely a PITA on windows. if at some point it does become viable, even if via a flag, it would add a a couple of image formats, see the sidebar in oiio's docs for the supported images.

https://github.com/zshipko/image2-rs https://openimageio.readthedocs.io/en/latest/builtinplugins.html

as a side note, image-rs may actually be getting support for DDS BC1-5 see https://github.com/image-rs/image/issues/1623 https://github.com/jansol/texpresso/issues/1 bc6/7 are on the roadmap for the tool too so it's worth keeping an eye on texpresso

VidhosticeSDK commented 1 year ago

It would take more support for this request: https://github.com/microsoft/DirectXTex/issues/313 ;-)

woelper commented 1 year ago

This seems to be a promising library: https://github.com/SiegeEngine/ddsfile

gabriel-andreescu commented 1 year ago

Any news on this?

woelper commented 1 year ago

Not yet, sorry. If you discover a library that supports some or all of the above features I'd be happy too give it a try!

woelper commented 1 year ago

I did find this repository: https://github.com/Shadlock0133/bigblob-decoder/tree/main - at least it offers BC7 support. They don't seem to have a release on crates.io, which means I can only use the git dependency, so this won't work for oculante's crates.io version. Maybe there are some better alternatives, and texpresso looks really great - but it does not support BC7 yet.