How do I prevent a mesh from masking an image?

Wondering how to accomplish a certain animation task? Ask here.

Moderators: Víctor Paredes, Belgarath, slowtiger

Post Reply
User avatar
Reindeer
Posts: 216
Joined: Sat Oct 17, 2015 8:13 am

How do I prevent a mesh from masking an image?

Post by Reindeer »

I am trying to animate the face in a portrait (a jpeg image) with a mesh.
I built the mesh around the face and features of the portrait's face, triangulated the mesh and then went to Frame 1 to start animating. But I find the face of the portrait is floating, alone, because the rest of the portrait is masked out by the mesh. Can I have Moho not do this?
kavlor
Posts: 42
Joined: Wed Jun 10, 2009 11:58 pm

Re: How do I prevent a mesh from masking an image?

Post by kavlor »

For it to draw the meshed image it has to both be covered by a triangle (manually drawn triangles will also work) and the triangle filled.Use the bucket icon when you have your vector selected and fill in any triangles that are showing holes.I don't know if there is a way to fill multiple triangles at once.
User avatar
dueyftw
Posts: 2174
Joined: Thu Sep 14, 2006 10:32 am
Location: kingston NY
Contact:

Re: How do I prevent a mesh from masking an image?

Post by dueyftw »

Duplicate your image. Place the duplicate behind the mesh image layer. You might have to shrink it a tiny bit or make the mashed image a tiny bit larger.

The ideal way is to cut out the meshed image from the background. Fill or 'redraw' (can be a pain in the @#$@) the background so you have the meshed image and the background separate form each other.

Dale
User avatar
Greenlaw
Posts: 9192
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: How do I prevent a mesh from masking an image?

Post by Greenlaw »

As mentioned above, the simplest thing is to just duplicate the image and place it behind the masked/deformed version. Ideally, you'll want to paint out part of the bg version, which is super easy using Photoshop's Content Aware Fill. Just lasso the subject, select Fill and choose Content Aware. This looks at the pixels surrounding the outside of the selection and interpolates the pixels and patterns it finds. It usually works surprisingly well...at the very least, it leaves you less work to fix manually.

If you really don't want the image masked and you don't mind the BG also deforming a little (which can be appropriate in some situations), just make the BG a part of your mesh. If you're drawing a square frame around the entire image, make sure you divide it an appropriate number of times using the Split button, and draw paths within the box to define the regions you want to animate and hold. Don't closed shapes unless you want holes punched into your mesh.

Another quick trick is to use the Grid shape for a mesh. Just drag it over the entire image and dial in your subdivisions. This will give you a mesh similar to what you might get using a standard mesh warp found in many compositing programs.

There's a lot of different ways to these tools so experiment and have fun.

Bonus tips:

Always create a duplicate of your shapes and paths before running Triangulate. This way, you you need to modify the mesh, you still have the original shape to work from.

If the mesh you created isn't detailed enough to make the deformation you want, apply Split on it and run Triangulate again. This will create a new mesh based on the same shapes but with twice the mesh density.
Last edited by Greenlaw on Sat Sep 24, 2016 11:00 pm, edited 1 time in total.
User avatar
Reindeer
Posts: 216
Joined: Sat Oct 17, 2015 8:13 am

Re: How do I prevent a mesh from masking an image?

Post by Reindeer »

Thank you, these are all really valuable suggestions!
Post Reply