I am using AsyncGPUReadbackRequest to read back the render rendering result asynchronously. Sometimes, I got both AsyncGPUReadbackRequest.done and AsyncGPUReadbackRequest.hasError ture. The document just said “This property is true if the request has encountered an error.” for “hasError”. But how can I know what error it is and why do I have this error?
Anyone has experience on resolve this “hasError”?
I see the document of AsyncGPUReadbackRequest said:
“The result is accessible only for a single frame once is successfully fulfilled and this request is then disposed of in the following frame” and
“A request that has been disposed of will result in the AsyncGPUReadbackRequest.hasError property being true”.
So I think my problem is that I have too many calls of “Camera.Render()” followed by “AsyncGPUReadback.Request” after every render in one frame. It seems that those renders cannot be all finished within one frame, and thus those finished in next frame will cause AsyncGPUReadbackRequest.hasError to be true.
I do not care about delay for my application. Is there any way to have the result of AsyncGPUReadbackRequest last longer than one frame?
Did you find an answer to this?