Closed Bug 565998 Opened 14 years ago Closed 14 years ago

Let glTexImage2D accept zero-sized textures

Categories

(Core :: Graphics: CanvasWebGL, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: bjacob, Assigned: bjacob)

References

Details

Attachments

(2 files, 2 obsolete files)

Our implementation of TexImage2D is currently rejecting zero-size textures, but it's looking like it shouldn't:

    http://www.khronos.org/opengles/sdk/docs/man/glTexImage2D.xml

Quote:

    GL_INVALID_VALUE is generated if width or height is
    less than 0 or greater than GL_MAX_TEXTURE_SIZE

Moreover, SpiderGL is relying on 0-size textures being accepted:

    http://spidergl.org/example.php?id=5

The question is how should we act upon 0-sized textures? Just passing them to GL's glTexImage2D is no good on systems doing software rendering, because it will try to do malloc(0) in our process, and that will call jemalloc(0)... and our implementation of jemalloc has an assertion that size!=0, so we crash. Filing a separate bug about that.

Do you think the patch is good to commit as-is or should we wait for our jemalloc to be fixed and then just call glTexImage2D with zero size?
OS: Linux → All
Hardware: x86 → All
Attached patch Allow zero-sized textures (obsolete) — Splinter Review
Attachment #445414 - Flags: review?(vladimir)
Ok OK it's not malloc(), it's memalign().

Will file bug report, but for now here's the crash's backtrace, that happens when a WebGL app tries to pass size 0x0 to glTexImage2D and we are using OSMesa. It shows that OSMesa is trying to call memalign(0) and that the JEMalloc of memalign doesn't like that.



*************


#0  0x00007f711fdff77d in nanosleep () from /lib/libc.so.6
#1  0x00007f711fdff60f in sleep () from /lib/libc.so.6
#2  0x00007f7124bad284 in ah_crap_handler (signum=6)
    at /home/bjacob/mozilla-central/toolkit/xre/nsSigHandlers.cpp:164
#3  0x00007f7124bb1bfa in nsProfileLock::FatalSignalHandler (signo=6, info=0x7fff7c021270, 
    context=0x7fff7c021140) at nsProfileLock.cpp:221
#4  <signal handler called>
#5  0x00007f711fd92465 in raise () from /lib/libc.so.6
#6  0x00007f711fd938e6 in abort () from /lib/libc.so.6
#7  0x0000000000412a82 in arena_malloc (arena=0x7f7127376040, size=0, zero=false)
    at /home/bjacob/mozilla-central/memory/jemalloc/jemalloc.c:3792
#8  0x0000000000413187 in ipalloc (alignment=512, size=0)
    at /home/bjacob/mozilla-central/memory/jemalloc/jemalloc.c:3923
#9  0x0000000000417213 in memalign (alignment=512, size=0)
    at /home/bjacob/mozilla-central/memory/jemalloc/jemalloc.c:5833
#10 0x0000000000417316 in posix_memalign (memptr=0x7fff7c0218b8, alignment=512, size=0)
    at /home/bjacob/mozilla-central/memory/jemalloc/jemalloc.c:5869
#11 0x00007f70f93d99c1 in _mesa_align_malloc () from /usr/lib/libOSMesa.so
#12 0x00007f70f94008d5 in _mesa_store_teximage2d () from /usr/lib/libOSMesa.so
#13 0x00007f70f93f2a66 in _mesa_TexImage2D () from /usr/lib/libOSMesa.so
#14 0x00007f7125221443 in mozilla::WebGLContext::TexImage2D_base (this=0x7f70fab94d40, 
    target=3553, level=0, internalformat=6408, width=0, height=0, border=0, format=6408, 
    type=5121, data=0x0, byteLength=0)
    at /home/bjacob/mozilla-central/content/canvas/src/WebGLContextGL.cpp:2641
#15 0x00007f7125221561 in mozilla::WebGLContext::TexImage2D_array (this=0x7f70fab94d40, 
    target=3553, level=0, internalformat=6408, width=0, height=0, border=0, format=6408, 
    type=5121, pixels=0x7f70f8a83460)
    at /home/bjacob/mozilla-central/content/canvas/src/WebGLContextGL.cpp:2666
