Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/branches/camera/src/world_entities/cameraman.cc @ 10205

Last change on this file since 10205 was 10205, checked in by gfilip, 19 years ago

tralala

File size: 992 bytes
RevLine 
[10192]1#include "shell_command.h"
2#include "cameraman.h"
[10197]3
[10195]4#include "state.h"
[10192]5
6
7
8
9cameraman::cameraman()
10{
[10197]11  currentCam=State::getCamera();
[10193]12  cameras[0]=currentCam;
13  camAmount=1;
[10192]14
15}
16
17
18void cameraman::createCam()
19{
[10195]20if (camAmount<6)
[10193]21{
[10197]22  Camera* newCamera=new Camera();
[10193]23  cameras[camAmount]=newCamera;
[10192]24}
[10195]25}
[10192]26
[10193]27void cameraman::setCam(int cameraNo)
[10192]28{
[10193]29  if (cameraNo<camAmount)
[10197]30  {
[10193]31  currentCam=cameras[cameraNo];
[10198]32  State::setCamera(currentCam, currentCam->getTarget());
[10197]33  }
[10195]34
[10192]35}
36
[10195]37
[10204]38
39void cameraman::moveCurrCam(int x, int y, int z)
40{
41currentCam->target->trans(x,y,z);
42}
43
44
45void cameraman::moveCam(int x, int y, int z, int camNo)
46{
47cameras[camNo]->target->trans(x,y,z);
48}
49
50
51void cameraman::changeTarget(int camNo, PNode* target)
52{
[10205]53  cameras[camNo]->target->atach(target);
[10204]54}
55
56
57void cameraman::changeCurrTarget(PNode* target)
58{
[10205]59  currentCam->target->atach(target);
[10204]60}
61
62void cameraman::jumpCam(int x, int y, int z, int camNo)
63{
64 // cameras[camNo]
65}
66
67
68void jumpCurrCam(int x, int y, int z)
69{
70}
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
Note: See TracBrowser for help on using the repository browser.