c4d.modules.mograph
¶
Follow me to the Inheritance diagramm .
GeGetMoData()
GeGetMoDataSelection()
GeSetMoDataSelection()
GeGetMoDataWeights()
GeSetMoDataWeights()
GetMoDataDefault()
GetMoDataDefaultType()
To get the generator (cloner, matrix object, text object, instance object, fracture object) that owns the
MoData
currently being modified in a Python effector, a global variable ‘gen’ is added to the effector code:
import c4d from c4d.modules import mograph as mo def main(): md = mo.GeGetMoData(op) if md==None: return 1.0 print gen # Generator object # Other variables are also available in a Python effector print doc # Document where the effector is located print op # Effector object return 1.0
c4d.modules.mograph.
GeGetMoData
(
op
)
¶
Returns the MoGraph data of an object.
Parameters: | op ( c4d.BaseObject ) – The object. |
---|---|
Return type: |
MoData
|
Returns: | The MoGraph data. |
c4d.modules.mograph.
GeGetMoDataSelection
(
op
)
¶
New in version R18.020.
Retrieves the MoGraph clones selection.
Parameters: |
op
(
c4d.BaseList2D
) – Can be either a MoGraph Selection tag or an object with a MoGraph Selection tag.
|
---|---|
Return type: |
c4d.BaseSelect
|
Returns: | The clones selection. |
c4d.modules.mograph.
GeSetMoDataSelection
(
op
,
selection
)
¶
New in version R18.039.
Sets the MoGraph clones selection.
Parameters: |
|
---|---|
Return type: |
bool |
Returns: |
True if successful, otherwise False . |
c4d.modules.mograph.
GeGetMoDataWeights
(
op
)
¶
New in version R18.020.
Retrieves the MoGraph clones weights.
Parameters: |
op
(
c4d.BaseList2D
) – Can be either a MoGraph Weightmap tag or an object with a MoGraph Weightmap tag.
|
---|---|
Return type: | list of float |
Returns: | The clones weights. |
c4d.modules.mograph.
GeSetMoDataWeights
(
op
,
weights
)
¶
New in version R18.039.
Sets the MoGraph clones weights.
Parameters: |
|
---|---|
Return type: |
bool |
Returns: |
True if successful, otherwise False . |
c4d.modules.mograph.
GetMoDataDefault
(
id
)
¶
Get the default value for the specified
MoData
ID.
Parameters: |
id
(
int
) –
The
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Return type: | any | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Returns: | The default value. |
c4d.modules.mograph.
GetMoDataDefaultType
(
id
)
¶
Get the default value for the specified
MoData
ID.
Parameters: |
id
(
int
) –
The
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Return type: | int | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Returns: |
The default type:
|