[ui] Replace Qt image I/O and scaling with pyalicevision in thumbnail creation#3067
Draft
[ui] Replace Qt image I/O and scaling with pyalicevision in thumbnail creation#3067
Conversation
…ation Agent-Logs-Url: https://github.com/alicevision/Meshroom/sessions/224783db-9d25-4869-96e8-53b046b06d2f Co-authored-by: fabiencastan <153585+fabiencastan@users.noreply.github.com>
Agent-Logs-Url: https://github.com/alicevision/Meshroom/sessions/fa077912-d210-4206-ae21-3961826cc704 Co-authored-by: fabiencastan <153585+fabiencastan@users.noreply.github.com>
Copilot created this pull request from a session on behalf of
fabiencastan
April 1, 2026 21:14
View session
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Replaces all Qt image handling (
QImageReader,QImageWriter,QImage.scaled) in thumbnail creation withpyalicevision.image(OpenImageIO backend), giving access to RAW, EXR, HDR and other formats Qt cannot decode.Features list
avImage.readImagewithEImageColorSpace_SRGBavImage.resizeImage(newW, newH, image, thumbnail)— aspect ratio computed in PythonavImage.writeImagewithEImageColorSpace_NO_CONVERSIONQImageReader,QImageWriter,QImage,Qt,numpyimports — thumbnail pipeline is now Qt-free for image dataImplementation remarks
The full pipeline in
createThumbnail:avImage.readImage(path, Image_RGBColor(), ImageReadOptions(EImageColorSpace_SRGB))scale = min(maxW/w, maxH/h), thenavImage.resizeImage(newW, newH, image, thumbnail)(OpenImageIO high-quality resampling)avImage.writeImage(path, thumbnail, ImageWriteOptions(), oiioParams().get())withEImageColorSpace_NO_CONVERSION(data already sRGB)The zero-dimension guard uses cached
w, hvariables retrieved before the check, avoiding redundant calls and making division-by-zero impossible.