Last Comment Bug 760968 - add --disable-webgl and --disable-canvas mozconfig options
: add --disable-webgl and --disable-canvas mozconfig options
Status: NEW
:
Product: Core
Classification: Components
Component: Audio/Video: Playback (show other bugs)
: Trunk
: All All
: -- enhancement with 1 vote (vote)
: ---
Assigned To: Nobody; OK to take it and work on it
:
Mentors:
Depends on: 857022
Blocks:
  Show dependency treegraph
 
Reported: 2012-06-03 03:42 PDT by :aceman
Modified: 2015-09-20 17:19 PDT (History)
4 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments

Description :aceman 2012-06-03 03:42:48 PDT
+++ This bug was initially created as a clone of Bug #760795 comment 10+++

Boris Zbarsky (:bz) 2012-06-02 17:55:11 CEST
r=me, but note that the new DOM bindings for WebGLContext almost certainly don't compile without MOZ_MEDIA either: I was told that was not a supported configuration, and there is no real infrastructure in WebIDL to make methods conditional on compiler ifdefs at the moment...

:aceman 2012-06-02 22:37:08 CEST
bz was right, after today's hg update WebGLRenderingContextBinding.cpp fails. So, is there a --disable-webgl mozconfig option?

Boris Zbarsky (:bz) 2012-06-03 06:37:32 CEST
There isn't, sorry.
Note that once we convert 2d canvas to new bindings it would have the same problem: the canvas spec explicitly lists HTMLVideoElement as one of the overloads for drawImage.  And I really doubt there will be a --disable-2d-canvas option...

------------------------------------
The request: either add new --disable-webgl and --disable-canvas mozconfig build options or sort out if building without MOZ_MEDIA still is supported. The option --disable-ogg undefines MOZ_MEDIA and it worked like that till today. But was broken by recent webgl bindings, that are hard to disable, as noted above.

The use case for these options:
For faster rebuilds of development builds it would be beneficial to ignore unneeded code for some products (in these cases Thunderbird and Seamonkey).
Thunderbird even has HW acceleration disabled by default so webgl seems to be an unsupported feature (by default).
Comment 1 cajbir (:cajbir) 2012-06-03 03:46:31 PDT
We could keep MOZ_MEDIA but disabled all codecs with a configure option. This would leave the video/audio elements there but they'd not be able to play anything.
Comment 2 :aceman 2012-06-03 04:15:35 PDT
Yes, that would be a solution too, in a similar way bug 760795 was solved.

What about webgl and canvas? Would it be doable to disable them?
Comment 3 Boris Zbarsky [:bz] (TPAC) 2012-06-03 12:26:49 PDT
I'm 99% sure parts of the toolkit UI use 2d canvas.

Note You need to log in before you can comment on or make changes to this bug.