HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
12.5: Major Changes In The HDK

Table Of Contents

UT_RefArray deprecated

The class UT_RefArray has been deprecated. Please convert your code to use UT_Array by changing the calls of UT_RefArray::remove() to either findAndRemove() or removeIndex() as appropriate.

Threading in GA

In Houdini12.0, attribute pages could only be written to by a single thread. Not all algorithms were able to work within this restriction. The new class GA_AutoHardenForThreading will ensure that attributes are set-up to allow for write access across attribute page boundaries.

GEO_Detail::points() deprecated

In the ongoing effort to phase out GEO_Point, the method GEO_Detail::points() is now deprecated, among several others. Please see the GA Porting documentation for details on how to update HDK code to avoid GEO_Point by using, for example, GA_Offset.

Parallel & bulk geometry building

Adding primitives to a single detail from separate threads is still not safe, but GU_PrimPoly::buildBlock() has been introduced, which builds a set of polygons in parallel, so can be much faster than building polygons separately. GU_PrimPolySoup::build() is much faster still and much less memory intensive than using GU_PrimPoly, creating a GU_PrimPolySoup in parallel.

For adding many points at a time, GA_Detail::appendPointBlock(npoints) can be hundreds of times faster than using GA_Detail::appendPointOffset() in a loop. The point offsets created by appendPointBlock() are guaranteed to be in a contiguous block, so it just returns the first GA_Offset.

Namespace Conversion Functions

In Houdini 12.5, the operator type namespace conversion functions have been moved to the UT library. They used to be part of OP_OTLDefinition class, but were needed in the lower libraries, hence the move.

Selections and GU_Detail::incrementMetaCacheCount()

In earlier versions of Houdini, it was necessary to call GU_Detail::incrementMetaCacheCount() whenever you updated a geometry selection. In Houdini 12.5, you should call GU_Detail::incrementSelectionCacheCount() instead. GU_Detail::incrementMetaCacheCount() now signals a more serious change to the detail and will invalidate any cached selections.

Segment interface in VRAY_Procedural

In Houdini 12.5, it's possible to build deforming geometry using VRAY_Procedural directly in a single GU_Detail. The new appendGeometrySegment(), queryGeometrySegment(), and clearGeometrySegments() methods expose this interface for directly constructing and accessing the additional attributes used by mantra for multi-segment motion blur.

Variadic VEX_VexOp support

The VEX_VexOp interface for defining custom VEX functions now supports variadic signatures using the trailing + token in the signature.

VRAY_Volume native step size

Houdini 12.5 now uses a volume quality parameter to control the quality of volume rendering rather than directly manipulating step size. This simpler interface requires some additional functionality on the procedural to determine what step size corresponds to a quality of 1. The new VRAY_Volume::getNativeStepSize() pure virtual method provides this information, and needs to be implemented in all VRAY_Volume procedurals. Normally, this method should return the voxel size for voxel-based primitives.