---Type <return> to continue, or q <return> to quit---
#16 0x00007f71258f5b76 in nsICanvasRenderingContextWebGL_TexImage2D (cx=0x7f711008a800, argc=9, 
    vp=0x7f710feebd70) at ../../../../dist/include/CustomQS_WebGL.h:274
#17 0x00007f71241596b9 in js_Interpret (cx=0x7f711008a800)
    at /home/bjacob/mozilla-central/js/src/jsops.cpp:2199
#18 0x00007f712416c976 in js_Invoke (cx=0x7f711008a800, argc=1, vp=0x7f710feeb8f8, flags=0)
    at /home/bjacob/mozilla-central/js/src/jsinterp.cpp:831
#19 0x00007f71258c24d5 in nsXPCWrappedJSClass::CallMethod (this=0x7f710fffa8d0, 
    wrapper=0x7f70fa8fb580, methodIndex=3, info=0x7f71144d80a0, nativeParams=0x7fff7c022bb0)
    at /home/bjacob/mozilla-central/js/src/xpconnect/src/xpcwrappedjsclass.cpp:1696
#20 0x00007f71258b9951 in nsXPCWrappedJS::CallMethod (this=0x7f70fa8fb580, methodIndex=3, 
    info=0x7f71144d80a0, params=0x7fff7c022bb0)
    at /home/bjacob/mozilla-central/js/src/xpconnect/src/xpcwrappedjs.cpp:570
#21 0x00007f7125faffc6 in PrepareAndDispatch (self=0x7f70f8a824a0, methodIndex=3, 
    args=0x7fff7c022d50, gpregs=0x7fff7c022cd0, fpregs=0x7fff7c022d00)
    at /home/bjacob/mozilla-central/xpcom/reflect/xptcall/src/md/unix/xptcstubs_x86_64_linux.cpp:153
#22 0x00007f7125fb0059 in SharedStub ()
    at /home/bjacob/mozilla-central/xpcom/reflect/xptcall/src/md/unix/xptcstubs_x86_64_linux.cpp:159
#23 0x00007f71252682be in nsDOMEventListenerWrapper::HandleEvent (this=0x7f70f8a826a0, 
    aEvent=0x7f70f8a9f740)
    at /home/bjacob/mozilla-central/content/events/src/nsDOMEventTargetHelper.cpp:65
#24 0x00007f7125229adf in nsEventListenerManager::HandleEventSubType (this=0x7f70fbe0e660, 
    aListenerStruct=0x7f70fbe0e6a8, aListener=0x7f70f8a826a0, aDOMEvent=0x7f70f8a9f740, 
    aCurrentTarget=0x7f70fab956a0, aPhaseFlags=6, aPusher=0x7fff7c023250)
    at /home/bjacob/mozilla-central/content/events/src/nsEventListenerManager.cpp:1085
#25 0x00007f7125229f9c in nsEventListenerManager::HandleEventInternal (this=0x7f70fbe0e660, 
    aPresContext=0x0, aEvent=0x7f71040197c0, aDOMEvent=0x7fff7c023220, 
---Type <return> to continue, or q <return> to quit---
    aCurrentTarget=0x7f70fab956a0, aFlags=6, aEventStatus=0x7fff7c023228, aPusher=0x7fff7c023250)
    at /home/bjacob/mozilla-central/content/events/src/nsEventListenerManager.cpp:1181
#26 0x00007f71252557e3 in nsEventListenerManager::HandleEvent (this=0x7f70fbe0e660, 
    aPresContext=0x0, aEvent=0x7f71040197c0, aDOMEvent=0x7fff7c023220, 
    aCurrentTarget=0x7f70fab956a0, aFlags=6, aEventStatus=0x7fff7c023228, aPusher=0x7fff7c023250)
    at /home/bjacob/mozilla-central/content/events/src/nsEventListenerManager.h:144
#27 0x00007f7125255d13 in nsEventTargetChainItem::HandleEvent (this=0x7f7110f1e690, aVisitor=..., 
    aFlags=6, aMayHaveNewListenerManagers=0, aPusher=0x7fff7c023250)
    at /home/bjacob/mozilla-central/content/events/src/nsEventDispatcher.cpp:212
#28 0x00007f7125253a9c in nsEventTargetChainItem::HandleEventTargetChain (this=0x7f7110f1e690, 
    aVisitor=..., aFlags=6, aCallback=0x0, aMayHaveNewListenerManagers=0, aPusher=0x7fff7c023250)
    at /home/bjacob/mozilla-central/content/events/src/nsEventDispatcher.cpp:341
