• Editor
  • [Feature Request] Masking

I agree, it would be awesome. The runtimes are really the limiting factor. The cheapest way to do clipping in OpenGL is probably a stencil buffer. The downsides are that it would have aliased edges and would cause two batch flushes. None of this matters for exporting video or images of course.

It's a good feature and I'd like for it to make it in, but there are lots of other things to do first.

Related Discussions
...

Yep totally understand. I made the post hoping to drum up support, but it looks like I might be in a minority on this one 😃

Thanks for the reply Nate. The community support here is top notch. Keep up the great work.

12 gün sonra

Yes Nate, make another Kickstarter project! You have my support too...

It's actually something we talked about a long time ago before this thread even came up. Personally I would love to have that feature, however the nature of it makes it unlikely that it is something all runtimes would support. Also there are more important tasks to take care of should we ever want to implement it. Currently it's not planned.

Oh and also no more Kickstarter plans 😉

2 ay sonra

I just recently started working with Spine. Loving the tool! Keep up the great work!

What workarounds/tools would you recommend as alternatives to masking in Spine for a cocos2d-x 3.0 pipeline? So far, GAF is the only alternative i've found that supports masking for cocos2d-x, however it hasn't been updated to support 3.0 yet.

A couple of example use cases:

  1. Clipping objects that are partially outside of another arbitrarily shaped object.
  2. Animated progress bars of arbitrary shapes.

Thanks!

12 gün sonra

I haven't looked into how clipping is done with cocos2d-x, they may have cocos2d-x classes to help with it. Otherwise you can just use OpenGL. glScissors is easiest for axis aligned clipping. The stencil buffer is your best bet for arbitrary shapes, though it won't have antialiased edges on the clipping. Maybe you could use a bounding box to define the clipping area for using the stencil buffer. That's actually a pretty cool idea.

HTTPS desteği olmadığı için görsel kaldırıldı. | Yine de Göster

3 ay sonra

I don't know about rest of the Spine users, but my project would benefit from masking regardless the run times. All graphics I've produced with Spine are exported into .png sequenced pictures anyways.

Venomlemon yazdı

I don't know about rest of the Spine users, but my project would benefit from masking regardless the run times. All graphics I've produced with Spine are exported into .png sequenced pictures anyways.

That is a very valid point, however due to the amount of work we still have to do on Spine we focus on features that benefit both users that export JSON and users who export images first. Unless it is really trivial to implement (which I'm pretty sure it's not) it will have to wait for other things to be finished first.

3 ay sonra

+1 for masking. 🙂

Yes please. I would love to have this feature in there too.

2 ay sonra

+1 for masking... it isn't a trivial feature :-P

+1 for masking.

12 gün sonra

+1 for masking.

10 gün sonra

+10 masking 😛

+1 to Masking +100 to increased workflow

2 ay sonra

+1 for masking. i would really love to be able to make "shinny" buttons and light sweeps over layers without generating huge textures...

10 gün sonra

-1000000 to masking! Ha! your idea has now been downvoted 😛

Nah seriously, we would love to do this, but the workload is already huge. I honestly don't know when we can get to it. For now I suggest using a bounding box as a mask. You won't be able to actually see the masking in effect inside of Spine, but at runtime you can write some code to make the magic happen.

4 ay sonra
Shiu yazdı

-1000000 to masking! Ha! your idea has now been downvoted 😛

Nah seriously, we would love to do this, but the workload is already huge. I honestly don't know when we can get to it. For now I suggest using a bounding box as a mask. You won't be able to actually see the masking in effect inside of Spine, but at runtime you can write some code to make the magic happen.

How might you actually use a bounding box to create an animated mask? Is it possible?

bir ay sonra
Shiu yazdı

-1000000 to masking! Ha! your idea has now been downvoted 😛

Nah seriously, we would love to do this, but the workload is already huge. I honestly don't know when we can get to it. For now I suggest using a bounding box as a mask. You won't be able to actually see the masking in effect inside of Spine, but at runtime you can write some code to make the magic happen.

Sooo.. I've come to want this feature, too. Last time you said something about this was 5 months ago.. Maybe something changed or is even in the works?

If not: You said something about using a bounding box as a mask. How would I go about doing this (can you point me in the right direction?)

Thanks!