FlowEngine 9.000
Photogrammetry Software Development Kit
Loading...
Searching...
No Matches
StereoPointCloudInterface.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 FLOWENGINESTEREODENSEPOINTCLOUD_H
20#define FLOWENGINESTEREODENSEPOINTCLOUD_H
21
22#pragma once
23
24#include "CommonDef.h"
25
26#include "BulkAccessInterface.h"
28
30
31namespace FlowEngine
32{
33 class CameraInterface;
34
40 {
41 public:
42
44 FLE_DLL virtual ~StereoPointCloudInterface() = default;
45
46 public:
47
49 FLE_DLL virtual Index getPointCount() const = 0;
50
52 FLE_DLL virtual Index getSeedPointCount() const = 0;
53
59 FLE_DLL virtual Result getPointPosition( Index idx, Point3 &outPosition ) const = 0;
60
66 FLE_DLL virtual Result getPointNormal( Index idx, Normal &outNormal ) const = 0;
67
73 FLE_DLL virtual Result getPointColor( Index idx, Color &outColor ) const = 0;
74
79 FLE_DLL virtual Index getPointVisibilityCount( Index pointIndex ) const = 0;
80
95 FLE_DLL virtual Result getPointVisibility( Index pointIndex,
96 Index visibilityIndex,
97 CameraInterface &outCamera ) const = 0;
98
100 FLE_DLL virtual double getMeanPointDistance() const = 0;
101
102 public:
103
117 FLE_DLL virtual Result mergeWith( ConstBuffer< StereoPointCloudInterface * > others, bool lastMerge = true ) = 0;
118
124 FLE_DLL virtual Result copyFrom( const StereoPointCloudInterface &inStereoPoints ) = 0;
125
130 FLE_DLL virtual Result reset( Size vertexCount ) = 0;
131
150 FLE_DLL virtual Result reset( ConstBuffer< Point3 > vertexData,
151 ConstBuffer< Color > colorData,
152 ConstBuffer< Normal > normalData ) = 0;
153
166
173 FLE_DLL virtual Result setPointPosition( Index idx, const Point3 &position ) = 0;
174
181 FLE_DLL virtual Result setPointNormal( Index idx, const Normal &normal ) = 0;
182
189 FLE_DLL virtual Result setPointColor( Index idx, const Color &color ) = 0;
190
197
206 FLE_DLL virtual Result initializeSeeds( LogListenerInterface &logListener, Index seedPoints, Buffer< CameraInterface * > bubbleViewCameras ) = 0;
207
217 FLE_DLL virtual Result removePoint( Index index ) = 0;
218
230 FLE_DLL virtual Result removePoints( ConstBuffer< Index > indexes ) = 0;
231
232 public:
233
237 FLE_DLL virtual Result copyPointsPositions( Buffer< Point3 > outData ) const = 0;
238
239 public:
240
242 FLE_DLL virtual Result saveToPly( ConstStringBuffer filePath,
243 bool saveColors = true,
244 bool saveNormals = true,
245 bool useBinaryEncoding = true ) const = 0;
246
256 FLE_DLL virtual Result loadFromPly( ConstStringBuffer filePath ) = 0;
257
258 public:
259
267 FLE_DLL virtual Result decimateByMaxPointCount( int targetPointCount ) = 0;
268
276 FLE_DLL virtual Result decimateByMaxPointCountOctree( unsigned int maxPointCount ) = 0;
277
284 FLE_DLL virtual Result decimateByPointsDistance( double distance ) = 0;
285
295 FLE_DLL virtual Result densificateByMaxPointCount( int targetPointCount ) = 0;
296
307 FLE_DLL virtual Result projectOnRegularGrid( double gridSpacing, double radius, StandardAxis axis ) = 0;
308 };
309
313
317}
318
319#endif
#define FLOWENGINE_FACTORY
Definition: CommonDef.h:32
Interface for all FlowEngine objects with functions to access data in bulk.
Definition: BulkAccessInterface.h:30
Stores a camera object to feed the Structure from Motion parameters.
Definition: CameraInterface.h:38
Pure virtual Log Listener interface.
Definition: LogListenerInterface.h:41
Interface for all FlowEngine objects with an editable name.
Definition: NamedObjectInterface.h:30
Stores a simple Dense Point Cloud object for the FlowEngine interface.
Definition: StereoPointCloudInterface.h:40
virtual FLE_DLL Result setPointPosition(Index idx, const Point3 &position)=0
virtual FLE_DLL Result transform(ConstBuffer< double > transform)=0
virtual FLE_DLL Result removePoints(ConstBuffer< Index > indexes)=0
virtual FLE_DLL Result replaceVisibility(ConstBuffer< CameraInterface * > cameras)=0
virtual FLE_DLL Result getPointPosition(Index idx, Point3 &outPosition) const =0
virtual FLE_DLL Result getPointNormal(Index idx, Normal &outNormal) const =0
virtual FLE_DLL Index getSeedPointCount() const =0
virtual FLE_DLL Result decimateByMaxPointCount(int targetPointCount)=0
virtual FLE_DLL Result copyFrom(const StereoPointCloudInterface &inStereoPoints)=0
virtual FLE_DLL ~StereoPointCloudInterface()=default
Default virtual destructor.
virtual FLE_DLL Result reset(ConstBuffer< Point3 > vertexData, ConstBuffer< Color > colorData, ConstBuffer< Normal > normalData)=0
virtual FLE_DLL Result getPointColor(Index idx, Color &outColor) const =0
virtual FLE_DLL Result densificateByMaxPointCount(int targetPointCount)=0
virtual FLE_DLL Result copyPointsPositions(Buffer< Point3 > outData) const =0
virtual FLE_DLL Result projectOnRegularGrid(double gridSpacing, double radius, StandardAxis axis)=0
virtual FLE_DLL Result decimateByPointsDistance(double distance)=0
virtual FLE_DLL Result removePoint(Index index)=0
virtual FLE_DLL Index getPointVisibilityCount(Index pointIndex) const =0
virtual FLE_DLL Result getPointVisibility(Index pointIndex, Index visibilityIndex, CameraInterface &outCamera) const =0
virtual FLE_DLL Result mergeWith(ConstBuffer< StereoPointCloudInterface * > others, bool lastMerge=true)=0
virtual FLE_DLL Result loadFromPly(ConstStringBuffer filePath)=0
virtual FLE_DLL Index getPointCount() const =0
virtual FLE_DLL Result saveToPly(ConstStringBuffer filePath, bool saveColors=true, bool saveNormals=true, bool useBinaryEncoding=true) const =0
Save the point cloud to PLY file.
virtual FLE_DLL Result reset(Size vertexCount)=0
virtual FLE_DLL Result initializeSeeds(LogListenerInterface &logListener, Index seedPoints, Buffer< CameraInterface * > bubbleViewCameras)=0
virtual FLE_DLL Result decimateByMaxPointCountOctree(unsigned int maxPointCount)=0
virtual FLE_DLL Result setPointColor(Index idx, const Color &color)=0
virtual FLE_DLL Result setPointNormal(Index idx, const Normal &normal)=0
virtual FLE_DLL double getMeanPointDistance() const =0
Definition: BoundingBoxInterface.cpp:26
StereoPointCloudInterface * CreateStereoPointCloud()
Definition: StereoPointCloudInterface.cpp:27
std::ptrdiff_t Index
Index type.
Definition: CommonDef.h:103
void DestroyStereoPointCloud(StereoPointCloudInterface *stereoPointCloud)
Definition: StereoPointCloudInterface.cpp:32
StandardAxis
enumerates the standard axes
Definition: CommonDef.h:582
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
a packed RGB color
Definition: CommonDef.h:495
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 normal
Definition: CommonDef.h:482
a three dimensional point
Definition: CommonDef.h:459