~ubuntu-branches/ubuntu/lucid/meshlab/lucid

« back to all changes in this revision

Viewing changes to meshlab/src/fgt/decorate_shadow/shadow_mapping.h

  • Committer: Bazaar Package Importer
  • Author(s): Teemu Ikonen
  • Date: 2009-10-08 16:40:41 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20091008164041-0c2ealqv8b8uc20c
Tags: 1.2.2-1
* New upstream version
* Do not build filter_isoparametrization because liblevmar dependency
  is not (yet) in Debian
* Fix compilation with gcc-4.4, thanks to Jonathan Liu for the patch
  (closes: #539544)
* rules: Add compiler variables to the qmake call (for testing with new
  GCC versions)
* io_3ds.pro: Make LIBS and INCLUDEPATH point to Debian version of lib3ds
* io_epoch.pro: Make LIBS point to Debian version of libbz2
* control:
  - Move Homepage URL to the source package section
  - Update to standards-version 3.8.3

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/****************************************************************************
 
2
* MeshLab                                                           o o     *
 
3
* A versatile mesh processing toolbox                             o     o   *
 
4
*                                                                _   O  _   *
 
5
* Copyright(C) 2005                                                \/)\/    *
 
6
* Visual Computing Lab                                            /\/|      *
 
7
* ISTI - Italian National Research Council                           |      *
 
8
*                                                                    \      *
 
9
* All rights reserved.                                                      *
 
10
*                                                                           *
 
11
* This program is free software; you can redistribute it and/or modify      *
 
12
* it under the terms of the GNU General Public License as published by      *
 
13
* the Free Software Foundation; either version 2 of the License, or         *
 
14
* (at your option) any later version.                                       *
 
15
*                                                                           *
 
16
* This program is distributed in the hope that it will be useful,           *
 
17
* but WITHOUT ANY WARRANTY; without even the implied warranty of            *
 
18
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the             *
 
19
* GNU General Public License (http://www.gnu.org/licenses/gpl.txt)          *
 
20
* for more details.                                                         *
 
21
*                                                                           *
 
22
****************************************************************************/
 
23
 
 
24
#ifndef SHADOW_MAPPING_H_
 
25
#define SHADOW_MAPPING_H_
 
26
 
 
27
 
 
28
#include <cassert>
 
29
#include <QString>
 
30
#include <QImage>
 
31
#include <QFile>
 
32
#include <GL/glew.h>
 
33
#include <meshlab/interfaces.h>
 
34
#include <meshlab/meshmodel.h>
 
35
#include <meshlab/glarea.h>
 
36
#include <decorate_shader.h>
 
37
 
 
38
class ShadowMapping : public DecorateShader
 
39
{
 
40
 
 
41
public:
 
42
        ShadowMapping();
 
43
                ~ShadowMapping();
 
44
 
 
45
        bool init();
 
46
        void runShader(MeshModel&, GLArea*);
 
47
 
 
48
private:
 
49
        bool compileAndLink();
 
50
        bool setup();
 
51
        void bind();
 
52
        void unbind();
 
53
 
 
54
        GLuint _fbo;
 
55
        GLuint _objectShaderProgram;
 
56
        GLuint _objectVert, _objectFrag ;
 
57
};
 
58
 
 
59
#endif /* SHADOW_MAPPING_H_ */