Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use PBO's to download textures to client memory asynchronously #32

Open
3 tasks
onox opened this issue Apr 27, 2019 · 0 comments
Open
3 tasks

Use PBO's to download textures to client memory asynchronously #32

onox opened this issue Apr 27, 2019 · 0 comments

Comments

@onox
Copy link
Owner

onox commented Apr 27, 2019

Get_Data and Get_Compressed_Data in GL.Objects.Textures assume no PBO is bound and operate synchronously. Refactor these functions so they can operate (only) asynchronously (requires binding a buffer to a PBO and setting a fence).

  • Refactor Get_Data and Get_Compressed_Data (bind a buffer as a PBO + set a fence)
  • Add support for downloading data asynchronously in a Orka.Rendering.Textures (use job graph system)
  • Find out how to obtain a file descriptor from an EGL/GL sync object.

After the fence has been retired, we can either:

  1. Copy the data with Get_Data in Orka.Rendering.Buffers
  2. Map the buffer, copy to an array, unmap the buffer
  3. Make sure a specific region of a PMB has been bound as a PBO (useful for video streaming)

The job graph system might need to be modified in order to postpone the execution of the remaining jobs of a job graph until a fence has been retired. Currently we either need to wait on a fence in a GPU job or insert a new GPU job between the current GPU job and the next job in a job graph. However, this new GPU job might immediately get executed by the thread which processes the GPU jobs. Currently there's no way to tell the system to wait until the next frame.

https://on-demand.gputechconf.com/gtc/2012/presentations/S0356-GTC2012-Texture-Transfers.pdf

@onox onox added this to the 1.0 milestone Apr 27, 2019
@onox onox modified the milestones: 0.1, 0.3 Jul 13, 2019
@onox onox self-assigned this Feb 27, 2022
@onox onox removed their assignment Oct 20, 2022
@onox onox modified the milestones: 0.3, 0.4 Oct 20, 2022
@onox onox modified the milestones: 0.4, 1.1 Feb 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant