MCPcopy Create free account
hub / github.com/KhronosGroup/OpenCOLLADA / findGeometryId

Method findGeometryId

dae2ma/src/DAE2MAGeometryImporter.cpp:3075–3100  ·  view source on GitHub ↗

--------------------------------------------

Source from the content-addressed store, hash-verified

3073
3074 // --------------------------------------------
3075 const COLLADAFW::UniqueId* GeometryImporter::findGeometryId (
3076 const COLLADAFW::UniqueId& sourceId,
3077 const COLLADAFW::UniqueId& transformId,
3078 const COLLADAFW::UniqueId* controllerId )
3079 {
3080 // Handle controller
3081 const COLLADAFW::UniqueId* geometryId = 0;
3082 if ( controllerId && controllerId->isValid () )
3083 {
3084 // Get the geometryId of the current controller element.
3085 ControllerImporter* controllerImporter = getDocumentImporter ()->getControllerImporter ();
3086 GeometryImporter::MeshControllerData* meshControllerData = findMeshControllerDataByControllerAndTransformId ( sourceId, transformId );
3087 if ( meshControllerData == 0 )
3088 {
3089 std::cerr << "No meshControllerData exist for the current geometry and transform!" << std::endl;
3090 return 0;
3091 }
3092 geometryId = &meshControllerData->getGeometryId ();
3093 }
3094 else
3095 {
3096 geometryId = &sourceId;
3097 }
3098
3099 return geometryId;
3100 }
3101
3102 // --------------------------------------------
3103 const size_t GeometryImporter::findGeometryUvSetIndex (

Callers 2

createUVChoosersMethod · 0.80

Calls 3

getControllerImporterMethod · 0.80
getGeometryIdMethod · 0.80
isValidMethod · 0.45

Tested by

no test coverage detected