Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

Texture Disposal in Spine?
Started by rlowenstein Dec 07 2016 04:27 PM

4 replies to this topic
spine atlas texture runtime removal clean
[TOPIC CONTROLS]
This topic has been archived. This means that you cannot reply to this topic.
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

rlowenstein

[GLOBAL: userInfoPane.html]
rlowenstein
  • Observer

  • 23 posts
  • Corona SDK

Does anyone know how to dispose of a Spine texture once it's been loaded in (like after a scene change)?  The TextureAtlas:dispose() method in the lua runtime is incomplete...



[TOPIC: post.html]
#2

kilopop

[GLOBAL: userInfoPane.html]
kilopop
  • Contributor

  • 258 posts
  • Corona SDK

If you have placed the spine object in a display object then remove that as usual. Also need to remove the runtime eventListener that updates skeleton animations.



[TOPIC: post.html]
#3

rlowenstein

[GLOBAL: userInfoPane.html]
rlowenstein
  • Observer

  • 23 posts
  • Corona SDK

Hey that totally works! Do I need to worry about all of the Lua memory, or does that just get garbage collected eventually? Thanks!!!!!

[TOPIC: post.html]
#4

kilopop

[GLOBAL: userInfoPane.html]
kilopop
  • Contributor

  • 258 posts
  • Corona SDK

Depends how you're dealing with your variables and tables. As for spine, as long as it is local to your scene everything from that is disposed on a new scene change. Spine does use a few globals though I've noticed.



[TOPIC: post.html]
#5

rlowenstein

[GLOBAL: userInfoPane.html]
rlowenstein
  • Observer

  • 23 posts
  • Corona SDK

Thanks, kilopop!!


[topic_controls]
[/topic_controls]