Commit d5954ead authored by Declara Denis's avatar Declara Denis Committed by Christian Schulte zu Berge
Browse files

Fixed errors due to rebase + Fixed rendering glitch in UsFanRenderer

Switch wrapping mode for texture in fan renderer, so that colors don't
bleed to the other sides on the edges.
parent 27296a28
......@@ -136,8 +136,7 @@ namespace campvis {
if (p_renderToTexture.getValue() == true) {
cgt::vec3 size = img->getSize();
cgt::Texture* resultTexture = new cgt::Texture(0, size, GL_RGB, GL_RGBA, GL_UNSIGNED_BYTE, cgt::Texture::LINEAR);
cgt::Texture* resultTexture = new cgt::Texture(GL_TEXTURE_2D, size, GL_RGB8, cgt::Texture::LINEAR);
glViewport(0, 0, static_cast<GLsizei>(size.x), static_cast<GLsizei>(size.y));
......@@ -117,6 +117,9 @@ namespace campvis {
_shader->setUniform("halfAngle", halfAngle);
_shader->setUniform("innerRadius", innerRadius);
// Set wrapping mode to mirror, in order to avoid artefacts at the edges of the fan
FramebufferActivationGuard fag(this);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment