Understading the folder structure
If you look inside your Atoms installation you will notice a python and scripts folder.
The python folder contains the Atoms core compiled libraries to interact with Atoms (i.e. _AtomsMaya.pyd, _Atoms.pyd, etc.). To know which methods for each library are available please have a look at the C++ documentation.
The script folder contains the python scripts that are used to run the exporters, UIs, etc. If you are planning to integrate Atoms into your pipeline, knowing the content of some of these files will help you greatly.
UIs
In Atoms Crowd we try to reuse the same python code between different applications as much as possible.
For this reason all the exporter UIs are shared between applications and you can find them under "Atoms/exporters". You will find files with same name under the exporters folder of each 3D app python folder (i.e. AtomsMaya, AtomsHoudini). Those are used for launching each UI from inside your 3D application.
Other UIs are stored under "Atoms/ui", the Atoms UI is the mainui.py file while Atoms Group UI (what you see in the attribute editor in maya ) is the nodeui.py.
If you have a look at those files you'll see they are all keeping a reference to a host bridge. That is what makes the UIs talk with your 3D application. Please read below to know more about host bridges.
You can find other app specific tools, such as the animation rig retargeting tool, under the tools folder in the 3D app python folder. In this case you would be looking into "AtomsMaya/ui/tools".
All the app specific tools may or may not have a reference to a host bridge.
Host Bridge
If you look in the "AtomsMaya/hostbridge" folder, you'll find few python files. Each one of them is used in different contexts. You will find the same files under "AtomsHoudini/hostbridge".
The atomsnode.py contains the host bridge used by the Atoms UI.
The atomsgroup.py contains the host bridge used by the Atoms Group UI.
The commands.py contains the host bridge used by the exporters.
The variationbuilder.py contains the host bridge used by the variation builder.
Depending on which application you are working with, some of the methods might not be implemented as we did not need them in python when integrating Atoms.
So let's say you are trying to understand how to export a skeleton config. First you would have a look at the skeleton exporter and see which host bridge method is calling. Then you should go inside the command.py hostbridge of your application and search for that method.
You can copy the code from there or call directly the host bridge methods if you like.
Copyright © 2017, Toolchefs LTD.