VSE: HDR support in preview regions #119462

Open
opened 2024-03-14 14:31:55 +01:00 by Sergey Sharybin · 2 comments

The preview regions of video sequencer do not support HDR display, forcing the content to be clipped despite the state of the High Dynamic Range option in the scene's color management settings. These regions are to follow the same rules w.r.t HDR as Render Result in the Image Editor or Compositor backdrop.

Part of the reason why it is happening is because the image buffer is rendered to an overlay framebuffer (sequencer_draw_preview() which uses GPU_viewport_framebuffer_overlay_get()) which is backed up by GPU_SRGB8_A8 texture, which causes clipping.

The reason for such render choice is because it makes it easy to render image buffer, which could be in a display space, even if it is a float buffer.

One immediate idea could be to render the sequencer preview to viewport's color_render_tx (which would require having framebuffer for it, similar to GPU_viewport_framebuffer_overlay_get, but GPU_viewport_framebuffer_render_get). However, it is not immediately clear how to deal with image buffers whose data is not in the linear space.

Attached an HDR EXR image and the scene which uses it. The goal is to make the preview region to give the same look as F12 render.

The preview regions of video sequencer do not support HDR display, forcing the content to be clipped despite the state of the `High Dynamic Range` option in the scene's color management settings. These regions are to follow the same rules w.r.t HDR as Render Result in the Image Editor or Compositor backdrop. Part of the reason why it is happening is because the image buffer is rendered to an overlay framebuffer (`sequencer_draw_preview()` which uses `GPU_viewport_framebuffer_overlay_get()`) which is backed up by `GPU_SRGB8_A8` texture, which causes clipping. The reason for such render choice is because it makes it easy to render image buffer, which could be in a display space, even if it is a float buffer. One immediate idea could be to render the sequencer preview to viewport's `color_render_tx` (which would require having framebuffer for it, similar to `GPU_viewport_framebuffer_overlay_get`, but `GPU_viewport_framebuffer_render_get`). However, it is not immediately clear how to deal with image buffers whose data is not in the linear space. Attached an HDR EXR image and the scene which uses it. The goal is to make the preview region to give the same look as F12 render.
Sergey Sharybin added the
Type
To Do
label 2024-03-14 14:31:55 +01:00
Sergey Sharybin added this to the Video Sequencer project 2024-03-14 14:31:58 +01:00
Member

The draw manager recreates the frame buffers based on the textures.
See DRW_view_data_default_lists_from_viewport. But I think we should add the GPU_viewport_framebuffer_render_get as that is easier tobe reused across multiple redraws

The draw manager recreates the frame buffers based on the textures. See `DRW_view_data_default_lists_from_viewport`. But I think we should add the `GPU_viewport_framebuffer_render_get` as that is easier tobe reused across multiple redraws
Aras Pranckevicius self-assigned this 2024-04-24 12:34:15 +02:00

I can try to make this happen. Perhaps because I don't know yet how deep the rabbit hole goes :)

I can try to make this happen. Perhaps because I don't know yet how deep the rabbit hole goes :)
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#119462
No description provided.