Point cloud from a bgeo file?

   590   1   0
User Avatar
Member
12 posts
Joined: June 2018
Offline
We are having trouble extracting the point cloud from one of our PDG Generated bgeo files.
The bgeo should contain volumes and a point cloud, but we are only getting the volumes as a result.


Our cook options are:
cookOptions.clearErrorsAndWarnings = true;
cookOptions.cookTemplatedGeos = true;
cookOptions.curveRefineLOD = 8.0f;
cookOptions.extraFlags = 0;
cookOptions.handleBoxPartTypes = false;		
cookOptions.handleSpherePartTypes = false;
cookOptions.maxVerticesPerPrimitive = -1;
cookOptions.packedPrimInstancingMode = HAPI_PACKEDPRIM_INSTANCING_MODE_DISABLED;
cookOptions.refineCurveToLinear = false;
cookOptions.splitGeosByGroup = false;
cookOptions.splitPointsByVertexAttributes = false;

The code to extract the data from the bgeo looks like:
HAPI_CreateNode(&session->m_Session, -1, "SOP/file", "loadbgeo", true, &idFileNode);
HAPI_GetDisplayGeoInfo(&session->m_Session, idFileNode, &geoInfo);
HAPI_GetParmIdFromName(&session->m_Session, idDisplayNode, "file", &idFileParm);
HAPI_SetParmStringValue(&session->m_Session, idFileNode, szPath, idFileParm, 0);

HAPI_CookNode(&session->m_Session, idNode, nullptr);
int cookStatus;
do
{
	hResult = HAPI_GetStatus(&session->m_Session, HAPI_STATUS_COOK_STATE, &cookStatus);
} while (cookStatus > HAPI_STATE_MAX_READY_STATE && hResult == HAPI_RESULT_SUCCESS);



When we use HAPI_GetPartInfo to get the results, we just get 22 volumes with each having 1 face, 1 vert, and 1 point.

Image Not Found
Edited by LithLoren - Sept. 16, 2019 13:38:28

Attachments:
terrain_ScatterVeg_1_2.bgeo.sc (7.1 MB)

User Avatar
Member
12 posts
Joined: June 2018
Offline
This appears to only be an issue when launching from visual studio.
I’ll see if I can reproduce this issue with a smaller sample program.
  • Quick Links