Vladimír Vondruš
6465fa14c9
GL: fix undefined behavior and potential leaks in Mesh.
...
The change done in 680144f1c5 was not
properly handling these cases:
* Mesh(NoCreateT) and wrap() were not constructing the internal vector,
which blew up when move-assigning another instance.
* ~Mesh() was not destructing the internal vector if the VAO ID was
zero or non-owning wrap() was used.
Strangely enough none of these were causing *any* problems for me on
Linux (even ASan was totally quiet and due to the unfortunate
combination of bugs even when I assigned totally random data to the
storage vector). This however blew up on MSVC, assuming there the
implementation is more checked.
Because it's possible to construct Mesh with no GL context available,
the move construction and destruction needs to avoid accessing Context
unless really necessary (it would be also unclear which type of vector
should be constructed if we have no context).
Extended the tests to handle hopefully all the cases.
8 years ago
Vladimír Vondruš
d0004865e5
modules: properly handle GLVND also in case of context libraries.
8 years ago
Vladimír Vondruš
ff7b9eadcb
modules: doc++
8 years ago
Vladimír Vondruš
816891ec2e
doc: keywords to make important pages more accessible.
8 years ago
Vladimír Vondruš
3a0d6ee57a
Hide m.css-specific variables from Doxygen.
8 years ago
Vladimír Vondruš
3dc5957142
package/ci: adapt to FindSDL2 updates on WinRT.
8 years ago
Vladimír Vondruš
c2e47ed10c
modules: doc++
8 years ago
Vladimír Vondruš
e505e52cf2
modules: updated FindCorrade.cmake.
8 years ago
Vladimír Vondruš
453fc0b3e7
Shaders: more convenient VertexColor::Color[34] attribute specifiers.
...
Much easier to write (and explain!) than Shaders::VertexColor2D::Color{
Shaders::VertexColor2D::Color::Components::Three}. Ugh. Why again it
took me *years* to realize?
8 years ago
Vladimír Vondruš
53c6d763ae
GL: make the usage parameter in Buffer::setData() optional.
...
So simple change, so big usability impact. These hints don't do much to
performance anyway.
8 years ago
Vladimír Vondruš
077dc67b4f
doc: updated changelog.
8 years ago
Vladimír Vondruš
f922f1e740
CMake: prefer GLVND if on CMake 3.11.
...
This *did not* make things simpler. At all. Ugh. Can I follow
Apple and deprecate GL too?
8 years ago
Squareys
52b7c26022
modules: make FindSDL2.cmake also find debug libraries.
...
Fixes an issue with SDL2d.dll not being copied to the output directory
with vcpkg.
8 years ago
Vladimír Vondruš
00c0aa468e
GL: no need to bind a buffer to do a DSA operation.
...
Breaindead copypaste error. Sorry for being shitty here.
8 years ago
Vladimír Vondruš
f7122d3ce6
Shaders: explicitly list deleted/defaulted copy/move constructor.
...
Two reasons:
* documentation
* making it actually work because the rules are so complex and ever
changing that a thing I thought "just worked" in fact did not work at
all
The Vector tests now compile again.
8 years ago
Vladimír Vondruš
f27b75bd65
Shaders: improve copy/move construction tests.
...
Doesn't compile at the moment because AbstractVector has a private
constructor and so the move constructors are not generated or something.
8 years ago
Vladimír Vondruš
b1acabcda1
GL: document copyability/movability explicitly in all classes.
...
In particular, the AbstractTexture and AbstractQuery subclasses didn't
have that. I can't remember the rules about noexcept (and the users even
less), so let's make that explicit.
8 years ago
Vladimír Vondruš
f47d591244
GL: move noncopyability tests to non-GL test executables.
8 years ago
Vladimír Vondruš
c99fe2888d
Trade: non-random defaults for PhongMaterialData.
8 years ago
Vladimír Vondruš
2fb7913b07
Trade: return Color4 from PhongMaterialData.
...
A breaking change, sorry everyone. It had to be done and there was no
other way.
8 years ago
Vladimír Vondruš
8fb6bfa8dc
modules: static build of SDL2 on Linux requires pthread and dl.
...
Do the same also for other Unix-like systems except for Apple platforms,
where those dependencies are most probably satisfied by some frameworks
instead.
8 years ago
Vladimír Vondruš
ff07b165c5
doc: avoid using deprecated functionality in image generators.
8 years ago
Vladimír Vondruš
4c29ff0d3b
GL: Mesh::draw() and MeshView::draw() return a reference to self as well.
...
So it's possible to chain the draw() calls (for example with a different
shader).
8 years ago
Vladimír Vondruš
8add2f4d86
GL: make spurious test failures with queries more bearable.
...
The XFAIL can be disabled globally, if needed.
8 years ago
Vladimír Vondruš
9275613006
GL: properly reset vertex divisor after drawing w/o a VAO.
...
Otherwise it messes up subsequent draws.
8 years ago
Vladimír Vondruš
d3a91ef22d
GL: test that vertex attrib divisor is properly reset when not using VAOs.
...
Fails, because it's not. Fix in next commit.
8 years ago
Vladimír Vondruš
b2ec555a84
GL: ANGLE_instanced_arrays *is* on WebGL 1, so test it.
8 years ago
Vladimír Vondruš
c750771034
GL: Avoid XPASS on Mesa with CubeMapTexture::invalidateSubData().
...
Check that given extension is actually enabled before testing for XFAIL.
8 years ago
Vladimír Vondruš
35ff2db2a9
GL: XFAIL for Mesa on some very specific 3D pixel storage tests.
...
I was getting similar failures on NV, so it's maybe my problem after
all? Not a priority right now.
8 years ago
Vladimír Vondruš
56c7c23040
Audio: std::abort() needs a header on iOS.
8 years ago
Vladimír Vondruš
e24d948b4d
Audio: make Playable omnidirectional by default.
8 years ago
Vladimír Vondruš
3b88f242cf
Audio: deprecated PlayableGroup::setClean() in favor of Listener::update().
...
No reason to keep the same functionality on two places.
8 years ago
Vladimír Vondruš
6df048eac8
Audio: doc++
...
Compiling code snippets, reworked the totally confused scenegraph
integration docs.
8 years ago
Vladimír Vondruš
5bb358e05d
Audio: cleaned up the scene graph implementation.
...
* De-inlined most of the code
* Reduced includes in headers
* Formatting
* Global variables don't need to be exposed publicly
8 years ago
Vladimír Vondruš
703a664fd2
Audio: ability to defer context creation to a later time.
8 years ago
Vladimír Vondruš
7036bc4ad5
Audio: include cleanup.
8 years ago
Vladimír Vondruš
2527927b21
Audio: make Context only move-constructible.
...
For some reason it was copyable and everything. Also fix the cleanup on
destruction so it can be created more than once.
8 years ago
Vladimír Vondruš
5b01762e33
Audio: test that it's possible to create Context multiple times.
8 years ago
Vladimír Vondruš
424eec4818
MeshTools: simplify compile().
...
I wanted to do this since *ever*.
8 years ago
Vladimír Vondruš
9be24a241e
GL: make it possible for a Mesh to own the vertex/index buffers.
...
I wanted to do this since 2015.
8 years ago
Vladimír Vondruš
9276a49388
GL: properly prefix section names.
8 years ago
Vladimír Vondruš
7a0f1ef32d
GL: store Mesh index buffer by value.
...
This allows moving Buffer instances without fear of breaking stuff. I
thought this was in since a long time, but doesn't seem so. This
reintroduces a header dependency, but until I have Containers::Storage
or something that *can* store forward-declared type safely, it's
inevitable.
8 years ago
Vladimír Vondruš
7e65b09ac6
GL: reduce function call stack a bit.
8 years ago
Vladimír Vondruš
b757dc2358
GL: test MeshView constructor.
...
Just for parity.
8 years ago
Vladimír Vondruš
2dd636a77b
GL: make calls to Mesh::setCount() and MeshView::setCount() mandatory.
...
Helps a lot with black screen of death and should have been here ages
ago.
8 years ago
Vladimír Vondruš
fdbd90a327
GL: construct simple Mesh and MeshView members in-class.
...
Better for maintenance, worse for header pollution.
8 years ago
Vladimír Vondruš
16558c8877
GL: assert that addVertexBuffer() is called with a valid Buffer.
8 years ago
Vladimír Vondruš
680144f1c5
GL: get rid of std::vector in Mesh header.
...
This is actually a preparation to make buffer-owning meshes a
possibility (where I would need an union of vectors otherwise),
nevertheless it removes the dependency on a vector.
8 years ago
Vladimír Vondruš
4ecf819fe5
Platform: avoid using deprecated APIs in WindowlessIosApplication.
...
Fallen through cracks. Sorry.
8 years ago
Vladimír Vondruš
308d97314d
SceneGraph: AnimableGroup.h doesn't really compile without this.
8 years ago