Bug 53054

Summary: texSubImage2D's format/type needs to match the internalformat/type from the previous texImage2D call
Product: WebKit Reporter: Zhenyao Mo <zmo>
Component: WebGLAssignee: Zhenyao Mo <zmo>
Status: RESOLVED FIXED    
Severity: Normal CC: cmarrin, enne, kbr
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: PC   
OS: OS X 10.5   
Attachments:
Description Flags
Patch
none
Patch kbr: review+

Description Zhenyao Mo 2011-01-24 17:49:26 PST
On desktop GL, if they don't match, no error will be generated; but in GLES, "the same constraints and errors apply to the TexSubImage commands' argument format and the internalformat of the texture array being respecified as apply to the format and internalformat arguments of its TexImage counterparts".
Comment 1 Zhenyao Mo 2011-01-27 16:30:25 PST
Created attachment 80375 [details]
Patch
Comment 2 Zhenyao Mo 2011-01-27 16:35:37 PST
Created attachment 80376 [details]
Patch
Comment 3 Kenneth Russell 2011-01-27 17:15:44 PST
Comment on attachment 80376 [details]
Patch

Looks good. Please add the test to the WebGL conformance suite.
Comment 4 Zhenyao Mo 2011-01-27 17:16:49 PST
This test is almost a duplication from one of the more/function/ test.  Should we still add it?
Comment 5 Kenneth Russell 2011-01-27 17:21:16 PST
(In reply to comment #4)
> This test is almost a duplication from one of the more/function/ test.  Should we still add it?

It would be better from a maintenance perspective if we tried to keep the WebGL layout tests a subset of the WebGL conformance tests in the Khronos repository. If this test is mostly a copy of one of the more/function/ tests, what about moving it into the conformance suite proper upstream?
Comment 6 Zhenyao Mo 2011-01-27 17:22:13 PST
You mean delete the more/ test and add this one?
Comment 7 Kenneth Russell 2011-01-27 17:23:24 PST
(In reply to comment #6)
> You mean delete the more/ test and add this one?

Yes.
Comment 8 Zhenyao Mo 2011-01-27 17:26:36 PST
Committed r76874: <http://trac.webkit.org/changeset/76874>