Digital humans the art of the digital double
Ever wanted to know how digital doubles are created in the movie industry? This course will give you an insight into how it's done.
# 1 20-05-2015 , 10:29 AM
Falott's Avatar
Registered User
Join Date: Jan 2005
Location: vienna
Posts: 1,095

expression via mel

Ahoi,


I have a question concerning expressions via mel script. for some reason it seems to work - no errors... but no expression is being written into the locators. (i have particle called pLetter_Zero. then want to figure out the particle-count, create as many locators and place them to each particle via expression)

any input is much appreciated!



int $partCount = `getAttr ("pLetter_Zero" + ".count") `;

for( $i=0; $i<$partCount; $i++ ) {

spaceLocator -n ("pLocator" + $i);
string $particleLocator[] = `ls -sl`;

string $exprX = ($particleLocator[0] + ".tx");
string $exprY = ($particleLocator[0] + ".ty");
string $exprZ = ($particleLocator[0] + ".tz");


string $cmd = " \
float $particlePos[] = `particle -id $i -at worldPosition -q pLetter_Zero`; \n\
$exprX = $particlePos[0]; \n\
$exprY = $particlePos[1]; \n\
$exprZ = $particlePos[2]; \n\
";

expression -s $cmd;

}


everything starts and ends in the right place at the right time.

Last edited by Falott; 20-05-2015 at 11:07 AM.
# 2 20-05-2015 , 12:04 PM
Falott's Avatar
Registered User
Join Date: Jan 2005
Location: vienna
Posts: 1,095


everything starts and ends in the right place at the right time.
Posting Rules Forum Rules
You may not post new threads | You may not post replies | You may not post attachments | You may not edit your posts | BB code is On | Smilies are On | [IMG] code is On | HTML code is Off

Similar Threads