1 /**************************************************************************\
2  * Copyright (c) Kongsberg Oil & Gas Technologies AS
3  * All rights reserved.
4  *
5  * Redistribution and use in source and binary forms, with or without
6  * modification, are permitted provided that the following conditions are
7  * met:
8  *
9  * Redistributions of source code must retain the above copyright notice,
10  * this list of conditions and the following disclaimer.
11  *
12  * Redistributions in binary form must reproduce the above copyright
13  * notice, this list of conditions and the following disclaimer in the
14  * documentation and/or other materials provided with the distribution.
15  *
16  * Neither the name of the copyright holder nor the names of its
17  * contributors may be used to endorse or promote products derived from
18  * this software without specific prior written permission.
19  *
20  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
21  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
22  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
23  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
24  * HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
25  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
26  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31 \**************************************************************************/
32 
33 #include "navigation/SoCameraUtils.h"
34 #include "coindefs.h"
35 
36 #include <cassert>
37 #include <cmath>
38 
39 #include <Inventor/SbVec3f.h>
40 #include <Inventor/nodes/SoPerspectiveCamera.h>
41 #include <Inventor/nodes/SoOrthographicCamera.h>
42 #include <Inventor/nodes/SoFrustumCamera.h>
43 #include <Inventor/errors/SoDebugError.h>
44 
45 class SoOrthoPerspectiveCameraManager : public SoCameraManager {
46 public:
47   SoOrthoPerspectiveCameraManager(SoCamera * camera);
48 
49   SoOrthographicCamera * getCastCamera(void) const;
50 
51   virtual void setZoomValue(float zoomvalue, SbBool limit = FALSE);
52   virtual void adjustZoomValue(float diffvalue, SbBool limit = TRUE); // diffvalue=0.0 is identity
53   virtual void adjustZoom(float factor, SbBool limit = TRUE); // factor=1.0 is identity
54 
55   virtual float getZoomFactor(void) const;
56 
57   virtual void setZoomValueByDolly(float zoomvalue, SbBool limit = FALSE);
58   virtual void adjustZoomByDollyDistance(float distance, SbBool limit = TRUE); // distance=0.0 is identity
59   virtual void adjustZoomByDolly(float factor, SbBool limit = TRUE); // factor=1.0 is identity
60 
61   virtual float getZoomByDollyFactor(void) const;
62 
63 };
64 
65 class SoPerspectiveCameraManager : public SoCameraManager {
66 public:
67   SoPerspectiveCameraManager(SoCamera * camera);
68 
69   SoPerspectiveCamera * getCastCamera(void) const;
70 
71   virtual void setZoomValue(float zoomvalue, SbBool limit = FALSE);
72   virtual void adjustZoomValue(float diffvalue, SbBool limit = TRUE); // diffvalue=0.0 is identity
73   virtual void adjustZoom(float factor, SbBool limit = TRUE); // factor=1.0 is identity
74 
75   virtual float getZoomFactor(void) const;
76 
77   virtual void setZoomValueByDolly(float zoomvalue, SbBool limit = FALSE);
78   virtual void adjustZoomByDollyDistance(float distance, SbBool limit = TRUE); // distance=0.0 is identity
79   virtual void adjustZoomByDolly(float factor, SbBool limit = TRUE); // factor=1.0 is identity
80 
81   virtual float getZoomByDollyFactor(void) const;
82 
83 };
84 
85 class SoFrustumCameraManager : public SoCameraManager {
86 public:
87   SoFrustumCameraManager(SoCamera * camera);
88 
89   SoFrustumCamera * getCastCamera(void) const;
90 
91   virtual void setZoomValue(float zoomvalue, SbBool limit = FALSE);
92   virtual void adjustZoomValue(float diffvalue, SbBool limit = TRUE); // diffvalue=0.0 is identity
93   virtual void adjustZoom(float factor, SbBool limit = TRUE); // factor=1.0 is identity
94 
95   virtual float getZoomFactor(void) const;
96 
97   virtual void setZoomValueByDolly(float zoomvalue, SbBool limit = FALSE);
98   virtual void adjustZoomByDollyDistance(float distance, SbBool limit = TRUE); // distance=0.0 is identity
99   virtual void adjustZoomByDolly(float factor, SbBool limit = TRUE); // factor=1.0 is identity
100 
101   virtual float getZoomByDollyFactor(void) const;
102 
103 };
104 
105 
106 // *************************************************************************
107 
108 SoCameraManager *
createFor(SoCamera * camera)109 SoCameraManager::createFor(SoCamera * camera)
110 {
111   assert(camera);
112 
113   // FIXME: need to be able to instantiate an appdomain orthographic camera as well
114   SoCameraManager * manager = NULL;
115   if (camera->isOfType(SoPerspectiveCamera::getClassTypeId())) {
116     manager = new SoPerspectiveCameraManager(camera);
117   }
118   else if (camera->isOfType(SoFrustumCamera::getClassTypeId())) {
119     manager = new SoFrustumCameraManager(camera);
120   }
121   else if (camera->isOfType(SoOrthographicCamera::getClassTypeId())) {
122     manager = new SoOrthoPerspectiveCameraManager(camera);
123   }
124   else {
125     SoDebugError::postInfo("SoCameraManager::createFor",
126                            "Unsupported camera type ('%s').",
127                            camera->getTypeId().getName().getString());
128   }
129   return manager;
130 }
131 
SoCameraManager(SoCamera * thecamera)132 SoCameraManager::SoCameraManager(SoCamera * thecamera)
133 : camera(thecamera)
134 {
135   assert(camera);
136   camera->ref();
137 
138   this->havezoomlimits = FALSE;
139   this->minzoom = this->maxzoom = 0.0f;
140   this->havezoombydollylimits = FALSE;
141   this->mindollydistance = this->maxdollydistance = this->unitydistance = 0.0f;
142 }
143 
~SoCameraManager(void)144 SoCameraManager::~SoCameraManager(void)
145 {
146   camera->unref();
147   camera = NULL;
148 }
149 
150 void
setZoomLimits(float minzoomvalue,float maxzoomvalue)151 SoCameraManager::setZoomLimits(float minzoomvalue, float maxzoomvalue)
152 {
153   if (minzoomvalue == 0.0f && maxzoomvalue == 0.0f) {
154     this->minzoom = this->maxzoom = 0.0f;
155     this->havezoomlimits = FALSE;
156   }
157   else {
158     this->minzoom = minzoomvalue;
159     this->maxzoom = maxzoomvalue;
160     this->havezoomlimits = TRUE;
161   }
162 }
163 
164 SbBool
getZoomLimits(float & minzoomvalue,float & maxzoomvalue) const165 SoCameraManager::getZoomLimits(float & minzoomvalue, float & maxzoomvalue) const
166 {
167   minzoomvalue = this->minzoom;
168   maxzoomvalue = this->maxzoom;
169   return this->havezoomlimits;
170 }
171 
172 float
getZoomValue(void) const173 SoCameraManager::getZoomValue(void) const
174 {
175   return 1.0f; // no implementation, zoom is 1.0
176 }
177 
178 void
setZoomByDollyLimits(float mindollydist,float maxdollydist,float unitydist)179 SoCameraManager::setZoomByDollyLimits(float mindollydist, float maxdollydist, float unitydist)
180 {
181   if (mindollydist == 0.0f && maxdollydist == 0.0f && unitydist == 0.0f) {
182     this->mindollydistance = this->maxdollydistance = this->unitydistance =  0.0f;
183     this->havezoombydollylimits = FALSE;
184   }
185   else {
186     this->mindollydistance = mindollydist;
187     this->maxdollydistance = maxdollydist;
188     this->unitydistance = unitydist;
189     this->havezoombydollylimits = TRUE;
190   }
191 
192 }
193 
194 SbBool
getZoomByDollyLimits(float & mindollydist,float & maxdollydist,float & unitydist) const195 SoCameraManager::getZoomByDollyLimits(float & mindollydist, float & maxdollydist, float & unitydist) const
196 {
197   mindollydist = this->mindollydistance;
198   maxdollydist = this->maxdollydistance;
199   unitydist = this->unitydistance;
200   return this->havezoombydollylimits;
201 }
202 
203 float
getZoomByDollyValue(void) const204 SoCameraManager::getZoomByDollyValue(void) const
205 {
206   return 1.0f; // no implementation, zoom is 1.0
207 }
208 
209 SbVec3f
getFocalPoint(void) const210 SoCameraManager::getFocalPoint(void) const
211 {
212   return SbVec3f(0.0f, 0.0f, 0.0f);
213 }
214 
215 void
copyLimits(const SoCameraManager * other)216 SoCameraManager::copyLimits(const SoCameraManager * other)
217 {
218   this->minzoom = other->minzoom;
219   this->maxzoom = other->maxzoom;
220   this->havezoomlimits = other->havezoomlimits;
221   this->mindollydistance = other->mindollydistance;
222   this->maxdollydistance = other->maxdollydistance;
223   this->unitydistance = other->unitydistance;
224   this->havezoombydollylimits = other->havezoombydollylimits;
225 }
226 
227 // *************************************************************************
228 
229 /*
230   \class SoOrthoPerspectiveCameraManager
231 
232   This class is about managing an SoOrthographicCamera as if it was an
233   SoPerspectiveCamera.  The defined behaviour is to have the scale of the model
234   identical in the plane in the focal point, based on the given zoom value.
235 */
236 
SoOrthoPerspectiveCameraManager(SoCamera * camera)237 SoOrthoPerspectiveCameraManager::SoOrthoPerspectiveCameraManager(SoCamera * camera)
238 : SoCameraManager(camera)
239 {
240 }
241 
242 SoOrthographicCamera *
getCastCamera(void) const243 SoOrthoPerspectiveCameraManager::getCastCamera(void) const
244 {
245   assert(this->getCamera() && this->getCamera()->isOfType(SoOrthographicCamera::getClassTypeId()));
246   return static_cast<SoOrthographicCamera *>(this->getCamera());
247 }
248 
249 void
setZoomValue(float zoomvalue,SbBool limit)250 SoOrthoPerspectiveCameraManager::setZoomValue(float zoomvalue, SbBool limit)
251 {
252   static const float defaultangle = float(M_PI_4);
253   static const float defaultheight = sin(defaultangle) / cos(defaultangle);
254 
255   SoOrthographicCamera * camera = this->getCastCamera();
256   float focaldistance = camera->focalDistance.getValue();
257 
258   if (zoomvalue < 0.0f) {
259     zoomvalue = 0.0f;
260   }
261 
262   if (limit && this->havezoomlimits) {
263     if (zoomvalue < this->minzoom) {
264       zoomvalue = this->minzoom;
265     } else if (zoomvalue > this->maxzoom) {
266       zoomvalue = this->maxzoom;
267     }
268   }
269 
270   float unityheight = defaultheight * focaldistance;
271   float zoomedheight = unityheight / zoomvalue;
272 
273   camera->height.setValue(zoomedheight);
274 }
275 
276 void
adjustZoomValue(float diffvalue,SbBool limit)277 SoOrthoPerspectiveCameraManager::adjustZoomValue(float diffvalue, SbBool limit)
278 {
279   float currentfactor = this->getZoomFactor();
280   float newfactor = currentfactor + diffvalue;
281   this->setZoomValue(newfactor, limit);
282 }
283 
284 void
adjustZoom(float factor,SbBool limit)285 SoOrthoPerspectiveCameraManager::adjustZoom(float factor, SbBool limit)
286 {
287   float currentfactor = this->getZoomFactor();
288   float newfactor = currentfactor * factor;
289   this->setZoomValue(newfactor, limit);
290 }
291 
292 float
getZoomFactor(void) const293 SoOrthoPerspectiveCameraManager::getZoomFactor(void) const
294 {
295   static const float defaultangle = float(M_PI_4);
296   static const float defaultheight = sin(defaultangle) / cos(defaultangle);
297 
298   SoOrthographicCamera * camera = this->getCastCamera();
299   float focaldistance = camera->focalDistance.getValue();
300 
301   float unityheight = defaultheight * focaldistance;
302   float height = camera->height.getValue();
303   float zoomvalue = unityheight / height;
304 
305   return zoomvalue;
306 }
307 
308 /*
309   Performs a dolly and at the same time adjusts height to emulate how a perspective
310   camera would zoom in
311 */
312 void
setZoomValueByDolly(float zoomvalue,SbBool limit)313 SoOrthoPerspectiveCameraManager::setZoomValueByDolly(float zoomvalue, SbBool limit)
314 {
315   if (!this->havezoombydollylimits) {
316     // don't have the necessary information
317     return;
318   }
319 
320   static const float defaultangle = float(M_PI_4);
321   static const float defaultheight = sin(defaultangle) / cos(defaultangle);
322 
323   // these are absolute, and wipes out existing non-dollied zoom. should fix
324   float newdistance = 0.0f;
325   if (zoomvalue < 0.0) {
326     zoomvalue = 0.0;
327     newdistance = 0.0;
328   } else {
329     newdistance = this->unitydistance / zoomvalue;
330     if (limit) {
331       if (newdistance < this->mindollydistance) {
332         newdistance = this->mindollydistance;
333       }
334       else if (newdistance > this->maxdollydistance) {
335         newdistance = this->maxdollydistance;
336       }
337     }
338     if (newdistance < 0.0) { newdistance = 0.0; }
339   }
340 
341   float newheight = newdistance * defaultheight;
342 
343   SoOrthographicCamera * camera = this->getCastCamera();
344   float focaldistance = camera->focalDistance.getValue();
345   SbVec3f projdir(0.0f, 0.0f, 0.0f);
346   camera->orientation.getValue().multVec(SbVec3f(0.0f, 0.0f, -1.0f), projdir);
347   SbVec3f focalpoint = camera->position.getValue() + projdir * focaldistance;
348   camera->position.setValue(focalpoint - projdir * newdistance);
349   camera->focalDistance.setValue(newdistance);
350   camera->height.setValue(newheight);
351 
352   //printf("setting zoom:%g, distance:%g height=%g\n", zoomvalue, newdistance, newheight);
353 }
354 
355 void
adjustZoomByDollyDistance(float distance,SbBool limit)356 SoOrthoPerspectiveCameraManager::adjustZoomByDollyDistance(float distance, SbBool limit)
357 {
358   SoOrthographicCamera * camera = this->getCastCamera();
359   float focaldistance = camera->focalDistance.getValue();
360 
361   float newfocaldistance = focaldistance + distance;
362   this->adjustZoomByDolly(newfocaldistance / focaldistance, limit);
363 }
364 
365 void
adjustZoomByDolly(float factor,SbBool limit)366 SoOrthoPerspectiveCameraManager::adjustZoomByDolly(float factor, SbBool limit)
367 {
368   float currentfactor = this->getZoomByDollyFactor();
369   this->setZoomValueByDolly(currentfactor * factor, limit);
370 }
371 
372 float
getZoomByDollyFactor(void) const373 SoOrthoPerspectiveCameraManager::getZoomByDollyFactor(void) const
374 {
375   if (!this->havezoombydollylimits) {
376     // without knowing unitydistance, nothing can be said about this
377     return 1.0f;
378   }
379   SoOrthographicCamera * camera = this->getCastCamera();
380   return (this->unitydistance / camera->focalDistance.getValue());
381 }
382 
383 
384 // *************************************************************************
385 
SoPerspectiveCameraManager(SoCamera * camera)386 SoPerspectiveCameraManager::SoPerspectiveCameraManager(SoCamera * camera)
387 : SoCameraManager(camera)
388 {
389 }
390 
391 SoPerspectiveCamera *
getCastCamera(void) const392 SoPerspectiveCameraManager::getCastCamera(void) const
393 {
394   assert(this->getCamera() && this->getCamera()->isOfType(SoPerspectiveCamera::getClassTypeId()));
395   return static_cast<SoPerspectiveCamera *>(this->getCamera());
396 }
397 
398 
399 void
setZoomValue(float inzoomvalue,SbBool limit)400 SoPerspectiveCameraManager::setZoomValue(float inzoomvalue, SbBool limit)
401 {
402   // default* defines what zoom=1.0 is
403   static const float defaultangle = float(M_PI_4);
404   static const float defaultheight = sin(defaultangle) / cos(defaultangle);
405 
406   float zoomvalue = inzoomvalue;
407   if (limit) {
408     if (zoomvalue < this->minzoom) { zoomvalue = this->minzoom; }
409     else if (zoomvalue > this->maxzoom) { zoomvalue = this->maxzoom; }
410   }
411   float zoomedheight = defaultheight / zoomvalue;
412   float zoomedangle = asin(zoomedheight / sqrt(1.0f + (zoomedheight * zoomedheight)));
413   //float height = sin(zoomedangle) / cos(zoomedangle);
414 
415   // printf("angle is set to %g (default %g/%g), height = %g (default %g), zoom = %g\n",
416   //        angle, defaultangle, mydefaultangle, height, defaultheight, inzoomvalue);
417 
418   SoPerspectiveCamera * camera = this->getCastCamera();
419   camera->heightAngle.setValue(2.0f * zoomedangle);
420   // we multiply by two to get full angle, not just with projection direction
421 
422   //const float calculated = this->getZoomFactor();
423   //printf("clamped zoom %g, recomputed to %g\n", zoomvalue, calculated);
424 
425 }
426 
427 void
adjustZoomValue(float diffvalue,SbBool limit)428 SoPerspectiveCameraManager::adjustZoomValue(float diffvalue, SbBool limit)
429 {
430   float zoomfactor = this->getZoomFactor();
431   float newzoomfactor = zoomfactor + diffvalue;
432   this->setZoomValue(newzoomfactor, limit);
433 }
434 
435 void
adjustZoom(float factor,SbBool limit)436 SoPerspectiveCameraManager::adjustZoom(float factor, SbBool limit)
437 {
438   float zoomfactor = this->getZoomFactor();
439   float newzoomfactor = zoomfactor * factor;
440   this->setZoomValue(newzoomfactor, limit);
441 }
442 
443 float
getZoomFactor(void) const444 SoPerspectiveCameraManager::getZoomFactor(void) const
445 {
446   // zoombydolly does not affect angle for SoPerspectiveCamera handling, so
447   // there is no need to compensate for that here.
448   static const float defaultangle = float(M_PI_4);
449   static const float defaultheight = sin(defaultangle) / cos(defaultangle);
450 
451   SoPerspectiveCamera * camera = this->getCastCamera();
452   const float angle = camera->heightAngle.getValue() * 0.5f;
453   const float height = sin(angle) / cos(angle);
454 
455   const float zoomfactor = defaultheight / height;
456 
457   return zoomfactor;
458 }
459 
460 void
setZoomValueByDolly(float zoomvalue,SbBool COIN_UNUSED_ARG (limit))461 SoPerspectiveCameraManager::setZoomValueByDolly(float zoomvalue, SbBool COIN_UNUSED_ARG(limit))
462 {
463   if (!this->havezoombydollylimits) {
464     // without unitydistance, we don't know anything
465     return;
466   }
467 
468   SoPerspectiveCamera * camera = this->getCastCamera();
469   float focaldistance = camera->focalDistance.getValue();
470   SbVec3f projdir(0.0f, 0.0f, 0.0f);
471   camera->orientation.getValue().multVec(SbVec3f(0.0f, 0.0f, -1.0f), projdir);
472   SbVec3f focalpoint = camera->position.getValue() + projdir * focaldistance;
473 
474   float newdistance = this->unitydistance / zoomvalue;
475   camera->position.setValue(focalpoint - projdir * newdistance);
476   camera->focalDistance.setValue(newdistance);
477 }
478 
479 void
adjustZoomByDollyDistance(float distance,SbBool limit)480 SoPerspectiveCameraManager::adjustZoomByDollyDistance(float distance, SbBool limit)
481 {
482   SoPerspectiveCamera * camera = this->getCastCamera();
483   float focaldistance = camera->focalDistance.getValue();
484   float newdistance = focaldistance + distance;
485   if (this->havezoombydollylimits && limit) {
486     if (newdistance < this->mindollydistance) {
487       newdistance = this->mindollydistance;
488     }
489     else if (newdistance > this->maxdollydistance) {
490       newdistance = this->maxdollydistance;
491     }
492   }
493   SbVec3f projdir(0.0f, 0.0f, 0.0f);
494   camera->orientation.getValue().multVec(SbVec3f(0.0f, 0.0f, -1.0f), projdir);
495   SbVec3f focalpoint = camera->position.getValue() + projdir * focaldistance;
496   camera->position.setValue(focalpoint - projdir * newdistance);
497   camera->focalDistance.setValue(newdistance);
498 }
499 
500 void
adjustZoomByDolly(float factor,SbBool limit)501 SoPerspectiveCameraManager::adjustZoomByDolly(float factor, SbBool limit)
502 {
503   SoPerspectiveCamera * camera = this->getCastCamera();
504   float focaldistance = camera->focalDistance.getValue();
505   float newdistance = focaldistance * (1.0f / factor);
506   if (this->havezoombydollylimits && limit) {
507     if (newdistance < this->mindollydistance) {
508       newdistance = this->mindollydistance;
509     }
510     else if (newdistance > this->maxdollydistance) {
511       newdistance = this->maxdollydistance;
512     }
513   }
514   SbVec3f projdir(0.0f, 0.0f, 0.0f);
515   camera->orientation.getValue().multVec(SbVec3f(0.0f, 0.0f, -1.0f), projdir);
516   SbVec3f focalpoint = camera->position.getValue() + projdir * focaldistance;
517   camera->position.setValue(focalpoint - projdir * newdistance);
518   camera->focalDistance.setValue(newdistance);
519 }
520 
521 float
getZoomByDollyFactor(void) const522 SoPerspectiveCameraManager::getZoomByDollyFactor(void) const
523 {
524   if (!this->havezoombydollylimits) {
525     // without unitydistance, we don't know anything
526     return 1.0f;
527   }
528 
529   SoPerspectiveCamera * camera = this->getCastCamera();
530   float focaldistance = camera->focalDistance.getValue();
531   float zoomfactor = this->unitydistance / focaldistance;
532 
533   return zoomfactor;
534 }
535 
536 // *************************************************************************
537 
538 // stub for now
539 
SoFrustumCameraManager(SoCamera * camera)540 SoFrustumCameraManager::SoFrustumCameraManager(SoCamera * camera)
541 : SoCameraManager(camera)
542 {
543 }
544 
545 SoFrustumCamera *
getCastCamera(void) const546 SoFrustumCameraManager::getCastCamera(void) const
547 {
548   assert(getCamera() && getCamera()->isOfType(SoFrustumCamera::getClassTypeId()));
549   return static_cast<SoFrustumCamera *>(this->getCamera());
550 }
551 
552 
553 void
setZoomValue(float COIN_UNUSED_ARG (zoomvalue),SbBool COIN_UNUSED_ARG (limit))554 SoFrustumCameraManager::setZoomValue(float COIN_UNUSED_ARG(zoomvalue), SbBool COIN_UNUSED_ARG(limit))
555 {
556 }
557 
558 void
adjustZoomValue(float COIN_UNUSED_ARG (diffvalue),SbBool COIN_UNUSED_ARG (limit))559 SoFrustumCameraManager::adjustZoomValue(float COIN_UNUSED_ARG(diffvalue), SbBool COIN_UNUSED_ARG(limit))
560 {
561 }
562 
563 void
adjustZoom(float COIN_UNUSED_ARG (factor),SbBool COIN_UNUSED_ARG (limit))564 SoFrustumCameraManager::adjustZoom(float COIN_UNUSED_ARG(factor), SbBool COIN_UNUSED_ARG(limit))
565 {
566 }
567 
568 float
getZoomFactor(void) const569 SoFrustumCameraManager::getZoomFactor(void) const
570 {
571   return 1.0f;
572 }
573 
574 
575 void
setZoomValueByDolly(float COIN_UNUSED_ARG (zoomvalue),SbBool COIN_UNUSED_ARG (limit))576 SoFrustumCameraManager::setZoomValueByDolly(float COIN_UNUSED_ARG(zoomvalue), SbBool COIN_UNUSED_ARG(limit))
577 {
578 }
579 
580 void
adjustZoomByDollyDistance(float COIN_UNUSED_ARG (distance),SbBool COIN_UNUSED_ARG (limit))581 SoFrustumCameraManager::adjustZoomByDollyDistance(float COIN_UNUSED_ARG(distance), SbBool COIN_UNUSED_ARG(limit))
582 {
583 }
584 
585 void
adjustZoomByDolly(float COIN_UNUSED_ARG (factor),SbBool COIN_UNUSED_ARG (limit))586 SoFrustumCameraManager::adjustZoomByDolly(float COIN_UNUSED_ARG(factor), SbBool COIN_UNUSED_ARG(limit))
587 {
588 }
589 
590 float
getZoomByDollyFactor(void) const591 SoFrustumCameraManager::getZoomByDollyFactor(void) const
592 {
593   return 1.0f;
594 }
595 
596 // *************************************************************************
597