• RuntimesBugs
  • Latest github runtime examples/spine-glfw

Hello!

We're considering adding Spine to our production toolset/pipeline.

Doing some initial technical evaluation around spine-glfw example there was no success passing past json.readSkeletonDataFile(...). Apparently, it was not finding some 'region' data while executing RegionAttachment *AtlasAttachmentLoader::newRegionAttachment(...) in AtlasAttachmentLoader.cpp - exactly the 'crosshair' region.

Out of curiosity we tried other data files, like 'alien-ess.json', 'owl-pro.json' etc - but none worked ending with error string like 'Uneable to read skeleton file'.

Is the runtime example broken for the moment or maybe the sample data files provided are incompatible/obsolete?
Can I get any pointers, please?

Thanks in advance!

Best,
Val

Related Discussions
...

It sounds like you are encountering issues with the spine-glfw example due to missing or incompatible data files. Here are a few pointers to help you troubleshoot and resolve the issue:

  1. Check Data File Compatibility: Ensure that the JSON data files you are using are compatible with the version of the Spine runtime you have. Different versions of Spine export data in slightly different formats, and using mismatched versions can lead to errors. You can find more information on version compatibility here.

  2. Verify Atlas Files: The error you mentioned about the 'crosshair' region suggests that the corresponding atlas file might be missing or incorrectly referenced. Make sure that the atlas file is correctly placed and referenced in your project. The atlas file should contain the region definitions that the JSON file refers to.

  3. Use Provided Examples: The Spine runtime repository on GitHub provides various examples that are known to work with specific versions. You can find these examples here. Make sure to switch to the appropriate branch that matches the version of the Spine runtime you are using.

  4. Debugging: If the issue persists, you can debug into the spSkeletonJson_readSkeleton function to see where it fails. This might give you more insight into what is going wrong.

  5. Update Runtime: Ensure that you are using the latest version of the Spine runtime. Sometimes, bugs are fixed in newer versions, and updating might resolve your issue.

If you follow these steps and still encounter issues, it might be helpful to share the specific JSON and atlas files you are using, as well as any relevant code snippets, so that a more detailed investigation can be conducted.

Thank you - it helped indeed to check the Atlas files - now everything works as expected.
Too bad it wasn't clear enough for me to look into atlases by the error message returned (I assumed it was a json-only related issue).

Sorry for the troubles! None of the examples should be broken and all should work out of the box as per the instructions. Could you tell me on what OS with what compiler/IDE/editor/Cmake you tried to run the spine-glfw example? I'm a little puzzled how the skeleton file could be found but the atlas file couldn't.

  • robo a répondu à ça.

    Mario

    Hi Mario,

    Thanks for asking - it all works now.

    I'm using Windows, x64/Debug Build Config with VS2022 for the moment.

    As bot message suggested it was an Atlas loading related problem.
    The error message provided while parsing json didn't mention that the atlas didn't
    actually load at all.
    (Probably, there should be some status provided that the Atlas is loaded -
    for the moment it makes no errors at all if the file doesn't exist)

    Now when I know that everything seems to work as expected and I'm proceeding next with the evaluation.

    Best,
    Val