![]() |
http://www.coin3d.org/ http://www.kongsberg.com/kogt/ |
00001 // src/Inventor/Qt/viewers/SoQtConstrainedViewer.h. Generated from SoGuiConstrainedViewer.h.in by configure. 00002 00003 /**************************************************************************\ 00004 * Copyright (c) Kongsberg Oil & Gas Technologies AS 00005 * All rights reserved. 00006 * 00007 * Redistribution and use in source and binary forms, with or without 00008 * modification, are permitted provided that the following conditions are 00009 * met: 00010 * 00011 * Redistributions of source code must retain the above copyright notice, 00012 * this list of conditions and the following disclaimer. 00013 * 00014 * Redistributions in binary form must reproduce the above copyright 00015 * notice, this list of conditions and the following disclaimer in the 00016 * documentation and/or other materials provided with the distribution. 00017 * 00018 * Neither the name of the copyright holder nor the names of its 00019 * contributors may be used to endorse or promote products derived from 00020 * this software without specific prior written permission. 00021 * 00022 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 00023 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 00024 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 00025 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 00026 * HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 00027 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 00028 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 00029 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 00030 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 00031 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 00032 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 00033 \**************************************************************************/ 00034 00035 #ifndef SOQT_CONSTRAINEDVIEWER_H 00036 #define SOQT_CONSTRAINEDVIEWER_H 00037 00038 #include <Inventor/Qt/viewers/SoQtFullViewer.h> 00039 00040 // ************************************************************************ 00041 00042 class SOQT_DLL_API SoQtConstrainedViewer : public SoQtFullViewer { 00043 SOQT_OBJECT_ABSTRACT_HEADER(SoQtConstrainedViewer, SoQtFullViewer); 00044 00045 public: 00046 void setUpDirection(const SbVec3f & dir); 00047 const SbVec3f & getUpDirection(void) const; 00048 00049 virtual void setCamera(SoCamera * newcam); 00050 virtual void saveHomePosition(void); 00051 virtual void resetToHomePosition(void); 00052 00053 protected: 00054 SoQtConstrainedViewer(QWidget * parent, 00055 const char * const name, 00056 SbBool embed, 00057 SoQtFullViewer::BuildFlag flag, 00058 SoQtViewer::Type type, 00059 SbBool build); 00060 00061 ~SoQtConstrainedViewer(); 00062 00063 virtual void tiltCamera(float delta); 00064 virtual void bottomWheelMotion(float value); 00065 virtual void leftWheelMotion(float value); 00066 00067 virtual void changeCameraValues(SoCamera * camera); 00068 void findUpDirection(SbVec2s mouselocation); 00069 void checkForCameraUpConstrain(void); 00070 00071 private: 00072 class SoQtConstrainedViewerP * pimpl; 00073 }; 00074 00075 // ************************************************************************ 00076 00077 #endif // ! SOQT_CONSTRAINEDVIEWER_H
Copyright © by Kongsberg Oil & Gas Technologies. All rights reserved.
Generated on Mon Sep 7 11:22:57 2015 for SoQt by Doxygen 1.5.6.