Mask effect

For questions about using Classic.

Post » Mon Dec 14, 2009 1:30 am

How is the mask effect used?
for the life of me, I can't figure it out.
B
3
S
2
G
4
Posts: 1,445
Reputation: 4,665

Post » Mon Dec 14, 2009 1:42 am

It's kind of like the erase effect, but it erases based on the alpha values of the image. If a pixel has an alpha value of 0, it will completely erase what's behind it, an alpha value between 0 and 1 will only partially erase, and 1 won't erase at all.
Moderator
B
97
S
36
G
19
Posts: 1,584
Reputation: 17,692

Post » Mon Dec 14, 2009 2:11 am

[quote="linkman2004":3v23vos9]It's kind of like the erase effect, but it erases based on the alpha values of the image. If a pixel has an alpha value of 0, it will completely erase what's behind it, an alpha value between 0 and 1 will only partially erase, and 1 won't erase at all.[/quote:3v23vos9]

It doesn't even do that for me. It seems to be doing something in the layout when applied (everything previously transparent in the image becomes black, and fades to transparent for the previously 100% opaque area's), but in the runtime it completely vanishes except for a faint pixel thin outline. If I change the layer to use force own texture, it'll then vanish completely in runtime.
B
3
S
2
G
3
Posts: 628
Reputation: 2,531

Post » Tue Dec 15, 2009 11:35 pm

Same for me, also can't figure out erase effect.

I think they'd be useful... can any kind soul post a simple example .cap showing them?
B
3
S
2
G
4
Posts: 1,445
Reputation: 4,665

Post » Wed Dec 16, 2009 12:11 am

[quote="Madster":f1xi6ut9]Same for me, also can't figure out erase effect.

I think they'd be useful... can any kind soul post a simple example .cap showing them?[/quote:f1xi6ut9]

This is a quick example of the erase effect (ignore the canvas not working correct, used this as an example for Ashley the other day). Basically erase + canvas = worms, lemmings.

I'm still having no luck on mask though, sorry :\
B
3
S
2
G
3
Posts: 628
Reputation: 2,531

Post » Wed Dec 16, 2009 1:08 am

[quote="Lost my Keys":1v89tjl1]Basically erase + canvas = worms, lemmings.[/quote:1v89tjl1]
Oh so it's only to be used with canvas? that'd explain why I can't figure it out :P
B
3
S
2
G
4
Posts: 1,445
Reputation: 4,665

Post » Wed Dec 16, 2009 1:43 am

[quote="Madster":143ia9js][quote="Lost my Keys":143ia9js]Basically erase + canvas = worms, lemmings.[/quote:143ia9js]
Oh so it's only to be used with canvas? that'd explain why I can't figure it out :P[/quote:143ia9js]

Erase works without it too. Put an object in a layer, then another object with the erase effect on top of it and it'll erase what's beneath.

Example

Uses the same brightness controls the amount, that a few other effects use. (oooh faded fog effects hehe)
B
3
S
2
G
3
Posts: 628
Reputation: 2,531

Post » Wed Dec 16, 2009 2:12 am

Or you could use erase to see what's really going on behind the Scirra forum!

Download

Or simulate using the forum while drunk
Download

:P
B
3
S
2
G
3
Posts: 628
Reputation: 2,531

Post » Wed Dec 16, 2009 10:11 pm

thanks for the examples, the first one did it.
Seems I wasn't getting any results because the erase object needs to be on top of the other objects (duh!) and works within a single layer.

:D this will be useful, I'm sure... I plan to use it to mask shadows out of an occluded object!
B
3
S
2
G
4
Posts: 1,445
Reputation: 4,665

Post » Wed Dec 16, 2009 11:22 pm

[quote="Madster":603id9nn]thanks for the examples, the first one did it.
Seems I wasn't getting any results because the erase object needs to be on top of the other objects (duh!) and works within a single layer.

:D this will be useful, I'm sure... I plan to use it to mask shadows out of an occluded object![/quote:603id9nn]

Yeah it can certainly do that, I was considering it in the other thread, but the way things are heading for me, i don't think I'll have the resources for even more objects lol.
B
3
S
2
G
3
Posts: 628
Reputation: 2,531

Next

Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 1 guest