vrecko
virtual reality framework
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
EditorLogic.h
Go to the documentation of this file.
1
#ifndef APFFDEDITOR_H
2
#define APFFDEDITOR_H
3
4
#include <
vrecko/Ability.h
>
5
#include "
GeometryLoader.h
"
6
#include "
Grid.h
"
7
#include "../EditorController/ControllableAbility.h"
8
9
using namespace
vrecko;
10
11
namespace
APFFDEditor {
12
13
class
EditorLogic
:
public
vrecko::ControllableAbility
,
public
GeometryLoader
{
14
public
:
15
EditorLogic
();
16
~EditorLogic
() {destroyGeometry();
if
(pGrid) pGrid->~Grid();};
17
18
void
update(
void
);
19
//void processEvent(const std::string &input_name, void *value) ;
20
void
postInitialize(
void
);
21
/*void preInitialize(void); */
22
bool
loadXMLParameters(XERCES_CPP_NAMESPACE_QUALIFIER
DOMNode
*);
23
//XERCES_CPP_NAMESPACE_QUALIFIER DOMNode *saveXMLParameters(XERCES_CPP_NAMESPACE_QUALIFIER DOMDocument *pDocNode) ;
24
protected
:
25
26
virtual
void
fillDefaultInfo();
27
virtual
bool
activate();
28
virtual
void
menuItemClicked(
const
char
* itemID);
29
virtual
void
menuSliderChanged(
const
char
* sliderID,
float
sliderPos);
30
void
CPscale(
float
scale);
31
bool
isThisControlPoint(
long
ID);
32
int
moveLock
;
33
34
float
CPsize
;
35
float
transparencyOfEditedObject
;
36
float
optimOfCP
;
37
osg::Vec3
previousObjectPosition
;
38
39
40
vrecko::EnvironmentObject
*
pEditedObject
;
41
Grid
*
pGrid
;
42
bool
gridChanged
;
43
bool
objectWasMoved
;
44
osg::Vec3
numberOfCPoints
;
45
//main function of deformation using positions grid control points and relative positions of verticies in geometry
46
void
updateObjectGeometry(
void
);
47
48
//in this function set relative position verticies of object in grid
49
void
setAtributesForDeformation(
void
);
50
void
resetGeometry(
void
);
51
//void showBoundary(unsigned short value);
52
//unsigned short boundary;
53
//osg::ref_ptr<osg::Geode> boundaryGeode;
54
55
osg::Matrix *
parentsTransform
;
56
osg::Matrix *
inverseParentsTransform
;
57
58
};
59
60
}
61
#endif
include
vreckoAP
FFDEditor
EditorLogic.h
Generated on Tue Feb 19 2013 10:23:43 for vrecko by
1.8.3.1