Page Curl

Ok, I’m guessing the answer will be “no” or “go buy advanced” but I just want to ask to make sure.

Is it possible to do the page curl effect with unity. It seems like a good fit with the game I’m making but totally not necessary.

Thanks for the help,
-Mike Berger

if you just want it to do it automatically you could potentially achieve it through using a bone based mesh animation. but it will cost a lot of performance if doable at all.

if you want it to make the curl being driven by finger movement, then no

no, not by finger movement. This isn’t an iPad. =]

I was just talking about a pre-set page curl / turn animation but the more I think about it the less I think it will happen.

its pretty hard to achieve it, as you have to do it through bone animation. Unity doesn’t over vertex animation.

Once OpenGL ES 2.0 is supported you could use a vertex shader but it would be a 3GS only thing.

What about animating it in Pixelmator frame by frame then animating the 100 images?

I’m just thinking out loud…

This guy starts in Unity the uses xcode. first is the link to the Unity player, the second is to the full article. I’m lookin for the code and will post it when I find it

http://mercury.lunaray.com/unity/pbp/

Here is the solution for vertex animation :wink:
in2Unity - Geometry (vertex) animation export from 3dsmax

It makes possible to export any animation (with Static Vertex Count) from 3dsmax to Unity
The forum link

You could snapshot the pages into a sequence of meshes.

If you’re using Max, try something like this:

// create a snapshot of the selected mesh at each frame in the Timeline
// works on skins, modifiers, whatever. Use Mesher or Blobmesh if you want to use it on particles.

        mainmesh = $
			
	for t = animationrange.start to animationrange.end
		do
			(	
				
			sliderTime=t
			
			snap=snapshot(mainmesh)

			snap.visibility = linear_float()
		
			animate on at time 0 snap.visibility.controller.value=0

			if t > 0 do
			(
				animate on at time (t-1) snap.visibility.controller.value=0
			)
			animate on at time t snap.visibility.controller.value=1
			animate on at time (t+1) snap.visibility.controller.value=0	

			hide(snap)    // comment this out to prevent it hiding the results
			
			)

Displaying them in Unity is simple enough; treat each mesh like a sprite frame.

Note that this script sets a Visibility track keyframe for each mesh snapshot… this is for convenience (easier to play through and check the results)… sadly, Unity ignores Vis track…I’ve asked for it :slight_smile:

1 Like

The author of the question can use this Unity Asset Store - The Best Assets for Game Making

[9-2021] here is some example with finger detection: