-
Notifications
You must be signed in to change notification settings - Fork 823
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Any ways to create BevelFilter? #1018
Comments
Yes, I know about dynamic lightning. But I have kinematic animation (not sprite sheet) with starling display object tree created with Flump. I cannot create normal maps in my case |
I really don't want do dig into AGAL to write custom shader, so any help will be appreciated :) |
That makes sense. I'll drop an email later (may be tomorrow) for more details. |
Just as a suggestion your kinematic animation works moving images(textures extracted from your spritesheet) around so probably the dynamic_lightning approach would work if you can modify Flump in order to use the normal maps and overlap it with the texture(copying the moving and applying it), also a workaround could be to copy the sprite currently being using into a bitmap and apply the filter, time ago I was trying to get the bevel filter to work on Starling but there were some issues to replicate as it was needed a bitmap anyway in order to duplicate the borders. |
Btw, inner glow can be used instead of bevel in my case. But I think the problem to implement inner glow is the same as bevel? |
Mhm, with the existing filters, only the Dynamic Lighting extension will give you a bevel-like result. However, it is rendered per mesh, thus the result you're seeing is different than what you'd get with a filter. It would be possible to create an inner glow filter — with a few adaptations of the Starling code. The DropShadowFilter and the GlowFilter actually work in two steps:
Right now, the CompositeFilter can only draw textures on top of each other. But it was always designed to get a "knockout" mode, where the alpha of one layer is inverted. With that implemented, it should work, in theory. However, there's still the performance penalty, of course: a blur filter takes several passes, and then it needs to be combined with the original texture. If that makes sense for you depends on the number of objects you need to process like this, and the devices you want to target. |
Yes, Bevel filter would be great addition to Starling! |
Are there any ready implementations of BevelFilter?
Something like in native flash display list?
The text was updated successfully, but these errors were encountered: