<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>126455</bug_id>
          
          <creation_ts>2014-01-03 13:27:06 -0800</creation_ts>
          <short_desc>[WebGL] glScissor Test is not accounted for when generating internal rendering textures</short_desc>
          <delta_ts>2014-01-03 13:42:16 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>WebGL</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Major</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Brent Fulgham">bfulgham</reporter>
          <assigned_to name="Brent Fulgham">bfulgham</assigned_to>
          <cc>bfulgham</cc>
    
    <cc>commit-queue</cc>
    
    <cc>dino</cc>
    
    <cc>kondapallykalyan</cc>
    
    <cc>noam</cc>
    
    <cc>roger_fong</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>964243</commentid>
    <comment_count>0</comment_count>
    <who name="Brent Fulgham">bfulgham</who>
    <bug_when>2014-01-03 13:27:06 -0800</bug_when>
    <thetext>Our WebGL implementation uses a texture handle part of the drawing operations to put the final rendered scene into the HTML Canvas. If a WebGL program is using the glScissor feature, this impacts our texture generation.

This bug manifests as regions of the screen being filled with random data, rather than the intended scene to be displayed.

We should check the status of the GL_SCISSOR_TEST and GL_DITHER features, disable them for our internal drawing, and then re-enable them (if needed) before returning to the JS program.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>964247</commentid>
    <comment_count>1</comment_count>
    <who name="Brent Fulgham">bfulgham</who>
    <bug_when>2014-01-03 13:30:39 -0800</bug_when>
    <thetext>This error causes the following examples to fail:

http://threejs.org/examples/#webgl_materials_texture_anisotropy
http://threejs.org/examples/#webgl_materials_texture_filters
http://threejs.org/examples/#webgl_materials_texture_manualmipmap
http://threejs.org/examples/#webgl_multiple_views</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>964248</commentid>
    <comment_count>2</comment_count>
      <attachid>220333</attachid>
    <who name="Brent Fulgham">bfulgham</who>
    <bug_when>2014-01-03 13:34:25 -0800</bug_when>
    <thetext>Created attachment 220333
Patch</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>964251</commentid>
    <comment_count>3</comment_count>
    <who name="WebKit Commit Bot">commit-queue</who>
    <bug_when>2014-01-03 13:37:03 -0800</bug_when>
    <thetext>Attachment 220333 did not pass style-queue:

Failed to run &quot;[&apos;Tools/Scripts/check-webkit-style&apos;, &apos;--diff-files&apos;, u&apos;Source/WebCore/ChangeLog&apos;, u&apos;Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp&apos;, &apos;--commit-queue&apos;]&quot; exit_code: 1
ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:200:  Wrong number of spaces before statement. (expected: 8)  [whitespace/indent] [4]
ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:201:  Wrong number of spaces before statement. (expected: 8)  [whitespace/indent] [4]
ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:202:  Wrong number of spaces before statement. (expected: 8)  [whitespace/indent] [4]
ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:202:  Wrong number of spaces before statement. (expected: 8)  [whitespace/indent] [4]
ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:219:  Wrong number of spaces before statement. (expected: 12)  [whitespace/indent] [4]
ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:221:  Wrong number of spaces before statement. (expected: 12)  [whitespace/indent] [4]
ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:219:  Wrong number of spaces before statement. (expected: 12)  [whitespace/indent] [4]
ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:221:  Wrong number of spaces before statement. (expected: 12)  [whitespace/indent] [4]
Total errors found: 8 in 2 files


If any of these errors are false positives, please file a bug against check-webkit-style.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>964252</commentid>
    <comment_count>4</comment_count>
    <who name="Brent Fulgham">bfulgham</who>
    <bug_when>2014-01-03 13:37:41 -0800</bug_when>
    <thetext>(In reply to comment #3)
&gt; Attachment 220333 [details] did not pass style-queue:
&gt; 
&gt; Failed to run &quot;[&apos;Tools/Scripts/check-webkit-style&apos;, &apos;--diff-files&apos;, u&apos;Source/WebCore/ChangeLog&apos;, u&apos;Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp&apos;, &apos;--commit-queue&apos;]&quot; exit_code: 1
&gt; ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:200:  Wrong number of spaces before statement. (expected: 8)  [whitespace/indent] [4]
&gt; ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:201:  Wrong number of spaces before statement. (expected: 8)  [whitespace/indent] [4]
&gt; ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:202:  Wrong number of spaces before statement. (expected: 8)  [whitespace/indent] [4]
&gt; ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:202:  Wrong number of spaces before statement. (expected: 8)  [whitespace/indent] [4]
&gt; ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:219:  Wrong number of spaces before statement. (expected: 12)  [whitespace/indent] [4]
&gt; ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:221:  Wrong number of spaces before statement. (expected: 12)  [whitespace/indent] [4]
&gt; ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:219:  Wrong number of spaces before statement. (expected: 12)  [whitespace/indent] [4]
&gt; ERROR: Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:221:  Wrong number of spaces before statement. (expected: 12)  [whitespace/indent] [4]
&gt; Total errors found: 8 in 2 files
&gt; 

These are very much false positives. The whole section of code is indented 4 spaces. What is check-webkit-style thinking?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>964257</commentid>
    <comment_count>5</comment_count>
    <who name="Brent Fulgham">bfulgham</who>
    <bug_when>2014-01-03 13:42:16 -0800</bug_when>
    <thetext>Committed r161285: &lt;http://trac.webkit.org/changeset/161285&gt;</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>220333</attachid>
            <date>2014-01-03 13:34:25 -0800</date>
            <delta_ts>2014-01-03 13:40:13 -0800</delta_ts>
            <desc>Patch</desc>
            <filename>bug-126455-20140103133424.patch</filename>
            <type>text/plain</type>
            <size>2010</size>
            <attacher name="Brent Fulgham">bfulgham</attacher>
            
              <data encoding="base64">SW5kZXg6IFNvdXJjZS9XZWJDb3JlL0NoYW5nZUxvZwo9PT09PT09PT09PT09PT09PT09PT09PT09
PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ci0tLSBTb3VyY2UvV2Vi
Q29yZS9DaGFuZ2VMb2cJKHJldmlzaW9uIDE2MTI4MikKKysrIFNvdXJjZS9XZWJDb3JlL0NoYW5n
ZUxvZwkod29ya2luZyBjb3B5KQpAQCAtMSwzICsxLDE3IEBACisyMDE0LTAxL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mlzaCgpOwogICAgIG1fbGF5ZXJDb21wb3NpdGVkID0gdHJ1ZTsKKworICAgIGlm
IChpc1NjaXNzb3JFbmFibGVkKQorICAgICAgICA6OmdsRW5hYmxlKEdMX1NDSVNTT1JfVEVTVCk7
CisgICAgaWYgKGlzRGl0aGVyRW5hYmxlZCkKKyAgICAgICAgOjpnbEVuYWJsZShHTF9ESVRIRVIp
OwogfQogI2VuZGlmCiAK
</data>
<flag name="review"
          id="244031"
          type_id="1"
          status="+"
          setter="dino"
    />
          </attachment>
      

    </bug>

</bugzilla>