Subversion Repositories gelsvn

Rev

Rev 566 | Rev 578 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 566 Rev 572
Line 1... Line -...
1
/*
-
 
-
 
1
/* ----------------------------------------------------------------------- *
2
 *  ManifoldRenderer.h
2
 * This file is part of GEL, http://www.imm.dtu.dk/GEL
3
 *  GEL
-
 
4
 *
-
 
5
 *  Created by J. Andreas Bærentzen on 20/09/08.
3
 * Copyright (C) the authors and DTU Informatics
6
 *  Copyright 2008 __MyCompanyName__. All rights reserved.
4
 * For license and list of authors, see ../../doc/intro.pdf
-
 
5
 * ----------------------------------------------------------------------- */
7
 *
6
 
8
 */
-
 
9
#ifndef __MESHEDIT_RENDERER_H__
7
#ifndef __MESHEDIT_RENDERER_H__
10
#define __MESHEDIT_RENDERER_H__
8
#define __MESHEDIT_RENDERER_H__
11
 
9
 
12
#include <GL/glew.h>
10
#include <GL/glew.h>
13
#include <GLGraphics/draw.h>
11
#include <GLGraphics/draw.h>
Line 193... Line 191...
193
		const static std::string fss;
191
		const static std::string fss;
194
	public:
192
	public:
195
		ScalarFieldRenderer(const HMesh::Manifold& m, bool smooth, HMesh::VertexAttributeVector<double>& field, double max_val, float gamma = 2.2);
193
		ScalarFieldRenderer(const HMesh::Manifold& m, bool smooth, HMesh::VertexAttributeVector<double>& field, double max_val, float gamma = 2.2);
196
	};
194
	};
197
 
195
 
-
 
196
    /** Render a scalar field. Positive scalars are mapped to blue and negative to red.
-
 
197
     This class also has controls for gamma correction which is highly useful if the 
-
 
198
     scalars are mostly small or large and simply scaling to the 0-1 range does not 
-
 
199
     produce a good result. */
-
 
200
    class PeriodicScalarFieldRenderer: public SimpleShaderRenderer
-
 
201
	{
-
 
202
		const static std::string vss;
-
 
203
		const static std::string fss;
-
 
204
	public:
-
 
205
		PeriodicScalarFieldRenderer(const HMesh::Manifold& m, bool smooth, HMesh::VertexAttributeVector<double>& field, float gamma = 2.2);
-
 
206
	};
-
 
207
 
198
/** Ambient occlusion renderer. Very similar to ScalarFieldRender. Simply assumes that the input values are
208
/** Ambient occlusion renderer. Very similar to ScalarFieldRender. Simply assumes that the input values are
199
	mean curvatures which in some sense indicate how concave the surface is.*/
209
	mean curvatures which in some sense indicate how concave the surface is.*/
200
class AmbientOcclusionRenderer: public SimpleShaderRenderer
210
class AmbientOcclusionRenderer: public SimpleShaderRenderer
201
	{
211
	{
202
		const static std::string vss;
212
		const static std::string vss;