/////////////////////////////////////////////////////////////////////////////// // Copyright (C) 2002-2025, Open Design Alliance (the "Alliance"). // All rights reserved. // // This software and its documentation and related materials are owned by // the Alliance. The software may only be incorporated into application // programs owned by members of the Alliance, subject to a signed // Membership Agreement and Supplemental Software License Agreement with the // Alliance. The structure and organization of this software are the valuable // trade secrets of the Alliance and its suppliers. The software is also // protected by copyright law and international treaty provisions. Application // programs incorporating this software must include the following statement // with their copyright notices: // // This application incorporates Open Design Alliance software pursuant to a license // agreement with Open Design Alliance. // Open Design Alliance Copyright (C) 2002-2025 by Open Design Alliance. // All rights reserved. // // By use of this software, its documentation or related materials, you // acknowledge and accept the above terms. /////////////////////////////////////////////////////////////////////////////// #ifndef ODEXGSOPENGLVECTORIZEDEVICE #define ODEXGSOPENGLVECTORIZEDEVICE #include "TD_PackPush.h" #include "GsOpenGLStreamVectorizer.h" #include "CommonOpenGLProps.h" OD_OPENGL_DEFINE_COMMON_PROPS(ExGsOpenGLVectorizeDeviceBase, OdGsOpenGLStreamVectorizeDevice, OdCommonDeviceProps); /** \details This class implements OpenGL Vectorizer Device objects for Android platform. Library: Source code provided. */ class ExGsOpenGLVectorizeDevice : public ExGsOpenGLVectorizeDeviceBase { bool m_bContextCreated; protected: ODRX_USING_HEAP_OPERATORS(ExGsOpenGLVectorizeDeviceBase); ExGsOpenGLVectorizeDevice(); virtual ~ExGsOpenGLVectorizeDevice(); void update(OdGsDCRect* pUpdatedRect); void updateScreen(); /** \details Creates a context for this Device object. */ virtual void createContext(); virtual void deleteContext(); }; /** \details This class implements OpenGL Vectorizer View objects for Android platform. Library: Source code provided. */ class ExGsOpenGLVectorizeView : public OdGsOpenGLStreamVectorizeView { /** \details Returns a device that owns this view. \returns Pointer a device that contains this view. */ ExGsOpenGLVectorizeDevice* device() { return static_cast(OdGsOpenGLVectorizeView::device()); } bool m_bSelecting; public: /** \details Default constructor for the ExGsOpenGLVectorizeView class. */ ExGsOpenGLVectorizeView(); /** \details Invokes the specified OdGsSelectionReactor object for the specified selection area (or point) in this view. \param points [in] Array of points. \param numPoints [in] Number of points. \param pReactor [in] Pointer to the reactor. \param mode [in] Selection mode. */ void select(const OdGePoint2d* points, int numPoints, OdGsSelectionReactor* pReactor, OdGsView::SelectionMode mode); /** \details Processes polyline data. \param numPoints [in] Number of points in the polyline. \param vertexList [in] Array of vertices that make up the polyline. \sa */ void polylineOut(OdInt32 numPoints, const OdGePoint3d* vertexList); /** \details Processes mesh data. \param numRows [in] Number of rows. \param numColumns [in] Number of columns. \param vertexList [in] Array of vertices. \param pEdgeData [in] Pointer to additional edge data. \param pFaceData [in] Pointer to additional face data. \param pVertexData [in] Pointer to additional vertex data. \sa */ void meshProc(OdInt32 numRows, OdInt32 numColumns, const OdGePoint3d* vertexList, const OdGiEdgeData* pEdgeData = 0, const OdGiFaceData* pFaceData = 0, const OdGiVertexData* pVertexData = 0); /** \details Processes shell data. \param numVertices [in] Number of vertices. \param vertexList [in] Array of vertices. \param faceListSize [in] Number of entries in faceList. \param faceList [in] Array of numbers that define the faces. \param pEdgeData [in] Pointer to additional edge data. \param pFaceData [in] Pointer to additional face data. \param pVertexData [in] Pointer to additional vertex data. \sa */ void shellProc(OdInt32 numVertices, const OdGePoint3d* vertexList, OdInt32 faceListSize, const OdInt32* faceList, const OdGiEdgeData* pEdgeData = 0, const OdGiFaceData* pFaceData = 0, const OdGiVertexData* pVertexData = 0); /** \details Processes raster images data. \param origin [in] Lower-left corner. \param u [in] Image width vector. \param v [in] Image height vector. \param pImage [in] Pointer to the RasterImage object. \param uvBoundary [in] Array of image boundary points (may not be null). \param numBoundPts [in] Number of boundary points. \param transparency [in] True if and only if image transparency is on. \param brightness [in] Image brightness [0.0 .. 100.0]. \param contrast [in] Image contrast [0.0 .. 100.0]. \param fade [in] Image fade value [0.0 .. 100.0]. \sa */ void rasterImageProc(const OdGePoint3d& origin, const OdGeVector3d& u, const OdGeVector3d& v, const OdGiRasterImage* pImage, const OdGePoint2d* uvBoundary, OdUInt32 numBoundPts, bool transparency = false, double brightness = 50.0, double contrast = 50.0, double fade = 0.0); /** \details Processes metafile data. \param origin [in] Metafile origin. \param u [in] Metafile width vector. \param v [in] Metafile height vector. \param pMetafile [in] Pointer to the metafile object. \param dcAligned [in] Reserved. \param allowClipping [in] Reserved. */ void metafileProc(const OdGePoint3d& origin, const OdGeVector3d& u, const OdGeVector3d& v, const OdGiMetafile* pMetafile, bool dcAligned = true, bool allowClipping = false); //void ownerDrawDc( // const OdGePoint3d& origin, // const OdGeVector3d& u, // const OdGeVector3d& v, // const OdGiSelfGdiDrawable* pDrawable, // bool dcAligned = true, // bool allowClipping = false); }; #include "TD_PackPop.h" #endif // ODEXGSOPENGLVECTORIZEDEVICE