brow / leaves

A page-turning interface for iOS apps
Other
1.44k stars 332 forks source link

Pull Request for CATiledLayer based zoom #16

Closed hammerlyrodrigo closed 11 years ago

hammerlyrodrigo commented 13 years ago

I've been working in a pdf reader based on your amazing work, however it needed a high quality zoom feature, after a little struggling, I found a good way to implement it. So I'm back here to return something back to the community. This is my first time sharing on github so please be kind! :)

aaronwardle commented 13 years ago

Hi,

Just spotted your contribution which sounds quite interesting we have been working for quite some time to improve the functionality with the leaves source code.

I tried to run your source code and when trying to use another PDF faced some errors is this working perfectly for you?

Also does this fix the zoom issue which is currently like a jumping effect when zooming in?

Thanks Aaron

hammerlyrodrigo commented 13 years ago

Hello Aron,

I managed to remove the "jumping" effect when zooming by stacking the CATiledLayer just over a page bitmap image, when zoom operation starts CATiledLayer flickers for a moment before content gets properly drawn, but the bitmap image is still visible so it goes unnoticed.

Regarding the errors you were facing can you send me the PDF to give a try? I faced a problem with some PDFs in the main project I was working with a couple of days ago, some pages were drawn in an odd fashion, I changed the draw routine and it fixed the problem.

Regards,

Rodrigo

aaronwardle commented 13 years ago

Hi Rodrigo,

Sorry for the delay with getting back to you, I've just downloaded it again and tried it on my iPad with the sample PDF and it seems to work really well, I'll now try it again with our PDF, and let you know how I get on.

Thanks Aaron

aaronwardle commented 13 years ago

Hi Rodrigo,

I have been trying your application and the zoom works quite well however when I try to use my PDF I can never seem to make it move to the 2nd page?

http://www.ge-mcs.com/download/orbit-archives/ORBIT_v30n1_2010_r15.pdf

Thanks Aaron

On 02/09/2011 20:25, "hammerlyrodrigo" reply@reply.github.com wrote:

Hello Aron,

I managed to remove the "jumping" effect when zooming by stacking the CATiledLayer just over a page bitmap image, when zoom operation starts CATiledLayer flickers for a moment before content gets properly drawn, but the bitmap image is still visible so it goes unnoticed.

Regarding the errors you were facing can you send me the PDF to give a try? I faced a problem with some PDFs in the main project I was working with a couple of days ago, some pages were drawn in an odd fashion, I changed the draw routine and it fixed the problem.

Regards,

Rodrigo

Reply to this email directly or view it on GitHub: https://github.com/brow/leaves/pull/16#issuecomment-1982280

hammerlyrodrigo commented 13 years ago

Aron:

You were right, it seems that I forgot to add some code when I made the port from my working code, now it's fixed, I've just updated the repository. Please let me know if now works for you.

achetwood commented 13 years ago

Hello Rodrigo.

I've been having a look at your leaves implementation, but whenever i try to scroll the pages in two pages mode. The page flip animation seems to be really slow and jerky on the iOS simulator. Have you or anyone else seen or had this problem? If i can work out a method to get it to work i'll post it, but im still struggling so any help would be appreciated.

Thanks Alex

hammerlyrodrigo commented 13 years ago

Alex:

Thanks you for the feedback. This is the first time I hear about this problem, it works fine on my simulator and it has not been mentioned by others so far, I have a couple of questions for you so I can have a better idea about it:

  1. Does the animation problem shows up in one and two pages mode or just two pages mode?
  2. Have you tried the original brows leaves version and it works ok in your simulator?
  3. Can you tell me which iOS version are you running?
  4. How are you triggering the turning page animation? By tapping the left and right side, or dragging the page?

I look forward for your feedback!

Rodrigo

achetwood commented 13 years ago

Hi.

Thanks for the reply. The animation problem only shows up in two pages mode while dragging the page, its fine if i tap it in two pages mode. I dont get the problem at all in single page mode.

I am currently using iOS 5, however i have tried 4.2 as well and got the same problem.

The original version of leaves works ok in my simulator when it comes to the dragging and animation effect in both one and two page views.

I'll keep working on it, sounds like it might be a problem with my simulator / xcode. I look forward to any more feedback from you, its appreciated.

Thanks Alex

achetwood commented 13 years ago

Hi again Rodrigo.

I have since tried this on my iphone and still have the same dragging across problem. I still am not sure on what the problem could be, I have also since tried it using iOS SDK 3.2 and it didnt work on that either.

Regards Alex

hammerlyrodrigo commented 13 years ago

Alex:

Sorry for the delay in the response, I've been away from computers this weekend. I think that the problem could be related to animation, I will try a couple of fixes today and I'll let you know.

Rodrigo

achetwood commented 13 years ago

Hi again.

Yeah ok, that would be interesting to see. Also, Ive tried this on device running iOS 3.1 but on this the page turner doesnt seem to work at all as well as the possible animation problem when dragging the page across on other iOS versions, whether it could be related to the animations i dont know.

Thanks a lot for the help. Alex

anilchopram commented 13 years ago

Hi Alex,

I am not Rodrigo! Probably you have got the wrong email id. BTW in IOS5 ibook like page flip has been introduced check it out :)

Thanks and Regards, Anil

On Mon, Oct 17, 2011 at 4:31 PM, achetwood < reply@reply.github.com>wrote:

Hi again Rodrigo.

I have since tried this on my iphone and still have the same dragging across problem. I still am not sure on what the problem could be, I have also since tried it using iOS SDK 3.2 and it didnt work on that either.

Regards Alex

Reply to this email directly or view it on GitHub: https://github.com/brow/leaves/pull/16#issuecomment-2427418

achetwood commented 13 years ago

Hi. Ive been working with Rodrigo's version of Leaves, I have managed to get the page turning to work on an iphone running iOS 3.1. However, I have for the moment got rid of the facing pages support because it is still slow and jumpy when dragging the page across. If anyones had any luck with this, any help would be great.

Thanks

lopes710 commented 12 years ago

Hi achetwood

Have you been able to solve slowness of page dragging? I have the same problem using it in iPad 5.0 simulator and a real iPad with also 5.0.

Thanks

brow commented 11 years ago

@hammerlyrodrigo Belated thanks for all your work. I'm sorry it was never merged. For posterity, I've added a link to your fork from the README.