Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(5798)

Issue 5696096: Prototype asynchronous glTex*Image2D.

Can't Edit
Can't Publish+Mail
Start Review
Created:
12 years, 2 months ago by apatrick1
Modified:
12 years, 1 month ago
Reviewers:
dgkoch, nicolas
CC:
angleproject-review_googlegroups.com, VangelisK, John Bauman
Base URL:
http://angleproject.googlecode.com/svn/trunk/
Visibility:
Public.

Description

Prototype asynchronous glTex*Image2D.

Patch Set 1 : #

Total comments: 15
Unified diffs Side-by-side diffs Delta from patch set Stats (+254 lines, -26 lines) Patch
M include/GLES2/gl2ext.h View 1 chunk +2 lines, -0 lines 1 comment Download
M src/libGLESv2/Texture.h View 5 chunks +29 lines, -0 lines 2 comments Download
M src/libGLESv2/Texture.cpp View 14 chunks +217 lines, -26 lines 11 comments Download
M src/libGLESv2/libGLESv2.cpp View 2 chunks +6 lines, -0 lines 1 comment Download

Messages

Total messages: 8
apatrick1
Hi Daniel, I think Vangelis mentioned this prototype I was working on last week. The ...
12 years, 2 months ago (2012-02-28 22:09:44 UTC) #1
dgkoch
Interesting approach. It's kind of like PBOs (http://www.opengl.org/registry/specs/ARB/pixel_buffer_object.txt), but in reverse -- instead of the ...
12 years, 1 month ago (2012-03-07 22:05:19 UTC) #2
apatrick1
Yes I was thinking about using PBOs. The reason I want the application to allocate ...
12 years, 1 month ago (2012-03-07 22:37:03 UTC) #3
dgkoch
On 2012/03/07 22:37:03, apatrick1 wrote: > Yes I was thinking about using PBOs. The reason ...
12 years, 1 month ago (2012-03-08 20:39:25 UTC) #4
apatrick1
> > As things stands UNPACK_REVERSE_ROW_ORDER would be needed. I have a couple of > ...
12 years, 1 month ago (2012-03-08 21:12:37 UTC) #5
apatrick1
Another thought. Chrome will probably soon not use EGL window surfaces at all. We're only ...
12 years, 1 month ago (2012-03-08 21:26:01 UTC) #6
dgkoch
That would certainly simplify the implementation, but unfortunately it isn't really correct. The other idea ...
12 years, 1 month ago (2012-03-13 12:35:45 UTC) #7
apatrick1
12 years, 1 month ago (2012-03-13 20:35:29 UTC) #8
I remember I tried doing the flip in the vertex shader. I almost got it working.
There were some corner cases that I couldn't think of a way around though at the
time. For example, glBlitFramebuffer on an FBO with a depth buffer attached is
hard if the differing "defaultness" of the draw and read FBOs implies a flip.
Direct3D's StretchRect can't do it given its restrictions. There are some notes
here on line 3531.

http://codereview.appspot.com/3265041/diff/12001/src/libGLESv2/Context.cpp

Thinking about it some more though, we could make the depth buffers lockable and
do the "blit" using the CPU when a flip is required.

Since using lockable depth formats might have a performance impact, on 9Ex, we
could start out using a regular depth format and replace it with a lockable one
if glBlitFramebuffer ever requires it. 9Ex can copy a non-lockable depth buffer
into a lockable one using UpdateSurface, like this:

http://msdn.microsoft.com/en-us/library/windows/desktop/bb219800(v=vs.85).asp...

I think ANGLE_framebuffer_multisampling is sufficiently restrictive about
multisampled depth stencil buffers.

I think patch set #2 here is more or less what you are describing. It used a
uniform to control the flip depending on the type of FBO. From patch set #3 on
it did the flip in the fragment shader on texture lookup.

http://codereview.appspot.com/3265041

I think it might be worth trying to get #2 working again.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b