2012-12-17 02:11 AM
// Get the UVs for vert1 API_TexCoordPars texCoordPars; API_UVCoord uvCoord; texCoordPars.bodyIdx = iBody; texCoordPars.elemIdx = elementId; texCoordPars.pgonIndex = iPoly; texCoordPars.surfacePoint.x = comp3D.vert.x; texCoordPars.surfacePoint.y = comp3D.vert.y; texCoordPars.surfacePoint.z = comp3D.vert.z; err = ACAPI_Goodies (APIAny_GetTextureCoordID, &texCoordPars, &uvCoord, NULL);Thanks in advance.
2012-12-17 11:30 AM
paulk wrote:I haven't used the Rendering kit, but I'm not certain that you can get anything beyond the texture
I am using the Rendering Dev Kit, and wish to obtain the texturemap FILENAME for a give material. Does anyone know how to do this for a given GSModeler::Polygon?
paulk wrote:Try using the ModelAccess API instead. I haven't tested
Also, I have been trying to use ACAPI_Goodies (APIAny_GetTextureCoordID, &texCoordPars, &uvCoord, NULL) to get UV coordinates
2012-12-17 10:11 PM
Retrieve the GSModeler::Texture for the material and call its GetName method.This only gives me the texture name (like "concrete"). I need the source filename (ie. directoryname + concrete.jpg).
Try using the ModelAccess API instead. I haven't tested APIAny_GetTextureCoordID, but the GetTextureCoordinate method of the GSModeler::Polygon class does the trick.If I use the ModelAccess API instead - then I cannot get the full filename of the texturemaps.
2012-12-18 06:43 AM
2012-12-18 11:30 AM
paulk wrote:That's not necessarily the same thing. For example, objects can contain embedded texture maps and create material definitions on the fly that won't be picked up by
1) The can get the full path name using the GSModeler API by iterating through scene materials with ACAPI_Attribute_Get and matching the material name.