art with code

2009-11-07

Done with canvas3d-tests WebGL port

As far as I know, the canvas3d-tests are now all ported to WebGL. However, I'm using a mix of GLSL 1.20 and 1.30 in the tests, which probably isn't a good idea. Porting all shaders to 1.20 or whatever GLSL ES uses as its base would be a good next step.

Hmm, I have an apigen in the git repo that generates GL constant -checking C++ wrappers for OpenGL functions. That could be hacked a bit to make it create better autotests.

The biggest issue with the current tests is that they only cover a small portion of the API, as I focused on writing only evil tests manually. The rest of the API gets banged by the API fuzzer to see if anything crashes. Evil tests then are me trying to cause a segfault or read back information I shouldn't be able to, and for general array indexing validation. I wrote them for things that do array access, read back data from OpenGL, or that seem iffy in some other way.

So. TODO: Port shaders to 1.20, better autotests, file bugs.

2 comments:

Alessandro said...

Hi !
Very Interesting !!

I checked the methods signatures, and I've found some mismatches between Nihilogic's WebGL Cheat Sheet and yours

Example:
(Nihilogic's)
void bufferSubData(long target, long offset, Object data);
and
(yours)
void bufferSubData (int target, int offset, Array data, int elementType);

Example:

void bufferData(long target, Object data, long usage);
and
void bufferData (int target, Array data, int elementType, int usage);

Thanks !

Ilmari Heikkinen said...

Hi! Good catch on the method signatures, gotta fix those, thanks!

Blog Archive