Extract Review resize but not distort (keep aspect ratio)

Hi, Is there a way to make extrack review plugin to perform resizing a product but not distorting it?

now we can specify both width and height preview resolution whitch results in behaivor where if my product is for example 4448x3096 whitch is not 16 by 9 it will generate a 16 by 9 preview whitch will be distorted version of a product.

For now i decide go wo resizing but its a bit painful because sometimes i have 6k and 8k footages whitch will generate same rez preview whitch weight a lot and client dont want to resieve 600mb preview files

I believe if you only configure the width or height but keep the other on 0 it will resize it whilst keeping aspect ratio. Could you show your settings?


Otherwise you may get lucky using the oiiotool transcoder if you want a specific output file but also want to apply some image manipulations. E.g. you could resize to 50% like here: Tray Publisher publish ACEScg EXR plates with a sRGB JPEG representation - #6 by BigRoy

The oiiotool arguments can also resize to a fixed width or height whilst keeping aspect ratio. So it could be a workaround if using 0 in settings does not work.

1 Like

would that be possible by modifying extract_review plugin to use oiio instead of ffmpeg ?


I’m not sure if it’s related to the discussion but there’s a TODO in extract_review about calculating width and height.

((((((


i dont want it since i want my exr transcods to be in the sourse rez and only mp4 to be resized to 1920*x

That’s exactly what the other topic describes - it transcodes (in that case) to jpeg that is half size as an extra representation. That should be similar for an extra mp4 then, no?

Tagging @jakub.jezek since he knows a lot about these settings

looks similar but how does it connects with mp4? i thought oiio cinverts img to img

For reference

The plugin that from which you took a screenshot is ExtractReview.
in profile settings

  • ayon+settings://core/publish/ExtractReview/profiles

we have two default outputs:

  • png
  • h264

both of them work with the same families review and render
Therefore the plugin picks the output based on additional condition:

keeping the source resolution should be selected by using 0 and 0
There’s also scale pixel aspect, let me quote its tool tip:

Rescale input when it's pixel aspect ratio is not 1. 
Useful for anamorphic reviews.

Also, here’s the docs for this plugin.

1 Like

Okey i have onother problem: my redshift render is has 1.799 pixel aspect and OIIO do its thing to converting colors but not preserving info for EXTRACT REVIEW plugin to undistort the image so i’m gettings distorted review(

adding video filters is mostly solves issue but ignored when anamorphic

according to plugin logic it uses the same scale filter so it overrides my own

1 Like

Hey @timsergeeff, I hope this was helpful and that you’ve solved the issue. For future readers, there’s also a way to add additional arguments to oiiotool, which can be done by adding an additional oiiotool argument for resizing - in the ayon+settings://core/publish/ExtractOIIOTranscode/profiles/0/outputs/0/oiiotool_args settings.

Note that setting the height value to zero will maintain the pixel aspect ratio of the original image. If you need to adjust the anamorphic value, you should do so later in the ExtractReview output FFmpeg arguments.

References:

But oiio tool is not used in Nuke so renders reviews will not use it

You can still use it if you configure the OIIOTranscode plugin profile to catch it. Please could you describe in details your flow:

  • Nuke render resolution WxHxPA (with anamorph baked?)
  • Nuke intermediate baking resolution
  • desired ExtractReview resolution (square pixels)

Hi @timsergeeff,

did you ever find a solution to your problem?

I’m currently facing the same issue: I want to transcode my EXR files to JPG using the OIIO Transcode plugin (keeping the original size), and then use the Extract Review plugin with those JPGs as the source to create a review MP4 resized to 1920px width while preserving the aspect ratio.

Using scale=1920:-2 in the Extract Review FFmpeg video filter settings does not work, since the plugin internally uses the same video filter and eventually overrides my custom filter setting.

This post is quite old, so I was wondering if there have been any significant changes since then that would allow rescaling the review MOV/MP4 to a given width while keeping the aspect ratio intact.

Any help would be appreciated.

Cheers,
Sebastian

Does this plugin ayon+settings://core/publish/ExtractOIIOPostProcess works for you?

hi! i dont remember how it was, but now i use like this and i believe it works ok for core 1.9.5

but this is for mp4 for oiio i dont use anything just blank defaults because this is rare when u need to use aspect in 3d

Hi!

@timsergeeff thanks for your reply,
it looks like if you use the videofilter as an output argument as you did,
instead of the ayon video filter setting above, I am able to override the setting and the result is resized as expected. Great!

@mustafa_jafar did not take a look at the OIIO Post Process since the solution above worked as expected. But thanks for your reply, I might take a look at that as soon as I have the time to investigate.

I still have an issue regarding the naming of the review files itself,
but I will probably create a separate thread for this.

Thanks!

FYI @timsergeeff

I managed to fix the anamorph issue when using a custom videofilter in the extract review plugin:

  1. Using the oiioconvert plugin, I force the pixel aspect ratio to 1.0 and then tag it as “reformatted”

  1. The extract review plugin picks up the color-converted sequence with a pixel aspect ratio of 1.0, and generates the mp4 with the given videofilter correctly.

Feels like a bit of a hack, but hey it works.