Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo
If I want to export U3D data to some other format, should I used Authormesh data (i.e. faces, positions, texcoords, and materials) or Meshgroup data?
AuthorMesh is easier to export, but the problem is that it lacks shader info (it only has material ID which does not contain texture info). So is there anyway to use AuthorMesh to get texture info of the faces?
Thanks in advance for the answers! please let me know if my question is not so clear.
Use IFXCoreServices::GetSceneGraph to get a reference to the IFXSceneGraph interface (IID_IFXSceneGraph). You can then get information about each of the shaders, materials and textures by using the IFXSceneGraph::GetPalette function to obtain the shader, material and/or texture palettes. With each palette you can obtain the desired entry with the ID associated with each mesh in a model's mesh group. The entries in each palette will depend upon the associated palette type (IID_IFXShaderLitTexture, IID_IFXMaterialResource, IID_IFXTextureObject).
BTW: It's been many years since I've looked at this stuff. I refreshed my memory about some of the specifics here by using the doxygen HTML overviews and how-tos in it. Unfortunately, the topic of what main interface IIDs are stored in each type of palette wasn't clearly identified. To quickly get that, I found reviewing the IDTF (intermediate data format) converter helper DebugInfo.cpp file helpful.
CE Software Engineering
Digital Home Group
The views expressed above are my own and not those of Intel
Thanks Timothy for the help, but seems my question was not so clear, so let me try to clarify it a bit:
I want to export a U3D file to some other format. I'm reading authormesh data, and export everything with almost no problems. the only problem that I have is with textures. basically, authormesh does not contain texture information, the only way I'm aware of to get texture info is to do the following: use the Meshgroup -> get the shader list of one of the elements -> get the shaders from the shader list -> and finally get the texture from the shader, the problem with this procedure is that I need to use Meshgroup instead of Authormesh, which I'm trying to avoid.
now, my question remains the same: is there a way to use Authormesh to get info about the texture being used in that mesh? another related quesiton: in U3D, how do you map faces in Authormesh to elements in Meshgroup? Your help is highly appreciated.
month after month, and I'm still not able to get an answer to my basic question. Is there anybody who can help here?
Fix the code, I think this is the bug CIFXTextureObject::GetRenderImage should return struct with texture data.