Commit Graph

951 Commits

Author SHA1 Message Date
Bas Schouten
e89848a4cc Bug 655836: Use Snapshot API for drawing one Azure canvas to another. r=roc 2011-10-05 01:12:23 +02:00
Brian Hackett
e89780c40d Remove jsobj.h from installed headers, bug 690943. r=luke 2011-10-04 07:06:54 -07:00
Justin Lebar
01cb8b32e2 Bug 686345 - Don't subtract from our count of canvas's memory if we never added to the count. r=jmuizelaar 2011-10-03 12:35:32 -04:00
Marco Bonardo
708de44700 Merge mozilla-central to mozilla-inbound 2011-10-03 17:13:54 +02:00
Benoit Jacob
3b0d019742 Bug 522193 - WebGL calls are slow because of memory allocation churning - r=roc
WebGL objects keep an array of refptrs of other WebGL objects owning references to them. In practical cases, the size of this array can oscillate between 0 and 2 at high frequency. nsTArray throws away its whole storage (mHdr) when its size hits 0. This patch makes us use a nsAutoTArray with a pre-allocated size of 2 or 8 depending on WebGL object types.
2011-10-03 08:41:56 -04:00
Atul Aggarwal
e9468a5526 Bug 673820 - Rewriting StringToInteger function to match behavior of Rules for parsing Integers specified in spec. r=jonas f=mounir,Ms2ger,dbaron 2011-10-01 19:30:27 +05:30
Doug Sherk
5b5702d6a4 Bug 684853: implement OES_standard_derivatives
Implemented OES_standard_derivatives and fallbacks if it isn't available. Exposes dFdx, dFdy, and fwidth functions to WebGL scripts.
2011-10-01 00:45:50 -04:00
Benoit Jacob
93ca6f5084 Bug 684882 - on Macs with Intel GPUs, limit cube map size to 512 - r=jrmuizel 2011-09-29 10:13:49 -04:00
Benoit Jacob
b79d3d9d20 Bug 684882 - back out db67bdba5ca8 2011-09-29 10:13:49 -04:00
Benoit Jacob
50ebdccf9f Bug 684882 - back out b4fd4fd0dc3f 2011-09-29 10:13:49 -04:00
Michael Wu
d8e503c38b Bug 675553 - Switch from PRBool to bool on a CLOSED TREE , r=bsmedberg,khuey,bz,cjones
--HG--
rename : tools/trace-malloc/bloatblame.c => tools/trace-malloc/bloatblame.cpp
2011-09-28 23:19:26 -07:00
Benoit Jacob
ca2a58f371 Bug 630728 - Intermittent test_webgl_conformance_test_suite.html | Test expected to fail, but passed: conformance/texture-npot.html; r=ehsan 2011-09-29 00:06:03 -04:00
Ehsan Akhgari
b542efd4e6 Bug 666414 - Prevent AddRef and Release from being called on the pointers wrapped in nsCOMPtr and nsRefPtr; r=bsmedberg 2011-09-16 16:22:44 -04:00
Benoit Jacob
e0690707cd Bug 684882 - Random video memory grabbed into WebGL cube map textures on Mac OS, including on 10.7.1, on Intel GPUs - r=jrmuizel
This patch does 3 things on Macs with Intel GPUs:
 * prevents attaching a cube map to a framebuffer.
     Test case: http://codeflow.org/webgl/irradiance/
 * skips glGenerateMipmaps on cube maps
 * since cube maps are now missing their mipmaps, prevents setting on them a minification filter that requires a mipmap, but only from OpenGL's point of view, not from WebGL's.
2011-09-23 20:29:40 -04:00
Benoit Jacob
c8be5c56a0 Bug 686398 - WebGL crash, addressing Texture ImageInfo out of bounds - r=jrmuizel
We were not checking that ImageInfoAt(level, face) existed before dereferencing it.
2011-09-22 02:57:26 -04:00
Benoit Jacob
b26a2af7ce Bug 685793 - WebGL buffer overflow issue and access to out of range memory - r=jrmuizel
We were not checking for integer overflow in a required-buffer-size computation. Fixing this by using CheckedInt.
2011-09-22 02:55:10 -04:00
Boris Zbarsky
bd01572fc8 Bug 444641 part 4. Remove the data: special-casing for images in canvas, since we now set the right principal for data: images. r=roc 2011-09-20 17:00:42 -04:00
Jeff Muizelaar
6f22e3e5d3 Bug 684859. Add telemetry to track when 2d or webgl canvas is used. r=bas
--HG--
extra : transplant_source : %FB5%40%FA%3A%2Cg%AF%14W%D3%E8%D1y%03%25%D1%E9%22%AB
2011-09-19 16:08:56 -04:00
Matt Woodrow
a868d859af Bug 676690 - Don't release DataSourceSurface pointers until we have finished accessing the pixels. r=Bas 2011-09-14 16:16:23 -07:00
Justin Wood
f90fd5539e m-c -> m-i merge 2011-09-09 22:04:09 -04:00
Benoit Jacob
247aca9d4a Bug 684882 - work around a glGenerateMipmap bug on Mac - r=jrmuizel 2011-09-09 18:00:20 -04:00
Benoit Jacob
7a24dd63e2 Bug 682335 - crash [@ WebGLContext::BufferSubData_array] - r=jrmuizel 2011-09-09 18:00:20 -04:00
Doug Sherk
f9a5610153 Bug 683710: added stripping of comments from shader sources before compiling and check for illegal characters, mostly from webkit code r=bjacob
This code is copied mostly from WebKit. It strips out comments from shader source code before actually compiling it, so that the comments can have illegal characters. It was benchmarked and it was noted that a test attached to the bug ticket took about twice as long with these changes.

