public class SoPackedColor extends SoNode
SoPackedColor is similar to SoBaseColor in that it sets the diffuse color component of the current material. However, it also changes the transparency component. The color and transparency information is packed into unsigned 32-bit integers: 0xrrggbbaa, where aa represents the alpha (0x00 = fully transparent, 0xff = opaque), and rr, gg, and bb represent the red, blue, and green components of the color, respectively. Note that the order (r,g,b,a) of these components is reversed from the ordering in releases of Open Inventor prior to 2.1 and is platform independent.
If the transparency type is SoGLRenderAction.SCREEN_DOOR, only the first transparency value will be used. With other transparency types, multiple transparencies will be used. (See SoGLRenderAction.SCREEN_DOOR description )
SoPackedColor uses less memory than SoBaseColor or SoMaterial to store multiple color and transparency values. It can be used in cases where space is critical. However, for geometry nodes that have a
vertexProperty field, the best practice is to use an SoVertexProperty node (which also has an orderedRGBA field) to specify diffuse color and transparency.
If setOverride() was called on an SoMaterial node higher in the scene graph and either the
diffuseColor field or the
transparency field is not ignored (setIgnored()), then the
color and transparency values from the SoMaterial node are used instead of the values in this node. It is not currently possible to override just the color or just the transparency.
File format/default:
PackedColor {
| orderedRGBA | 0xccccccff |
Action behavior:
SoGLRenderAction, SoCallbackAction
Sets the current base (diffuse) color(s) in the state.
See also:
Inventor.ConstructorCommand| Modifier and Type | Field and Description |
|---|---|
SoMFUInt32 |
orderedRGBA
Defines the packed colors.
|
VERBOSE_LEVEL, ZeroHandle| Constructor and Description |
|---|
SoPackedColor()
Creates a packed color node with default settings.
|
affectsState, callback, copy, copy, distribute, doAction, getAlternateRep, getBoundingBox, getByName, getMatrix, getPrimitiveCount, getRenderUnitID, GLRender, GLRenderBelowPath, GLRenderInPath, GLRenderOffPath, grabEventsCleanup, grabEventsSetup, handleEvent, isBoundingBoxIgnoring, isOverride, pick, rayPick, search, setOverride, touch, writecopyFieldValues, copyFieldValues, enableNotify, fieldsAreEqual, get, getAllFields, getEventIn, getEventOut, getField, getFieldName, hasDefaultValues, isNotifyEnabled, set, setToDefaultsdispose, getEXTERNPROTO, getName, getPROTO, isDisposable, isSynchronizable, setName, setSynchronizablegetAddress, getNativeResourceHandle, startInternalThreads, stopInternalThreadspublic final SoMFUInt32 orderedRGBA
Generated on February 24, 2026, Copyright © Thermo Fisher Scientific. All rights reserved. http://www.openinventor.com