Jump to content

Is there any PixiJS V4 Shader Example with Source Code


StratosphereDesigns
 Share

Recommended Posts

Hi guys, I'm new here on the forum as you can see my first post. I'm curious to know is there any good sourced tutorial for V4 Shader Implementation? I have looked but find old tutorials and from what I see its changed in v4.

I've got down all the other stuff for PixiJS and I love it, but the shaders implementation for V4 has me a bit lost lol.

What would be great is a demo of the the V2 or V3 shader that came packaged working in V4. Or maybe a shadertoy.com version.

I'm looking to implement it using the JavaScript Tag encapsulated. Maybe I've overlooked info somewhere?

 

 

Link to comment
Share on other sites

Filters: https://github.com/pixijs/pixi.js/wiki/v4-Creating-Filters

Shaders in renderer plugin for sprites: https://github.com/pixijs/pixi-plugin-example

Yeah, its not as easy as v3. Some performance optimizations lead to significant difficulties. We'll fix it in v5.

Sorry, I dont have any demos about those things, you have to experiment and use forum search.

If you want more hardcore examples, that's multi-texture renderer plugin that adds dark tint like in Spine: https://github.com/gameofbombs/pixi-heaven/tree/master/src/twotint Also it can batch masks. No other webgl renderer can do that.

Projection plugin adds 2d projections (sorry, no 3d yet), and shaders for them: https://github.com/pixijs/pixi-projection

Link to comment
Share on other sites

I'm not a person who focuses on docs. I just want people who really need it to fix filters and make renderer plugins to be able to get that difficulty. My tutorials made it possible, but I cant guarantee that its actually easy, you need knowledge about pixi architecture and webgl low-level anyway. I hope we'll bring it to "for general usage" level in next version again.

Link to comment
Share on other sites

1 hour ago, ivan.popelyshev said:

Filters: https://github.com/pixijs/pixi.js/wiki/v4-Creating-Filters

Shaders in renderer plugin for sprites: https://github.com/pixijs/pixi-plugin-example

Yeah, its not as easy as v3. Some performance optimizations lead to significant difficulties. We'll fix it in v5.

Sorry, I dont have any demos about those things, you have to experiment and use forum search.

If you want more hardcore examples, that's multi-texture renderer plugin that adds dark tint like in Spine: https://github.com/gameofbombs/pixi-heaven/tree/master/src/twotint Also it can batch masks. No other webgl renderer can do that.

Projection plugin adds 2d projections (sorry, no 3d yet), and shaders for them: https://github.com/pixijs/pixi-projection

 

1 hour ago, ivan.popelyshev said:

I'm not a person who focuses on docs. I just want people who really need it to fix filters and make renderer plugins to be able to get that difficulty. My tutorials made it possible, but I cant guarantee that its actually easy, you need knowledge about pixi architecture and webgl low-level anyway. I hope we'll bring it to "for general usage" level in next version again.

Thanks Ivan, appreciate the info this will help get me going in the right direction. look forward to v5! Thanks for all your efforts!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...