Zivid  1.0.1+3607.8a7510c4
Zivid API
Frame.h
Go to the documentation of this file.
1 /*[
2  * This file is part of the Zivid 3D Camera API
3  *
4  * Copyright 2015-2018 (C) Zivid Labs. All rights reserved.
5  * Contact info@zividlabs.com or see http://www.zividlabs.com
6  *
7  * This code is proprietary and confidential.
8  * Unauthorized copying of this file, via any medium is strictly prohibited.
9 ]*/
10 
11 #pragma once
12 
15 
16 #include "APIExport.h"
17 #include "PointCloud.h"
18 #include "DeviceCloud.h"
19 #include "Settings.h"
20 #include "CameraState.h"
21 #include "FrameInfo.h"
22 #include "ComputeDevice.h"
23 
24 #include <vector>
25 #include <memory>
26 
27 namespace Zivid
28 {
29  class FrameImpl;
30 
36  class Frame
37  {
38  public:
40  ZIVID_API Frame();
41 
43  ZIVID_API explicit Frame(const std::string &fileName);
44 
46  ZIVID_API explicit Frame(const std::string &fileName, ComputeDevice computeDevice);
47 
49  ZIVID_API Frame clone() const;
50 
52  ZIVID_API PointCloud getPointCloud() const;
53 
55  ZIVID_API DeviceCloud deviceCloud() const;
56 
58  ZIVID_API CameraState state() const;
59 
61  ZIVID_API Settings settings() const;
62 
64  ZIVID_API FrameInfo info() const;
65 
67  ZIVID_API void save(const std::string& fileName) const;
68 
70  ZIVID_API void load(const std::string& fileName);
71 
72 #ifndef DOXYGEN_SHOULD_SKIP_THIS
73  ZIVID_API explicit Frame(FrameImpl && other);
74  ZIVID_API FrameImpl &getImpl();
75  ZIVID_API const FrameImpl &getImpl() const;
76 #endif
77 
78  private:
79  std::shared_ptr<FrameImpl> m_impl;
80  };
81 }
Settings for a Zivid camera
Include file with data type definitions for an organized point cloud.
ZIVID_API void save(const std::string &fileName) const
Save the frame as a Zivid data file.
Point cloud on the Compute device
ZIVID_API Frame()
Construct a new frame.
ZIVID_API void load(const std::string &fileName)
Load a frame from a Zivid data file.
A point cloud with x,y,z, contrast and color data laid out on a 2D grid.
Definition: PointCloud.h:28
Definition: Application.h:19
Definitions for export of DLL interfaces
ZIVID_API PointCloud getPointCloud() const
Copies the point cloud to the CPU and returns it.
A frame captured by a Zivid camera
Definition: Frame.h:36
Point cloud on the Compute device.
Definition: DeviceCloud.h:31
ZIVID_API DeviceCloud deviceCloud() const
Returns the point cloud on the Compute device.
Various information for a frame
ZIVID_API Frame clone() const
Clone the frame.
Information about camera connection state, live mode, temperatures, etc.
A Compute device on which to allocate a device point cloud
Settings for a Zivid camera
Definition: Settings.h:50
A Compute device on which to allocate a device point cloud.
Definition: ComputeDevice.h:28
Various information for a frame
Definition: FrameInfo.h:36
ZIVID_API FrameInfo info() const
Get information collected at the time of the frame capture.
ZIVID_API Settings settings() const
Get the settings for the API at the time of the frame capture.
Information about camera connection state, live mode, temperatures, etc.
Definition: CameraState.h:38
ZIVID_API CameraState state() const
Get the camera state data at the time of the frame capture.