FlowEngine 9.000
Photogrammetry Software Development Kit
Loading...
Searching...
No Matches
StereoTexturedMeshInterface.h
Go to the documentation of this file.
1/*
2 *
3 * C@@o ____ _____ __ _
4 * oC8@@@@@@@o |___ \| __ \ / _| |
5 * o@@@@@@@@@@@@O __) | | | | |_| | _____ __
6 * O@O 8@@@@@@@@@O |__ <| | | | _| |/ _ \ \ /\ / /
7 * o@@@@@@@O OOOOOCo ___) | |__| | | | | (_) \ V V /
8 * C@@@@@@@@@@@@Oo |____/|_____/|_| |_|\___/ \_/\_/
9 * o8@@@@@@@@@@@@@@@@8OOCCCC
10 * oO@@@@@@@@@@@@@@@@@@@o 3Dflow s.r.l. - www.3dflow.net
11 * oO8@@@@@@@@@@@@o Copyright 2022
12 * oO88@@@@@@@@8OCo All Rights Reserved
13 * O@@@@@@@@@@@@@@@@@@@@@@@@@8OCCoooooooCCo
14 * @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@O
15 * @@@Oo oO8@@@@@@@@@@@@@@@@8
16 *
17 */
18
19#ifndef FLOWENGINESTEREOTEXTUREDMESH_H
20#define FLOWENGINESTEREOTEXTUREDMESH_H
21
22#pragma once
23
24#include "CommonDef.h"
25
27#include "BulkAccessInterface.h"
28
29namespace FlowEngine
30{
31 class StereoMeshInterface;
32
38 {
39 public:
40
42 FLE_DLL virtual ~StereoTexturedMeshInterface() = default;
43
44 public:
45
47 FLE_DLL virtual Index getPointCount() const = 0;
48
50 FLE_DLL virtual Index getTriangleCount() const = 0;
51
61 FLE_DLL virtual Result getPointPosition( Index idx, Point3 &outPosition ) const = 0;
62
71 FLE_DLL virtual Result getPointTexCoords( Index idx, TexCoords &outTexCoord ) const = 0;
72
82 FLE_DLL virtual Result getPointTexCoordData( Buffer< TexCoords > outTexCoordData, bool flipV = false ) const = 0;
83
92 FLE_DLL virtual Result getInputMeshIndexes( Buffer< Index > outIndexes ) const = 0;
93
103 FLE_DLL virtual Result getTriangle( Index idx, Triangle &outTriangle ) const = 0;
104
106 FLE_DLL virtual Index getTextureCount() const = 0;
107
112 FLE_DLL virtual Result getTextureDimensions( Index texIdx,
113 int &outWidth,
114 int &outHeight ) const = 0;
115
120 FLE_DLL virtual Result getTextureData( Index texIdx,
121 Buffer< PointColor32 > outData ) const = 0;
122
137 FLE_DLL virtual Result saveTextureToFile( Index texIdx, ConstStringBuffer filePath, Size textureSize = 0, Size channelBitDepth = 0 ) const = 0;
138
148 FLE_DLL virtual Result loadFromObj( ConstStringBuffer filePath, bool loadTextures ) = 0;
149
166 FLE_DLL virtual Result saveToObj( ConstStringBuffer filePath, bool saveTextures = true, ConstStringBuffer textureFileFormat = "png" ) const = 0;
167
178 FLE_DLL virtual Result extractStereoMesh( StereoMeshInterface &outStereoMesh, bool unifyDuplicatedVertices = true ) const = 0;
179
192 FLE_DLL virtual Result extractStereoMesh( StereoMeshInterface &outStereoMesh, Buffer< Index > inOutTextureToMeshVertexMapping ) const = 0;
193
194 public:
195
201 FLE_DLL virtual Result copyFrom( const StereoTexturedMeshInterface &inStereoTexturedMesh ) = 0;
202
206 FLE_DLL virtual Result setPointPosition( Index idx, const Point3 &position ) = 0;
207
211 FLE_DLL virtual Result setPointTexCoords( Index idx, const TexCoords &texCoords ) = 0;
212
216 FLE_DLL virtual Result setTriangle( Index idx, const Triangle &triangle ) = 0;
217
224
234 FLE_DLL virtual Result removePoint( Index index ) = 0;
235
247 FLE_DLL virtual Result removePoints( ConstBuffer< Index > indexes ) = 0;
248 };
249
253
257}
258
259#endif
#define FLOWENGINE_FACTORY
Definition: CommonDef.h:32
Interface for all FlowEngine objects with functions to access data in bulk.
Definition: BulkAccessInterface.h:30
Interface for all FlowEngine objects with an editable name.
Definition: NamedObjectInterface.h:30
Stores a simple stereo mesh object for the FlowEngine interface.
Definition: StereoMeshInterface.h:40
Stores a simple textured mesh object for the FlowEngine interface.
Definition: StereoTexturedMeshInterface.h:38
virtual FLE_DLL Result getInputMeshIndexes(Buffer< Index > outIndexes) const =0
virtual FLE_DLL ~StereoTexturedMeshInterface()=default
Default virtual destructor.
virtual FLE_DLL Result extractStereoMesh(StereoMeshInterface &outStereoMesh, Buffer< Index > inOutTextureToMeshVertexMapping) const =0
virtual FLE_DLL Result getTextureData(Index texIdx, Buffer< PointColor32 > outData) const =0
virtual FLE_DLL Index getTriangleCount() const =0
virtual FLE_DLL Result setTriangle(Index idx, const Triangle &triangle)=0
virtual FLE_DLL Index getTextureCount() const =0
virtual FLE_DLL Result removePoints(ConstBuffer< Index > indexes)=0
virtual FLE_DLL Result copyFrom(const StereoTexturedMeshInterface &inStereoTexturedMesh)=0
virtual FLE_DLL Result getTriangle(Index idx, Triangle &outTriangle) const =0
virtual FLE_DLL Result setPointTexCoords(Index idx, const TexCoords &texCoords)=0
virtual FLE_DLL Result loadFromObj(ConstStringBuffer filePath, bool loadTextures)=0
virtual FLE_DLL Result getPointTexCoords(Index idx, TexCoords &outTexCoord) const =0
virtual FLE_DLL Result transform(ConstBuffer< double > transform)=0
virtual FLE_DLL Result extractStereoMesh(StereoMeshInterface &outStereoMesh, bool unifyDuplicatedVertices=true) const =0
virtual FLE_DLL Result getPointTexCoordData(Buffer< TexCoords > outTexCoordData, bool flipV=false) const =0
virtual FLE_DLL Result getPointPosition(Index idx, Point3 &outPosition) const =0
virtual FLE_DLL Result setPointPosition(Index idx, const Point3 &position)=0
virtual FLE_DLL Result getTextureDimensions(Index texIdx, int &outWidth, int &outHeight) const =0
virtual FLE_DLL Index getPointCount() const =0
virtual FLE_DLL Result saveTextureToFile(Index texIdx, ConstStringBuffer filePath, Size textureSize=0, Size channelBitDepth=0) const =0
virtual FLE_DLL Result removePoint(Index index)=0
virtual FLE_DLL Result saveToObj(ConstStringBuffer filePath, bool saveTextures=true, ConstStringBuffer textureFileFormat="png") const =0
Definition: BoundingBoxInterface.cpp:26
std::ptrdiff_t Index
Index type.
Definition: CommonDef.h:103
void DestroyStereoTexturedMesh(StereoTexturedMeshInterface *stereoTexturedMesh)
Definition: StereoTexturedMeshInterface.cpp:32
StereoTexturedMeshInterface * CreateStereoTexturedMesh()
Definition: StereoTexturedMeshInterface.cpp:27
std::size_t Size
Size type.
Definition: CommonDef.h:106
Result
Enumerates possible results generated by FlowEngine.
Definition: CommonDef.h:48
Holds a (mutable) non_owning pointer and a size Used to marshal memory buffers as arguments in a safe...
Definition: CommonDef.h:127
Specialization for a const buffer characters.
Definition: CommonDef.h:305
Holds a (non mutable) non_owning pointer and a count Used to marshal memory buffers as arguments in a...
Definition: CommonDef.h:200
a three dimensional point
Definition: CommonDef.h:459
a texture coordinate Holds a couple of floats representing texture coordinates
Definition: CommonDef.h:540
a triangle. Holds 3 indexes to points. Triangles are specified in counter-clockwise order
Definition: CommonDef.h:526