Hello,
I'm using the MegaBook/Page flip stuff to create a book for a client. I've managed to get the book up and running (amazingly fast, great product!), and now I'm trying to figure out how to flip forward/backwards, page by page.
I have something built right now that does this using the bookAlpha property. I'm modifying the value by X over time each time the user clicks to turn. However, the pages don't always end up being flush against their side when my turn stops. Either the left or right page ends up jittering a bit when I start my next turn because it wasn't 100% fully turned, or it was a tiny bit over turned. When my value per page ends up being something like 11.1111 I just don't know how to get it exact. Am I doing something wrong over here? Is there a way to get it to be an integer and not a float?
If not, is there a way to check if the pages are at a 0 rotation? Theoretically I could loop through my increment each update, and check if its finished before adding a little more, until I get it perfectly on target. I'm not sure how to tell where in the flip a page is though.
I'm really hoping this is a stupid hack for something you guys have already made more elegant that I just don't know about yet. I can't release something that doesn't feel polished, and having a slight jitter every page or two that catches the eye just enough to see, even though its close to perfect, isn't acceptable. Especially when I can't have any faith that this system won't end up messing up on a page and just leave it in an obviously semi-turned state.
Its a great product, but every project with a page turner that I've seen so far (its been a few) has always required discreet increments of pages ... not leaving it up to the user how much of a page is turned. So I'm going to assume this has already been hashed out :).
Any help would be really appreciated.
Thanks so much for your time guys,
- D
[Edit]
I forgot, I have a second problem:
There is a gap between the front cover of the book and the rest of the book while opening it. When the front cover finished rotating, it rests seamlessly against the the rest of the book, but while rotating, there is a gap between it and the book. I can see the table through the middle (where the binding would be in a real book).
How do I get rid of this?
Thanks again,
-D
|