Info

Statistics

  • Download count1,262 total downloads
  • Latest download count 514 downloads of latest version
  • Average download count1 downloads per day average

Owners

Description

Deform a quad image within the boundary of an object using relative vertices with the object.

Example Files

Example, see events for an option to animate the control points.

Add a helper function, which allows quad to be deformed to any size on the screen, reduces bbox to minimum size and move quads origin to match. Also added a helper function to create deform quads.

Discussion

  • 19 Comments

  • Order by
Want to leave a comment? Login or Register an account!
  • Hi Mikal, this is great and currently does a better job than the new built in Mesh. However, when testing on iOS (both in browser and as Xcode app) whilst moving each corner of the sprite using touch, sometimes the whole sprite goes really pixelated. I can get it to do it every time by moving the corners into certain positions. Do you know what might cause this?

    I have added a video to show what is happening, this does not happen in chrome on my computer (in preview) but happens on iOS if I remote preview or build to Xcode and install as an app

    streamable.com/zqitsd

    EDIT: Also happens using Chrome on iOS.

    EDIT 2 : It appears that this happens when edges are parallel maybe? I also noticed in the effect code there is a test for parallel edges? But I'm not very good with shader code so not sure if there is something that can be done there or not?

  • They are a little different, one is an effect, one is plugin. This will generally look better, but require more perf. This one requires a helper function to do something similar to what FQ does.