onlyoneHai
onlyoneHai
About Me
Connect
LOCATION
Not Specified
ウェブサイト
Houdini Engine
Availability
Not Specified
Recent Forum Posts
About use sprintf vex function converts a int to a string. 2009年4月22日3:13
hi all, i use vex sop add a string attribute(neighbourpoints) to default grid, but the result isnt expected, every point attribute have a number 10, like that,
any help?
thanks,
sop
vopsop1()
{
int count = getneighbourcount(ptnum, 0);
string temp = “”;
int test=0;
int i;
for(i=0; i < count; i +=1 )
{
int neighptnum = getneighbour(ptnum, i, 0);
temp+=sprintf(“%d ”,neighptnum);
test+=neighptnum;
}
printf(“%s ”,test);
addattribute(“neighbourpoints”, temp);
}
the “test” variable export is right:
11 13 16 19 22 25 28 31 34 27 31 44 48 …
any help?
thanks,
sop
vopsop1()
{
int count = getneighbourcount(ptnum, 0);
string temp = “”;
int test=0;
int i;
for(i=0; i < count; i +=1 )
{
int neighptnum = getneighbour(ptnum, i, 0);
temp+=sprintf(“%d ”,neighptnum);
test+=neighptnum;
}
printf(“%s ”,test);
addattribute(“neighbourpoints”, temp);
}
the “test” variable export is right:
11 13 16 19 22 25 28 31 34 27 31 44 48 …
Python for curve expression 2009年3月19日7:46
Right click Coordinates Parameter first, select expression->toggle expression, then enter the code as follow.
a=' ‘
for (x,y,z) in zip(range(10),range(10),range(10)):
a+=’%f,%f,%f ' %(x,y,z)
return a
a=' ‘
for (x,y,z) in zip(range(10),range(10),range(10)):
a+=’%f,%f,%f ' %(x,y,z)
return a
How to export multiple different Channels in CHOPS 2009年3月15日22:32
right click,select Export Set Scope,