Jump to content

How do I process pixels over the final render on each frame


Recommended Posts

Hi Im very new to Phaser but I'm looking to take the final render output on each frame and pipe it through a simple pixel process function before showing the final rendered output. I'm wanting to do this for every frame, the resolution will be fairly low and the function will be pretty simple and quick so it shouldn't have any lag.


Thank You

Link to comment
Share on other sites

Thanks, I was looking for a complete Phaser approach where I would somehow get the final rendered image into a bitmapdata object and manipulate the pixels through phaser's API - but I like the context approach because its less function calls and loading / creating data meaning less overhead on each frame rendering

Link to comment
Share on other sites

  • 4 months later...

Sorry to revive an old thread but I've come back to this issue because I I more or less created a workaround which just got problematic and messy. I noticed there was a postRender method metnioned in the API docs but no information or link was given to it so this leaves me a bit confused and I'm taking a guess that the render method is meant for any postRender manipulation before postRender is called which I asusme is when it displays the rendered output and gives a chance to do something after its been called, although I cant find anywhere to configm that.


Essentially what I'm trying to do is make the final output fit within a 4-color palette that can whimsically be changed. Any help with this would be great, thanks.

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.

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.


  • Recently Browsing   0 members

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