This includes the patch from bug 680722 to check for illegal characters.
2011-09-07 17:17:44 -04:00
Ehsan Akhgari
99a7871114 Bug 686026 - test_mozGetAsFile.html runs finish three times, instead of once; r=joedrew 2011-09-09 18:17:50 -04:00
Boris Zbarsky
25316d6093 Bug 685518 part 3. Add crossorigin 2d canvas tests. r=roc 2011-09-09 17:58:40 -04:00
Boris Zbarsky
3b76a63272 Bug 685518 part 2. Move the crossorigin webgl test to a saner location so I can add cross-origin non-webgl tests. r=roc
--HG--
rename : content/canvas/test/webgl/crossorigin/image-allow-credentials.png => content/canvas/test/crossorigin/image-allow-credentials.png
rename : content/canvas/test/webgl/crossorigin/image-allow-credentials.png^headers^ => content/canvas/test/crossorigin/image-allow-credentials.png^headers^
rename : content/canvas/test/webgl/crossorigin/image-allow-star.png => content/canvas/test/crossorigin/image-allow-star.png
rename : content/canvas/test/webgl/crossorigin/image-allow-star.png^headers^ => content/canvas/test/crossorigin/image-allow-star.png^headers^
rename : content/canvas/test/webgl/crossorigin/image.png => content/canvas/test/crossorigin/image.png
rename : content/canvas/test/webgl/crossorigin/test_webgl_crossorigin_textures.html => content/canvas/test/crossorigin/test_webgl_crossorigin_textures.html
2011-09-09 17:58:38 -04:00
Boris Zbarsky
f4ec90e1f0 Bug 685518 part 1. Look at the image CORS mode for drawImage into a canvas 2d context. r=roc 2011-09-09 17:58:35 -04:00
Phil Ringnalda
946b02e238 Back out d333f4021aaf, 5e90688c720e and bdb0bff93ce8 for Windows build redness 2011-09-07 15:20:26 -07:00
Doug Sherk
73534e1d22 Bug 683710: added stripping of comments from shader sources before compiling and check for illegal characters, mostly from webkit code r=bjacob
This code is copied mostly from WebKit. It strips out comments from shader source code before actually compiling it, so that the comments can have illegal characters. It was benchmarked and it was noted that a test attached to the bug ticket took about twice as long with these changes.

This includes the patch from bug 680722 to check for illegal characters.
2011-09-07 17:17:44 -04:00
Benoit Jacob
d36cfc4ea7 back out 1b09c80c46c3 (bug 680722, WebGL shader validation) because of regression, see bug 684312 and 683710 2011-09-02 15:43:03 -04:00
Doug Sherk
ffb5ce184d Bug 682172: fixed tex2DImage WebGL function, which was rejecting 0-size textures and doing an incorrect validation - r=bjacob
There was actually some surrounding logic breaking 0-size textures. It was because there was code that basically checked "did uint=negative_num*other_vars overflow". For incorrect validation, two copies of the same variable (one stored internally and one passed in) were available to the function, but the one stored internally was being validated, while the version passed in wasn't. The fix for this was simply checking the passed var instead.
2011-09-01 15:28:34 -04:00
Doug Sherk
384fd43041 Bug 681835: fixed a series of object deletion conformance issues r=bjacob
The bindX() commands were erroring with INVALID_VALUE when they're instead supposed to simply fail silently when they're given a deleted object. Additionally, the getParameter() function was failing after its associated variable was deleted, sometimes returning values when it should return null.
* * *
Bug 681835: WebGL fix for previous patch which introduced a bug with deletion

