<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: FbxAxisSystem::Max.ConvertScene(pScene) does not change the axis in FBX2019. in FBX Forum</title>
    <link>https://forums.autodesk.com/t5/fbx-forum/fbxaxissystem-max-convertscene-pscene-does-not-change-the-axis/m-p/8579890#M1214</link>
    <description>&lt;P&gt;Hi&lt;/P&gt;
&lt;P&gt;I am using existing code that convert an FBX model to OpenScene graph.&amp;nbsp; I am testing on different models (some are Z up and other Y up)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The code I am using as a function to to evaluate the transform. I will check if I can change that code with&amp;nbsp;FbxNode::EvaluateLocal/GlobalTransform() .&amp;nbsp; I don't have time this week but I will try it next week.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks for helping.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Patrick&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 07 Feb 2019 14:08:40 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2019-02-07T14:08:40Z</dc:date>
    <item>
      <title>FbxAxisSystem::Max.ConvertScene(pScene) does not change the axis in FBX2019.0</title>
      <link>https://forums.autodesk.com/t5/fbx-forum/fbxaxissystem-max-convertscene-pscene-does-not-change-the-axis/m-p/8513588#M1210</link>
      <description>&lt;P&gt;I am importing an FBX model in a scene (Y up) and trying to convert to Z up and it's not working.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The only thing it seem to change when I call&amp;nbsp;FbxAxisSystem::Max.ConvertScene(pScene)&amp;nbsp; is what this call return&amp;nbsp;&lt;/P&gt;
&lt;P&gt;FbxAxisSystem::EUpVector eUp = fbxAxis.GetUpVector(upSign);&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;here is part of the code&lt;/P&gt;
&lt;P&gt;pSdkManager-&amp;gt;SetIOSettings(FbxIOSettings::Create(pSdkManager, IOSROOT));&lt;/P&gt;
&lt;P&gt;FbxScene* pScene = FbxScene::Create(pSdkManager, "");&lt;/P&gt;
&lt;P&gt;std::string utf8filename(osgDB::convertStringFromCurrentCodePageToUTF8(filename));&lt;BR /&gt;FbxImporter* lImporter = FbxImporter::Create(pSdkManager, "");&lt;/P&gt;
&lt;P&gt;Importer-&amp;gt;Initialize(utf8filename.c_str(), -1, pSdkManager-&amp;gt;GetIOSettings());&lt;/P&gt;
&lt;P&gt;lImporter-&amp;gt;Import(pScene);&lt;/P&gt;
&lt;P&gt;FbxAxisSystem::Max.ConvertScene(pScene);&amp;nbsp; &amp;nbsp;&amp;lt;&amp;lt;-- does nothing&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Any suggestion ? This call seem to work in older FBX SDK ... Any plan for a SDK patch soon ?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Thu, 10 Jan 2019 16:21:52 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fbx-forum/fbxaxissystem-max-convertscene-pscene-does-not-change-the-axis/m-p/8513588#M1210</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2019-01-10T16:21:52Z</dc:date>
    </item>
    <item>
      <title>Re: FbxAxisSystem::Max.ConvertScene(pScene) does not change the axis in FBX2019.</title>
      <link>https://forums.autodesk.com/t5/fbx-forum/fbxaxissystem-max-convertscene-pscene-does-not-change-the-axis/m-p/8575350#M1211</link>
      <description>&lt;P&gt;My aplogies but I don't quite understand your issue. I just tried and my incoming scene did get converted from a Y-Up to a Z-Up system. For your information, the FbxAxisSystem works on the "first level" children of the scene. As you know, an Fbx Scene is composed like:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;FbxScene&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; FbxRootNode()&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; FirstLevelChild1 (FbxNode)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Child2 (FbxNode)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Child3 (FbxNode)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; FirstLevelChild2 (FbxNode)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [attribute (FbxMesh)]&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ...&lt;/P&gt;
&lt;P&gt;Therefore, the "conversion" is applied to FirstLevelChild1 and FirstLevelChild2&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In a concrete example&lt;/P&gt;
&lt;P&gt;Y-Up:&lt;/P&gt;
&lt;PRE&gt;	Model: 35648528, "Model::BBallPlayer:Root", "Null" {
		Version: 232
		Properties70:  {
			P: "ScalingMin", "Vector3D", "Vector", "",1,1,1
			P: "Show", "bool", "", "",0
			P: "NegativePercentShapeSupport", "bool", "", "",0
			P: "DefaultAttributeIndex", "int", "Integer", "",0
&lt;/PRE&gt;
&lt;P&gt;Converted to Z-Up:&lt;/P&gt;
&lt;PRE&gt;	Model: 35386384, "Model::BBallPlayer:Root", "Null" {
		Version: 232
		Properties70:  {
&lt;FONT color="#FF00FF"&gt;			P: "PreRotation", "Vector3D", "Vector", "",90,-0,0
			P: "RotationActive", "bool", "", "",1&lt;/FONT&gt;
			P: "ScalingMin", "Vector3D", "Vector", "",1,1,1
			P: "Show", "bool", "", "",0
			P: "NegativePercentShapeSupport", "bool", "", "",0
			P: "DefaultAttributeIndex", "int", "Integer", "",0&lt;/PRE&gt;</description>
      <pubDate>Tue, 05 Feb 2019 21:26:03 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fbx-forum/fbxaxissystem-max-convertscene-pscene-does-not-change-the-axis/m-p/8575350#M1211</guid>
      <dc:creator>regalir</dc:creator>
      <dc:date>2019-02-05T21:26:03Z</dc:date>
    </item>
    <item>
      <title>Re: FbxAxisSystem::Max.ConvertScene(pScene) does not change the axis in FBX2019.</title>
      <link>https://forums.autodesk.com/t5/fbx-forum/fbxaxissystem-max-convertscene-pscene-does-not-change-the-axis/m-p/8575388#M1212</link>
      <description>&lt;P&gt;My goal is not to edit the FBX and change the coordinate system in the FBX.&amp;nbsp; I am using the FBX SDK to read the nodes of an FBX model.&amp;nbsp; When the model was saved with the Z-Up coordinate system everything work fine. Now if I read Y-Up model I should be able to use the function&amp;nbsp;FbxAxisSystem::Max.ConvertScene(pScene) on the imported scene and the Y-UP should be returned as a Z-Up model when I read the nodes but nothing seem to happen with the function&amp;nbsp;FbxAxisSystem::Max.ConvertScene(pScene) !&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Have you tried some FBX SDK code with that function ?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Patrick&lt;/P&gt;</description>
      <pubDate>Tue, 05 Feb 2019 21:38:22 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fbx-forum/fbxaxissystem-max-convertscene-pscene-does-not-change-the-axis/m-p/8575388#M1212</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2019-02-05T21:38:22Z</dc:date>
    </item>
    <item>
      <title>Re: FbxAxisSystem::Max.ConvertScene(pScene) does not change the axis in FBX2019.</title>
      <link>https://forums.autodesk.com/t5/fbx-forum/fbxaxissystem-max-convertscene-pscene-does-not-change-the-axis/m-p/8577146#M1213</link>
      <description>&lt;P&gt;In my post I did not implied that you edit the FBX files!&lt;/P&gt;
&lt;P&gt;I am pretty sure you understand well how to use the FbxAxisSystem but, just so we speak the same language, let me explain it again.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;When you call FbxAxisSystem::ConvertScene() on any given scene, the first thing the function does is to check what is the axis system defined in the scene. If it is the same as the one used to call ConvertScene, then nothing happens since the scene is already in the desired system. However, if different, then what I explained in the previous post applies. So, if your incoming scene is in Y-Up and you call FbxAxisSystem::Max.ConvertScene(), the scene own axis system is going to be changed to Z-Up and the appropriate transforms applied to the "first level children" (as I explained). The code snippets I attached previously are showing the result of the following steps:&lt;/P&gt;
&lt;OL style="list-style-position: inside;"&gt;
&lt;LI&gt;import a Y-Up scene&lt;/LI&gt;
&lt;LI&gt;call FbxAxisSystem::Max.ConvertScene(lScene)&lt;/LI&gt;
&lt;LI&gt;export lScene&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;This is the code I'm using (note that LoadScene simply end up calling Import())&lt;/P&gt;
&lt;PRE&gt;    lResult = LoadScene(lSdkManager, lScene, lFilePath.Buffer());
    if( lResult )
    {		
        FbxAxisSystem::Max.ConvertScene(lScene);
        FbxAxisSystem sas = lScene-&amp;gt;GetGlobalSettings().GetAxisSystem();
        FbxAxisSystem::ECoordSystem cs = sas.GetCoorSystem();
        int sign = 0;
        FbxAxisSystem::EFrontVector fv = sas.GetFrontVector(sign);
        FbxAxisSystem::EUpVector uv = sas.GetUpVector(sign);
        lResult = SaveScene(lSdkManager, lScene, lOutFile.Buffer(), 1);
    }&lt;/PRE&gt;
&lt;P&gt;while the scene is Y-Up (skip over the call ConvertScene())&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;cs = eRightHanded&lt;/P&gt;
&lt;P&gt;fv = eParityOdd&amp;nbsp;&amp;nbsp; sign=1&lt;/P&gt;
&lt;P&gt;uv = eYAxis&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; sign=1&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;with the call to ConvertScene():&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;cs = eRightHanded&lt;/P&gt;
&lt;P&gt;fv = eParityOdd&amp;nbsp;&amp;nbsp; sign=-1&lt;/P&gt;
&lt;P&gt;uv = eZAxis&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; sign=1&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;and in the file we see the pre rotation value.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;After this is done, you can query your nodes PreRotation and see if it does indeed contains a (-90,0,0). I can see two circumstances where you can have the impression that this does not work.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;a) your incoming scene is in fact already defined as Z-up (not very likely but ... ;-))&lt;/P&gt;
&lt;P&gt;b) your manipulation of the scene data afterword does not take into consideration the PreRotation property. Do you evaluate your transform using FbxNode::EvaluateLocal/GlobalTransform() or are you computing it directly from the LclTranslation, LclRotation and LclScaling and maybe forgot the Pre/Post rotation values?&lt;/P&gt;</description>
      <pubDate>Wed, 06 Feb 2019 15:11:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fbx-forum/fbxaxissystem-max-convertscene-pscene-does-not-change-the-axis/m-p/8577146#M1213</guid>
      <dc:creator>regalir</dc:creator>
      <dc:date>2019-02-06T15:11:49Z</dc:date>
    </item>
    <item>
      <title>Re: FbxAxisSystem::Max.ConvertScene(pScene) does not change the axis in FBX2019.</title>
      <link>https://forums.autodesk.com/t5/fbx-forum/fbxaxissystem-max-convertscene-pscene-does-not-change-the-axis/m-p/8579890#M1214</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;
&lt;P&gt;I am using existing code that convert an FBX model to OpenScene graph.&amp;nbsp; I am testing on different models (some are Z up and other Y up)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The code I am using as a function to to evaluate the transform. I will check if I can change that code with&amp;nbsp;FbxNode::EvaluateLocal/GlobalTransform() .&amp;nbsp; I don't have time this week but I will try it next week.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks for helping.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Patrick&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 07 Feb 2019 14:08:40 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fbx-forum/fbxaxissystem-max-convertscene-pscene-does-not-change-the-axis/m-p/8579890#M1214</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2019-02-07T14:08:40Z</dc:date>
    </item>
    <item>
      <title>Re: FbxAxisSystem::Max.ConvertScene(pScene) does not change the axis in FBX2019.</title>
      <link>https://forums.autodesk.com/t5/fbx-forum/fbxaxissystem-max-convertscene-pscene-does-not-change-the-axis/m-p/8587661#M1215</link>
      <description>&lt;P&gt;OK found the error in the pre/post rotation osg code ... will try to use FbxAxisSystem::ConvertScene()&amp;nbsp;and FbxNode::EvaluateLocal/GlobalTransform() at some point.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Mon, 11 Feb 2019 16:12:13 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fbx-forum/fbxaxissystem-max-convertscene-pscene-does-not-change-the-axis/m-p/8587661#M1215</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2019-02-11T16:12:13Z</dc:date>
    </item>
    <item>
      <title>Re: FbxAxisSystem::Max.ConvertScene(pScene) does not change the axis in FBX2019.</title>
      <link>https://forums.autodesk.com/t5/fbx-forum/fbxaxissystem-max-convertscene-pscene-does-not-change-the-axis/m-p/12764212#M1216</link>
      <description>&lt;P&gt;Hello, Im having the exact same problem after calling the ConvertScene function, the nodes are not being updated with the correspondent prerotation. I see that after I call the function SaveScene, even if I do not call LoadFile again, the scene gets updated properly. Can you explain maybe why the save scene function is needed in order to update the scene?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2024 05:51:57 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fbx-forum/fbxaxissystem-max-convertscene-pscene-does-not-change-the-axis/m-p/12764212#M1216</guid>
      <dc:creator>juan.francoCL6TQ</dc:creator>
      <dc:date>2024-05-10T05:51:57Z</dc:date>
    </item>
  </channel>
</rss>

