|
|
|||
File indexing completed on 2026-07-26 09:18:14
0001 // Created on: 1997-02-10 0002 // Created by: Alexander BRIVIN 0003 // Copyright (c) 1997-1999 Matra Datavision 0004 // Copyright (c) 1999-2014 OPEN CASCADE SAS 0005 // 0006 // This file is part of Open CASCADE Technology software library. 0007 // 0008 // This library is free software; you can redistribute it and/or modify it under 0009 // the terms of the GNU Lesser General Public License version 2.1 as published 0010 // by the Free Software Foundation, with special exception defined in the file 0011 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT 0012 // distribution for complete text of the license and disclaimer of any warranty. 0013 // 0014 // Alternatively, this file may be used under the terms of Open CASCADE 0015 // commercial license or contractual agreement. 0016 0017 #ifndef _Vrml_LOD_HeaderFile 0018 #define _Vrml_LOD_HeaderFile 0019 0020 #include <Standard.hxx> 0021 #include <Standard_Type.hxx> 0022 0023 #include <TColStd_HArray1OfReal.hxx> 0024 #include <gp_Vec.hxx> 0025 #include <Standard_Transient.hxx> 0026 #include <Standard_OStream.hxx> 0027 0028 class Vrml_LOD; 0029 DEFINE_STANDARD_HANDLE(Vrml_LOD, Standard_Transient) 0030 0031 //! defines a LOD (level of detailization) node of VRML specifying properties 0032 //! of geometry and its appearance. 0033 //! This group node is used to allow applications to switch between 0034 //! various representations of objects automatically. The children of this 0035 //! node typically represent the same object or objects at the varying 0036 //! of Levels Of Detail (LOD), from highest detail to lowest. 0037 //! 0038 //! The specified center point of the LOD is transformed by current 0039 //! transformation into world space, and the distance from the transformed 0040 //! center to the world-space eye point is calculated. 0041 //! If thedistance is less than the first value in the ranges array, 0042 //! than the first child of the LOD group is drawn. If between 0043 //! the first and second values in the range array, the second child 0044 //! is drawn, etc. 0045 //! If there are N values in the range array, the LOD group should 0046 //! have N+1 children. 0047 //! Specifying too few children will result in the last child being 0048 //! used repeatedly for the lowest lewels of detail; if too many children 0049 //! are specified, the extra children w ll be ignored. 0050 //! Each value in the ranges array should be greater than the previous 0051 //! value, otherwise results are undefined. 0052 class Vrml_LOD : public Standard_Transient 0053 { 0054 0055 public: 0056 Standard_EXPORT Vrml_LOD(); 0057 0058 Standard_EXPORT Vrml_LOD(const Handle(TColStd_HArray1OfReal)& aRange, const gp_Vec& aCenter); 0059 0060 Standard_EXPORT void SetRange(const Handle(TColStd_HArray1OfReal)& aRange); 0061 0062 Standard_EXPORT Handle(TColStd_HArray1OfReal) Range() const; 0063 0064 Standard_EXPORT void SetCenter(const gp_Vec& aCenter); 0065 0066 Standard_EXPORT gp_Vec Center() const; 0067 0068 Standard_EXPORT Standard_OStream& Print(Standard_OStream& anOStream) const; 0069 0070 DEFINE_STANDARD_RTTIEXT(Vrml_LOD, Standard_Transient) 0071 0072 protected: 0073 private: 0074 Handle(TColStd_HArray1OfReal) myRange; 0075 gp_Vec myCenter; 0076 Standard_Boolean myRangeFlag; 0077 }; 0078 0079 #endif // _Vrml_LOD_HeaderFile
| [ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
|
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
|