Nuke binary plugins 15.1.5
 
Loading...
Searching...
No Matches
DD::Image::Channel_KnobI Class Referenceabstract

The Channel_KnobI class is used to expose the selection handle in DDImage. More...

#include <Channel_KnobI.h>

Public Types

enum class  SelectionHandling {
  Default , AllButNonInputGreyed , AllNormal , InputOnly ,
  InternalOnly
}
 
enum class  ChannelIoHandling { CollapseAndValidate , AutoCreate }
 

Public Member Functions

virtual void setSelectionHandling (const SelectionHandling)=0
 Set the selection handling before the Widget is constructed.
 
virtual SelectionHandling selectionHandling () const =0
 
virtual void setChannelManager (ndk::ChannelManager *manager)=0
 
virtual ndk::ChannelManager * channelManager () const =0
 
virtual bool usingDefaultGlobalManager () const =0
 
virtual void setChannelIoHandling (const ChannelIoHandling)=0
 
virtual ChannelIoHandling channelIoHandling () const =0
 
virtual void setAvailableChannels (const ChannelSet &)=0
 
virtual ChannelSet availableChannels () const =0
 

Detailed Description

The Channel_KnobI class is used to expose the selection handle in DDImage.

Member Enumeration Documentation

◆ SelectionHandling

Enumerator
Default 

Channels that are not in the node input get put in the "Other" menu.

AllButNonInputGreyed 

User can select any channel, but those not in the input are greyed out.

AllNormal 

User can select any channel normally.

InputOnly 

Users can only select node input channels.

InternalOnly 

Users can only select internally-created node channels.

◆ ChannelIoHandling

Enumerator
AutoCreate 

Write only the layer name if all channels are in the same layer, and validate names on read.

Member Function Documentation

◆ setChannelManager()

virtual void DD::Image::Channel_KnobI::setChannelManager ( ndk::ChannelManager *  manager)
pure virtual

Assign a custom ChannelManager for the knob to use, if desired. By default the knob uses the global default ChannelManager. For internal use only!

◆ channelManager()

virtual ndk::ChannelManager * DD::Image::Channel_KnobI::channelManager ( ) const
pure virtual

Get the ChanneSetContext assigned to the knob. For internal use only!

◆ usingDefaultGlobalManager()

virtual bool DD::Image::Channel_KnobI::usingDefaultGlobalManager ( ) const
pure virtual

Is the knob using the global Nuke ChannelManager or a custom one? For internal use only!

◆ setChannelIoHandling()

virtual void DD::Image::Channel_KnobI::setChannelIoHandling ( const  ChannelIoHandling)
pure virtual

Control how the knob should write/read serialized channel/layer names. Set this during knob creation (makeKnobs() = true) to make sure knob loading is affected. By default the knob does 'CollapseAndValidate' which tries to write only the layer name if all channels are part of the same layer, and on read the names are checked against the global set. However only writing the layer name loses individual channel name information and requires the 'add_layer' and 'add_channel' script directives to supply this information to Nuke -before- the knob is loaded. In internal-only mode this is not possible because those channel names will not be part of the global set, so to avoid this the knob uses 'AutoCreate' which writes all channel names explicitly and skips the name validation on read, auto-creating the channels. These default behaviors can be changed via this method. For internal use only!

◆ setAvailableChannels()

virtual void DD::Image::Channel_KnobI::setAvailableChannels ( const ChannelSet )
pure virtual

Set the subset of channels that the knob can select from. This is useful when the knob is accessing an internal channel manager that is not coming from any input but created internally. This is typically used in conjunction with setChannelIoHandling()=AutoCreate because the channels created by an internal manager are not exposed in the global channel set, which means the normal method to pre-create channels & layers for knobs does not work, the channel creation needs to be within the scope of the node the knob is on. For internal use only!

◆ availableChannels()

virtual ChannelSet DD::Image::Channel_KnobI::availableChannels ( ) const
pure virtual

Returns the currently assigned available channels set. This should query the SelectionHandling value to determine what is the source of the channels presented on the menu for selection. For internal use only!



©2024 The Foundry Visionmongers, Ltd. All Rights Reserved.
www.foundry.com