25 #ifndef OSD_OMP_SMOOTHNORMAL_CONTROLLER_H
26 #define OSD_OMP_SMOOTHNORMAL_CONTROLLER_H
28 #include "../version.h"
30 #include "../osd/nonCopyable.h"
31 #include "../osd/cpuSmoothNormalContext.h"
33 namespace OpenSubdiv {
34 namespace OPENSUBDIV_VERSION {
49 template<
class VERTEX_BUFFER>
51 VERTEX_BUFFER * iBuffer,
int iOfs,
52 VERTEX_BUFFER * oBuffer,
int oOfs ) {
54 if (not context)
return;
56 context->Bind(iBuffer, iOfs, oBuffer, oOfs);
58 _smootheNormals(context);
74 using namespace OPENSUBDIV_VERSION;
78 #endif // OSD_OMP_SMOOTHNORMAL_CONTROLLER_H
~OmpSmoothNormalController()
Destructor.
OmpSmoothNormalController()
Constructor.
void SmootheNormals(CpuSmoothNormalContext *context, VERTEX_BUFFER *iBuffer, int iOfs, VERTEX_BUFFER *oBuffer, int oOfs)
Computes smooth vertex normals.
void Synchronize()
Waits until all running subdivision kernels finish.