#29 0x00007f7125254779 in nsEventDispatcher::Dispatch (aTarget=0x7f70fab956a0, aPresContext=0x0, 
    aEvent=0x7f71040197c0, aDOMEvent=0x7f70f8a9f740, aEventStatus=0x0, aCallback=0x0, aTargets=0x0)
    at /home/bjacob/mozilla-central/content/events/src/nsEventDispatcher.cpp:628
#30 0x00007f7125254b4e in nsEventDispatcher::DispatchDOMEvent (aTarget=0x7f70fab956a0, aEvent=0x0, 
    aDOMEvent=0x7f70f8a9f740, aPresContext=0x0, aEventStatus=0x0)
    at /home/bjacob/mozilla-central/content/events/src/nsEventDispatcher.cpp:691
#31 0x00007f7125268f3f in nsDOMEventTargetHelper::DispatchDOMEvent (this=0x7f70fab956a0, 
    aEvent=0x0, aDOMEvent=0x7f70f8a9f740, aPresContext=0x0, aEventStatus=0x0)
    at /home/bjacob/mozilla-central/content/events/src/nsDOMEventTargetHelper.cpp:229
#32 0x00007f71251fce4d in nsXMLHttpRequest::ChangeState (this=0x7f70fab956a0, aState=2, 
    aBroadcast=1) at /home/bjacob/mozilla-central/content/base/src/nsXMLHttpRequest.cpp:3018
#33 0x00007f71251f6ea5 in nsXMLHttpRequest::OpenRequest (this=0x7f70fab956a0, method=..., url=..., 
    async=1, user=..., password=...)
    at /home/bjacob/mozilla-central/content/base/src/nsXMLHttpRequest.cpp:1790
#34 0x00007f71251f6fec in nsXMLHttpRequest::Open (this=0x7f70fab956a0, method=..., url=..., 
    async=1, user=..., password=..., optional_argc=1 '\001')
---Type <return> to continue, or q <return> to quit---
    at /home/bjacob/mozilla-central/content/base/src/nsXMLHttpRequest.cpp:1817
#35 0x00007f7125fafaea in NS_InvokeByIndex_P (that=0x7f70fab95720, methodIndex=12, paramCount=6, 
    params=0x7fff7c023930)
    at /home/bjacob/mozilla-central/xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_unix.cpp:208
#36 0x00007f71258d0594 in CallMethodHelper::Invoke (this=0x7fff7c0238f0)
    at /home/bjacob/mozilla-central/js/src/xpconnect/src/xpcwrappednative.cpp:2993
#37 0x00007f71258ce71a in CallMethodHelper::Call (this=0x7fff7c0238f0)
    at /home/bjacob/mozilla-central/js/src/xpconnect/src/xpcwrappednative.cpp:2318
#38 0x00007f71258ca638 in XPCWrappedNative::CallMethod (ccx=..., 
    mode=XPCWrappedNative::CALL_METHOD)
    at /home/bjacob/mozilla-central/js/src/xpconnect/src/xpcwrappednative.cpp:2282
#39 0x00007f71258dacc3 in XPC_WN_CallMethod (cx=0x7f711008a800, obj=0x7f70fa752a40, argc=3, 
    argv=0x7f710feeb8b8, vp=0x7fff7c023d10)
    at /home/bjacob/mozilla-central/js/src/xpconnect/src/xpcwrappednativejsops.cpp:1770
#40 0x00007f712416c924 in js_Invoke (cx=0x7f711008a800, argc=3, vp=0x7f710feeb8a8, flags=2)
    at /home/bjacob/mozilla-central/js/src/jsinterp.cpp:823
#41 0x00007f71241598cb in js_Interpret (cx=0x7f711008a800)
    at /home/bjacob/mozilla-central/js/src/jsops.cpp:2226
#42 0x00007f712416c976 in js_Invoke (cx=0x7f711008a800, argc=1, vp=0x7f710feeb038, flags=0)
    at /home/bjacob/mozilla-central/js/src/jsinterp.cpp:831
#43 0x00007f71258c24d5 in nsXPCWrappedJSClass::CallMethod (this=0x7f710fffa8d0, 
    wrapper=0x7f70f9a15780, methodIndex=3, info=0x7f71144d80a0, nativeParams=0x7fff7c024dd0)
    at /home/bjacob/mozilla-central/js/src/xpconnect/src/xpcwrappedjsclass.cpp:1696
#44 0x00007f71258b9951 in nsXPCWrappedJS::CallMethod (this=0x7f70f9a15780, methodIndex=3, 
    info=0x7f71144d80a0, params=0x7fff7c024dd0)
    at /home/bjacob/mozilla-central/js/src/xpconnect/src/xpcwrappedjs.cpp:570
#45 0x00007f7125faffc6 in PrepareAndDispatch (self=0x7f70f9b825c0, methodIndex=3, 
---Type <return> to continue, or q <return> to quit---
    args=0x7fff7c024f70, gpregs=0x7fff7c024ef0, fpregs=0x7fff7c024f20)
    at /home/bjacob/mozilla-central/xpcom/reflect/xptcall/src/md/unix/xptcstubs_x86_64_linux.cpp:153
#46 0x00007f7125fb0059 in SharedStub ()
    at /home/bjacob/mozilla-central/xpcom/reflect/xptcall/src/md/unix/xptcstubs_x86_64_linux.cpp:159
#47 0x00007f7125229adf in nsEventListenerManager::HandleEventSubType (this=0x7f70fc152be0, 
    aListenerStruct=0x7f70fbeba3c8, aListener=0x7f70f9b825c0, aDOMEvent=0x7f71036940e0, 
    aCurrentTarget=0x7f70fa605880, aPhaseFlags=6, aPusher=0x7fff7c025450)
    at /home/bjacob/mozilla-central/content/events/src/nsEventListenerManager.cpp:1085
#48 0x00007f7125229f9c in nsEventListenerManager::HandleEventInternal (this=0x7f70fc152be0, 
    aPresContext=0x7f70fa605000, aEvent=0x7fff7c025580, aDOMEvent=0x7fff7c025420, 
    aCurrentTarget=0x7f70fa605880, aFlags=6, aEventStatus=0x7fff7c025428, aPusher=0x7fff7c025450)
    at /home/bjacob/mozilla-central/content/events/src/nsEventListenerManager.cpp:1181
#49 0x00007f71252557e3 in nsEventListenerManager::HandleEvent (this=0x7f70fc152be0, 
    aPresContext=0x7f70fa605000, aEvent=0x7fff7c025580, aDOMEvent=0x7fff7c025420, 
    aCurrentTarget=0x7f70fa605880, aFlags=6, aEventStatus=0x7fff7c025428, aPusher=0x7fff7c025450)
    at /home/bjacob/mozilla-central/content/events/src/nsEventListenerManager.h:144
#50 0x00007f7125255d13 in nsEventTargetChainItem::HandleEvent (this=0x7f7110f1e230, aVisitor=..., 
    aFlags=6, aMayHaveNewListenerManagers=0, aPusher=0x7fff7c025450)
    at /home/bjacob/mozilla-central/content/events/src/nsEventDispatcher.cpp:212
#51 0x00007f7125253a9c in nsEventTargetChainItem::HandleEventTargetChain (this=0x7f7110f1e0e0, 
    aVisitor=..., aFlags=6, aCallback=0x0, aMayHaveNewListenerManagers=0, aPusher=0x7fff7c025450)
    at /home/bjacob/mozilla-central/content/events/src/nsEventDispatcher.cpp:341
#52 0x00007f7125254779 in nsEventDispatcher::Dispatch (aTarget=0x7f71100adc00, 
    aPresContext=0x7f70fa605000, aEvent=0x7fff7c025580, aDOMEvent=0x0, 
    aEventStatus=0x7fff7c0255cc, aCallback=0x0, aTargets=0x0)
    at /home/bjacob/mozilla-central/content/events/src/nsEventDispatcher.cpp:628
---Type <return> to continue, or q <return> to quit---
#53 0x00007f7124e4adc4 in DocumentViewerImpl::LoadComplete (this=0x7f71105a89c0, aStatus=0)
    at /home/bjacob/mozilla-central/layout/base/nsDocumentViewer.cpp:1029
#54 0x00007f712598e7a0 in nsDocShell::EndPageLoad (this=0x7f71100ad400, aProgress=0x7f71100ad428, 
    aChannel=0x7f70fa9d9050, aStatus=0)
    at /home/bjacob/mozilla-central/docshell/base/nsDocShell.cpp:5764
