Is there a way to hardset the viewport render resolution? I’d like to render in portrait mode with cropping / gate on the sides, for example 600x900.
No easy way, found some sort of “hack” for custom resolution viewport but it depends on the resolution of your monitor in a way(limitation doing it this way is you can’t set the resolution too high unless you are using a high res monitor like 4k and above).
Basically click the gear icon in viewport and set aperture policy to fit and fill viewport to checked. Next resize your viewport to the required resolution like 600x900 ( you can undock the viewport for more screen estate space if you are using full HD resolution like me).
Hello @JC_sculpture & @DavidDPD! Our development team is working on a way to set custom viewport resolutions! (I added this forum post to the development ticket OM-48501: Ability to set a custom viewport resolution.)
Thank you for your post @DavidDPD! I really appreciate you taking the time to look into this.
You can copy the code snippet as below and run in Window->Script Editor or wirte a extension
import carb carb.settings.get_settings().set("/app/renderer/resolution/width", 600) carb.settings.get_settings().set("/app/renderer/resolution/height", 900) default_window = omni.kit.viewport_legacy.get_default_viewport_window() if default_window: default_window.set_visible(False) view_port_factory = omni.kit.viewport_legacy.acquire_viewport_interface() handle = view_port_factory.create_instance() vp = view_port_factory.get_viewport_window(handle) vp.set_window_size(600, 900) vp.set_window_pos(0, 0) vp.set_visible(True)