Vladimír Vondruš
fd4ada4fc1
Method chaining in Shader.
...
The methods return reference instead of pointer, as the class is
commonly created on the stack. Removed static functions
Shader::fromFile() and Shader::fromData(), as they are not needed now.
Also asserting that the file exists and is readable in addFile().
13 years ago
Vladimír Vondruš
623fda0dc7
Shaders: removed superfluous `*Shader` suffix from class names.
13 years ago
Vladimír Vondruš
127910d537
Shaders: minor tweaks.
...
Non-matching number of opening and closing braces confused editors with
code folding feature.
13 years ago
Vladimír Vondruš
c5ab86794b
Relicensing to MIT/Expat license, part 3: source files.
...
Added license header also to shader sources. Hopefully it won't harm
compilation times too much.
13 years ago
Vladimír Vondruš
2d98dadb0a
Shaders: first DistanceFieldVectorShader implementation.
...
Currently only fill and outline can be specified. Also crosslinked from
documentation of VectorShader and TextureTools::distanceField().
13 years ago
Vladimír Vondruš
3c31519133
Shaders: cleanup of VectorShader.
...
Using this-> for accessing parent class members breaks KDevelop
autocompletion, using explicit class name instead (but the shorter one).
13 years ago
Vladimír Vondruš
b6caae10b0
Shaders: vertex VectorShader is implementation independent.
...
Renamed it to AbstractVectorShader.
13 years ago
Vladimír Vondruš
91f0d302c2
Shaders: renamed TextShader to VectorShader.
...
The code can be used for drawing any vector art, not only font glyphs.
13 years ago
Vladimír Vondruš
003e524a26
Shaders: using new type aliases in whole Shaders namespace.
13 years ago
Vladimír Vondruš
0cba8db268
Shaders: added missing 3D version of text shader.
13 years ago
Vladimír Vondruš
a22bf1bf4e
Shaders: don't use explicit attribute location on GL 2.1.
13 years ago
Vladimír Vondruš
29a07c7d62
GCC 4.6 compilation fixes.
14 years ago
Vladimír Vondruš
df1d8a95b4
Shaders: basic text shader.
14 years ago
Vladimír Vondruš
7a894e97a0
Using ARB_explicit_uniform_location in shaders.
...
The backwards compatibility fully kills the purpose, but at least I can
test the feature somewhere :-)
14 years ago
Vladimír Vondruš
231c002838
Explicitly use *Matrix in names when appropriate.
...
* In shader uniforms (projectionMatrix makes more sense than projection
alone)
* For underlying types for SceneGraph transformation. It is already
used in Drawable::clean() as transformationMatrix, so why not use it
also in AbstractFeature::clean(). Moreover, clean() could be in
future also done using something else, this helps to distinguish the
type just from parameter name.
* In Physics shapes - applyTransformationMatrix() (as it could be in
future also done using something else).
14 years ago
Vladimír Vondruš
e4a6832eab
Accidentaly forgot commented-out code.
14 years ago
Vladimír Vondruš
2dd0a68329
Internal "traits" cleanup.
...
Don't use constexpr class members, as their usage is not so convenient
compared to classic inline functions.
14 years ago
Vladimír Vondruš
6f6d3d09b2
Blind port of FlatShader to OpenGL 2.1 and OpenGL ES 2.0.
14 years ago
Vladimír Vondruš
d46bc34390
Moved flat shader from internal physics implementation to Shaders.
...
It is so general that it can be reused elsewhere.
14 years ago
Vladimír Vondruš
f85a7fc568
Physics: Minimal initial implementation of debug draw.
14 years ago