Vladimír Vondruš
19e0e96d74
Updated copyright year.
6 years ago
Vladimír Vondruš
9d104a7e88
Shaders: document how to propagate generic attribs to shader code.
6 years ago
Vladimír Vondruš
28965d4887
Shaders: I happily forgot SwiftShader has broken gl_VertexID.
...
Sigh.
6 years ago
Vladimír Vondruš
e8f36033f9
Shaders: GS is needed only for wireframe.
...
So don't skip the test when rendering just object/primitive/.. ID. Turns
out due to the skip this test was never executed on SwiftShader, and it
thus needs some threshold bumping.
6 years ago
Vladimír Vondruš
698a7ed24c
Shaders: whoopsie.
6 years ago
Vladimír Vondruš
062055d20d
Shaders: add vertex ID visualization to MeshVisualizer.
...
Helps visualizing face connectivity (or the lack of it).
6 years ago
Vladimír Vondruš
7a58bf5e42
Shaders: reorder code for consistency.
...
It's InstancedObjectId and then PrimitiveId in the flags, so follow the
same order in the code also.
6 years ago
Vladimír Vondruš
6eccc479f0
Shaders: simplify a bunch of repeated checks in shader code.
6 years ago
Vladimír Vondruš
b858385b84
Shaders: unify assert for common flags in 2D and 3D meshvisualizer.
6 years ago
Vladimír Vondruš
86a5a63af9
Test: most tests now pass on Zink as well.
...
Just adding a bunch of extension checks that I thought I would never
need again.
6 years ago
Vladimír Vondruš
881a50f7fa
Shaders: clarify that object ID features need GL 3.0 extensions.
...
Important for Zink, which has neither of them.
6 years ago
Vladimír Vondruš
8b0ad005d8
Shaders: properly skip a test if image plugins are not available.
6 years ago
Vladimír Vondruš
97e3e2a8fe
MeshTools,Shaders: make the rendering tests pass on llvmpipe.
6 years ago
Michael Tao
e5a6f543a0
Shaders: ambient also changes color with VertexColor in Phong.
...
Also adapt the test to explicitly check for this.
6 years ago
Vladimír Vondruš
65a2ced2a7
Make this compile and test cleanly with CORRADE_NO_ASSERT defined.
6 years ago
Vladimír Vondruš
c03ed3af75
doc: show how to set up blending for alpha / transparency.
...
Hopefully more discoverable now also.
6 years ago
Vladimír Vondruš
13c1fcdbfc
Shaders: forgot to list this file.
...
Made the WebGL test fail.
6 years ago
Vladimír Vondruš
55685ea382
Shaders: implement instancing in Phong.
6 years ago
Vladimír Vondruš
a1f1f66c04
Shaders: implement instancing in Flat.
6 years ago
Vladimír Vondruš
e6010388c3
Shaders: reorganize the Flat and Phong docs.
...
Dry blabber followed by dry code is worse than those two interleaved.
6 years ago
Vladimír Vondruš
638f96f099
Shaders: be sure to list required extensions in generic attribs.
...
Those aren't needed when the attributes are not used non-instanced, but
that's extremely unlikely.
6 years ago
Vladimír Vondruš
c9ea6aba2e
Shaders: grumble.
6 years ago
Vladimír Vondruš
3e310cbd94
Shaders: note to self: *save* before commiting.
6 years ago
Vladimír Vondruš
9da27ce8dd
Shaders: ensure test description is set before skipping it.
6 years ago
Vladimír Vondruš
06ab5b33cd
Shaders: fix strict aliasing warnings.
6 years ago
Vladimír Vondruš
e3841ade7e
Shaders: object and primitive ID visualization in MeshVisualizer.
6 years ago
Vladimír Vondruš
60968779da
Shaders: avoid using deprecated functionality in a test.
6 years ago
Vladimír Vondruš
46d492fcc9
Shaders: list forgotten MeshVisualizer test files.
6 years ago
Vladimír Vondruš
6b0d29bec2
Shaders: turn a construction test into an instanced one.
...
Got more cases to test for.
6 years ago
Vladimír Vondruš
1cb7193034
Shaders: reorder MeshVisualizer docs.
6 years ago
Vladimír Vondruš
02525527a4
Shaders: ability to render instanced object ID in Flat/Phong.
6 years ago
Vladimír Vondruš
3759d26a7d
Shaders: NO, these are not layers.
6 years ago
Vladimír Vondruš
171e8a5301
Shaders: remove MeshVisualizer default behavior.
...
It was rendering everything with a plain color, which is rather useless.
Moreover it wasn't consistent with TBN visualization where you might
actually want only the lines rendered and not the triangle.
6 years ago
Vladimír Vondruš
6299ece980
Shaders: test MeshVisualizer TBN direction defaults.
...
Now possible, with compile() supporting the new attribs and primitives
generating them.
Finally out of this cyclic dependency hell, yay.
6 years ago
Vladimír Vondruš
c82a34c157
Shaders: doc++
6 years ago
Vladimír Vondruš
1b21e4e7ba
Primitives: switch to an enum set for texturable primitives.
...
Making room for GenerateTangents in 3D, and keeping the 2D ones
consistent with 3D. Also renamed GenerateTextureCoords to
GenerateTextureCoordinates in the remaining places to be consistent with
naming in the rest of the APIs.
6 years ago
Vladimír Vondruš
5b569942b8
Shaders: tangent space visualization in MeshVisualizer3D.
6 years ago
Vladimír Vondruš
c880e6293a
Shaders: enable noperspective in MeshVisualizer properly.
...
This makes existing tests slightly broken, which is good (if it
wouldn't, the thresholds would be too huge). Since the addition of ES3.2
geometry shaders (which broke this) happened long before there were
rendering tests for shaders, this breakage wasn't caught until now. Of
course proper tests would include the perspective case from the previous
commit since the very beginning, but that's hard to do when you're
testing long after the code was written.
The test files are now RLE-encoded, which makes them significantly
smaller (tho I assume Git would further compress both anyway). Not
updating existing files to RLE yet to avoid repo history bloat, doing
that the next time they get changed.
6 years ago
Vladimír Vondruš
73b6d1084a
Shaders: test perspective interpolation in MeshVisualizer wireframe.
...
Broken, sigh.
6 years ago
Vladimír Vondruš
74c75178de
Shaders: add a 2D variant of MeshVisualizer.
6 years ago
Vladimír Vondruš
566713e68c
Shaders: improve MeshVisualizer docs a bit.
6 years ago
Vladimír Vondruš
1a53976447
Shaders: delete duplicate code also in shader tests.
...
Half done in 2d1d9f4b29 , but these got
forgotten.
6 years ago
Vladimír Vondruš
fff1b6e5cf
Shaders: delete 8 kB of needless shader code.
...
I get the best ideas on the shitter. I should go there more often.
6 years ago
Vladimír Vondruš
f3a92c2afb
Shaders: rethink generic attribute allocation from scratch.
...
This adds binormals, object IDs and instanced transformation, but has to
break existing locations in order to provide new guarantees.
6 years ago
Vladimír Vondruš
0c7e3bf96a
Shaders: minor cleanup.
6 years ago
Vladimír Vondruš
9a06b3515b
Shaders: implement texture coordinate transformation for all shaders.
...
Except MeshVisualizer and VertexColor, which don't have any texturing,
so there it's not needed. In most cases the tests are reusing existing
ground truth files and only modifying transformations / flipping images.
6 years ago
Vladimír Vondruš
a35d53118b
Shaders: name the textureCoordinates attribute consistently in GLSL.
...
Interestingly enough, on Phong it was named textureCoords while on the
C++ side it was asking for textureCoordinates, and I don't remember this
being an issue *ever*, on any driver.
6 years ago
Vladimír Vondruš
0329721405
Shaders: fix default alpha mask in a zero-light Phong on GLES.
...
A corner case of a corner case, of a corner case. Adapted the test to
check the defaults as well.
6 years ago
Vladimír Vondruš
27f0c34372
Shaders: remove last forgotten deprecated bits.
...
Leftover from b4f88f00ab .
6 years ago
Vladimír Vondruš
1bc4101100
Shaders: make method chaining return types consistent in templates.
...
Not sure why C++ allows either, it only leads to inconsistency.
6 years ago