glFlush + glFenceSync not work correctly

This topic contains 1 reply, has 2 voices, and was last updated by  Tobias Hector 4 years ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #31483

    rory_yin
    Member

    i am trying to use glFlush + glFenceSync to alternate glFinish, but it seems that this doesn’t work.
    my code looks like follow:

    while(1) {
    glDrawArray();
    sync = glFenceSyncAPPLE(GL_SYNC_GPU_COMMANDS_COMPLETE_APPLE, 0);
    enqueueSync(sy nc);
    glFlush();

    sync = getSyncQueueHeader()
    glGetSyncivAPPLE(sync, GL_SYNC_STATUS_APPLE, 1, NULL, status)
    if (status == GL_SIGNALED_APPLE) {
    dequeueSync();
    dosomethingelse()
    }
    }

    i am not sure if my code is alright or just i need some more time to get my signal after glFlush? thanks!

    #37980

    Hi Rory,

    Using the EGL version of this functionality works on our drivers to do this at least in all the tests I’ve done myself – unfortunately the fence syncs you’re using are specific to Apple’s version of the drivers. If you’re encountering a problem with these functions I’m afraid you’ll have to get in contact with Apple directly, as we won’t be able to help.

    Regards,
    Tobias

Viewing 2 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic.