v4.0
Creates and adds a UserDataBlob or CustomProperty to a Clip object.
oReturn = Clip.AddProperty( Preset, [BranchFlag], [Name] ); |
CustomProperty, UserDataBlob or UserDataMap, depending on the preset that was used.
Parameter | Type | Description |
---|---|---|
Preset | String | This argument contains either the name of a Property Preset or a string with
the filename or full path to a Preset file. Note: Only CustomProperty Presets, UserDataBlob Presets, and UserDataMap Presets are valid for clips. The type of property that is created is determined by this argument. For example, "CustomProperty" creates an empty CustomProperty and "UserDataBlob" creates a UserDataBlob. |
BranchFlag | Boolean | False is the only supported value.
Default Value: false |
Name | String | Represents the name of the new property (see SIObject.Name). If not specified the object is named based on the Preset argument. |
NewScene( null,false ) ; var oRoot = ActiveProject.ActiveScene.Root ; var oGrid = oRoot.AddGeometry( "Grid", "MeshSurface" ); var oGeom = oGrid.ActivePrimitive.Geometry ; var oClip = oGeom.SaveShapeKey(1) ; var oPSet = oClip.AddProperty( "CustomProperty",false,"ClipData" ) ; oPSet.AddParameter3( "StringOnClip", siString ) ; //You can also store binary data oClip.AddProperty( "UserDataBlob",false,"MyBlob" ) ; //The new properties show up on the bottom //of the PPG InspectObj( oClip ) ; |