Re: [osg-users] [osgPlugins] FBX textures file names is UTF8

2012-12-26 Thread Alline Betts
Very fine and helpful post. I like to use 3D max. So fine. -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=51684#51684 ___ osg-users mailing list osg-users@lists.openscenegraph.org

Re: [osg-users] [osgPlugins] FBX textures file names is UTF8

2012-12-05 Thread Felix Hu
Actually, the official Autodesk documents says the same: http://download.autodesk.com/global/docs/fbxsdk2012/en_us/files/GUID-D3844B1D-4E74-4C64-AD79-14B00EB1FE4-42.htm FBX SDK uses UTF-8 strings internally. and you should use KString and its macros to deal with strings in fbx sdk.

[osg-users] [osgPlugins] FBX textures file names is UTF8

2012-12-05 Thread Felix Hu
According to my tests, by exporting fbx files from 3DS Max, the external texture file names stored in the fbx file is actually UTF-8. It means, KFbxFileTexture::GetFileName returns an UTF-8 string, if the string contains complex characters like Chinese/Janpanese/Korean etc, osgDB::readImageFile()

Re: [osg-users] [osgPlugins] FBX textures file names is UTF8

2012-12-05 Thread Felix Hu
OK, I tried modify the file \src\osgPlugins\fbx\fbxMaterialToOsgStateSet.cpp and changed this function, it seems to work ! but I guess there are other places to change right ? actually any string got from fbx sdk should be converted from utf8 to ansi before used in osg. Code:

Re: [osg-users] [osgPlugins] FBX textures file names is UTF8

2012-12-05 Thread Felix Hu
Well, I just found this option OSG_USE_UTF8_FILENAMES, so I guess my changes are not needed if this option is on, but still better when its off, so, may still worth considering. :P -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=51089#51089