DeleteRenderbuffer and DeleteFramebuffer weren't checking if the deleted buffer was the currently bound buffer before deleting them. This patch implements this functionality. A separate test case patch was also submitted to Khronos:
http://www.khronos.org/bugzilla/show_bug.cgi?id=518
2011-09-01 15:28:34 -04:00
Doug Sherk
1be48befb7 Bug 593867: removed nvidia check for forcing getProgramParameter() so it now returns 1 on any Mac OSX setup 2011-09-01 15:28:34 -04:00
Benoit Jacob
4e7482058c Bug 658856 - implement drawingbufferWidth/Height - r=jmuizelaar
These are new WebGLRenderingContext attributes exposing the actual drawing buffer size
2011-09-01 15:28:34 -04:00
Benoit Jacob
982e3f2239 Bug 681715 - rework the WebGL test runner HTML to make more room for the test page - r=joe
This makes the buffer-offscreen-test.html test pass. It was failing because it relied on getting composited and fell outside the visible area.
2011-09-01 15:28:34 -04:00
Matt Woodrow
9c9e398ae8 Bug 591358 - Delay creation of canvases until we actually draw to them. r=roc 2011-08-31 14:03:31 +12:00
Benoit Jacob
5de2c95a0d Bug 682506 - Upgrade ANGLE to r740 - r=upstream
I need this now especially as it gets us the shader modification mechanisms to work around Mac GL crashes, see bug 665578

The relevant ANGLE revisions are 734, 738, and 740 fixes a bug in 738.

This also allows us to reset our set of cherrypicked ANGLE revisions which was starting to be very big.
2011-08-30 18:50:05 -04:00
Benoit Jacob
03bf748a6a Bug 683216 - shut up a WebGL test failure about OES_texture_float - r=jrmuizel
This test is valid, but flaky as it relies on GC happening at a particular time. A recent JS engine change making it actually happen caused it to actually catch a bug we've always had in the OES_texture_float impl, see the discussion on bug 630672, and I don't have time to fix that now.
2011-08-30 18:01:50 -04:00
Marco Castelluccio
7cb0506077 Bug 682744 - Sprinkle some do_QueryObject fairy dust around the tree; r=khuey 2011-08-30 22:45:31 +01:00
Kyle Huey
2eb5f2b441 Merge m-c to b-s. 2011-08-28 06:00:17 -04:00
Benoit Jacob
38a46bd1e5 Bug 679864 - [5/5] Upgrade WebGL conformance test suite to r15318
This is just removing some old cruft, mainly old patches that are not needed anymore.
2011-08-19 11:39:00 -04:00
Benoit Jacob
bbda139a99 Bug 679864 - [4/5] Upgrade WebGL conformance test suite to r15318
This reapplies the patch replacing remote images by local ones on http://example.com and http://mochi.test:8888 URLs.
2011-08-19 11:39:00 -04:00
Benoit Jacob
1cc7f76c99 Bug 679864 - [3/5] Upgrade WebGL conformance test suite to r15318
This patch disables the quickCheckAPI.html page, with this comment:

this test causes whichever comes after to intermittently time out.
forcing a GC run doesn't solve this issue. Could be something about using a random amount of memory that
can be too high, causing e.g. swapping.
2011-08-22 11:52:19 -04:00
Benoit Jacob
ea88b927bd Bug 679864 - [2/5] Upgrade WebGL conformance test suite to r15318
This patch updates the lists of failing tests, and adds some code to ignore a few intermittently failing tests: 1 on Linux and 4 on Mac
2011-08-19 11:39:00 -04:00
Benoit Jacob
7051305d50 Bug 679864 - [1/5] Upgrade WebGL conformance test suite to r15318
This is the actual upgrade. The canonical URL for this test suite is

https://cvs.khronos.org/svn/repos/registry/trunk/public/webgl/sdk/tests/
2011-08-19 11:39:00 -04:00
Benoit Jacob
b097dfda2f Bug 669013 - Despite supporting OES_texture_float, getSupportedExtensions still returns no extensions - r=joe 2011-08-15 15:53:02 -04:00
Malini Das
02665c9658 Bug 367393 - Add a packed MochiKit that contains only SimpleTest dependencies- plain 1/1. r=jmaher, a=test-only 2011-08-12 12:21:42 -04:00
Malini Das
da32b5cbd3 Bug 367393 - Add a packed MochiKit that contains only SimpleTest dependencies- update tests. r=jmaher, a=test-only 2011-08-12 12:21:37 -04:00
Benoit Jacob
da8591f8ce Bug 676413 - test crossOrigin without value - r=bz 2011-08-10 18:25:22 -04:00
Benoit Jacob
0a3e57c7ac Bug 676413 - test that crossOrigin="" or invalid value has the behavior of "anonymous" - r=bz 2011-08-10 18:25:22 -04:00