0031668: Visualization - WebGL sample doesn't work on Emscripten 1.39
[occt.git] / src / IVtk / IVtk_IShapeData.hxx
... / ...
CommitLineData
1// Created on: 2011-10-12
2// Created by: Roman KOZLOV
3// Copyright (c) 2011-2014 OPEN CASCADE SAS
4//
5// This file is part of Open CASCADE Technology software library.
6//
7// This library is free software; you can redistribute it and/or modify it under
8// the terms of the GNU Lesser General Public License version 2.1 as published
9// by the Free Software Foundation, with special exception defined in the file
10// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
11// distribution for complete text of the license and disclaimer of any warranty.
12//
13// Alternatively, this file may be used under the terms of Open CASCADE
14// commercial license or contractual agreement.
15
16#ifndef __IVTK_ISHAPEDATA_H__
17#define __IVTK_ISHAPEDATA_H__
18
19#include <IVtk_Interface.hxx>
20#include <IVtk_Types.hxx>
21
22class IVtk_IShapeData;
23DEFINE_STANDARD_HANDLE( IVtk_IShapeData, IVtk_Interface )
24
25//! @class IVtk_IShapeData
26//! @brief Interface for working with triangulated data.
27class IVtk_IShapeData : public IVtk_Interface
28{
29public:
30 typedef Handle(IVtk_IShapeData) Handle;
31
32 virtual ~IVtk_IShapeData() { }
33
34 DEFINE_STANDARD_RTTIEXT(IVtk_IShapeData,IVtk_Interface)
35
36 //! Insert a coordinate
37 //! @param [in] theX X coordinate
38 //! @param [in] theY Y coordinate
39 //! @param [in] theZ Z coordinate
40 //! @return id of added point
41 virtual IVtk_PointId InsertCoordinate (double theX, double theY, double theZ) = 0;
42
43 //! Insert a vertex.
44 //! @param [in] theShapeID id of the sub-shape to which the vertex belongs.
45 //! @param [in] thePointId id of the point that defines the coordinates of the vertex
46 //! @param [in] theMeshType mesh type of the sub-shape (MT_Undefined by default)
47 virtual void InsertVertex (const IVtk_IdType theShapeID,
48 const IVtk_PointId thePointId,
49 const IVtk_MeshType theMeshType = MT_Undefined) = 0;
50
51 //! Insert a line.
52 //! @param [in] theShapeID id of the subshape to which the line belongs.
53 //! @param [in] thePointId1 id of the first point
54 //! @param [in] thePointId2 id of the second point
55 //! @param [in] theMeshType mesh type of the subshape (MT_Undefined by default)
56 virtual void InsertLine (const IVtk_IdType theShapeID,
57 const IVtk_PointId thePointId1,
58 const IVtk_PointId thePointId2,
59 const IVtk_MeshType theMeshType = MT_Undefined) = 0;
60
61 //! Insert a poly-line.
62 //! @param [in] shapeID id of the subshape to which the polyline belongs.
63 //! @param [in] pointIds vector of point ids
64 //! @param [in] meshType mesh type of the subshape (MT_Undefined by default)
65 virtual void InsertLine (const IVtk_IdType theShapeID,
66 const IVtk_PointIdList* thePointIds,
67 const IVtk_MeshType theMeshType = MT_Undefined) = 0;
68
69 //! Insert a triangle
70 //! @param [in] theShapeID id of the subshape to which the triangle belongs.
71 //! @param [in] thePointId1 id of the first point
72 //! @param [in] thePointId2 id of the second point
73 //! @param [in] thePointId3 id of the third point
74 //! @param [in] theMeshType mesh type of the subshape (MT_Undefined by default)
75 virtual void InsertTriangle (const IVtk_IdType theShapeID,
76 const IVtk_PointId thePointId1,
77 const IVtk_PointId thePointId2,
78 const IVtk_PointId thePointId3,
79 const IVtk_MeshType theMeshType = MT_Undefined) = 0;
80};
81
82#endif // __IVTK_ISHAPEDATA_H__