As of FBX version 7500, the element metadata values are 64-bit as
opposed to being 32-bit in earlier versions.
FBX exported by Blender are currently always FBX version 7400, so the
fbx binary writing code was only set up to handle writing version 7400
files and earlier.
The json2fbx.py script however, can create FBX files with whatever
version is defined in the .json. Because the script uses the same code
as exporting an FBX with Blender, it would create invalid FBX version
7500+ files with 32-bit metadata values. Attempting to read one of these
files with Blender or external software would cause errors.
This patch sets global variables based on the version of the file being
exported and then uses those global variables when exporting to export
with the correct metadata values for the file version being exported.
This process is very similar to what is already done in parse_fbx.py
when importing FBX files.
There are no expected changes to FBX files exported by Blender with this
patch, only the json2fbx.py script should be affected.