3.1 Polygon Support
Opened this issue · 4 comments
Any plans in the future to support the polygon packing feature for atlas export/import in the near future?
We'd like to do that. But AFAIK there's not way to set polygon sprites in Godot (yet).
Scratch some of the above. I just went back to it again this morning, and noticed there are generic exports with various data formats. Good stuff. X)
Yes - that's why we've added them. You should be able to modify the godot exporter easily.
Would be interested to see if you can make it work.
TexturePacker supports a quite big variety of frameworks - for us it's unfortunately not possible to dig deep into the frameworks without some insider knowledge... which you seem to have :)
Would be interested to see if you can make it work.
Outside of the context of a full fledged tool, it's not much to load the data into a Dictionary and set the data into a Polygon2D node. Several lines of code if I recall.
However, for anyone stopping by, it's not a good idea to use polygons like this in Godot. Polygon2D comes at a significant and quickly realized performance cost.
Upon investigating it, it's been a known issue for years.
~10x slower according to this person's benchmarking: godotengine/godot#19943
Sticking to rectangle region cuts from atlases is the better bet, and this may always be the case.