Skip to content

Conversation

@nigelsumner
Copy link

Add dissolve blend composite mode with UI controls

This PR implements a new dissolve blend composite mode for OpenRV's stack compositor with full UI integration and real-time controls.

OpenRV_dissolveBlend.mov

Features Added

  • Dissolve blend mode in StackIPNode for 2-input compositing
  • GPU shader implementation (Dissolve2.glsl) with configurable amount
  • UI slider and text input controls in Session Manager
  • Real-time dissolve amount adjustment (0.0 to 1.0 range)
  • Immediate UI updates when switching between composite modes

Technical Implementation

Core Implementation

  • StackIPNode.cpp: Added dissolve mode support with m_dissolveAmount property
  • StackIPNode.h: Added property declaration for dissolve amount control
  • ShaderCommon.cpp/.h: Implemented newDissolveBlend() function for GPU shader management

GPU Shaders

  • Dissolve2.glsl: GLSL shader for hardware-accelerated dissolve blending

UI Integration

  • composite.ui: Added QSlider and QLineEdit controls for dissolve amount
  • Composite_edit_mode.mu: Enhanced with slider integration and UI synchronization

Build System

  • CMakeLists.txt: Updated build configuration for dissolve shader compilation

Testing

  • Successfully builds on macOS with existing OpenRV build system
  • UI controls properly show/hide when switching composite modes
  • Slider and text field remain synchronized during interaction
  • Dissolve blending works correctly with 2-input stacks

Usage

  1. Load two media sources into a stack
  2. In Session Manager, set composite mode to "Dissolve"
  3. Use the slider or text input to control dissolve amount (0.0 = first input, 1.0 = second input)
  4. Real-time preview updates as you adjust the dissolve amount

This commit implements a new dissolve blend composite mode for OpenRV's
stack compositor with full UI integration and real-time controls.

Features:
- Dissolve blend mode in StackIPNode for 2-input compositing
- GPU shader implementation (Dissolve2.glsl) with configurable dissolve amount
- UI slider and text input controls in Session Manager
- Real-time dissolve amount adjustment (0.0 to 1.0 range)
- Immediate UI updates when switching between composite modes

Technical Implementation:
- StackIPNode.cpp: Added dissolve mode support with m_dissolveAmount property
- ShaderCommon.cpp: Implemented newDissolveBlend() function for GPU shader management
- Dissolve2.glsl: GLSL shader for hardware-accelerated dissolve blending
- composite.ui: Added QSlider and QLineEdit controls for dissolve amount
- Composite_edit_mode.mu: Enhanced with slider integration and UI synchronization
- CMakeLists.txt: Updated build configuration for dissolve shader compilation

Tested on macOS with existing OpenRV build system. UI controls properly
show/hide when switching composite modes, and dissolve blending works
correctly with 2-input stacks.

Signed-off-by: nigel sumner <[email protected]>
Copy link
Contributor

@pbergeron-adsk pbergeron-adsk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks OK to me, needs to be view tested.

@bernie-laberge bernie-laberge added the community Contribution from the Open RV Community label Dec 1, 2025
F = blend(size, name,
overShaders[size - 2]); //*2_glsl is at position 0
break;
// TODO: dissolve
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @nigelsumner for adding the dissolve !
(I checked in the git history of the original RV code base and this comment dates back from 13 years ago)


IntProperty* autoSizeProperty() const { return m_autoSize; }

// float dissolveAmount() const { return m_dissolveAmount->front(); }
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Detail: Please remove if not used: we prefer not to leave any deadcode if possible unless you think it might be useful.

maya_tools.mu
# See rvnuke_mode.mu.in
rvnuke_mode.mu
rvnuke_mode.musrc/plugins/rv-packages/session_manager/composite_ui.py
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe there is a newline missing after rvnuke_mode.mu and before composite_ui.py.
Also: where are those *_ui.py files coming from ?

Copy link
Contributor

@bernie-laberge bernie-laberge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @nigelsumner for this great contribution !

@bernie-laberge bernie-laberge changed the title Add Dissolve blend composite mode to stackIPNode with UI controls SG-41316: Add Dissolve blend composite mode to stackIPNode with UI controls Dec 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

community Contribution from the Open RV Community

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants