Addon ID

  • skymen_BetterOutline

Info

Statistics

  • Download count10,077 total downloads
  • Latest download count 4,053 downloads of latest version
  • Average download count5 downloads per day average

Owners

Description

(Webgl2 / WebGPU support) A better outline shader than the one that already exists on the C3 addon stack exchange

Discussion

  • 43 Comments

  • Order by
Want to leave a comment? Login or Register an account!
  • skymen there is one issue in this effect if we rotate layout 90 or 270 degree by setting its angle then outline streches from one side. see this image

    • Hi, yeah this is an issue with C3's effect compositor. It doesn't provide a good way to get the size of one layout pixel unit across all scales and angles. I use an approximation that hopefully works in most use cases, but assumes that the render target and the layout are aligned which isn't true if the layout is rotated.

      In fact my approximation only works at angles 0 and 180 and breaks on every other angle value, and there is no way to really fix this without also breaking the fact that the outline pixel size is tied to layout pixels.

      If you want, you can modify the effect. In the code you should find a value called "texelSize" which is my approximation, and instead use C3's "pixelSize" value and it should hopefully stop stretching, and you can counter act the wrong pixel size value by using bigger width values

  • Nice effect!

  • Thank you for the great effect, Skymen! It's very very useful. ✨

  • no work on Text

  • Amazing, thank you!

  • Not sure why people are saying it doesn't work on text. The text and spritefont objects can do an outline with bb code.

  • новый

  • Is there a way to have the outline not extend beyond the character? Instead, have it scale inner, rather than outer?

  • This effect fixes the outline spikes, and makes it easier to add the outline (no bbcode before text). It also works for regular sprites

    Man you're the goat

    • I would still recommend using the bbcode outline when possible because it is a billion times faster than my shader for text

      • I noticed. It's not a big deal since the bulk of the texts are in the game menus, which don't need to maximize performance, while the ones in-game are much less, and i can use the bbcode there to keep it light

  • The effect hasn't been working well for me. It's adding the outline to some parts of the border of the object instead of just the sprite, and the part of the border it chooses changes depending on if it's in full screen or not, it's bugged out and I don't know how to fix this.

    • Hi, this is likely due to a spritesheet bleeding issue which is unrelated to the shader.

      Make sure to add 1px of empty space around all of your sprites to prevent spritesheet bleeding (clicking the crop button does this for that exact reason)

  • Load more comments (24 replies)