using namespace HDK_Sample;
void
{
"hdk_dualstar",
"Dual Star",
1,
1,
0,
0,
2));
}
static PRM_Name negativeName(
"nradius",
"Negative Radius");
};
1,
&fiveDefault,
0,
),
};
{
}
{
}
SOP_DualStar::~SOP_DualStar() {}
{
}
void
{
int divisions = DIVISIONS(now)*2;
int plane = ORIENT();
int negradius = NEGRADIUS();
float tx = CENTERX(now);
float ty = CENTERY(now);
float tz = CENTERZ(now);
int xcoord, ycoord, zcoord;
switch (plane)
{
case 0:
xcoord = 0;
ycoord = 1;
zcoord = 2;
break;
case 1:
xcoord = 1;
ycoord = 2;
zcoord = 0;
break;
case 2:
xcoord = 0;
ycoord = 2;
zcoord = 1;
break;
}
if (divisions < 4)
{
divisions = 4;
}
if (boss.wasInterrupted())
{
return;
}
for (int i = 0; i < divisions; i++)
{
if (boss.wasInterrupted())
break;
float tmp = (
float)i * tinc;
float rad = (i & 1) ? XRADIUS(now) : YRADIUS(now);
if (!negradius && rad < 0)
rad = 0;
pos(xcoord) = SYScos(tmp) * rad + tx;
pos(ycoord) = SYSsin(tmp) * rad + ty;
pos(zcoord) = 0 + tz;
}
}
{
}