I’m Ayush Satpathy, a B.Tech student in Computer Science and Engineering at the National Institute of Engineering, Mysore. I have been actively exploring Synfig’s codebase as part of my open-source journey and have started working on implementing an exporter for Spine JSON animations.
So far, I have implemented a menu option for exporting to Spine JSON and have raised a PR where clicking this option downloads a hardcoded JSON file for now. While this is a starting point, I want to refine the approach and ensure that the implementation aligns well with Synfig’s architecture.
I am considering two possible approaches:
Keeping it as a menu option (which I have already implemented as a basic structure)
Implementing it as a plugin, similar to how the Lottie exporter works.
I have gone through the codebase, but I would love some guidance on how the plugin-based implementation would look in practice. Specifically, what steps would be required to integrate it cleanly into Synfig’s existing structure?
I’ve implemented the Spine export as a plugin, and right now, it supports downloading a hardcoded JSON file. The next step is to retrieve the actual bone and skeleton animation data from Synfig’s structure, and I was wondering if anyone could help point me in the right direction.
I went through the Lottie exporter source files to understand how it retrieves this kind of data, but I couldn’t pinpoint exactly where the fetching happens. If anyone is familiar with this, could you direct me to the files in the Lottie exporter that handle bone data parsing? It would really help me figure out how to extract the necessary information for the Spine exporter.
Synfig saves the file to disk and calls the plugin script (currently only Python is supported), passing it the path to this file.
The plugin processes the file and returns control to Synfig.
To work with this, you’ll need to understand the Synfig file format.
I’ll try to clarify tomorrow where to find the Synfig file format documentation and will reply here.
You need to start working on the proposal now (the deadline is April 8th).
In the proposal, mark these points as requiring clarification.
Yes, I went through the XML content of a sample .sif file and understood how the data is being stored. Then I explored the code in plugins/lottie-exporter/common/Param.py and lottie-exporter/common/Canvas.py, which helped me understand how different pieces of information are parsed for the Lottie exporter.
By identifying the specific code related to bone parsing, I was able to implement a basic bone parser for the Spine exporter. I then mapped the parsed content into the Spine JSON format. The core functionality is now working, but I’m currently troubleshooting a few errors here and there. I’m working on fixing them right now and will update you as soon as I’ve resolved the issues.
Hi community,
I wanted to share a quick update on the spine-exporter plugin for Synfig. Right now, the plugin reads a Synfig .sif file, extracts the bone hierarchy along with its global transformations, and exports everything into a Spine-compatible JSON file. I’ve also updated the build files (CMakeLists.txt and Makefile.am) for smoother installation.
I’ve raised a PR with these updates. The plugin works well in standard cases, although there are some intermittent edge-case issues that I plan to address in future updates.
Any feedbak regarding the same would be helpful. @ice0@rodolforg
Hi community!
Just wanted to give a quick update on what I’ve worked on over the past week:
I picked up an issue and raised PR #3562, where I added a width parameter to ensure it behaves correctly when drawing spline tangents in the Advanced Outline layer.
I’ve also been diving deeper into how the Spine exporter works. Specifically, I’ve been exploring the different parameters involved in the spine_export file and figuring out how each one can be parsed from the .sif file.
Along with that, I started understanding how bones are implemented in Synfig. I had already built a basic bone parser earlier (as mentioned in my last update), and this week I’ve been building on top of that — figuring out how to extract more bone-related data that will be essential for exporting to the Spine JSON format.
Hi community,
In the past week(+3😅), i’ve worked on implementation the feature as mentioned in the #PR. It included adding an option for the default interpolation setting in the documents page.
Regarding the Spine Exporter,
This week, I explored how interpolation is handled internally in synfig by studying this article and revisiting my work on default interpolation from #PR3573. I learned how different interpolation types like linear, clamped, etc behave between keyframes. This understanding is important because, while synfig has multiple interpolation modes, spine mainly uses Bezier curves — so mapping them correctly will ensure smooth animation exports.
Thanks!