#55 0x00007f712598e15d in nsDocShell::OnStateChange (this=0x7f71100ad400, 
    aProgress=0x7f71100ad428, aRequest=0x7f70fa9d9050, aStateFlags=131088, aStatus=0)
    at /home/bjacob/mozilla-central/docshell/base/nsDocShell.cpp:5642
#56 0x00007f71259bdfc6 in nsDocLoader::FireOnStateChange (this=0x7f71100ad400, 
    aProgress=0x7f71100ad428, aRequest=0x7f70fa9d9050, aStateFlags=131088, aStatus=0)
    at /home/bjacob/mozilla-central/uriloader/base/nsDocLoader.cpp:1317
#57 0x00007f71259bccb4 in nsDocLoader::doStopDocumentLoad (this=0x7f71100ad400, 
    request=0x7f70fa9d9050, aStatus=0)
    at /home/bjacob/mozilla-central/uriloader/base/nsDocLoader.cpp:929
#58 0x00007f71259bc89d in nsDocLoader::DocLoaderIsEmpty (this=0x7f71100ad400, aFlushLayout=1)
    at /home/bjacob/mozilla-central/uriloader/base/nsDocLoader.cpp:805
#59 0x00007f71259bc3c2 in nsDocLoader::OnStopRequest (this=0x7f71100ad400, 
    aRequest=0x7f70fc1fda80, aCtxt=0x0, aStatus=0)
    at /home/bjacob/mozilla-central/uriloader/base/nsDocLoader.cpp:700
#60 0x00007f7124bf75ed in nsLoadGroup::RemoveRequest (this=0x7f71100970e0, request=0x7f70fc1fda80, 
    ctxt=0x0, aStatus=0) at /home/bjacob/mozilla-central/netwerk/base/src/nsLoadGroup.cpp:680
#61 0x00007f712516a637 in nsDocument::DoUnblockOnload (this=0x7f71143a1000)
    at /home/bjacob/mozilla-central/content/base/src/nsDocument.cpp:7086
#62 0x00007f712516a3f8 in nsDocument::UnblockOnload (this=0x7f71143a1000, aFireSync=1)
    at /home/bjacob/mozilla-central/content/base/src/nsDocument.cpp:7028
#63 0x00007f7125253535 in ~nsLoadBlockingPLDOMEvent (this=0x7f70f9baa8d0, 
    __in_chrg=<value optimized out>)
    at /home/bjacob/mozilla-central/content/events/src/nsPLDOMEvent.cpp:86
---Type <return> to continue, or q <return> to quit---
#64 0x00007f712525358c in ~nsLoadBlockingPLDOMEvent (this=0x7f70f9baa8d0, 
    __in_chrg=<value optimized out>)
    at /home/bjacob/mozilla-central/content/events/src/nsPLDOMEvent.cpp:88
#65 0x00007f7125f28d56 in nsRunnable::Release (this=0x7f70f9baa8d0) at nsThreadUtils.cpp:55
#66 0x00007f7124baebc8 in ~nsCOMPtr (this=0x7fff7c0260b0, __in_chrg=<value optimized out>)
    at ../../dist/include/nsCOMPtr.h:510
#67 0x00007f7125f940ce in nsThread::ProcessNextEvent (this=0x7f711b5380d0, mayWait=0, 
    result=0x7fff7c02612c) at /home/bjacob/mozilla-central/xpcom/threads/nsThread.cpp:520
#68 0x00007f7125f292bc in NS_ProcessNextEvent_P (thread=0x7f711b5380d0, mayWait=0)
    at nsThreadUtils.cpp:250
#69 0x00007f7125e64b04 in mozilla::ipc::MessagePump::Run (this=0x7f711b5dc340, 
    aDelegate=0x7f711b555840) at /home/bjacob/mozilla-central/ipc/glue/MessagePump.cpp:118
#70 0x00007f7126008957 in MessageLoop::RunInternal (this=0x7f711b555840)
    at /home/bjacob/mozilla-central/ipc/chromium/src/base/message_loop.cc:216
#71 0x00007f71260088dc in MessageLoop::RunHandler (this=0x7f711b555840)
    at /home/bjacob/mozilla-central/ipc/chromium/src/base/message_loop.cc:199
