Closed Bug 480497 Opened 15 years ago Closed 14 years ago

[c3d] getImageData missing

Categories

(Core :: Graphics: CanvasWebGL, defect)

x86
Linux
defect
Not set
normal

Tracking

()

RESOLVED INVALID

People

(Reporter: ilmari.heikkinen, Unassigned)

Details

Attachments

(2 files, 3 obsolete files)

User-Agent:       Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2a1pre) Gecko/20090226 Minefield/3.2a1pre
Build Identifier: 

There's no getImageData implementation in the 3d canvas. GetImageData should read from the visible image on the pbuffer surface. 


Reproducible: Always

Steps to Reproduce:
1. gl.getImageData(0,0,1,1)

Actual Results:  
Error, no getImageData method.

Expected Results:  
Should have returned an imagedata object {width:1, height:1, data:[r,g,b,a]}.
Implementations for GetImageData and GetInputStream adapted
from nsCanvasRenderingContext2D.cpp

ToDataURL doesn't work, probably because ToDataURLImpl in
content/html/content/src/nsHTMLCanvasElement.cpp
has the 2D context assumption hardcoded
( GetContext(NS_LITERAL_STRING("2d"), getter_AddRefs(context)) )
Attachment #364482 - Attachment is obsolete: true
Attachment #365146 - Flags: review?(vladimir)
Attachment #364483 - Attachment is obsolete: true
Attachment #365148 - Attachment is patch: false
Attachment #365148 - Attachment mime type: text/plain → text/html
Comment on attachment 365146 [details] [diff] [review]
Updated patch, depends on the glReadPixels patch for CheckSaneSubrectSize

Argh, GetInputStream doesn't use OPERATOR_SOURCE, so you get garbled data.
Attachment #365146 - Attachment is obsolete: true
Attachment #365146 - Flags: review?(vladimir)
Component: Canvas: 2D → Canvas: WebGL
getImageData doesn't exist in the current WebGL spec.
Status: UNCONFIRMED → RESOLVED
Closed: 14 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: