#include <hboost/shared_ptr.hpp>
using namespace HDK_Sample;
void
{
"hom_wave", "HOM Wave",
1, 1));
}
{
}
};
SOP_HOMWave::SOP_HOMWave(
{
}
void
SOP_HOMWave::cookWithHOM()
{
hboost::shared_ptr<HOM_Geometry> geo(
HOMdel(
dynamic_cast<HOM_SopNode*>(hou.
pwd()))->geometry());
double f = hou.
frame() * 0.03;
std::vector<HOM_ElemPtr<HOM_Point> > points = geo->points();
std::vector<double> pos_vector(3);
for (
int i=0;
i<points.size(); ++
i)
{
hboost::shared_ptr<HOM_Point> p(points[
i].myPointer);
hboost::shared_ptr<HOM_Vector3> pos_ptr(p->position());
pos[1] =
sin(pos[0] * 0.2 + pos[2] * 0.3 + f);
p->setPosition(pos_vector);
}
}