#72 0x00007f712600886d in MessageLoop::Run (this=0x7f711b555840)
    at /home/bjacob/mozilla-central/ipc/chromium/src/base/message_loop.cc:173
#73 0x00007f7125d17675 in nsBaseAppShell::Run (this=0x7f7113fab5c0)
    at /home/bjacob/mozilla-central/widget/src/xpwidgets/nsBaseAppShell.cpp:175
#74 0x00007f7125a7bb09 in nsAppStartup::Run (this=0x7f71129b3100)
    at /home/bjacob/mozilla-central/toolkit/components/startup/src/nsAppStartup.cpp:184
#75 0x00007f7124b9ee9d in XRE_main (argc=4, argv=0x7fff7c026d48, aAppData=0x7f711b5250f0)
    at /home/bjacob/mozilla-central/toolkit/xre/nsAppRunner.cpp:3564
#76 0x000000000040214c in main (argc=4, argv=0x7fff7c026d48)
    at /home/bjacob/mozilla-central/browser/app/nsBrowserApp.cpp:158
To clarify:

The above bug is what happens _if_ we try to pass the 0x0 size directly to GL.

The patch attached here does NOT do that --- it returns immediately without making any GL call. Hence it doesn't crash.
Attached patch Allow zero-sized textures (obsolete) — Splinter Review
Fix/update comment.

Filed the bug against jemalloc: bug 566017
Attachment #445414 - Attachment is obsolete: true
Attachment #445434 - Flags: review?(vladimir)
Attachment #445414 - Flags: review?(vladimir)
Comment on attachment 445434 [details] [diff] [review]
Allow zero-sized textures

Hmm, I realize that the man pages (and the ES 2.0 spec) say that 0 is allowed, but I have no idea what that means.  Is this a Mesa bug?  It's not valid to just ignore a TexImage2D call with 0,0 width because at the very least if it's valid to do so, then it has to destroy the current texture contents instead of making no change.
Attachment #445434 - Flags: review?(vladimir) → review-
No, it's not a Mesa bug that passing 0x0 to glTexImage2D crashes, it's a bug in (Mozilla's version of) jemalloc, specifically jemalloc's implementation of posix_memalign. See bug 566017. In the meanwhile, we can't pass 0x0 to glTexImage2D. So let's either fix that bug 566017 in priority, or perhaps work around it by changing all zero sizes (0xN and Nx0) to 1x1, passing a dummy array.
This patch is mutually exclusive with the next one.

It replaces 0-sized textures by 1x1 so we have something correct and non-crashy today. It is a work-around for bug 566017, which makes OSMesa crash on 0-sized textures when used within Firefox.
Attachment #445434 - Attachment is obsolete: true
Attachment #445539 - Flags: review?(vladimir)
This patch is mutually exclusive with the previous one.

It just passes 0x0 textures to OpenGL, not treating them as a special case.

This is the simplest and most correct approach, but currently crashes with certain software renderers like OSMesa because of bug 566017.
Attachment #445540 - Flags: review?(vladimir)
Depends on: 566017
Can you try osmesa without jemalloc?  I think you should be able to just relink the firefox binary without the jemalloc lib, or rebuild with --disable-jemalloc.  If OSMesa allows for 0x0 normally, then yeah, it sounds like we're just being screwed by jemalloc's bug and we can fix that.
OK, I tried it, and that works:
 - applying the patch "Pass 0-sized textures to OpenGL" here
 - building firefox with --disable-jemalloc
works, no crash, with OSMesa. So that confirms that's a bug in jemalloc. Anyway I have submitted a patch in bug 566017, that solves the problem for me, so hopefully that can get resolved soon. So forget the other patch "Replace 0-sized textures by 1x1".
There is many "corner cases" that are not well defined (if at all) in OpenGL :

- What is the behavior/value of accessing a 0x0 texture from a shader? (some docs say that 0x0 means null texture, in that case that could be opaque white instead of 0,0,0,0 unintuitively enough)
- What happens when a 0x0 texture is attached to a framebuffer?
- What happens when you do readPixels from such a framebuffer?

Also Direct3D do not accept 0x0 textures, they will be silently created as 1x1 texture instead, would this cause (consistency) problems with WebGL implementations on top of Direct3D ?
Fixed this for now -- but we should revisit the issue on the webgl list.

http://hg.mozilla.org/mozilla-central/rev/5d7d04b5a24e
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Assignee: nobody → bjacob
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: