Vis 2 Demo
1.0
Technical illustration type real-time rendering of geometry
Main Page
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Macros
src
geometry
ModelTextured.cpp
Go to the documentation of this file.
1
#include "
ModelTextured.h
"
2
3
using namespace
vis2;
4
5
ModelTextured::ModelTextured
( glm::mat4 _modelMatrix,
6
Shader
* _shader,
7
Texture
* _diffuseTexture,
8
const
GLfloat* _positions_Ptr,
9
const
GLfloat* _normals_Ptr,
10
const
GLfloat* _uv_Ptr,
11
const
GLuint* _index_Ptr,
12
const
unsigned
int
_vertex_count,
13
const
unsigned
int
_face_ind_count)
14
:
GeometricObjectTextured
( _modelMatrix,
15
_shader,
16
_diffuseTexture,
17
_positions_Ptr,
18
_vertex_count,
19
_normals_Ptr,
20
_vertex_count,
21
_uv_Ptr,
22
_vertex_count,
23
_index_Ptr,
24
_face_ind_count)
25
// \internal diffuse_texture(_diffuseTexture) \internal
26
{
27
28
// DEBUG
29
30
// unsigned int f_i = 18;
31
// std::cout << "f[" << f_i << "] " << _index_Ptr[f_i] << std::endl;
32
// unsigned int i = 8;
33
// std::cout << "v[" << i << "] " << _positions_Ptr[i*3] << " " << _positions_Ptr[i*3 + 1] << " " << _positions_Ptr[i*3 + 2] << std::endl;
34
// std::cout << "vt[" << i << "] " << _uv_Ptr[i*2] << " " << _uv_Ptr[i*2 + 1] << std::endl;
35
// std::cout << "vn[" << i << "] " << _normals_Ptr[i*3] << " " << _normals_Ptr[i*3 + 1] << " " << _normals_Ptr[i * 3 + 2] << std::endl;
36
37
38
}
39
40
ModelTextured::~ModelTextured
()
41
{
42
}
43
44
void
ModelTextured::update
(
double
_deltaT)
45
{
46
47
//this->modelMatrix = glm::rotate( this->modelMatrix,
48
// 45.0f * (float)_deltaT,
49
// glm::vec3(-0.1f, 1.0f, -0.1f));
50
51
}
52
53
void
ModelTextured::draw
(glm::mat4 & _projectionMatrix)
54
{
55
GeometricObjectTextured::draw
(_projectionMatrix);
56
}
Generated on Tue Jun 11 2013 08:43:14 for Vis 2 Demo by
1.8.3.1