Current document in Team Render



  • I'm using BaseDocument
    *doc = GetActiveDocument();
    to get the document we are using and

    const UnitScaleData docScaleData = (const UnitScaleData)doc->GetDataInstance()->GetCustomDataType(DOCUMENT_DOCUNIT, CUSTOMDATATYPE_UNITSCALE);
    Float otherScale = 1.0f;
    docScaleData->GetUnitScale(otherScale, docunit);

    to get the units in the scene, unfortunatly GetActiveDocument() returns a doc named "Untitled 1" in Team Render rendering process so I cannot get the scene units.

    Is there any way to get the current scene or units during a Team Render rendering session?



  • Hi Victor, thanks for reaching us.

    With regard to the issue mentioned, please provide me with some more detail about the context in which you're attempting to retrieve the document being rendered.
    Waiting for your additional details, please beware as pointed out in the Access section of the BaseDocument Manual that GetActiveDocument() just returns the document being displayed in the editor. In the context of TeamRender you definitively don't have to make use of it but depending on the context you're, you have to select a different option.

    Looking forward further info, give best.

    Riccardo



  • @r_gigante It was about updating an object during the render process but I used a different aproach just by sending the object's doc to that function so I think it could be solved already.


Log in to reply