Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

(Another) Objective C Question: Refraining OpenGL view from pausing when scrolling [SOLVED]

edited January 2014 in Beta Posts: 2,820

Hello,
@Simeon - I had noticed this on Codea Commits that you achieved this, so I thought I might ask myself:
How do I make it so the OpenGL frame does not freeze when I am scrolling in my web view?
Thanks!
P.S. Did your change only affect scrolling the output view, or all UIScrollViews when scrolling?

Comments

  • SimeonSimeon Admin Mod
    edited January 2014 Posts: 5,362

    I actually changed this behaviour back due to performance.

    If you want to do this you can force a render in the scroll view's scrollViewDidScroll: delegate method. However, the priority of scroll view scrolling is very high, so it will lower the frame rate. I felt that the tradeoff wasn't worth it.

    Edit: I moved this to the Beta tag.

  • Posts: 2,820

    @Simeon - Thanks. How exactly do I force a render? And I only use scroll views in non-graphic intense, so I should be able to. Turn it off and on. Thanks!

  • SimeonSimeon Admin Mod
    Posts: 5,362

    Assuming you have a GLKView then:

    [glView setNeedsDisplay];
    [glView display];
    
  • edited January 2014 Posts: 2,820

    @Simeon - Thanks. How can I access Codea's GLView? (I think you told me before, but I can't find it).
    Thanks!
    Edit: Found it.

  • Posts: 2,820

    I thought I might post this info for the community if they are curious:
    This is super simple to do, but like Simeon said, it's really glitchy. In the first place, some things like EllapsedTime is not updated for the Lua code, so my clouds jump around in StackIt when you scroll. Along with that, the scrolling is very un-smooth, since it forces the GLKView to update faster than it can.
    In conclusion, it's not worth it.
    Thanks!

Sign In or Register to comment.