Astra SDK: Astra SDK v2.0.15

Astra SDK 2.0.15
Astra SDK v2.0.15

Astra SDK v2.0.15
Copyright (c) 2015-2019 Orbbec
https://www.orbbec3d.com

For help and support, visit us at https://3dclub.orbbec3d.com.

Features
========
  Depth stream
  Point stream - an image where each pixel is the real-world 3D point, i.e. depth to world
  Color stream - Astra, Astra Pro, and Persee
  Infrared stream - can start when color is stopped
  Body stream - features include:
   Full-body skeleton tracking - Tracks 6 people max, though performance may vary
   Body mask
   Floor mask and floor plane
   Hand pose recognition: Grip (fist) and other (open hand)
   Note: when the Body stream is started, the depth stream automatically goes into
   registered depth mode so that depth & color line up
  Masked Color stream - Background removal on the color frame using the body mask
  Colorized Body stream - Body mask visualized with different colors for each body
  Hand stream - separate from body tracking and uses less CPU: wave your hand to track a single hand point

Supported systems
=================
  Windows 8 and 10, 32-bit and 64-bit
  Ubuntu 14.04 64-bit
  Ubuntu 16.04 64-bit
  Android 4.4.2 and 5.1 (armeabi-v7a 32-bit)
  Orbbec Persee

Supported languages & frameworks
================================
  C
  C++
  .NET/C#
  Java
  Unity 5 - sample provided for Unity 5.3.6

Possibly working systems - these may work but are untested/unsupported at this time
========================
  Android 6.0, Android 7.0, Android 8.1
  Unity3D 2017, Unity3D 2018, Unity 4.7

Orbbec Body Tracking trial time expiration
===============
For this release, Orbbec Body Tracking expires on 2019/06/30
and will stop operating. Please make sure to update to a new version before then.
You can now set your license string to extend the trial. See API notes below for
orbbec_body_tracking_set_license().

For support on the trial expiration or to extend your trial, please contact
info@orbbec3d.com.

What's New
==========

v2.0.15 2019/03/15
  Add support for the Orbbec Astra Deeyea camera model and Orbbec Astra DaBai camera model.
  Add device opened notification callbacks on Android for Unity. You can implement this
  interface and use it when calling "openAllDevices" on "AstraUnityPlayerActivity",
  For more information, see AstraUnityContext.cs in Unity Sample.
  C#:
    public class AstraDeviceManagerListener : AndroidJavaProxy
    {
        public AstraDeviceManagerListener() :
            base("com.orbbec.astra.android.AstraDeviceManagerListener") {}

        //When open completed will call this. In this function, before you create streams,
        //you should check the number of available devices by calling "getAvailableDevicesSize"
        //on "AstraUnityPlayerActivity". If number is zero, Don't create streams.
        void onOpenAllDevicesCompleted(AndroidJavaObject availableDevices) {}

        //Can't work currently.
        void onOpenDeviceCompleted(AndroidJavaObject device, AndroidJavaObject opened) {}

        //There is no Orbbec device to open.
        void onNoDevice() {}

        //Requesting usb permission is denied by user.
        void onPermissionDenied(AndroidJavaObject device){}
    }
  Support getting NV21 format image from ColorStream on Android when using Astra Pro and
  Astra Pro Plus.
  Java: ColorStream stream = ColorStream.getNV21ColorStream(streamReader);
        ColorFrame colorFrame = ColorFrame.getNV21ColorFrame(readerFrame);
  C#:   using Astra.Core;
        ColorStream stream = streamReader.GetStream(StreamSubType.COLOR_NV21_SUBTYPE);
        ColorFrame colorFrame = frame.GetFrame(StreamSubType.COLOR_NV21_SUBTYPE);
  Add D (for Deeyea and DaBai) keyboard shortcut to SimpleDepthViewer-SFML, SimpleBodyViewer-SFML
  and MaskedColorViewer-SFML to work with Deeyea and DaBai.
  Add N keyboard shortcut to MaskedColorViewer-SFML to mirror color stream.
  Support skeleton recognition for five people.

v2.0.14 2018/12/10
  Add device opened notification callbacks on Android
  Improve body joint alignment with depth image (fix issue related to field-of-view)

v2.0.13 2018/11/22
  Add Skeleton Optimization level APIs. The optimization level gives the developer
  control over the balance between memory usage and accuracy for skeleton tracking.
  There are 9 optimization levels, with 1 being the minimum memory but worst tracking
  accuracy, and 9 requiring the most memory but best tracking accuracy. Level 9 is
  the default. Level 2 is the minimum recommended level. Optimization enums have suggested
  values: Min Memory = 2, Balanced = 5, Best Accuracy = 9.
  C:    astra_skeleton_optimization_t optimization;
        astra_bodystream_get_skeleton_optimization(bodyStream, &optimization);
        astra_bodystream_set_skeleton_optimization(bodyStream, optimization);
  C++:  SkeletonOptimization optimization = bodyStream.get_skeleton_optimization();
        bodyStream.set_skeleton_optimization(optimization);
  C#:   SkeletonProfile optimization = bodyStream.GetSkeletonProfile();
        bodyStream.SetSkeletonProfile(optimization);
  Java: SkeletonOptimization optimization = bodyStream.getSkeletonOptimization();
        bodyStream.setSkeletonOptimization(optimization);
  Unity sample has been updated with UI controls for Skeleton Optimization
  SkeletonProfile.UpperBody is now available. This profile includes all joints
  above MidSpine. Unity sample has been updated with UI option to select Upper Body Profile.
  POTENTIALLY BREAKING: The Java wrapper has been updated so that various classes
  that were marked public are now internal.
  Add support for the Orbbec Astra Pro Plus camera model.
  Docs now contains more docs.
  C# wrapper now allocates even less garbage-collected memory per frame.
  Add "Debug Text" toggle option in Unity wrapper sample application. This is enabled
  by default. When disabled, the FPS display and internal timings are cleared.
  This reduces the GC memory allocation by approximately 2k per frame, useful for profiling.
  Fix stream corruption issue in Unity wrapper sample application when switching scenes.
  Fix issue where depth stream may be stopped when the color stream was stopped,
  and vice versa.
  Fix issue where MaskedColorStream and ColorizedBodyStream both stopped when one
  of those streams was stopped.
  Fix issue where terminating and then initializing the SDK on Android didn't work.
  Frame skipping is now disabled in Orbbec Body Tracking. We expect that
  previous improvements to the Unity wrapper allowing asynchronous processing
  will result in a better overall experience.
  Minor internal bug fixes
  Internal code cleanup

v2.0.12 2018/09/30
  In C++ API, RGBAPixel was renamed to RgbaPixel for style consistency.
  There is a typedef RgbaPixel RGBAPixel; so existing code still works,
  but RGBAPixel is deprecated.
  Adds C++-style serial number API to C++ API:
  C++:    DepthStream depthStream = [...];
          std::string serialNumber = depthStream.serial_number();
  The existing C-style method in the DepthStream class is still available
  for compatibility reasons but is considered deprecated:
          void serial_number(char* serialnumber, uint32_t length) const;
  Add astra_reader_has_new_frame() thread-safe C API and implementation.

  This method is designed to be safe to call from any thread. Internally,
  it stores the status in an atomic_bool, which is thread-safe.
  The reason for making this thread-safe is so that astra_update() can
  be called in a loop in a background thread, and the main thread can
  check whether it should try to sync with the background thread so that
  it can open a new frame from readers.

  This is a short-term solution that helps support a specific threading
  scenario until the full Astra API is updated to be thread-safe. In this
  threading scenario, the app must guarantee that the Astra API is still
  only called from one thread at a time through its own synchronization
  (mutex, etc.), with the one exception that astra_reader_has_new_frame()
  may be called from any thread.
  C:    astra_reader_t reader = [...];
        bool hasNewFrame;
        reader_has_new_frame(reader, &hasNewFrame)
  C++:  astra::StreamReader reader = [...];
        bool hasNewFrame = reader.has_new_frame();
  C#:   Astra.StreamReader reader = [...];
        bool hasNewFrame = reader.HasNewFrame();
  Java: Astra.StreamReader reader = [...];
        boolean hasNewFrame = reader.hasNewFrame();
  Add P (for Profile) keyboard shortcut to SimpleBodyViewer-SFML to toggle
  between Full skeleton profile and Basic skeleton profile.
  Add T (for Tracking) keyboard shortcut to SimpleBodyViewer-SFML to toggle
  between Segmentation, Segmentation+Body, and Segmentation+Body+HandPoses
  as default body feature tracking states.
  Performance of MaskedColorStream processing has been improved significantly
  (roughly 4x faster depending upon platform and image ratios) through the use
  of cross-platform SIMD code.
  Fix issue in Java wrapper where MaskedColorStream/ColorizedBodyStream used
  ImageStream as base class. Those now derive from DataStream as intended.
  Fix issue in Java wrapper where PointFrame.getPointBuffer() called itself
  recursively instead of returning the point buffer. It now returns the point buffer.
  Fix issue in Java wrapper where PointStream.get() wasn't public. It is now public.
  Fix inconsistent definition/declaration of astra_core_version
  Fix issue in OBT where skeletons would be tracked even in Segmentation-only mode
  Fix issue in OBT where if a user moves further than four meters from the sensor
  (the max for skeleton tracking) the user would not get skeleton tracking again
  until they left the frame completely. Now the user can walk further than four meters
  then closer and will get skeleton tracking again.
  Fix issue in OBT where a class was inappropriately being used by multiple threads
  and caused some rare crashes on certain Android machines. Now each thread has its
  own instance of the class.
  Fix issue in OBT where changing the SkeletonProfile would not re-initialize a
  type properly. The type now reinitialized property.
  Fix issue in OBT where the legs was not allowed to rotate more than a
  certain angle. The legs can now be tracked with larger leg swings.
  Streams now used aligned memory allocation for all stream bins. This is to support
  SIMD operations on bin data.
  Add ASTRA_ALIGN(N) macro to headers to explcitly align certain fields as necessary.
  Update CMakeLists so Astra SDK can be built with Visual Studio 2017 (compiler 19.14).
  Refactor software-registration code in MaskedColorStream for legacy Astra mx400 cameras
  Internal changes to protect against some crashes in certain multi-threading
  scenarios. With the exception of astra_reader_has_new_frame(), the API
  must still be called from only a single thread. Deadlocks and crashes are
  still possible if multiple threads access the API simultaneously.
  Minor changes to naming and refactoring to sample code to clarify the purpose of the code
  Internal code cleanup

v2.0.11-beta5 2018/08/01
  BREAKING: In Java, Body.getId() now returns an int instead of a byte.
  This fixes an issue where body ids would appear to be negative when the id
  is greater than 127.
  Add SkeletonProfile API. This allows the developer to select from several options
  for which skeleton joints are tracked. Full profile tracks all available joints
  and basic profile only tracks head, MidSpine, left hand, and right hand.
  Basic profile is more accurate for the tracked joints and takes less time to track.
  C:    astra_skeleton_profile_t profile;
        astra_bodystream_get_skeleton_profile(bodyStream, &profile);
        astra_bodystream_set_skeleton_profile(bodyStream, profile);
        Valid options for astra_skeleton_profile_t include:
        ASTRA_SKELETON_PROFILE_FULL
        ASTRA_SKELETON_PROFILE_BASIC
  C++:  bodyStream.set_skeleton_profile(SkeletonProfile::Full); // or SkeletonProfile::Basic
        SkeletonProfile profile = bodyStream.get_skeleton_profile();
  C#:   bodyStream.SetSkeletonProfile(SkeletonProfile.Full); // or SkeletonProfile.Basic
        SkeletonProfile profile = bodyStream.GetSkeletonProfile();
  Java: bodyStream.setSkeletonProfile(SkeletonProfile.Full); // or SkeletonProfile.Basic
        SkeletonProfile profile = bodyStream.getSkeletonProfile();
  Improve the C# wrapper to significantly reduce heap allocation.
  Optimized Android yuv2rgb conversion, saving up to 2.5ms on low-end Android boxes
  Fix issue where the body center of mass could be NaN if certain joints were not tracked
  Fix issue where OpenNI2 could crash if the driver dlls are in a non-standard directory
  Fix issue where a zero byte astra.log is created even if file_output is false in astra.toml.
  Now astra.log is no longer created when file_output is false.
  Fix issue where some plugins were requesting the device serial number with too small
  of a string. 256 bytes is recommended the serial number char[] size.
  Fix out-of-bounds memory access in Orbbec Body Tracking
  Fix issue where OBT licensing periodic check can fail after the trial expiration date,
  even with a valid license
  Fix issue in OBT where the position of the head joint was inappropriately influenced
  by other joints
  Fix bug where if the first body frame is estimated (due to a very slow CPU) then
  the body frame would have garbage data. The data is now properly initialized.
  Fix issue where skeletonizer could have been deleted twice
  Refactor data loading methods in OBT to reduce memory overhead and slightly
  reduce startup time.
  Internal improvements to performance profiling and fixing some minor compiler warnings.

v2.0.10-beta4 2018/07/05

  BREAKING: In C++, the CoordinateMapper class's methods convert_depth_to_world()
  and convert_world_to_depth() now take the output parameters by reference instead of by pointer:
  void convert_depth_to_world(float  depthX, float  depthY, float  depthZ,
                              float& worldX, float& worldY, float& worldZ) const;
  void convert_world_to_depth(float  worldX, float  worldY, float  worldZ,
                              float& depthX, float& depthY, float& depthZ) const;
  Add stream availability API. This allows developers to determine if a stream will
  ever return data. A stream may not be available if the sensor is not plugged in or
  if the sensor or plugin does not support that stream. This may depend upon the current
  sensor configuration. A stream that is not available will not receive start()/stop() commands
  and will not process get/set/invoke commands such as setting the resolution.
  Once the stream becomes available, you must call start() and configure the resolution.
  C:    astra_depthstream_is_available(astra_depthstream_t depthStream, bool* isAvailable)
        and similar for every other stream
  C++:  astra::DepthStream depthStream = reader.stream();
        bool isAvailable = depthStream.is_available()
        and similar for every other stream
  C#:   DepthStream depthStream = reader.GetStream();
        bool isAvailable = depthStream.IsAvailable;
        and similar for every other stream
  Java: DepthStream depthStream = DepthStream.get(reader);
        boolean isAvailable = depthStream.getIsAvailable();
  Add StreamSet availability API. This allows developers to determine if a StreamSet is available.
  A StreamSet is available when a sensor is plugged in that matches the StreamSet URI such as device/sensor0.
  If a sensor is unplugged or was not yet plugged in, the StreamSet is not available.
  Any streams accessed from an unavailable StreamSet will also be unavailable.
  C:    astra_streamsetconnection_t streamSet;
        astra_streamset_open("device/sensor1", &streamSet);
        astra_streamset_is_available(streamSet, bool* isAvailable);
  C++:  StreamSet streamSet("device/sensor1");
        bool isAvailable = streamSet.is_available();
  C#:   StreamSet streamSet = StreamSet.Open("device/sensor1");
        bool isAvailable = streamSet.IsAvailable;
  Java: StreamSet streamSet = StreamSet.open("device/sensor1");
        boolean isAvailable = streamSet.getIsAvailable();
  Add StreamSet URI API. This allows developers to determine the URI of a StreamSet.
  Typically this is the URI that is passed in when opening the StreamSet, but if the
  StreamSet was default constructed or used "device/default", then the URI will be
  "device/sensor0".
  C:    char uri[ASTRA_STREAMSET_URI_MAX_LENGTH];
        astra_streamsetconnection_t streamSet;
        astra_streamset_open("device/default", &streamSet);
        astra_streamset_get_uri(streamSet, uri, ASTRA_STREAMSET_URI_MAX_LENGTH);
        // uri now contains "device/sensor0"
        The method copies the URI into the char* memory provided by the caller.
  C++:  StreamSet streamSet;
        std::string uri = streamSet.uri(); //"device/sensor0"
  C#:   StreamSet streamSet = StreamSet.Open();
        string uri = streamSet.Uri; //"device/sensor0"
  Java: StreamSet streamSet = StreamSet.open();
        String uri = streamSet.getUri();
  Add IsEstimated API for BodyFrame in C# and Java wrappers. This was previously
  added to BodyFrameInfo, but in those wrappers BodyFrameInfo is not accessible.
  This fixes the issue and publicly exposes IsEstimated.
  C#:   bool isEstimated = bodyFrame.IsEstimated;
  Java: boolean isEstimated = bodyFrame.getIsEstimated();
  DepthStream field-of-view now changes when registration is enabled. When registration
  is enabled, the DepthStream field-of-view matches the ColorStream.
  Update body tracking to use correct field-of-view as provided by the DepthStream
  Optimized memory usage in Orbbec Body Tracker to reduce overall RAM usage by about 50 MB.
  Accessing less memory also leads to a small performance improvement.
  Fix issue where bodies that went beyond the max skeleton range of 4 meters would never
  get their skeletons back when they come back within 4 meters.
  Fix issue where sometimes a UVC color device (e.g. Astra Pro color) fails to open.
  The UVC device may fail to open if the device is not ready yet. Now the SDK will
  attempt to open the UVC device repeatedly with a short delay between each attempt.
  Fixes a crash on Linux when more than one UVC color device (Astra Pro) is plugged in.
  The SDK still only supports one UVC color devices at a time, but now additional UVC
  color devices will not cause a crash and you can use the non-color streams from
  the additional sensors.
  Fix issue where the stream bin system would allocate more memory than necessary.
  This reduces the memory usage of active streams.
  Fix issue in MaskedColorStream when the resolution of the color stream is smaller
  than the resolution of the body stream/depth stream.
  Fix issue in SimpleBodyViewer-SFML where the Neck and Wrist joints were not properly
  connected to the skeleton visualization
  Fix Java JNI bug where getting a boolean property (such as getMirroring(), getRegistration())
  may not have returned the correct value.
  Fix issue where an internal stage of the hand pose recognizer selected an incorrect value
  from a list of points on the user's hand.
  Fix issue where an internal stage of the hand pose recognizer may have dereferenced invalid memory
  Fix issue in body tracking where an iterator was used incorrectly when erasing lost bodies
  Fix various minor logic issues found when auditing the Orbbec Body Tracking segmentation module
  Various internal code cleanup and minor changes to support new features
  Orbbec Body Tracking trial expiration set to September 30, 2018

v2.0.9-beta3 2018/03/31

  Add missing astra_jni.dll for Java wrapper which was omitted from previous release.
  Add body tracking frame skipping for very low-end CPUs (usually Android devices):
  If the calculation of a body frame is taking too long, it will estimate the next
  frame joints based upon the velocity of previous frames. The frame calculation
  will continue in the background and the results will be incorporated in a future
  frame. If the CPU is fast enough then this feature will not change body tracking
  behavior.
  Add isEstimated to determine if the body frame has been estimated due to extremely slow CPU.
  Typically this will only happen on very low-end Android devices.
  C: astra_bodyframe_info_t.isEstimated
  C++: BodyFrameInfo::is_estimated()
  C#: BodyFrameInfo.IsEstimated
  Java: BodyFrameInfo.getIsEstimated()
  astra_imagestream_get_usb_info()/ColorStream::usb_info() is now supported on
  Astra Pro color stream
  Minor improvements to the public headers (fixed some missing includes)
  Fix Android support on certain boxes: crashes, Astra Pro support
  Android will now write Astra SDK logs to the Android log (logcat)
  Minor improvements to error checking in the sample projects
  Fix issue with BodyStream that prevented it from starting again after it was
  previously started and then stopped.
  Slightly reduce RAM usage and improve startup time of body tracking
  Fix issue with SimpleBodyViewer-SFML running at low FPS by changing depth resolution
  from 160x120 to 640x480. (320x240 would also work.) There is a bug in some Astra
  firmwares that causes 160x120 to run at a slower framerate.
  Fix issue with color stream not working on Astra Mini
  Fix issue where MaskedColorStream would crash when user was farther than 2m
  when using an Astra camera with MX400 chip.

v2.0.8-beta2 2018/01/31

Full list of changes upcoming with final v2.0 release. This version has some small
breaking API changes. Be aware, there will be more breaking API changes between
now and the final v2.0 release.

New features:
  On Android with UVC color (Astra Pro & Persee), the API now supports listing the
  available resolutions, getting the current resolution, and setting the resolution.
  For low-end Android devices we recommend running color at 320x240 for performance
  reasons.
  Add body tracking feature API that lets you control the processing done for a tracked body:
  just segmentation, joints, hand poses. Each level includes the previous (hand poses
  includes joints and joints includes segmentation.) You can set the default for
  new bodies as well as change how a body is tracked for future frames.
  C: astra_body_t has the astra_body_features_t features field, which reflects the
     features used to generate the astra_body_t.
     astra_bodystream_get_body_features(), astra_bodystream_set_body_features(),
     astra_bodystream_get_default_body_features(), astra_bodystream_set_default_body_features()
  C++: Body::joints_enabled(), Body::hand_poses_enabled(),
       BodyStream::get_body_features(), BodyStream::set_body_features(),
       BodyStream::get_default_body_features(), BodyStream::set_default_body_features()
  C#: Body.AreJointsEnabled, Body.AreHandPosesEnabled,
      BodyStream.GetBodyFeatures(), BodyStream.SetBodyFeatures(),
      BodyStream.GetDefaultBodyFeatures(), BodyStream.SetDefaultBodyFeatures()
  Java: Body.areJointsEnabled(), Body.areHandPosesEnabled(),
        BodyStream.getBodyFeatures(), BodyStream.setBodyFeatures(),
        BodyStream.getDefaultBodyFeatures(), BodyStream.setDefaultBodyFeatures()
  Add license API:
  C/C++: orbbec_body_tracking_set_license(const char* licenseString)
  C#: Astra.BodyTracking.SetLicense(String licenseString)
  Java: BodyTracking.setLicense(String licenseString)
  Call these methods directly after astra_initialize() with the license key string
  provided to you by Orbbec.
  Orbbec Body Tracking trial expiration set to March 31, 2018
  Add Chinese translation of Astra Book documentation in docs/html-zh_CN
  Java and C# APIs updated to match features of C++ API
  MaskedColor calculation is now 3x faster
  C#: FloorMask now has CopyData() and IntPtr DataPtr to reduce memory allocations
  C++: Fixed bug where Neck joint was id 19 when it should have been id 18
  OpenNI2 backend updated with MX6000 chip support
  Various bug fixes

v2.0.7-beta 2017/12/16

Full list of changes upcoming with final v2.0 release. This version has some small
breaking API changes. Be aware, there will be more breaking API changes between
now and the final v2.0 release.

New features:
  .NET/C# wrapper
  Java wrapper
  Unity wrapper - distributed separately
  Color support for Astra Pro and Orbbec Persee
  Orbbec Body Tracking integration
  MaskedColorStream
  ColorizedBodyStream
  Various bug fixes
  Support for Android 4.4.2 & 5.1 - distributed separately

v0.5.0 2016/04/26

This release cleans up the API and library organization a bit. There are a few breaking changes in this release
from v0.4 but they should be relatively quick to update existing code.

  BREAKING: Library names:
    astra -> astra_core
    astraul -> astra
    astra_api -> astra_core_api
  BREAKING: C++ API stylistic changes: standardize on namespace::ClassName::method_name
  BREAKING: Besides the predictable stylistic changes, a few C++ method renames:
    DepthStream/ColorStream/etc horizontalFieldOfView -> hFov, verticalFieldOfView -> vFov
    DepthFrame/ColorFrame/etc resolutionX/resolutionY -> width/height
    DepthFrame/ColorFrame/etc numberOfPixels -> length
  BREAKING: C++ header filenames renamed according to namespace.hpp or Class.hpp.
    Main header to include:  &  -> just .
    Don't need to explicitly include astra_core.hpp.
  BREAKING: astra::Astra::{initialize(),terminate()} -> astra::{initialize(),terminate()}
  Fix: Cycling start/stop on a stream multiple times no longer crashes
  Fix: SXGA depth & color support now work
  Enhancement: (ALL) Add const as appropriate in the C++ API, makes passing around references to frame types possible
  Enhancement: (ALL) StreamSet and StreamReader have improved copy-semantics and default ctor,
                     allowing simpler storage as a class field.
  Enhancement: (ALL) Add MultiSensorViewer-SFML sample demonstrating multi-sensor support
  Enhancement: (ALL) Removed the dependency on OpenCV and reimplemented the necessary functionality internally.
  Enhancement: (Windows) Add VS2015 support
  Enhancement: (OSX) libusb, SFML are now distributed with the SDK, and rpaths are automatically setup.
                     No more brew installing! (except maybe CMake)
  Enhancement: (OSX) Add build_samples.sh script in samples/, see ./build_samples.sh -h for help
  Enhancement: (OSX) Building the samples also copies the Astra SDK and SFML binaries to the lib dir,
                     allowing simpler copy-only deployment: Just copy bin/ and lib/.

v0.4.0 2015/10/14

  Add official support for Win64 and OS X 10.8+
  Updated SFML to 2.3.2
  Added features to SimpleDepthViewer-SFML and SimpleStreamViewer-SFML: pausing,
  overlay color on depth, display depth data under the mouse in text overlay. (See keyboard shortcut section below.)
  Minor internal bug fixes

v0.3.0 2015/09/14

  Rename to Astra SDK.
  Rename Sensor to StreamSet in C++ API.
  Various bug fixes and internal enhancements.
  New samples:  SimpleStreamViewer-SFML, SimpleColorViewer-SFML, ColorReaderEvent, ColorReaderPoll
  Samples have improved performance.
  Add IR stream, mirrored depth, and registered depth support.
  VS2013 samples solution no longer requires copying files - compiles and runs out of the box.
  StreamReader start() and stop() are functional now. See SimpleStreamViewer-SFML.
  Add initial getting started documentation

v0.2.1 2015/07/06 Updated Android and Windows drivers for new sensor USB IDs. Add Android test app .apk.

v0.2.0 2015/07/03 First version ready for external use.

Pre-built samples
=================

Pre-built samples are included in the bin/ directory.
Simply plug in your sensor and then run any of the executable files in the bin/ directory.

We recommend starting with SimpleStreamViewer-SFML and SimpleHandViewer-SFML.
In the hand viewer, wave left and right at the sensor a few times to start hand tracking.

OS-specific instructions:

OS X:
=======
Requires:
  OS X 10.8+
  Xcode 6.2+

Windows:
=======
If you want to run the pre-compiled samples and don't have Visual Studio installed,
you must install the Visual C++ Redistributable Packages.
For VS2013: https://www.microsoft.com/en-us/download/details.aspx?id=40784
For VS2015: https://www.microsoft.com/en-us/download/details.aspx?id=48145

Sample keyboard shortcuts
=========================

SimpleStreamViewer-SFML:

  F - toggle fullscreen
  R - toggle registered depth
  M - toggle mirrored streams
  I - enable IR (RGB mode)
  G - enable IR (Gray16 mode)
  C - enable color
  P - toggle pausing the streams
  O - toggle overlay color stream on depth stream

SimpleDepthViewer-SFML:

  F - toggle fullscreen
  R - toggle registered depth
  M - toggle mirrored streams
  P - toggle pausing the streams
  Space bar - toggle text overlay with the depth data under the mouse cursor

Building the samples from source
================================

OS X
====

The sample build system uses CMake 3.2+.

Getting CMake
=============

Option 1:
You can download it from https://cmake.org/download/

Option 2:
If you are a homebrew user (https://brew.sh), you can install the latest
CMake version by running the following in a terminal:
$ brew install cmake

Compiling Samples
=================

Once CMake has been properly installed, compiling the included samples
can be accomplished by enter the following at a terminal prompt:

$ cd /path/to/sdk
$ cd samples
$ ./build_samples.sh

> The samples will be compiled into samples/build/bin/

For additional sample build options e.g. creating an Xcode project or compiling in debug configuration:
$ ./build_samples.sh -h

Windows
=======

Requirements:
  Visual Studio 2013 or later. The VS 2015 Community version is a free download:
https://www.visualstudio.com/en-us/products/visual-studio-community-vs.aspx
  Windows 7 or later. Tested on Windows 10, Windows 8.1, Windows 7.

The provided Visual Studio 2013/2015 solution is already configured to run out of the box.

Steps:
1) Open astra-samples.sln found either in samples/vs2013 or samples/vs2015 folder.
2) Once in Visual Studio, change the Solution Configuration to Release.
3) Build the solution.

> The samples will be compiled into samples/{vs{2013,2015}/bin/{Release,RelWithDebInfo,Debug}
  depending on your version of Visual Studio and the chosen build configuration.

Tips
====

You can exit samples by pressing Control-C. They will catch this signal and exit cleanly.
To exit samples with a GUI window, press Control-C, escape, or simply close the window.

When you start development, we highly recommend using the C++ API (or a higher level language wrapper.)
The C API is better suited for binding to other languages, or in environments where C is preferred.

Documentation
=============

Preliminary documentation in HTML format can be found in the sdk/docs directory.

Known Issues
============

  There is no error message if no sensor is found or plugged in. (But, it doesn't crash!)
  Hot-plugging (plugging in or removing the sensor while an app is running) is not currently supported.

  If a sample crashes or you forcibly terminate an app that uses Astra SDK before it is given a chance to
  properly shutdown the Astra sensor, the sensor driver may exhibit strange behavior.
  To FIX, simply unplug and re-plug the sensor into the USB port. (This is primarily an OpenNI issue.)

  If any samples appear to be running slow on your computer, make sure you are building the samples in
  Release configuration. This is the default if you are using the OSX build_samples.sh script.

  In Unity 5.5.4+ the body lags the color in MaskedColorStream

  Documentation is limited. We are working on full API documentation for a later release.

  Bone orientation/rotation can be inconsistent if passing through ambiguous positions, such as
  rotating the arm while it is straight out with the elbow unbent.

  There are some APIs that are missing: camera hardware configuration (white balance, exposure, etc.),
  controlling the IR projector and Astra Mini IR flood, etc. These are coming soon.

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: Overview

Overview

Welcome to the document on the Astra SDK! The Astra SDK's exposes to the developer a comprehensive set of functionality to utilize all of the Astra's capabilities through a simple yet powerful API.

This document will be a vital resource to any developer who wants to:

  • Quickly get up to speed with Astra SDK development
  • Understand the high-level concepts with the SDK
  • Find detailed information on specific SDK functionality or features


Astra SDK: Introduction

Introduction

Table of Contents

  • Motivation
  • Low Ceremony Design
  • Cross-Everything
  • Mobile
  • Extensibility

Motivation

The design goals for the SDK are straightforward and lofty - to create the world's best 3D sensor development experience. To facilitate this, the best ideas from many other modern device and sensor SDKs, along with many original ideas from Orbbec's development team, were combined to put emphasis on developer creativity, remove needless complexity, and generally make Astra SDK development a joyful, unintrusive process.

Low Ceremony Design

The designers of the SDK are also experienced 3D sensor developers themselves, and recognize the features that are most commonly used when developing 3D sensor applications. To this end, the Astra SDK reduces the boilerplate code required to obtain sensor data by exposing high-level stream types in addition to low-level stream types through a consistent, easy-to-understand API. This can be best shown with some example code:

astra::initialize();
astra::StreamSet streamSet; //By default, a StreamSet will address the Astra
astra::StreamReader reader = streamSet.create_reader();
// Low-Level Streams
reader.stream<astra::DepthStream>().start();
reader.stream<astra::ColorStream>().start();
//High-Level Streams
reader.stream<astra::HandStream>().start();
reader.stream<astra::PointStream>().start();
astra::Frame frame = reader.get_latest_frame();
//Low-Level Streams
const auto depthFrame = frame.get<astra::DepthFrame>();
const auto colorFrame = frame.get<astra::ColorFrame>();
//High-Level Streams
const auto handFrame = frame.get<astra::HandFrame>();
const auto pointFrame = frame.get<astra::PointFrame>();
astra::terminate();

First, take note where we create our StreamSet object on line 1. Without any additional configuration, it will default to addressing the Astra sensor. In the lines below, you can see that, regardless of the stream type, the same API calls are made to interact with each stream.

If you're an advanced 3D sensor developer and worried that this SDK is designed for simple applications only, rest assured that the Astra SDK also handles less-common cases, often simply by passing different parameters to object constructors. In short, no matter how complicated your application might be, the Astra SDK can handle it.

Cross-Everything

The Astra SDK exposes its functionality through a core C API and also provides a modern C++11 API. From this foundation, the SDK is able to support a number of languages and platforms:

Currently Supported

  • Languages: C, C++11, Java, C#
  • Platforms: Windows, OSX, Linux, Android
  • Frameworks: Unity

Mobile

Mobile devices are becoming more powerful and smaller each passing year, but are comparatively resource contrained to desktop PCs. With this in mind, the Astra SDK has been carefully engineered to minimize CPU and memory overhead to keep mobile devices running smoothly while economizing battery usage.

Extensibility

Perhaps the most powerful feature of the Astra SDK is its plugin layer. Plugins afford advanced developers a method to extend the SDK's functionality with the same consistency and level of support as the rest of the platform. In fact, all of the "stock" stream types included with the SDK are actually supported through plugins themselves.Plugins aren't limited to adding additional stream type support, though. Imagine adding support to address a network of sensors through the same consistent API as a single sensor. The possibilities are truly innumerable, and will allow exciting first and third party additions as the SDK matures.


Astra SDK: Concepts

Concepts

Table of Contents

  • Stream
  • StreamSet
  • StreamReader

Now that you've installed the Astra SDK and ran through a brief tutorial on its basic use, let's focus our lens on three core SDK concepts - streams, streamsets and readers. Understanding these concepts is vital to harnessing the power of the SDK with finesse and confidence. Furthermore, possessing a solid understanding of these concepts will help you to quickly pick up both more advanced and new SDK features as they are introduced in the future.

Stream

A stream is the sequential flow of frames from a particular data source. Imagine an old-time movie reel, with the video recorded as individual image snapshots in sequence on a long stripe of film. Each image snapshot is a frame, and you can imagine the full film as a stream, with the distinction that a stream doesn't necessarily have a definite end.

Streams come in a variety of flavors. For instance, a color stream produces color frames, and a depth stream produces depth frames. Both of these stream types usually come from physical sensors (such as the Astra), but streams can also be generated by the SDK through "plugins" (more on plugins in a different section). For instance, the hand tracker in the SDK uses the depth stream from a sensor to generate a hand stream.

StreamSet

A streamset is a group of closely related streams. Continuing with the analogy above, modern movies aren't only sequenced image frames - they have sound as well. The audio and video for a film are packaged together as a movie, since they are inextricably related to each other. In our terms, this combined package of audio and video can be thought of as a streamset.

While a streamset could be entirely composed of streams arriving from a physical sensor, it can also contain streams created through the SDK plugins. As an example, the Astra camera is represented by a streamset containing a depth stream, a color stream, as well as middleware-generated streams such as the hand stream.

Streamsets are addressed by a string-based unique identifier (URI) which allows developers to access multiple distinct streamsets at once in code. This becomes useful when working with multiple StreamSets, or perhaps addressing a server that produces higher-level streams created by a network of StreamSets.

StreamReader

A stream reader is our window to the frames in the stream. Before we can actually look at each individual frame of any given type coming from our streamsets, we use the streamset to create a reader in order to access the frames of that stream. To help with understanding what a reader does, let's continue with the film analogy one more time. While the audio/video film contains all of the information that we need to playback a movie, the film alone isn't sufficient to presenting the movie. Another device is needed - a reel-to-reel projector. The projector not only advances the film and projects the images onto a screen, but also synchronizes the film's audio to the video for a smooth, seamless performance.

A stream reader is functionally similar to a reel-to-reel projector. It consumes specified streams coming from a streamset (i.e. the film) and coordinates the actual delivery of each frame (the projector) to the application. Each reader can read multiple types of streams at once, and a streamset can create as many readers as are necessary for a given application. If more than one stream type is started by the reader, the reader will synchronize the streams before delivering them.


Astra SDK: Architecture

Architecture
Astra SDK architecture

In this diagram, the arrows represent data flow

Astra consists of several libraries. The main library is astra_core.dll. (Or libastra_core.so on Linux-style systems.) Astra_core.dll provides support for delivering frames via StreamReaders and loading plugins that provide Streams and StreamSets. Astra_core.dll delivers frame data but it does not know what is inside the frame. It treats them as opaque byte arrays. This gives us the flexibility to add new streams in the future without changing the API or astra_core.dll. To add new stream types, such as new middleware, we can update a plugin or add a plugin.

The second library is astra.dll. This library knows about the plugins that ship with Astra SDK, so it can interpret the frame byte arrays from astra_core.dll into concrete data types for the Streams. It also provides mechanisms to control and configure plugins, such as changing the resolution or checking the field of view. The application that uses Astra SDK uses both astra.dll and astra_core.dll when it uses the API. Plugins also use astra.dll to understand the frame data provided from other plugins.

Astra SDK ships with several plugins. Together, these plugins provide the data sources for all of the Streams in Astra SDK. The plugin openni_sensor.dll uses OpenNI2 as a backend for accessing raw sensor data, including color and depth. Other plugins contain middleware that consume the raw sensor Streams and publish derivative Streams such as PointFrame and BodyFrame.

All of this happens behind the scenes and the SDK only computes what is needed to provide the host application with the streams that it requests. For example, if an application does not start the BodyStream, then body tracking is not calculated.

There is also another library, astra_core_api.dll which serves as a proxy for the Astra API and forwards all API calls back to astra_core.dll. It is needed for plugins for technical reasons but it is not important for applications developers to know about. As long as all of the libraries in Astra SDK are present, then the system will work.


Astra SDK: Installation

Installation

Table of Contents

  • System Requirements
  • Setup for Visual Studio
  • Setup for Android Studio
  • Setup for Unity

System Requirements

OS Requirements Details
Windows
  • Windows 8 and 10, 32-bit and 64-bit
  • x86-based processor @ 1.8+ ghz
  • USB 2.0
  • 4 gigabytes of RAM
  • Supports development with both Visual Studio 2013 and Visual Studio 2015.
Linux
  • Ubuntu 14.04 or later
  • x86-based processor @ 1.8+ ghz
  • USB 2.0
  • 1 gigabyte of RAM
  • GCC 4.9 and Clang 3.5 have both been extensively tested, but any compiler with support for C++11 should be compatible,including XCode 5 or better, GCC 4.9 or better, Clang 3.1 or better, and Android NDK r9e or better.
Android
  • Android OS 4.4.2 (KitKat) +
  • Multi-core ARMv7a-based processor @ 1.5 ghz+
  • USB 2.0 host support (OTG-capable)
  • 512 megabytes of RAM
  • GCC 4.9 and Clang 3.5 have both been extensively tested, but any compiler with support for C++11 should be compatible,including XCode 5 or better, GCC 4.9 or better, Clang 3.1 or better, and Android NDK r9e or better.
macOS
  • OS X 10.8 or later
  • x86-based processor @ 1.8+ghz
  • USB 2.0
  • 4 gigabytes of RAM
  • GCC 4.9 and Clang 3.5 have both been extensively tested, but any compiler with support for C++11 should be compatible,including XCode 5 or better, GCC 4.9 or better, Clang 3.1 or better, and Android NDK r9e or better.
  • Astra SDK v2.0 for macOS is coming soon. For now you can download Astra SDK v0.5.0 for macOS.

Setup for Visual Studio

When you develop with Visual Studio on a Windows platform, you have some extra work to do.The Astra SDK works fine depends on the OpenNI SDK and Orbbec sensor driver for Windows.So, you should install them rightly first.

  1. Download OpenNI SDK and install it.
  2. Download Orbbec Sensor Driver for Windows and install it.
  3. Download Astra SDK according to your Visual Studio distribution.Unzip it to a folder, for example called $ASTRA_HOME.
  4. Open a new project or an existing one.
  5. In the Visual Studio menu, open the Project menu and choose Project properties.
  6. In the C/C++ section, under the General node, find the "Additional Include Directories" and add "$ASTRA_HOME\include".
  7. In the Linker section, under the General node, find the "Additional Library Directories" and add "$ASTRA_HOME\lib","$ASTRA_HOME\lib\Plugins".
  8. In the Linker section, under the Input node, find the "Additional Dependencies" and add astra.lib,astra_core.lib,astra_core_api.lib

Setup for Android Studio

  1. Download Astra SDK package for Android.
  2. Open a new project or an existing one.
  3. Copy the downloaded file to libs folder
  4. Add the following code to build.gradle
    android {
    repositories {
    flatDir {
    dirs 'libs'
    }
    }
    }
    dependencies {
    implementation (name:'astra-android-release-v2.0.12-b48cd2945b', ext:'aar')
    }
    Note
    The value 'astra-android-release-v2.0.12-b48cd2945b' above is exactly the name of the downloaded file.

Setup for Unity

  1. Download Astra SDK package for Unity.
  2. Open a new project or an existing one.
  3. Import that downloaded file into project.


Astra SDK: Tutorials

Tutorials

Time Required: ~10 minutes

Want to get a taste of our SDK before diving deeper? Then let's get our hands dirty and write some code!

By the end of this tutorials you should be familiar with:

  • Proper initialization and termination of the SDK
  • Reading data from the sensor
  • Examining the depth information provided by the Astra's depth camera

Before We Begin

If you skipped over the section where we install the SDK and build the sample applications provided by the SDK, make sure you've at least downloaded and extracted Astra to a folder you can easily access.

Getting Down to Business!

Our first step will be to set up a basic application as a starting point for progressively adding new functionality.

  1. Using your favorite IDE, set up a new console application project and create a new source file called "main.cpp".
  2. Copy the following into your main.cpp file:
#include <astra/astra.hpp>
#include <cstdio>
#include <iostream>
int main(int argc, char** argv)
{
std::cout << "hit enter to exit program" << std::endl;
std::cin.get();
return 0;
}
  • Line 1 - astra.hpp must be included in all applications. It is the core of Astra and is required for all C++ based Astra applications.
  • Lines 9-10 - We'll use std::cin.get() <http://en.cppreference.com/w/cpp/io/basic_istream/get>_ to make sure we have an opportunity to see our handiwork before our application closes its window.

Initializing and Terminating Astra

To prepare Astra to do our bidding, we must first initialize Astra, which is unsurprisingly done via the initialize function. When we're ready to end our session with the SDK, we then need to give Astra an opportunity to cleanly shutdown. This is accomplished by calling the terminate function, which will, among other things, properly turn off attached devices.

Add the two new lines below:

int main(int argc, char** argv)
{
astra::initialize();
// what will go here? you'll find out soon!
astra::terminate();
std::cout << "hit enter to exit program" << std::endl;
std::cin.get();
return 0;
}

Trust But Verify

Before we get ahead of ourselves, let's take a moment to make sure that everything is as we expect it. Compile and run the application. The application should start up, print out a series of diagnostic messages to the console, and then patiently wait for you to press the "Enter" key. Once pressed, the application should gracefully exit.

Attention
Astra by default logs a fair amount of diagnostic information to the console. If you do run into an issue, this can be a great place to start looking for answers.

Next up: Talking to Astra.

Connecting to the Astra

Now that we know how to properly initialize and terminate Astra, it's time to actually communicate with the Astra sensor. For this, we use the StreamSet class, which broadly encapsulates the idea of a group of related data sources (think: video and audio from a 2D video camera). For now, however, it's sufficient to think of a streamSet as a physical device like the Astra, and the StreamSet class, your portal to its functionality.

Between our initialization and termination bookends, let's declare a StreamSet variable.

int main(int argc, char** argv)
{
astra::initialize();
astra::StreamSet streamSet;
astra::terminate();
std::cout << "hit enter to exit program" << std::endl;
std::cin.get();
return 0;
}

Now, sure, this seems like a small addition from our previous step, but this line is more significant than it appears. Just by declaring and constructing a StreamSet object, you are instructing Astra to start the process of connecting to the first available Astra sensor it can locate. Cool, right?

Attention
Astra provides an additional constructor that will allow you to connect to a specific Astra sensor.

Now that we're connected, we're ready to do what we came here to do - see through the eyes of the Astra!

Retrieving Sensor Data

Time to put our StreamSet object to good use and get some data. To do this, we'll need to read one of the streams that the Astra is providing. Streams contain the data coming from our camera packaged in packets of data called "frames". Astra currently supports a number of types of streams, including depth, color, hand, and point streams.

In order to access streams from the Astra and get to the frames, we'll need a StreamReader to tap into one of the streams. For the purposes of our application,we're going to focus on the depth stream. This stream gives us the distances of anything that our camera sees in pixels, and those pixels are packaged in a frame.

  1. First, let's create a StreamReader using our StreamSet.
int main(int argc, char** argv)
{
astra::initialize();
astra::StreamSet streamSet;
astra::StreamReader reader = streamSet.create_reader();
astra::terminate();
std::cout << "hit enter to exit program" << std::endl;
std::cin.get();
return 0;
}
  • Line 11 - Creates a StreamReader
  1. Next we start the depth stream using the StreamReader that we created in the previous step. Starting the depth stream tells Astra that we're interested in getting depth data from our StreamSet.
int main(int argc, char** argv)
{
astra::initialize();
astra::StreamSet streamSet;
astra::StreamReader reader = streamSet.create_reader();
reader.stream<astra::DepthStream>().start();
astra::terminate();
std::cout << "hit enter to exit program" << std::endl;
std::cin.get();
return 0;
}
  • Line 13 - Starts the depth stream
  1. With our depth stream stared, let's pull the latest depth frame from our depth stream. To do this, we'll need to first retrieve the latest Frame through our StreamReader, then call get<T> to get the depth frame data from our frame.
int main(int argc, char** argv)
{
astra::initialize();
astra::StreamSet streamSet;
astra::StreamReader reader = streamSet.create_reader();
reader.stream<astra::DepthStream>().start();
astra::Frame frame = reader.get_latest_frame();
const auto depthFrame = frame.get<astra::DepthFrame>();
astra::terminate();
std::cout << "hit enter to exit program" << std::endl;
std::cin.get();
return 0;
}
  • Line 15 - Retrieves the latest frame
  • Line 16 - Gets the depth frame from the latest frame
  1. The only remaining task is to print some data from the depth frame that we just retrieved.
int main(int argc, char** argv)
{
astra::initialize();
astra::StreamSet streamSet;
astra::StreamReader reader = streamSet.create_reader();
reader.stream<astra::DepthStream>().start();
astra::Frame frame = reader.get_latest_frame();
const auto depthFrame = frame.get<astra::DepthFrame>();
const int frameIndex = depthFrame.frame_index();
const short pixelValue = depthFrame.data()[0];
std::cout << std::endl
<< "Depth frameIndex: " << frameIndex
<< " pixelValue: " << pixelValue
<< std::endl
<< std::endl;
astra::terminate();
std::cout << "hit enter to exit program" << std::endl;
std::cin.get();
return 0;
}
  • Line 18 - Gets a copy of the frame index from our depth frame
  • Line 19 - Gets a copy of the value within the first pixel of our depth frame's data
  • Line 21-25 - Prints the two aforementioned values to the console
  • Line 27-28 - Pauses execution so we can soak in our success

You can go ahead and run your application now to test that everything works. Just like before, a console window should pop up and display diagnostic information. Then, you should see a line with the frame data that we retrieved. Press enter when you're done.

You just retrieved your first frame from Astra! There's one more task before you graduate from our Astra crash course, and that's working with a sequence of frames.

Consuming a StreamSet stream

Now that you know how to create a StreamReader and get a frame from it, you're ready to work with a stream of frames. To do this, we only need to make a small change and loop over our call to the StreamReader's get_latest_frame function. In this particular case, we're going to get the first 100 frames from our depth stream and print the value of each frame's first pixel to the console.

The following code is highly similar to the code from our last example, except we've added a do while loop around our frame processing code, in addition to some variables that store the number of times we've looped and the maximum number of frames we want to process.

int main(int argc, char** argv)
{
astra::initialize();
astra::StreamSet streamSet;
astra::StreamReader reader = streamSet.create_reader();
reader.stream<astra::DepthStream>().start();
const int maxFramesToProcess = 100;
int count = 0;
do {
astra::Frame frame = reader.get_latest_frame();
const auto depthFrame = frame.get<astra::DepthFrame>();
const int frameIndex = depthFrame.frame_index();
const short pixelValue = depthFrame.data()[0];
std::cout << std::endl
<< "Depth frameIndex: " << frameIndex
<< " pixelValue: " << pixelValue
<< std::endl
<< std::endl;
count++;
} while (count < maxFramesToProcess);
std::cout << "Press any key to continue...";
std::cin.get();
astra::terminate();
std::cout << "hit enter to exit program" << std::endl;
std::cin.get();
return 0;
}
  • Line 15 - Stores the maximum number of frames we're going to process in the loop
  • Line 16 - Sentinel to count the number of frames that we've processed
  • Line 18-32 - The frame processing loop

Compile and run. While the program is running and the Astra is focused on you, move around a bit and watch the data values on the frames change.

Achievement get! You've just made your first Astra application! If you haven't had your fill of fun with Astra yet, continue on to our Simple Depth Viewer Tutorial.


Astra SDK: Samples

Samples

This help document presents a number of sample programs showing how to program with the Astra SDK API.

  • C
  • C++


Astra SDK: C

  • Samples
C

Poll

The following samples illustrate how to program with the Astra SDK using poll mode.

Color Reader

This sample show how to read color stream with Astra SDK.

Source code

Depth Reader

This sample show how to read depth stream with Astra SDK.

Source code

Infrared Reader

This sample show how to read infrared stream with Astra SDK.

Source code

Body Reader

This sample show how to read body with Astra SDK.

Source code

Hand Reader

This sample show how to read hand data with Astra SDK.

Source code

Event

The following samples illustrate how to program with the Astra SDK using event mode.

Color Reader

This sample show how to read color stream with Astra SDK.

Source code

Depth Reader

This sample show how to read depth stream with Astra SDK.

Source code

Infrared Reader

This sample show how to read infrared stream with Astra SDK.

Source code

Infrared and Color Reader

This sample show how to read infrared and color stream with Astra SDK at same time.

Source code


Astra SDK: C++

  • Samples
C++

Event

The following samples illustrate how to program with the Astra SDK using event mode.

Color Reader

This sample show how to read color stream with Astra SDK.

Source code

Depth Reader

This sample show how to read depth stream with Astra SDK.

Source code


Astra SDK: Legal stuff

Legal stuff
  • Copyright
  • Acknowledgements
  • License


Astra SDK: Copyright

  • Legal stuff
Copyright

The Astra SDK release under Apache License belows.

Copyright (c) 2015-2019 Orbbec 3D

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.


Astra SDK: Acknowledgements

  • Legal stuff
Acknowledgements

Table of Contents

  • Core
  • Orbbec Bodies Plugin
  • Samples

This software is based on following open source projects.

Core

  • catch
  • cpptoml
  • easyloggingpp https://github.com/easylogging/easyloggingpp
  • libjpeg http://www.ijg.org/
  • libsimdpp
  • libuvc https://github.com/ktossell/libuvc
  • openni2 https://github.com/OpenNI/OpenNI2
  • shinyprofiler https://sourceforge.net/projects/shinyprofiler/
  • tinydir https://github.com/cxong/tinydir

Orbbec Bodies Plugin

  • boost https://www.boost.org/
  • ceres-solver http://www.ceres-solver.org/
  • Eigen
  • liblbfgs-1.10
  • libsodium
  • libsvm https://www.csie.ntu.edu.tw/~cjlin/libsvm/
  • libusb https://libusb.info/
  • shinyprofiler https://sourceforge.net/projects/shinyprofiler/
  • tinyxml

Samples

  • SFML https://www.sfml-dev.org/


Astra SDK: License

  • Legal stuff
License

The function of Orbbec Bodies Track, whice is an optional module of Astra SDK, need licensing. You can contact us through:

Email: info@.nosp@m.orbb.nosp@m.ec3d..nosp@m.com

Phone: +1 (248) 284-4673 (Office)


Astra SDK: FAQ

FAQ

How to apply for license

C and C++ - Add this directly after calling astra_initialize() and replace <LICENSE STRING> with the provided license key:

orbbec_body_tracking_set_license("<LICENSE STRING>");

Java - Add this directly after calling Astra.initialize(), add import com.orbbec.astra.BodyTracking at the top of the .java file, and replace <LICENSE STRING> with the provided license key:

BodyTracking.setLicense("<LICENSE STRING>");

C# and Unity - Add this directly after calling Astra.Context.Initialize() and replace <LICENSE STRING> with the provided license key:

Astra.BodyTracking.SetLicense("<LICENSE STRING>");


Astra SDK: Modules

Modules
Here is a list of all modules:
[detail level 12]
▼ C Reference
body stream apis
color stream apis
colorized body stream apis
depth stream apis
hand stream apis
image stream apis
infrared stream apis
masked color stream apis
point stream apis
astra core apis
C++ Reference
C# Reference
Java Reference
Android Reference


Astra SDK: C Reference

Modules | Functions
C Reference

Modules

body stream apis
color stream apis
colorized body stream apis
depth stream apis
hand stream apis
image stream apis
infrared stream apis
masked color stream apis
point stream apis
astra core apis

Functions

ASTRA_API_EX astra_status_t astra_version (astra_version_info_t *info)

Detailed Description

Function Documentation

◆ astra_version()

ASTRA_API_EX astra_status_t astra_version ( astra_version_info_t * info )

get current sdk version.

Parameters
info structure of astra_version_info_t, shouldn't be null.


Astra SDK: body stream apis

Functions
body stream apis
C Reference

Functions

ASTRA_API_EX astra_status_t | astra_reader_get_bodystream (astra_reader_t reader, astra_bodystream_t *bodyStream)
ASTRA_API_EX astra_status_t | astra_bodystream_is_available (astra_bodystream_t bodyStream, bool *isAvailable)
ASTRA_API_EX astra_status_t | astra_bodystream_get_body_features (astra_bodystream_t bodyStream, astra_body_id_t id, astra_body_tracking_feature_flags_t *features)
ASTRA_API_EX astra_status_t | astra_bodystream_set_body_features (astra_bodystream_t bodyStream, astra_body_id_t id, astra_body_tracking_feature_flags_t features)
ASTRA_API_EX astra_status_t | astra_bodystream_get_default_body_features (astra_bodystream_t bodyStream, astra_body_tracking_feature_flags_t *features)
ASTRA_API_EX astra_status_t | astra_bodystream_set_default_body_features (astra_bodystream_t bodyStream, astra_body_tracking_feature_flags_t features)
ASTRA_API_EX astra_status_t | astra_bodystream_get_skeleton_profile (astra_bodystream_t bodyStream, astra_skeleton_profile_t *skeletonProfile)
ASTRA_API_EX astra_status_t | astra_bodystream_set_skeleton_profile (astra_bodystream_t bodyStream, astra_skeleton_profile_t skeletonProfile)
ASTRA_API_EX astra_status_t | astra_bodystream_get_skeleton_optimization (astra_bodystream_t bodyStream, astra_skeleton_optimization_t *skeletonOptimization)
ASTRA_API_EX astra_status_t | astra_bodystream_set_skeleton_optimization (astra_bodystream_t bodyStream, astra_skeleton_optimization_t skeletonOptimization)
ASTRA_API_EX astra_status_t | astra_frame_get_bodyframe (astra_reader_frame_t readerFrame, astra_bodyframe_t *bodyFrame)
ASTRA_API_EX astra_status_t | astra_bodyframe_get_frameindex (astra_bodyframe_t bodyFrame, astra_frame_index_t *index)
ASTRA_API_EX astra_status_t | astra_bodyframe_info (astra_bodyframe_t bodyFrame, astra_bodyframe_info_t *info)
ASTRA_API_EX astra_status_t | astra_bodyframe_bodymask (astra_bodyframe_t bodyFrame, astra_bodymask_t *bodyMask)
ASTRA_API_EX astra_status_t | astra_bodyframe_bodymask_ptr (astra_bodyframe_t bodyFrame, uint32_t *width, uint32_t *height, void **dataPtr)
ASTRA_API_EX astra_status_t | astra_bodyframe_copy_bodymask_data (astra_bodyframe_t bodyFrame, void *data)
ASTRA_API_EX astra_status_t | astra_bodyframe_floor_info (astra_bodyframe_t bodyFrame, astra_floor_info_t *floorInfo)
ASTRA_API_EX astra_status_t | astra_bodyframe_floormask_ptr (astra_bodyframe_t bodyFrame, uint32_t *width, uint32_t *height, void **dataPtr)
ASTRA_API_EX astra_status_t | astra_bodyframe_copy_floormask_data (astra_bodyframe_t bodyFrame, void *data)
ASTRA_API_EX astra_status_t | astra_bodyframe_floor_info_ptr (astra_bodyframe_t bodyFrame, astra_floor_info_t **floorInfo)
ASTRA_API_EX astra_status_t | astra_bodyframe_body_list (astra_bodyframe_t bodyFrame, astra_body_list_t *bodyList)
ASTRA_API_EX astra_status_t | orbbec_body_tracking_set_license (const char *licenseString)

Detailed Description

Function Documentation

◆ orbbec_body_tracking_set_license()

ASTRA_API_EX astra_status_t orbbec_body_tracking_set_license ( const char * licenseString )

set license to use sdk after trial.

Parameters
licenseString the licenseString.
Returns
ASTRA_STATUS_SUCCESS if license is valid.
Examples:
BodyReaderPoll\main.c, ColorizedBodyViewer-SFML\main.cpp, MaskedColorViewer-SFML\main.cpp, and SimpleBodyViewer-SFML\main.cpp.


Astra SDK: color stream apis

Functions
color stream apis
C Reference

Functions

ASTRA_API_EX astra_status_t | astra_reader_get_colorstream (astra_reader_t reader, astra_colorstream_t *colorStream)
ASTRA_API_EX astra_status_t | astra_colorstream_is_available (astra_colorstream_t colorStream, bool *isAvailable)
ASTRA_API_EX astra_status_t | astra_colorstream_get_usb_info (astra_colorstream_t colorStream, astra_usb_info_t *usbInfo)
ASTRA_API_EX astra_status_t | astra_frame_get_colorframe (astra_reader_frame_t readerFrame, astra_colorframe_t *colorFrame)
ASTRA_API_EX astra_status_t | astra_frame_get_colorframe_with_subtype (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype, astra_colorframe_t *colorFrame)
ASTRA_API_EX astra_status_t | astra_colorframe_get_data_byte_length (astra_colorframe_t colorFrame, uint32_t *byteLength)
ASTRA_API_EX astra_status_t | astra_colorframe_get_data_ptr (astra_colorframe_t colorFrame, uint8_t **data, uint32_t *byteLength)
ASTRA_API_EX astra_status_t | astra_colorframe_get_data_rgb_ptr (astra_colorframe_t colorFrame, astra_rgb_pixel_t **data, uint32_t *byteLength)
ASTRA_API_EX astra_status_t | astra_colorframe_copy_data (astra_colorframe_t colorFrame, uint8_t *data)
ASTRA_API_EX astra_status_t | astra_colorframe_get_metadata (astra_colorframe_t colorFrame, astra_image_metadata_t *metadata)
ASTRA_API_EX astra_status_t | astra_colorframe_get_frameindex (astra_colorframe_t colorFrame, astra_frame_index_t *index)

Detailed Description

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: colorized body stream apis

Functions
colorized body stream apis
C Reference

Functions

ASTRA_API_EX astra_status_t | astra_reader_get_colorizedbodystream (astra_reader_t reader, astra_colorizedbodystream_t *colorizedbodyStream)
ASTRA_API_EX astra_status_t | astra_colorizedbodystream_is_available (astra_colorizedbodystream_t colorizedbodyStream, bool *isAvailable)
ASTRA_API_EX astra_status_t | astra_frame_get_colorizedbodyframe (astra_reader_frame_t readerFrame, astra_colorizedbodyframe_t *colorizedbodyFrame)
ASTRA_API_EX astra_status_t | astra_frame_get_colorizedbodyframe_with_subtype (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype, astra_colorizedbodyframe_t *colorizedbodyFrame)
ASTRA_API_EX astra_status_t | astra_colorizedbodyframe_get_data_byte_length (astra_colorizedbodyframe_t colorizedbodyFrame, uint32_t *byteLength)
ASTRA_API_EX astra_status_t | astra_colorizedbodyframe_get_data_ptr (astra_colorizedbodyframe_t colorizedbodyFrame, astra_rgba_pixel_t **data, uint32_t *byteLength)
ASTRA_API_EX astra_status_t | astra_colorizedbodyframe_copy_data (astra_colorizedbodyframe_t colorizedbodyFrame, astra_rgba_pixel_t *data)
ASTRA_API_EX astra_status_t | astra_colorizedbodyframe_get_metadata (astra_colorizedbodyframe_t colorizedbodyFrame, astra_image_metadata_t *metadata)
ASTRA_API_EX astra_status_t | astra_colorizedbodyframe_get_frameindex (astra_colorizedbodyframe_t colorizedbodyFrame, astra_frame_index_t *index)

Detailed Description

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: depth stream apis

Functions
depth stream apis
C Reference

Functions

ASTRA_API_EX astra_status_t | astra_convert_depth_to_world (astra_depthstream_t depthStream, float depthX, float depthY, float depthZ, float *pWorldX, float *pWorldY, float *pWorldZ)
ASTRA_API_EX astra_status_t | astra_convert_world_to_depth (astra_depthstream_t depthStream, float worldX, float worldY, float worldZ, float *pDepthX, float *pDepthY, float *pDepthZ)
ASTRA_API_EX astra_status_t | astra_reader_get_depthstream (astra_reader_t reader, astra_depthstream_t *depthStream)
ASTRA_API_EX astra_status_t | astra_depthstream_is_available (astra_depthstream_t depthStream, bool *isAvailable)
ASTRA_API_EX astra_status_t | astra_depthstream_get_depth_to_world_data (astra_depthstream_t depthStream, astra_conversion_cache_t *conversionData)
ASTRA_API_EX astra_status_t | astra_depthstream_get_hfov (astra_depthstream_t depthStream, float *hFov)
ASTRA_API_EX astra_status_t | astra_depthstream_get_vfov (astra_depthstream_t depthStream, float *vFov)
ASTRA_API_EX astra_status_t | astra_depthstream_get_registration (astra_depthstream_t depthStream, bool *enabled)
ASTRA_API_EX astra_status_t | astra_depthstream_set_registration (astra_depthstream_t depthStream, bool enabled)
ASTRA_API_EX astra_status_t | astra_depthstream_get_serialnumber (astra_depthstream_t depthStream, char *serialnumber, uint32_t length)
ASTRA_API_EX astra_status_t | astra_depthstream_get_chip_id (astra_depthstream_t depthStream, uint32_t *chipId)
ASTRA_API_EX astra_status_t | astra_depthstream_get_usb_info (astra_depthstream_t depthStream, astra_usb_info_t *usbInfo)
ASTRA_API_EX astra_status_t | astra_frame_get_depthframe (astra_reader_frame_t readerFrame, astra_depthframe_t *depthFrame)
ASTRA_API_EX astra_status_t | astra_frame_get_depthframe_with_subtype (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype, astra_depthframe_t *colorFrame)
ASTRA_API_EX astra_status_t | astra_depthframe_get_data_byte_length (astra_depthframe_t depthFrame, uint32_t *byteLength)
ASTRA_API_EX astra_status_t | astra_depthframe_get_data_ptr (astra_depthframe_t depthFrame, int16_t **data, uint32_t *byteLength)
ASTRA_API_EX astra_status_t | astra_depthframe_copy_data (astra_depthframe_t depthFrame, int16_t *data)
ASTRA_API_EX astra_status_t | astra_depthframe_get_metadata (astra_depthframe_t depthFrame, astra_image_metadata_t *metadata)
ASTRA_API_EX astra_status_t | astra_depthframe_get_frameindex (astra_depthframe_t depthFrame, astra_frame_index_t *index)

Detailed Description

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: hand stream apis

Functions
hand stream apis
C Reference

Functions

ASTRA_API_EX astra_status_t | astra_reader_get_handstream (astra_reader_t reader, astra_handstream_t *handStream)
ASTRA_API_EX astra_status_t | astra_handstream_is_available (astra_handstream_t handStream, bool *isAvailable)
ASTRA_API_EX astra_status_t | astra_frame_get_handframe (astra_reader_frame_t readerFrame, astra_handframe_t *handFrame)
ASTRA_API_EX astra_status_t | astra_frame_get_handframe_with_subtype (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype, astra_handframe_t *handFrame)
ASTRA_API_EX astra_status_t | astra_handframe_get_frameindex (astra_handframe_t handFrame, astra_frame_index_t *index)
ASTRA_API_EX astra_status_t | astra_handframe_get_hand_count (astra_handframe_t handFrame, uint32_t *handCount)
ASTRA_API_EX astra_status_t | astra_handframe_copy_hands (astra_handframe_t handFrame, astra_handpoint_t *handPointsDestination)
ASTRA_API_EX astra_status_t | astra_handframe_get_shared_hand_array (astra_handframe_t handFrame, astra_handpoint_t **handpoints, uint32_t *handCount)
ASTRA_API_EX astra_status_t | astra_handstream_get_include_candidate_points (astra_handstream_t handStream, bool *includeCandidatePoints)
ASTRA_API_EX astra_status_t | astra_handstream_set_include_candidate_points (astra_handstream_t handStream, bool includeCandidatePoints)
ASTRA_API_EX astra_status_t | astra_reader_get_debug_handstream (astra_reader_t reader, astra_debug_handstream_t *debugHandStream)
ASTRA_API_EX astra_status_t | astra_frame_get_debug_handframe (astra_reader_frame_t readerFrame, astra_debug_handframe_t *debugHandFrame)
ASTRA_API_EX astra_status_t | astra_debug_handstream_get_view_type (astra_debug_handstream_t debugHandStream, astra_debug_hand_view_type_t *viewType)
ASTRA_API_EX astra_status_t | astra_debug_handstream_set_view_type (astra_debug_handstream_t debugHandStream, astra_debug_hand_view_type_t viewType)
ASTRA_API_EX astra_status_t | astra_debug_handstream_set_mouse_position (astra_debug_handstream_t debugHandStream, astra_vector2f_t normPosition)
ASTRA_API_EX astra_status_t | astra_debug_handstream_set_use_mouse_probe (astra_debug_handstream_t debugHandStream, bool useMouseProbe)
ASTRA_API_EX astra_status_t | astra_debug_handstream_set_pause_input (astra_debug_handstream_t debugHandStream, bool pauseInput)
ASTRA_API_EX astra_status_t | astra_debug_handstream_set_lock_spawn_point (astra_debug_handstream_t debugHandStream, bool lockSpawnPoint)

Detailed Description

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: image stream apis

Functions
image stream apis
C Reference

Functions

ASTRA_API_EX astra_status_t | astra_imagestream_get_mirroring (astra_imagestream_t imageStream, bool *mirroring)
ASTRA_API_EX astra_status_t | astra_imagestream_set_mirroring (astra_imagestream_t imageStream, bool mirroring)
ASTRA_API_EX astra_status_t | astra_imagestream_get_hfov (astra_imagestream_t imageStream, float *hFov)
ASTRA_API_EX astra_status_t | astra_imagestream_get_vfov (astra_imagestream_t imageStream, float *vFov)
ASTRA_API_EX astra_status_t | astra_imagestream_get_usb_info (astra_imagestream_t imageStream, astra_usb_info_t *usbInfo)
ASTRA_API_EX astra_status_t | astra_imagestream_request_modes (astra_imagestream_t imageStream, astra_result_token_t *token, uint32_t *count)
ASTRA_API_EX astra_status_t | astra_imagestream_get_modes_result (astra_imagestream_t imageStream, astra_result_token_t token, astra_imagestream_mode_t *modes, uint32_t count)
ASTRA_API_EX astra_status_t | astra_imagestream_get_mode (astra_imagestream_t imageStream, astra_imagestream_mode_t *mode)
ASTRA_API_EX astra_status_t | astra_imagestream_set_mode (astra_imagestream_t imageStream, const astra_imagestream_mode_t *mode)
ASTRA_API_EX astra_status_t | astra_reader_get_imageframe (astra_reader_frame_t readerFrame, astra_stream_type_t type, astra_stream_subtype_t subtype, astra_imageframe_t *imageFrame)
ASTRA_API_EX astra_status_t | astra_imageframe_get_stream (astra_imageframe_t imageFrame, astra_streamconnection_t *stream)
ASTRA_API_EX astra_status_t | astra_imageframe_get_frameindex (astra_imageframe_t imageFrame, astra_frame_index_t *index)
ASTRA_API_EX astra_status_t | astra_imageframe_get_data_byte_length (astra_imageframe_t imageFrame, uint32_t *byteLength)
ASTRA_API_EX astra_status_t | astra_imageframe_get_data_ptr (astra_imageframe_t imageFrame, void **data, uint32_t *byteLength)
ASTRA_API_EX astra_status_t | astra_imageframe_copy_data (astra_imageframe_t imageFrame, void *data)
ASTRA_API_EX astra_status_t | astra_imageframe_get_metadata (astra_imageframe_t imageFrame, astra_image_metadata_t *metadata)
ASTRA_API_EX void | astra_pixelformat_get_bytes_per_pixel (astra_pixel_format_t format, uint8_t *bpp)

Detailed Description

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: infrared stream apis

Functions
infrared stream apis
C Reference

Functions

ASTRA_API_EX astra_status_t | astra_reader_get_infraredstream (astra_reader_t reader, astra_infraredstream_t *infraredstream)
ASTRA_API_EX astra_status_t | astra_infraredstream_is_available (astra_infraredstream_t infraredStream, bool *isAvailable)
ASTRA_API_EX astra_status_t | astra_infraredstream_get_hfov (astra_infraredstream_t infraredstream, float *hFov)
ASTRA_API_EX astra_status_t | astra_infraredstream_get_vfov (astra_infraredstream_t infraredstream, float *vFov)
ASTRA_API_EX astra_status_t | astra_infraredstream_get_usb_info (astra_infraredstream_t infraredStream, astra_usb_info_t *usbInfo)
ASTRA_API_EX astra_status_t | astra_frame_get_infraredframe (astra_reader_frame_t readerFrame, astra_infraredframe_t *infraredframe)
ASTRA_API_EX astra_status_t | astra_frame_get_infraredframe_with_subtype (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype, astra_infraredframe_t *colorFrame)
ASTRA_API_EX astra_status_t | astra_infraredframe_get_data_byte_length (astra_infraredframe_t infraredframe, uint32_t *byteLength)
ASTRA_API_EX astra_status_t | astra_infraredframe_get_data_ptr (astra_infraredframe_t infraredframe, uint8_t **data, uint32_t *byteLength)
ASTRA_API_EX astra_status_t | astra_infraredframe_copy_data (astra_infraredframe_t infraredframe, uint8_t *data)
ASTRA_API_EX astra_status_t | astra_infraredframe_get_metadata (astra_infraredframe_t infraredframe, astra_image_metadata_t *metadata)
ASTRA_API_EX astra_status_t | astra_infraredframe_get_frameindex (astra_infraredframe_t infraredframe, astra_frame_index_t *index)

Detailed Description

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: masked color stream apis

Functions
masked color stream apis
C Reference

Functions

ASTRA_API_EX astra_status_t | astra_reader_get_maskedcolorstream (astra_reader_t reader, astra_maskedcolorstream_t *maskedcolorStream)
ASTRA_API_EX astra_status_t | astra_maskedcolorstream_is_available (astra_maskedcolorstream_t maskedcolorStream, bool *isAvailable)
ASTRA_API_EX astra_status_t | astra_frame_get_maskedcolorframe (astra_reader_frame_t readerFrame, astra_maskedcolorframe_t *maskedcolorFrame)
ASTRA_API_EX astra_status_t | astra_frame_get_maskedcolorframe_with_subtype (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype, astra_maskedcolorframe_t *maskedcolorFrame)
ASTRA_API_EX astra_status_t | astra_maskedcolorframe_get_data_byte_length (astra_maskedcolorframe_t maskedcolorFrame, uint32_t *byteLength)
ASTRA_API_EX astra_status_t | astra_maskedcolorframe_get_data_ptr (astra_maskedcolorframe_t maskedcolorFrame, astra_rgba_pixel_t **data, uint32_t *byteLength)
ASTRA_API_EX astra_status_t | astra_maskedcolorframe_copy_data (astra_maskedcolorframe_t maskedcolorFrame, astra_rgba_pixel_t *data)
ASTRA_API_EX astra_status_t | astra_maskedcolorframe_get_metadata (astra_maskedcolorframe_t maskedcolorFrame, astra_image_metadata_t *metadata)
ASTRA_API_EX astra_status_t | astra_maskedcolorframe_get_frameindex (astra_maskedcolorframe_t maskedcolorFrame, astra_frame_index_t *index)

Detailed Description

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: point stream apis

Functions
point stream apis
C Reference

Functions

ASTRA_API_EX astra_status_t | astra_reader_get_pointstream (astra_reader_t reader, astra_pointstream_t *pointStream)
ASTRA_API_EX astra_status_t | astra_pointstream_is_available (astra_pointstream_t pointStream, bool *isAvailable)
ASTRA_API_EX astra_status_t | astra_frame_get_pointframe (astra_reader_frame_t readerFrame, astra_pointframe_t *pointFrame)
ASTRA_API_EX astra_status_t | astra_frame_get_pointframe_with_subtype (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype, astra_pointframe_t *pointFrame)
ASTRA_API_EX astra_status_t | astra_pointframe_get_data_byte_length (astra_pointframe_t pointFrame, uint32_t *byteLength)
ASTRA_API_EX astra_status_t | astra_pointframe_get_data_ptr (astra_pointframe_t pointFrame, astra_vector3f_t **data, uint32_t *byteLength)
ASTRA_API_EX astra_status_t | astra_pointframe_copy_data (astra_pointframe_t pointFrame, astra_vector3f_t *data)
ASTRA_API_EX astra_status_t | astra_pointframe_get_metadata (astra_pointframe_t pointFrame, astra_image_metadata_t *metadata)
ASTRA_API_EX astra_status_t | astra_pointframe_get_frameindex (astra_pointframe_t pointFrame, astra_frame_index_t *index)

Detailed Description

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: astra core apis

Functions
astra core apis
C Reference

Functions

ASTRA_API astra_status_t | astra_initialize ()
Initializes the library. More...
ASTRA_API astra_status_t | astra_terminate ()
Terminate the library, destroying all its streams. More...
ASTRA_API astra_status_t | astra_notify_plugin_event (astra_event_id id, const void *data, uint32_t dataSize)
Notify plugins an event. More...
ASTRA_API astra_status_t | astra_streamset_is_available (astra_streamsetconnection_t streamSet, bool *isAvailable)
Test whether the StreamSet is valid. More...
ASTRA_API astra_status_t | astra_streamset_open (const char *uri, astra_streamsetconnection_t *streamSet)
Open a StreamSet. More...
ASTRA_API astra_status_t | astra_streamset_close (astra_streamsetconnection_t *streamSet)
Close the handle to StreamSet. More...
ASTRA_API astra_status_t | astra_streamset_get_uri (astra_streamsetconnection_t streamSet, char *uri, int32_t size)
Get the URI of StreamSet. More...
ASTRA_API astra_status_t | astra_reader_create (astra_streamsetconnection_t streamSet, astra_reader_t *reader)
Create a StreamReader in StreamSet. More...
ASTRA_API astra_status_t | astra_reader_destroy (astra_reader_t *reader)
Destroy the handle to StreamReader. More...
ASTRA_API astra_status_t | astra_reader_get_stream (astra_reader_t reader, astra_stream_type_t type, astra_stream_subtype_t subtype, astra_streamconnection_t *stream)
Get specified stream from StreamReader reader. More...
ASTRA_API astra_status_t | astra_stream_get_description (astra_streamconnection_t stream, astra_stream_desc_t *description)
Get description of Stream. More...
ASTRA_API astra_status_t | astra_stream_is_available (astra_streamconnection_t stream, bool *isAvailable)
Test whether the handle to Stream is valid. More...
ASTRA_API astra_status_t | astra_stream_start (astra_streamconnection_t stream)
Start the Stream. More...
ASTRA_API astra_status_t | astra_stream_stop (astra_streamconnection_t stream)
Stop the Stream. More...
ASTRA_API astra_status_t | astra_reader_has_new_frame (astra_reader_t reader, bool *hasNewFrame)
Test whether there is a new frame. More...
ASTRA_API astra_status_t | astra_reader_open_frame (astra_reader_t reader, int timeoutMillis, astra_reader_frame_t *frame)
Open. More...
ASTRA_API astra_status_t | astra_reader_close_frame (astra_reader_frame_t *frame)
Close. More...
ASTRA_API astra_status_t | astra_reader_register_frame_ready_callback (astra_reader_t reader, astra_frame_ready_callback_t callback, void *clientTag, astra_reader_callback_id_t *callbackId)
Registers a callback function to StreamReader. More...
ASTRA_API astra_status_t | astra_reader_unregister_frame_ready_callback (astra_reader_callback_id_t *callbackId)
Unregisters the callback function. More...
ASTRA_API astra_status_t | astra_reader_get_frame (astra_reader_frame_t frame, astra_stream_type_t type, astra_stream_subtype_t subtype, astra_frame_t **subFrame)
Read a frame. More...
ASTRA_API astra_status_t | astra_stream_set_parameter (astra_streamconnection_t connection, astra_parameter_id parameterId, uint32_t inByteLength, astra_parameter_data_t inData)
Set parameter to StreamSet. More...
ASTRA_API astra_status_t | astra_stream_get_parameter (astra_streamconnection_t connection, astra_parameter_id parameterId, uint32_t *resultByteLength, astra_result_token_t *token)
Get parameter from StreamSet. More...
ASTRA_API astra_status_t | astra_stream_get_result (astra_streamconnection_t connection, astra_result_token_t token, uint32_t dataByteLength, astra_parameter_data_t dataDestination)
ASTRA_API astra_status_t | astra_stream_invoke (astra_streamconnection_t connection, astra_command_id commandId, uint32_t inByteLength, astra_parameter_data_t inData, uint32_t *resultByteLength, astra_result_token_t *token)
ASTRA_API astra_status_t | astra_update ()
Drive the library to get a new frame of stream.

Detailed Description

Function Documentation

◆ astra_initialize()

ASTRA_API astra_status_t astra_initialize ( )

Initializes the library.

This function must be called before calling any other function.

Examples:
BodyReaderPoll\main.c, ColorReaderEvent\main.c, ColorReaderPoll\main.c, DepthReaderEvent\main.c, DepthReaderPoll\main.c, HandReader\main.c, InfraredColorReaderEvent\main.c, InfraredReaderEvent\main.c, and InfraredReaderPoll\main.c.

◆ astra_notify_plugin_event()

ASTRA_API astra_status_t astra_notify_plugin_event | ( | astra_event_id | id,
 |  | const void * | data,
 |  | uint32_t | dataSize
 | ) |  |

Notify plugins an event.

App use this function to notify plugins an event.

Parameters
[in] | id | event ID.
[in] | data | A pointer to the event data.
[in] | dataSize | Size of the data.

◆ astra_reader_close_frame()

ASTRA_API astra_status_t astra_reader_close_frame ( astra_reader_frame_t * frame )

Close.

Parameters
[in] frame
Examples:
BodyReaderPoll\main.c, ColorReaderPoll\main.c, DepthReaderPoll\main.c, HandReader\main.c, and InfraredReaderPoll\main.c.

◆ astra_reader_create()

ASTRA_API astra_status_t astra_reader_create | ( | astra_streamsetconnection_t | streamSet,
 |  | astra_reader_t * | reader
 | ) |  |

Create a StreamReader in StreamSet.

Parameters
[in] | streamSet | The handle to StreamSet.
[out] | reader | The handle to StreamReader.
Examples:
BodyReaderPoll\main.c, ColorReaderEvent\main.c, ColorReaderPoll\main.c, DepthReaderEvent\main.c, DepthReaderPoll\main.c, HandReader\main.c, InfraredColorReaderEvent\main.c, InfraredReaderEvent\main.c, and InfraredReaderPoll\main.c.

◆ astra_reader_destroy()

ASTRA_API astra_status_t astra_reader_destroy ( astra_reader_t * reader )

Destroy the handle to StreamReader.

The StreamReader must be destroyed when not used.

Parameters
[in] reader The handle to StreamReader created by astra_reader_create().
Examples:
BodyReaderPoll\main.c, ColorReaderEvent\main.c, ColorReaderPoll\main.c, DepthReaderEvent\main.c, DepthReaderPoll\main.c, HandReader\main.c, InfraredColorReaderEvent\main.c, InfraredReaderEvent\main.c, and InfraredReaderPoll\main.c.

◆ astra_reader_get_frame()

ASTRA_API astra_status_t astra_reader_get_frame | ( | astra_reader_frame_t | frame,
 |  | astra_stream_type_t | type,
 |  | astra_stream_subtype_t | subtype,
 |  | astra_frame_t ** | subFrame
 | ) |  |

Read a frame.

Parameters
[in] | frame | The handle to Frame.
[in] | type
[in] | subtype
[in] | subFrame

◆ astra_reader_get_stream()

ASTRA_API astra_status_t astra_reader_get_stream | ( | astra_reader_t | reader,
 |  | astra_stream_type_t | type,
 |  | astra_stream_subtype_t | subtype,
 |  | astra_streamconnection_t * | stream
 | ) |  |

Get specified stream from StreamReader reader.

Parameters
[in] | reader | The handle to StreamReader.
[in] | type | type of Stream.
[in] | subtype | subtype of Stream.
[out] | stream | The output handle to Stream.

◆ astra_reader_has_new_frame()

ASTRA_API astra_status_t astra_reader_has_new_frame | ( | astra_reader_t | reader,
 |  | bool * | hasNewFrame
 | ) |  |

Test whether there is a new frame.

Parameters
[in] | reader | The handle to StreamReader.
[out] | hasNewFrame

◆ astra_reader_open_frame()

ASTRA_API astra_status_t astra_reader_open_frame | ( | astra_reader_t | reader,
 |  | int | timeoutMillis,
 |  | astra_reader_frame_t * | frame
 | ) |  |

Open.

Parameters
[in] | reader
[in] | timeoutMillis
[in] | frame
Examples:
BodyReaderPoll\main.c, ColorReaderPoll\main.c, DepthReaderPoll\main.c, HandReader\main.c, and InfraredReaderPoll\main.c.

◆ astra_reader_register_frame_ready_callback()

ASTRA_API astra_status_t astra_reader_register_frame_ready_callback | ( | astra_reader_t | reader,
 |  | astra_frame_ready_callback_t | callback,
 |  | void * | clientTag,
 |  | astra_reader_callback_id_t * | callbackId
 | ) |  |

Registers a callback function to StreamReader.

Parameters
[in] | reader | The reader that callback will be registered to.
[in] | callback | A pointer to a function that will be called when frame ready to read.
[in] | clientTag | A user cookie that will be passed to the callback function.
[in] | callbackId | Output handle to be passed to astra_reader_unregister_frame_ready_callback() after later.
Examples:
ColorReaderEvent\main.c, DepthReaderEvent\main.c, InfraredColorReaderEvent\main.c, and InfraredReaderEvent\main.c.

◆ astra_reader_unregister_frame_ready_callback()

ASTRA_API astra_status_t astra_reader_unregister_frame_ready_callback ( astra_reader_callback_id_t * callbackId )

Unregisters the callback function.

Parameters
[in] callbackId The handle created by astra_reader_register_frame_ready_callback() before.
Examples:
ColorReaderEvent\main.c, DepthReaderEvent\main.c, InfraredColorReaderEvent\main.c, and InfraredReaderEvent\main.c.

◆ astra_stream_get_description()

ASTRA_API astra_status_t astra_stream_get_description | ( | astra_streamconnection_t | stream,
 |  | astra_stream_desc_t * | description
 | ) |  |

Get description of Stream.

Parameters
[in] | stream | The handle to Stream.
[out] | description | The output location for description pointer.

◆ astra_stream_get_parameter()

ASTRA_API astra_status_t astra_stream_get_parameter | ( | astra_streamconnection_t | connection,
 |  | astra_parameter_id | parameterId,
 |  | uint32_t * | resultByteLength,
 |  | astra_result_token_t * | token
 | ) |  |

Get parameter from StreamSet.

Parameters
[in] | connection
[in] | parameterId
[in] | resultByteLength
[in] | token

◆ astra_stream_is_available()

ASTRA_API astra_status_t astra_stream_is_available | ( | astra_streamconnection_t | stream,
 |  | bool * | isAvailable
 | ) |  |

Test whether the handle to Stream is valid.

Parameters
[in] | stream | The handle to Stream.
[in] | isAvailable | The test result(true:valid false:invalid).

◆ astra_stream_set_parameter()

ASTRA_API astra_status_t astra_stream_set_parameter | ( | astra_streamconnection_t | connection,
 |  | astra_parameter_id | parameterId,
 |  | uint32_t | inByteLength,
 |  | astra_parameter_data_t | inData
 | ) |  |

Set parameter to StreamSet.

Parameters
[in] | connection
[in] | parameterId
[in] | resultByteLength
[in] | token

◆ astra_stream_start()

ASTRA_API astra_status_t astra_stream_start ( astra_streamconnection_t stream )

Start the Stream.

The Stream must be started before reading frame it.

Parameters
[in] stream The handle to Stream.
Examples:
BodyReaderPoll\main.c, ColorReaderEvent\main.c, ColorReaderPoll\main.c, DepthReaderEvent\main.c, DepthReaderPoll\main.c, HandReader\main.c, InfraredColorReaderEvent\main.c, InfraredReaderEvent\main.c, and InfraredReaderPoll\main.c.

◆ astra_stream_stop()

ASTRA_API astra_status_t astra_stream_stop ( astra_streamconnection_t stream )

Stop the Stream.

After stoping the Stream, can't read frame from it anymore.

Parameters
[in] The handle to Stream.
Examples:
InfraredColorReaderEvent\main.c.

◆ astra_streamset_close()

ASTRA_API astra_status_t astra_streamset_close ( astra_streamsetconnection_t * streamSet )

Close the handle to StreamSet.

Parameters
[in] streamSet The handle to StreamSet.
Examples:
BodyReaderPoll\main.c, ColorReaderEvent\main.c, ColorReaderPoll\main.c, DepthReaderEvent\main.c, DepthReaderPoll\main.c, HandReader\main.c, InfraredColorReaderEvent\main.c, InfraredReaderEvent\main.c, and InfraredReaderPoll\main.c.

◆ astra_streamset_get_uri()

ASTRA_API astra_status_t astra_streamset_get_uri | ( | astra_streamsetconnection_t | streamSet,
 |  | char * | uri,
 |  | int32_t | size
 | ) |  |

Get the URI of StreamSet.

Parameters
[in] | streamSet | The handle to the StreamSet.
[out] | uri | Pointer to the buffer which receives output data.
[in] | size | Size of the buffer.

◆ astra_streamset_is_available()

ASTRA_API astra_status_t astra_streamset_is_available | ( | astra_streamsetconnection_t | streamSet,
 |  | bool * | isAvailable
 | ) |  |

Test whether the StreamSet is valid.

Parameters
[in] | streamSet | The handle to the StreamSet.
[out] | isAvailable | The test result(true:valid false:invalid)

◆ astra_streamset_open()

ASTRA_API astra_status_t astra_streamset_open | ( | const char * | uri,
 |  | astra_streamsetconnection_t * | streamSet
 | ) |  |

Open a StreamSet.

The StreamSet to be opened is identified by the uri.

Parameters
[in] | uri | A string-based unique identifier addressed the device.
[out] | streamSet | The output handle to StreamSet.
Examples:
BodyReaderPoll\main.c, ColorReaderEvent\main.c, ColorReaderPoll\main.c, DepthReaderEvent\main.c, DepthReaderPoll\main.c, HandReader\main.c, InfraredColorReaderEvent\main.c, InfraredReaderEvent\main.c, and InfraredReaderPoll\main.c.

◆ astra_terminate()

ASTRA_API astra_status_t astra_terminate ( )

Terminate the library, destroying all its streams.

This function must be called when library not used, otherwise there will be problems when re-initialize it.And do not call any other function after calling this method.

Examples:
BodyReaderPoll\main.c, ColorReaderEvent\main.c, ColorReaderPoll\main.c, DepthReaderEvent\main.c, DepthReaderPoll\main.c, HandReader\main.c, InfraredColorReaderEvent\main.c, InfraredReaderEvent\main.c, and InfraredReaderPoll\main.c.


Astra SDK: C++ Reference

Classes | Typedefs | Enumerations | Functions
C++ Reference

Classes

class | astra::Array< T >
Simple wrapper around primitive arrays. More...
struct | astra::Matrix3x3
Represents a 3x3 rotation matrix. More...
struct | astra::Vector2f
Represents a float 2d vector. More...
struct | astra::Vector2i
Represents a float 2d vector. More...
struct | astra::Vector3f
Represents a float 3d vector. More...
struct | astra::Vector3i
Represents a float 3d vector. More...
class | astra::BitmapMask
Bitmap representing a 2d mask. More...
class | astra::Joint
Body joint More...
class | astra::Body
Human body. More...
class | astra::Plane
3D geometric plane More...
class | astra::BodyFrame
Body tracking information produced by a BodyTracker instance More...
class | astra::BodyStream
A Body Data Stream. More...
class | astra::ColorStream
A color stream. More...
class | astra::ColorFrame
color frame of rgb format More...
class | astra::RawColorFrame
color frame of raw format More...
class | astra::ColorizedBodyStream
A Colorized Body Stream. More...
class | astra::ColorizedBodyFrame
A Colorized Body Frame. More...
class | astra::DebugHandStream
A Debug Hand Stream. More...
class | astra::DebugHandFrame
A Debug Hand Frame. More...
class | astra::CoordinateMapper
CoordinateMapper. More...
class | astra::DepthStream
A Depth Stream. More...
class | astra::DepthFrame
A Depth Frame. More...
class | astra::HandPoint
Hand Point struct. More...
class | astra::HandStream
A Hand Stream. More...
class | astra::HandFrame
A Hand Data Frame. More...
struct | astra::RgbPixel
rgb pixel struct More...
struct | astra::RgbaPixel
rgba pixel struct More...
class | astra::ImageStreamMode
Image Stream Mode. More...
class | astra::ImageStream
basic Image Stream More...
class | astra::ImageFrame< TDataType, TStreamType >
Basic Image Frame. More...
class | astra::InfraredStream
A Infrared Stream. More...
class | astra::InfraredFrame16
A Infrared Frame use 16bit unsigned short format. More...
class | astra::InfraredFrameRgb
A Infrared Frame use rgb format. More...
class | astra::MaskedColorStream
A Masked Color Stream. More...
class | astra::MaskedColorFrame
A Masked Color Frame of Masked Color Stream. More...
class | astra::PointStream
A Point Data Stream. More...
class | astra::PointFrame
A Point Data Frame. More...
class | astra::DataStream
Data Stream. More...
class | astra::Frame
Frame class. More...
class | astra::FrameListener
Frame Listener class. More...
class | astra::StreamDescription
Stream Description class. More...
class | astra::StreamReader
Stream Reader class. More...
class | astra::StreamServiceProxy
Stream Service Proxy Class. More...
class | astra::StreamSet
Stream Set Class. More...

Typedefs

using | astra::BodyMask = BitmapMask
Mask representing pixels that have been identified as belonging to tracked bodies.
using | astra::FloorMask = BitmapMask
Mask representing pixels that have been identified as belonging to the floor plane.
using | astra::JointList = Array< const Joint >
Type alias for an immutable Array of Joints.
using | astra::BodyId = astra_body_id_t
Identifier type for bodies.
using | astra::BodyList = Array< const Body >
Type alias for an immutable Array of Bodies.

Enumerations

enum | astra::BodyTrackingFeatureFlags : ::astra_body_tracking_feature_flags_t { astra::BodyTrackingFeatureFlags::Segmentation = 0, astra::BodyTrackingFeatureFlags::Joints = 1, astra::BodyTrackingFeatureFlags::HandPoses = 3 }
Bitmask of body features Represents the possible features that body tracking can produce on a body. This is a bitmask so multiple features can be combined. More...
enum | astra::SkeletonProfile : ::astra_skeleton_profile_t { astra::SkeletonProfile::Full = 0, astra::SkeletonProfile::UpperBody = 1, astra::SkeletonProfile::Basic = 2 }
Skeleton profile representing the set of joints to be tracked. More...
enum astra::SkeletonOptimization : ::astra_skeleton_optimization_t {
Optimization1 = 1, astra::SkeletonOptimization::MinimizeMemory = 2, Optimization2 = 2, Optimization3 = 3,
Optimization4 = 4, astra::SkeletonOptimization::Balanced = 5, Optimization5 = 5, Optimization6 = 6,
Optimization7 = 7, Optimization8 = 8, Optimization9 = 9, astra::SkeletonOptimization::BestAccuracy = 9
}
Represents the body tracking configuration that trades-off tracking accuracy, memory, and CPU usage. More...
enum | astra::JointStatus : ::astra_joint_status_t { astra::JointStatus::NotTracked = 0, astra::JointStatus::LowConfidence = 1, astra::JointStatus::Tracked = 2 }
Joint status enumeration. More...
enum astra::JointType : ::astra_joint_type_t {
astra::JointType::Head = 0, astra::JointType::ShoulderSpine = 1, astra::JointType::LeftShoulder = 2, astra::JointType::LeftElbow = 3,
astra::JointType::LeftHand = 4, astra::JointType::RightShoulder = 5, astra::JointType::RightElbow = 6, astra::JointType::RightHand = 7,
astra::JointType::MidSpine = 8, astra::JointType::BaseSpine = 9, astra::JointType::LeftHip = 10, astra::JointType::LeftKnee = 11,
astra::JointType::LeftFoot = 12, astra::JointType::RightHip = 13, astra::JointType::RightKnee = 14, astra::JointType::RightFoot = 15,
astra::JointType::LeftWrist = 16, astra::JointType::RightWrist = 17, astra::JointType::Neck = 18, astra::JointType::Unknown = 255
}
Joint type enumeration. More...
enum | astra::HandPose : ::astra_handpose_t { astra::HandPose::Unknown = 0, astra::HandPose::Grip = 1 }
Hand pose enum. Enumeration of the hand poses that can be detected. More...
enum | astra::BodyStatus : ::astra_body_status_t { astra::BodyStatus::NotTracking = 0, astra::BodyStatus::TrackingLost = 1, astra::BodyStatus::TrackingStarted = 2, astra::BodyStatus::Tracking = 3 }
Enumeration of possible tracking status of a orbbec::bodytracking::Body. More...

Functions

template<typename T >
Array< T > | astra::make_array (T *ptr, std::size_t size)
Simplifies Array construction by leveraging function template type deduction. More...
astra_status_t | astra::initialize ()
Initializes the library. More...
astra_status_t | astra::terminate ()
Terminate the library, destroying all its streams. More...
bool | astra::operator== (const StreamDescription &lhs, const StreamDescription &rhs)
compare StreamDescription is equal More...
bool | astra::operator!= (const StreamDescription &lhs, const StreamDescription &rhs)
compare StreamDescription is not equal More...

Detailed Description

Enumeration Type Documentation

◆ BodyStatus

enum astra::BodyStatus : ::astra_body_status_t
strong

Enumeration of possible tracking status of a orbbec::bodytracking::Body.

Enumerator
NotTracking | Body is not currently tracked
TrackingLost | Tracking of Body was lost
TrackingStarted | Tracking of Body has begun
Tracking | Body is currently being tracked

◆ BodyTrackingFeatureFlags

enum astra::BodyTrackingFeatureFlags : ::astra_body_tracking_feature_flags_t
strong

Bitmask of body features Represents the possible features that body tracking can produce on a body. This is a bitmask so multiple features can be combined.

Enumerator
Segmentation | No features beyond minimal body mask segmentation
Joints | Tracking of joints
HandPoses | Recognition of hand poses

◆ HandPose

enum astra::HandPose : ::astra_handpose_t
strong

Hand pose enum. Enumeration of the hand poses that can be detected.

Enumerator
Unknown | Hand pose is not known or unrecognized
Grip | Grip pose

◆ JointStatus

enum astra::JointStatus : ::astra_joint_status_t
strong

Joint status enumeration.

Enumerator
NotTracked | Joint not currently tracked
LowConfidence | Joint is currently tracked with low confidence possibly due to occlusion
Tracked | Joint is currently tracked

◆ JointType

enum astra::JointType : ::astra_joint_type_t
strong

Joint type enumeration.

Enumerator
Head | Head
ShoulderSpine | Shoulder spine
LeftShoulder | Left Shoulder
LeftElbow | Left Elbow
LeftHand | Left hand
RightShoulder | Right Shoulder
RightElbow | Right Elbow
RightHand | Right Hand
MidSpine | Mid spine
BaseSpine | Base spine
LeftHip | Left Hip
LeftKnee | Left Knee
LeftFoot | Left Foot
RightHip | Right Hip
RightKnee | Right Knee
RightFoot | Right Foot
LeftWrist | Left Wrist
RightWrist | Right Wrist
Neck | Neck
Unknown | Unknown

◆ SkeletonOptimization

enum astra::SkeletonOptimization : ::astra_skeleton_optimization_t
strong

Represents the body tracking configuration that trades-off tracking accuracy, memory, and CPU usage.

Enumerator
MinimizeMemory | Configuration that minimizes memory usage at a cost of lower tracking accuracy
Balanced | Configuration that balances accuracy with lower memory and CPU usage
BestAccuracy | Configuration that produces the best tracking accuracy

◆ SkeletonProfile

enum astra::SkeletonProfile : ::astra_skeleton_profile_t
strong

Skeleton profile representing the set of joints to be tracked.

Enumerator
Full | All supported joints
UpperBody | Upper body only
Basic | Only four basic joints: Head, MidSpine, LeftHand, RightHand

Function Documentation

◆ initialize()

astra_status_t astra::initialize ( )
inline

Initializes the library.

This function must be called before calling any other function.

Examples:
ColorizedBodyViewer-SFML\main.cpp, ColorReaderEventCPP\main.cpp, DepthReaderEventCPP\main.cpp, MaskedColorViewer-SFML\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleBodyViewer-SFML\main.cpp, SimpleColorViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, SimpleHandViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

◆ make_array()

template<typename T >
Array<T> astra::make_array | ( | T * | ptr,
 |  | std::size_t | size
 | ) |  |
inline

Simplifies Array construction by leveraging function template type deduction.

Parameters
[in] | ptr | Pointer to array
[in] | size | Size of array

◆ operator!=()

bool astra::operator!= | ( | const StreamDescription & | lhs,
 |  | const StreamDescription & | rhs
 | ) |  |
inline

compare StreamDescription is not equal

Returns
StreamDescription is not equal

◆ operator==()

bool astra::operator== | ( | const StreamDescription & | lhs,
 |  | const StreamDescription & | rhs
 | ) |  |
inline

compare StreamDescription is equal

Returns
StreamDescription is equal

◆ terminate()

astra_status_t astra::terminate ( )
inline

Terminate the library, destroying all its streams.

This function must be called when library not used, otherwise there will be problems when re-initialize it.And do not call any other function after calling this method.

Examples:
ColorizedBodyViewer-SFML\main.cpp, ColorReaderEventCPP\main.cpp, DepthReaderEventCPP\main.cpp, MaskedColorViewer-SFML\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleBodyViewer-SFML\main.cpp, SimpleColorViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, SimpleHandViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.


Astra SDK: astra::Array< T > Class Template Reference

  • astra
  • Array
Public Member Functions | List of all members
astra::Array< T > Class Template Reference
C++ Reference

Simple wrapper around primitive arrays. More...

#include <Array.hpp>

Public Member Functions

Array ()
Default constructs zero-length array.
Array (decltype(nullptr))
Implicit conversion constructor from nullptr to a zero-length array.
Array (T *ptr, size_t size)
Constructs array from pointer and size.
Array (T *begin, T *end)
Constructs array from begin and end iterators.
size_t | size () const
Gets size of array.
bool | empty () const
Returns true if array is zero length.
T * | data ()
Gets mutable raw pointer to array data.
const T * | data () const
Gets immutable raw pointer to array data.
T * | begin ()
Gets mutable iterator pointing to beginning of array.
const T * | begin () const
Gets immutable iterator pointing to beginning of array.
T * | end ()
Gets mutable iterator pointing to one past the end of array.
const T * | end () const
Gets iterator pointing to one past the end of array.
T & | front ()
Gets mutable reference to first array element.
const T & | front () const
Gets immutable reference to first array element.
T & | back ()
Gets mutable reference to last array element.
const T & | back () const
Gets immutable reference to last array element.
T & | operator[] (size_t index)
Mutable index operator into array. More...
const T & | operator[] (size_t index) const
Immutable index operator into array. More...
Array< T > | slice (size_t start, size_t end)
Creates a mutable sub-array of the same type based on a start and end index. More...
Array< const T > | slice (size_t start, size_t end) const
Creates an immutable sub-array of the same type based on a start and end index. More...
bool | operator== (const Array &other) const
Identity based equality operator.
bool | operator!= (const Array &other) const
Identity based inequality operator.

Detailed Description

template<typename T>
class astra::Array< T >

Simple wrapper around primitive arrays.

Provides a strongly-typed wrapper around primitive C-style arrays. Array does not copy or consider itself the owner of the data provided through the constructor. Users should make sure that the Array instance does not live longer than the data it points to.

Examples:
SimpleBodyViewer-SFML\main.cpp.

Member Function Documentation

◆ operator[]() [1/2]

template<typename T>
T& astra::Array< T >::operator[] ( size_t index )
inline

Mutable index operator into array.

Parameters
[in] index Index into array

◆ operator[]() [2/2]

template<typename T>
const T& astra::Array< T >::operator[] ( size_t index ) const
inline

Immutable index operator into array.

Parameters
[in] index Index into array

◆ slice() [1/2]

template<typename T>
Array<T> astra::Array< T >::slice | ( | size_t | start,
 |  | size_t | end
 | ) |  |
inline

Creates a mutable sub-array of the same type based on a start and end index.

Parameters
[in] | start | Start index
[in] | end | End index (exclusive)

◆ slice() [2/2]

template<typename T>
Array<const T> astra::Array< T >::slice | ( | size_t | start,
 |  | size_t | end
 | ) |  | const
 inline

Creates an immutable sub-array of the same type based on a start and end index.

Parameters
[in] | start | Start index
[in] | end | End index (exclusive)
The documentation for this class was generated from the following file:
  • Array.hpp


Astra SDK: astra::Matrix3x3 Struct Reference

  • astra
  • Matrix3x3
Public Member Functions | Friends | List of all members
astra::Matrix3x3 Struct Reference
C++ Reference

Represents a 3x3 rotation matrix. More...

#include <Matrix3x3.hpp>

Inheritance diagram for astra::Matrix3x3:
_astra_matrix3x3

Public Member Functions

Matrix3x3 ()
Default constructs zero Matrix.
const Vector3f & | x_axis () const
X axis basis vector, or the first column vector. More...
const Vector3f & | y_axis () const
Y axis basis vector, or the second column vector. More...
const Vector3f & | z_axis () const
Z axis basis vector, or the third column vector. More...
float | m00 () const
the m00 coef More...
float | m10 () const
the m10 coef More...
float | m20 () const
the m20 coef More...
float | m01 () const
the m01 coef More...
float | m11 () const
the m11 coef More...
float | m21 () const
the m21 coef More...
float | m02 () const
the m02 coef More...
float | m12 () const
the m12 coef More...
float | m22 () const
the m22 coef More...

Friends

class Joint

Detailed Description

Represents a 3x3 rotation matrix.

Member Function Documentation

◆ m00()

float astra::Matrix3x3::m00 ( ) const
inline

the m00 coef

Returns
s the m00 coef.

◆ m01()

float astra::Matrix3x3::m01 ( ) const
inline

the m01 coef

Returns
s the m01 coef.

◆ m02()

float astra::Matrix3x3::m02 ( ) const
inline

the m02 coef

Returns
s the m02 coef.

◆ m10()

float astra::Matrix3x3::m10 ( ) const
inline

the m10 coef

Returns
s the m10 coef.

◆ m11()

float astra::Matrix3x3::m11 ( ) const
inline

the m11 coef

Returns
s the m11 coef.

◆ m12()

float astra::Matrix3x3::m12 ( ) const
inline

the m12 coef

Returns
s the m12 coef.

◆ m20()

float astra::Matrix3x3::m20 ( ) const
inline

the m20 coef

Returns
s the m20 coef.

◆ m21()

float astra::Matrix3x3::m21 ( ) const
inline

the m21 coef

Returns
s the m21 coef.

◆ m22()

float astra::Matrix3x3::m22 ( ) const
inline

the m22 coef

Returns
s the m22 coef.

◆ x_axis()

const Vector3f& astra::Matrix3x3::x_axis ( ) const
inline

X axis basis vector, or the first column vector.

Returns
the X axis basis vector.

◆ y_axis()

const Vector3f& astra::Matrix3x3::y_axis ( ) const
inline

Y axis basis vector, or the second column vector.

Returns
the Y axis basis vector.

◆ z_axis()

const Vector3f& astra::Matrix3x3::z_axis ( ) const
inline

Z axis basis vector, or the third column vector.

Returns
the Z axis basis vector.
The documentation for this struct was generated from the following file:
  • Matrix3x3.hpp


Astra SDK: astra::Vector2f Struct Reference

  • astra
  • Vector2f
Public Member Functions | Static Public Member Functions | Friends | List of all members
astra::Vector2f Struct Reference
C++ Reference

Represents a float 2d vector. More...

#include <Vector2f.hpp>

Inheritance diagram for astra::Vector2f:
astra_vector2f_t

Public Member Functions

Vector2f ()
constructs zero vector.
Vector2f (const astra_vector2f_t &v)
constructs for astra_vector2f_t
Vector2f & | operator= (const astra_vector2f_t &rhs)
copy constructs for astra_vector2f_t
Vector2f (float x, float y)
constructs
operator::astra_vector2f_t * ()
operator const ::astra_vector2f_t * () const
float | length () const
calc length More...
float | length_squared () const
calc length squared More...
float | dot (const Vector2f &v) const
dot cross width v. More...
bool | is_zero () const
adjust vector is zero. More...
Vector2f | operator- ()
Vector2f & | operator+= (const Vector2f &rhs)
Vector2f & | operator-= (const Vector2f &rhs)
Vector2f & | operator*= (const float &rhs)
Vector2f & | operator/= (const float &rhs)

Static Public Member Functions

static Vector2f | normalize (Vector2f v)
normalize vector. More...
static Vector2f | zero ()
make vector all zero.

Friends

bool | operator== (const Vector2f &lhs, const Vector2f &rhs)
Vector2f | operator+ (const Vector2f &lhs, const Vector2f &rhs)
Vector2f | operator- (const Vector2f &lhs, const Vector2f &rhs)
Vector2f | operator* (const Vector2f &lhs, const float &rhs)
Vector2f | operator* (const float &lhs, const Vector2f &rhs)
Vector2f | operator/ (const Vector2f &lhs, const float &rhs)

Additional Inherited Members

- Public Attributes inherited from astra_vector2f_t
float | x
float | y

Detailed Description

Represents a float 2d vector.

Member Function Documentation

◆ dot()

float astra::Vector2f::dot ( const Vector2f & v ) const
inline

dot cross width v.

Parameters
[in] vector2f v
Returns
x * v.x + y * v.y

◆ is_zero()

bool astra::Vector2f::is_zero ( ) const
inline

adjust vector is zero.

Returns
is all zero

◆ length()

float astra::Vector2f::length ( ) const
inline

calc length

Returns
sqrt(x * x + y * y).

◆ length_squared()

float astra::Vector2f::length_squared ( ) const
inline

calc length squared

Returns
x * x + y * y

◆ normalize()

Vector2f astra::Vector2f::normalize ( Vector2f v )
inlinestatic

normalize vector.

Parameters
[in] vector2f v
Returns
normalize vector2f
The documentation for this struct was generated from the following file:
  • Vector2f.hpp


Astra SDK: astra::Vector2i Struct Reference

  • astra
  • Vector2i
Public Member Functions | Static Public Member Functions | Friends | List of all members
astra::Vector2i Struct Reference
C++ Reference

Represents a float 2d vector. More...

#include <Vector2i.hpp>

Inheritance diagram for astra::Vector2i:
astra_vector2i_t

Public Member Functions

Vector2i ()
constructs zero vector.
Vector2i (const astra_vector2i_t &v)
constructs for astra_vector2i_t
Vector2i & | operator= (const astra_vector2i_t &rhs)
copy constructs for astra_vector2i_t
Vector2i (int x, int y)
constructs
operator::astra_vector2i_t * ()
operator const ::astra_vector2i_t * () const
float | length () const
calc length More...
std::int32_t | length_squared () const
calc length squared More...
std::int32_t | dot (const Vector2i &v) const
dot cross width v. More...
bool | is_zero () const
adjust vector is zero. More...
Vector2i | operator- ()
Vector2i & | operator+= (const Vector2i &rhs)
Vector2i & | operator-= (const Vector2i &rhs)
Vector2i & | operator*= (const std::int32_t rhs)
Vector2i & | operator/= (const std::int32_t rhs)

Static Public Member Functions

static Vector2i | normalize (const Vector2i &v)
normalize vector. More...
static const Vector2i & | zero ()
make vector all zero.

Friends

bool | operator== (const Vector2i &lhs, const Vector2i &rhs)
Vector2i | operator+ (const Vector2i &lhs, const Vector2i &rhs)
Vector2i | operator- (const Vector2i &lhs, const Vector2i &rhs)
Vector2i | operator* (const Vector2i &lhs, const std::int32_t rhs)
Vector2i | operator* (const std::int32_t lhs, const Vector2i &rhs)
Vector2i | operator/ (const Vector2i &lhs, const std::int32_t rhs)

Additional Inherited Members

- Public Attributes inherited from astra_vector2i_t
int32_t | x
int32_t | y

Detailed Description

Represents a float 2d vector.

Examples:
SimpleHandViewer-SFML\main.cpp.

Member Function Documentation

◆ dot()

std::int32_t astra::Vector2i::dot ( const Vector2i & v ) const
inline

dot cross width v.

Parameters
[in] vector2i v
Returns
x * v.x + y * v.y

◆ is_zero()

bool astra::Vector2i::is_zero ( ) const
inline

adjust vector is zero.

Returns
is all zero

◆ length()

float astra::Vector2i::length ( ) const
inline

calc length

Returns
sqrt(x * x + y * y).

◆ length_squared()

std::int32_t astra::Vector2i::length_squared ( ) const
inline

calc length squared

Returns
x * x + y * y

◆ normalize()

Vector2i astra::Vector2i::normalize ( const Vector2i & v )
inlinestatic

normalize vector.

Parameters
[in] vector2i v
Returns
normalize vector2i
The documentation for this struct was generated from the following file:
  • Vector2i.hpp


Astra SDK: astra::Vector3f Struct Reference

  • astra
  • Vector3f
Public Member Functions | Static Public Member Functions | Friends | List of all members
astra::Vector3f Struct Reference
C++ Reference

Represents a float 3d vector. More...

#include <Vector3f.hpp>

Inheritance diagram for astra::Vector3f:
astra_vector3f_t

Public Member Functions

Vector3f ()
constructs zero vector.
Vector3f (const astra_vector3f_t &v)
constructs for astra_vector3f_t
Vector3f & | operator= (const astra_vector3f_t &rhs)
copy constructs for astra_vector3f_t
Vector3f (float x, float y, float z)
constructs
operator::astra_vector3f_t * ()
operator const ::astra_vector3f_t * () const
float | length () const
calc length More...
float | length_squared () const
calc length More...
float | dot (const Vector3f &v) const
dot cross width v. More...
Vector3f | cross (const Vector3f &v) const
cross width v. More...
bool | is_zero () const
adjust vector is zero. More...
Vector3f & | operator+= (const Vector3f &rhs)
Vector3f & | operator-= (const Vector3f &rhs)
Vector3f & | operator*= (const float &rhs)
Vector3f & | operator/= (const float &rhs)
Vector3f | operator- ()

Static Public Member Functions

static Vector3f | zero ()
make vector all zero.
static Vector3f | normalize (Vector3f v)
normalize vector. More...

Friends

bool | operator== (const Vector3f &lhs, const Vector3f &rhs)
bool | operator!= (const Vector3f &lhs, const Vector3f &rhs)
Vector3f | operator+ (const Vector3f &lhs, const Vector3f &rhs)
Vector3f | operator- (const Vector3f &lhs, const Vector3f &rhs)
Vector3f | operator* (const Vector3f &lhs, const float &rhs)
Vector3f | operator* (const float &lhs, const Vector3f &rhs)
Vector3f | operator/ (const Vector3f &lhs, const float &rhs)

Additional Inherited Members

- Public Attributes inherited from astra_vector3f_t
float | x
float | y
float | z

Detailed Description

Represents a float 3d vector.

Member Function Documentation

◆ cross()

Vector3f astra::Vector3f::cross ( const Vector3f & v ) const
inline

cross width v.

Parameters
[in] vector3f v
Returns
cross width v

◆ dot()

float astra::Vector3f::dot ( const Vector3f & v ) const
inline

dot cross width v.

Parameters
[in] vector3f v
Returns
x * v.x + y * v.y + z * v.z

◆ is_zero()

bool astra::Vector3f::is_zero ( ) const
inline

adjust vector is zero.

Returns
is all zero

◆ length()

float astra::Vector3f::length ( ) const
inline

calc length

Returns
sqrt(x * x + y * y + z * z).

◆ length_squared()

float astra::Vector3f::length_squared ( ) const
inline

calc length

Returns
x * x + y * y + z * z.

◆ normalize()

Vector3f astra::Vector3f::normalize ( Vector3f v )
inlinestatic

normalize vector.

Parameters
[in] vector2f v
Returns
normalize vector2f
The documentation for this struct was generated from the following file:
  • Vector3f.hpp


Astra SDK: astra::Vector3i Struct Reference

  • astra
  • Vector3i
Public Member Functions | Static Public Member Functions | Friends | List of all members
astra::Vector3i Struct Reference
C++ Reference

Represents a float 3d vector. More...

#include <Vector3i.hpp>

Inheritance diagram for astra::Vector3i:
astra_vector3i_t

Public Member Functions

Vector3i ()
constructs zero vector.
Vector3i (const astra_vector3i_t &v)
constructs for astra_vector3i_t
Vector3i & | operator= (const astra_vector3i_t &rhs)
copy constructs for astra_vector3i_t
Vector3i (int x, int y, int z)
constructs
operator::astra_vector3i_t * ()
operator const ::astra_vector3i_t * () const
float | length () const
calc length More...
std::int32_t | length_squared () const
calc length More...
std::int32_t | dot (const Vector3i &v) const
dot cross width v. More...
Vector3i | cross (const Vector3i &v) const
cross width v. More...
bool | is_zero () const
adjust vector is zero. More...
Vector3i & | operator+= (const Vector3i &rhs)
Vector3i & | operator-= (const Vector3i &rhs)
Vector3i & | operator*= (const std::int32_t rhs)
Vector3i & | operator/= (const std::int32_t rhs)
Vector3i | operator- ()

Static Public Member Functions

static Vector3i | normalize (const Vector3i &v)
make vector all zero.
static const Vector3i & | zero ()
normalize vector. More...

Friends

bool | operator== (const Vector3i &lhs, const Vector3i &rhs)
bool | operator!= (const Vector3i &lhs, const Vector3i &rhs)
Vector3i | operator+ (const Vector3i &lhs, const Vector3i &rhs)
Vector3i | operator- (const Vector3i &lhs, const Vector3i &rhs)
Vector3i | operator* (const Vector3i &lhs, const std::int32_t rhs)
Vector3i | operator* (const float lhs, const Vector3i &rhs)
Vector3i | operator/ (const Vector3i &lhs, const std::int32_t rhs)

Additional Inherited Members

- Public Attributes inherited from astra_vector3i_t
int32_t | x
int32_t | y
int32_t | z

Detailed Description

Represents a float 3d vector.

Member Function Documentation

◆ cross()

Vector3i astra::Vector3i::cross ( const Vector3i & v ) const
inline

cross width v.

Parameters
[in] vector3i v
Returns
cross width v

◆ dot()

std::int32_t astra::Vector3i::dot ( const Vector3i & v ) const
inline

dot cross width v.

Parameters
[in] vector3i
Returns
x * v.x + y * v.y + z * v.z

◆ is_zero()

bool astra::Vector3i::is_zero ( ) const
inline

adjust vector is zero.

Returns
is all zero

◆ length()

float astra::Vector3i::length ( ) const
inline

calc length

Returns
sqrt(x * x + y * y + z * z).

◆ length_squared()

std::int32_t astra::Vector3i::length_squared ( ) const
inline

calc length

Returns
x * x + y * y + z * z.

◆ zero()

const Vector3i & astra::Vector3i::zero ( )
inlinestatic

normalize vector.

Parameters
[in] vector2f v
Returns
normalize vector2f
The documentation for this struct was generated from the following file:
  • Vector3i.hpp


Astra SDK: astra::BitmapMask Class Reference

  • astra
  • BitmapMask
Public Member Functions | Friends | List of all members
astra::BitmapMask Class Reference
C++ Reference

Bitmap representing a 2d mask. More...

#include <Body.hpp>

Inheritance diagram for astra::BitmapMask:
_astra_bitmapmask

Public Member Functions

BitmapMask ()
Default constructs an empty zero-sized BitmapMask.
int32_t | width () const
Gets the width of the mask.
int32_t | height () const
Gets the height of the mask.
int32_t | bpp () const
Gets the bytes per pixel.
int32_t | length () const
Gets the length of the mask in pixels.
int32_t | byte_length () const
Gets the length of the mask in bytes.
const uint8_t * | data () const
Gets an immutable raw pointer to mask data.

Friends

class | FloorInfo
class | BodyFrame

Detailed Description

Bitmap representing a 2d mask.

Encapsulates a 2-dimensional bitmask. A non-zero pixel value is considered part of the mask.

Examples:
SimpleBodyViewer-SFML\main.cpp.
The documentation for this class was generated from the following file:
  • Body.hpp


Astra SDK: astra::Joint Class Reference

  • astra
  • Joint
Public Member Functions | Friends | List of all members
astra::Joint Class Reference
C++ Reference

Body joint More...

#include <Body.hpp>

Inheritance diagram for astra::Joint:
_astra_joint

Public Member Functions

JointType | type () const
Gets the type of joint.
JointStatus | status () const
Gets the current status of the Joint.
const Vector2f & | depth_position () const
Gets the depth ("projective") position of the Joint. More...
const Vector3f & | world_position () const
Gets the real world position of the Joint.
const Matrix3x3 & | orientation () const
Gets the 3x3 Rotation matrix representing the rotation of this joint.

Friends

class Body

Detailed Description

Body joint

Encapsulates information about a particular joint. Joint positions are provided in both projective and world coordinates.

See also
JointType for the possible tracked joints
JointStatus for the possible states of joint tracking

Member Function Documentation

◆ depth_position()

const Vector2f& astra::Joint::depth_position ( ) const
inline

Gets the depth ("projective") position of the Joint.

The position reported is given with respect to BodyFrame::width and BodyFrame::height, which are the same dimensions as those of the input DepthMap

The documentation for this class was generated from the following file:
  • Body.hpp


Astra SDK: astra::Body Class Reference

  • astra
  • Body
Public Member Functions | Friends | List of all members
astra::Body Class Reference
C++ Reference

Human body. More...

#include <Body.hpp>

Inheritance diagram for astra::Body:
_astra_body

Public Member Functions

BodyId | id () const
Gets BodyId associated with the Body. More...
BodyStatus | status () const
Gets the tracking status of the body.
const Vector3f & | center_of_mass () const
Gets the real world center of mass estimate.
bool | joints_enabled () const
bool | hand_poses_enabled () const
JointList | joints () const
Gets the current list of joints (Joint) being currently tracked.
const HandPoseInfo & | hand_poses () const

Friends

class BodyFrame

Detailed Description

Human body.

Provides info about a human body tracked by the BodyTracker. Joints positions are provided in both projective and world coordinates.

See also
BodyTracker for information how to generate this data
Joint for information related to individual joints
BodyStatus for possible tracking statuses of a Body
Examples:
SimpleBodyViewer-SFML\main.cpp.

Member Function Documentation

◆ id()

BodyId astra::Body::id ( ) const
inline

Gets BodyId associated with the Body.

BodyId can be used to match a particular active Body across frames. Additionally, BodyId match the values in a BodyMask

The documentation for this class was generated from the following file:
  • Body.hpp


Astra SDK: astra::Plane Class Reference

  • astra
  • Plane
Public Member Functions | Friends | List of all members
astra::Plane Class Reference
C++ Reference

3D geometric plane More...

#include <Body.hpp>

Inheritance diagram for astra::Plane:
_astra_plane

Public Member Functions

Plane ()
Default constructs a plane that passes though origin, has a zero-length normal, and is considered degenerate.
float | a () const
Gets the A coefficient.
float | b () const
Gets the B coefficient.
float | c () const
Gets the C coefficient.
float | d () const
Gets the D coefficent (signed distance)
const Vector3f & | normal () const
Gets the plane normal.
bool | is_degenerate () const
Returns whether than plane is considered degenerate (invalid)

Friends

class FloorInfo

Detailed Description

3D geometric plane

Represents a 3D plane.

The normal of the plane is defined to be (A, B, C). The plane coefficients and real world coordinates (x, y, and z) are related by the plane equation:

Ax + By + Cz + D = 0

Remarks
The vector v = (A, B, C) represents the normal to the plane and D represents the signed distance along the normal between the plane and the origin of the coordinate system. The the origin of the coordinate system is the camera's depth sensor
The documentation for this class was generated from the following file:
  • Body.hpp


Astra SDK: astra::BodyFrame Class Reference

  • astra
  • BodyFrame
Public Member Functions | Static Public Member Functions | List of all members
astra::BodyFrame Class Reference
C++ Reference

Body tracking information produced by a BodyTracker instance More...

#include <Body.hpp>

Public Member Functions

BodyFrame (const BodyFrame &)=delete
BodyFrame is not copy constructible.
BodyFrame & | operator= (const BodyFrame &)=delete
BodyFrame is not copy assignable.
BodyFrame (BodyFrame &&other)
BodyFrame is move constructible.
BodyFrame & | operator= (BodyFrame &&other)
BodyFrame is move assignable.
bool | is_valid () const
get body frame is vaild More...
astra_frame_index_t | frame_index () const
get body frame index More...
const BodyFrameInfo & | info () const
get body frame info More...
const BodyMask & | body_mask () const
Gets the BodyMask of the current tracked bodies.
const FloorInfo & | floor_info () const
BodyList | bodies () const
Gets the current tracked bodies associated with the current BodyFrame. More...

Static Public Member Functions

template<typename TFrameType >
static TFrameType acquire (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype)

Detailed Description

Body tracking information produced by a BodyTracker instance

Examples:
SimpleBodyViewer-SFML\main.cpp.

Member Function Documentation

◆ bodies()

BodyList astra::BodyFrame::bodies ( ) const
inline

Gets the current tracked bodies associated with the current BodyFrame.

See also
Body for body specific information
Examples:
SimpleBodyViewer-SFML\main.cpp.

◆ frame_index()

astra_frame_index_t astra::BodyFrame::frame_index ( ) const
inline

get body frame index

Returns
body frame index
Examples:
SimpleBodyViewer-SFML\main.cpp.

◆ info()

const BodyFrameInfo& astra::BodyFrame::info ( ) const
inline

get body frame info

Returns
body frame info
Examples:
SimpleBodyViewer-SFML\main.cpp.

◆ is_valid()

bool astra::BodyFrame::is_valid ( ) const
inline

get body frame is vaild

Returns
body frame is vaild
Examples:
SimpleBodyViewer-SFML\main.cpp.
The documentation for this class was generated from the following file:
  • Body.hpp


Astra SDK: astra::BodyStream Class Reference

  • astra
  • BodyStream
Public Member Functions | Static Public Attributes | List of all members
astra::BodyStream Class Reference
C++ Reference

A Body Data Stream. More...

#include <Body.hpp>

Inheritance diagram for astra::BodyStream:
astra::DataStream

Public Member Functions

BodyStream (astra_streamconnection_t connection)
default constructs More...
BodyTrackingFeatureFlags | get_body_features (astra_body_id_t id)
get body features More...
void | set_body_features (astra_body_id_t id, BodyTrackingFeatureFlags features)
set body features More...
BodyTrackingFeatureFlags get_default_body_features ()
get default body features More...
void | set_default_body_features (BodyTrackingFeatureFlags features)
set default body features More...
SkeletonProfile get_skeleton_profile ()
get skeleton profile More...
void | set_skeleton_profile (SkeletonProfile skeletonProfile)
set skeleton profile More...
SkeletonOptimization get_skeleton_optimization ()
get skeleton optimization More...
void | set_skeleton_optimization (SkeletonOptimization skeletonOptimization)
set skeleton optimization More...
- Public Member Functions inherited from astra::DataStream
DataStream (astra_streamconnection_t connection)
default constructs More...
bool | is_available ()
start stream More...
void | start ()
start stream
void | stop ()
stop stream

Static Public Attributes

static const astra_stream_type_t id = ASTRA_STREAM_BODY

Detailed Description

A Body Data Stream.

A Body Data Stream.

Examples:
ColorizedBodyViewer-SFML\main.cpp, MaskedColorViewer-SFML\main.cpp, and SimpleBodyViewer-SFML\main.cpp.

Constructor & Destructor Documentation

◆ BodyStream()

astra::BodyStream::BodyStream ( astra_streamconnection_t connection )
inlineexplicit

default constructs

Parameters
[in] connection

Member Function Documentation

◆ get_body_features()

BodyTrackingFeatureFlags astra::BodyStream::get_body_features ( astra_body_id_t id )
inline

get body features

Returns
body features

◆ get_default_body_features()

BodyTrackingFeatureFlags astra::BodyStream::get_default_body_features ( )
inline

get default body features

Returns
default body features

◆ get_skeleton_optimization()

SkeletonOptimization astra::BodyStream::get_skeleton_optimization ( )
inline

get skeleton optimization

Returns
skeleton optimization

◆ get_skeleton_profile()

SkeletonProfile astra::BodyStream::get_skeleton_profile ( )
inline

get skeleton profile

Returns
skeleton profile

◆ set_body_features()

void astra::BodyStream::set_body_features | ( | astra_body_id_t | id,
 |  | BodyTrackingFeatureFlags | features
 | ) |  |
inline

set body features

Parameters
[in] body features

◆ set_default_body_features()

void astra::BodyStream::set_default_body_features ( BodyTrackingFeatureFlags features )
inline

set default body features

Parameters
[in] default body features

◆ set_skeleton_optimization()

void astra::BodyStream::set_skeleton_optimization ( SkeletonOptimization skeletonOptimization )
inline

set skeleton optimization

Parameters
[in] skeleton optimization

◆ set_skeleton_profile()

void astra::BodyStream::set_skeleton_profile ( SkeletonProfile skeletonProfile )
inline

set skeleton profile

Parameters
[in] skeleton profile
The documentation for this class was generated from the following file:
  • Body.hpp


Astra SDK: astra::ColorStream Class Reference

  • astra
  • ColorStream
Public Member Functions | Static Public Attributes | List of all members
astra::ColorStream Class Reference
C++ Reference

A color stream. More...

#include <Color.hpp>

Inheritance diagram for astra::ColorStream:
astra::ImageStream astra::DataStream

Public Member Functions

ColorStream (astra_streamconnection_t connection)
- Public Member Functions inherited from astra::ImageStream
ImageStream (astra_streamconnection_t connection)
float | hFov () const
get horizontal fov More...
float | vFov () const
get vertical fov More...
astra_usb_info_t | usb_info () const
get usb_info More...
bool | mirroring_enabled () const
get is mirroring More...
void | enable_mirroring (bool mirroring)
enable mirroring More...
std::vector< ImageStreamMode > | available_modes () const
get available_modes More...
ImageStreamMode | mode () const
get current image mode More...
void | set_mode (const ImageStreamMode &mode)
set current image mode More...
- Public Member Functions inherited from astra::DataStream
DataStream (astra_streamconnection_t connection)
default constructs More...
bool | is_available ()
start stream More...
void | start ()
start stream
void | stop ()
stop stream

Static Public Attributes

static const astra_stream_type_t id = ASTRA_STREAM_COLOR

Detailed Description

A color stream.

A color stream.

Examples:
ColorizedBodyViewer-SFML\main.cpp, ColorReaderEventCPP\main.cpp, MaskedColorViewer-SFML\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleColorViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.
The documentation for this class was generated from the following file:
  • Color.hpp


Astra SDK: astra::ColorFrame Class Reference

  • astra
  • ColorFrame
Public Member Functions | List of all members
astra::ColorFrame Class Reference
C++ Reference

color frame of rgb format More...

#include <Color.hpp>

Inheritance diagram for astra::ColorFrame:
astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR >

Public Member Functions

ColorFrame (astra_imageframe_t frame)
- Public Member Functions inherited from astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR >
ImageFrame (astra_imageframe_t frame, astra_pixel_format_t expected_format)
Default constructs. More...
const bool | is_valid () const
get is vaild More...
const int | width () const
get width More...
const int | height () const
get height More...
const std::uint8_t | bytes_per_pixel () const
get bytes per pixel More...
const astra_frame_index_t | frame_index () const
get frame index More...
const astra_imageframe_t | handle () const
get handle More...
const RgbPixel * | data () const
get data pointer More...
const size_t | byte_length () const
get byte length More...
const size_t | length () const
get length More...
void | copy_to (RgbPixel *buffer) const
copy to buffer More...

Additional Inherited Members

- Static Public Member Functions inherited from astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR >
static astra_stream_type_t | stream_type ()
get stream type More...
static TFrameType | acquire (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype)
acquire frame More...

Detailed Description

color frame of rgb format

color frame of rgb format

Examples:
ColorReaderEventCPP\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleColorViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.
The documentation for this class was generated from the following file:
  • Color.hpp


Astra SDK: astra::RawColorFrame Class Reference

  • astra
  • RawColorFrame
Public Member Functions | List of all members
astra::RawColorFrame Class Reference
C++ Reference

color frame of raw format More...

#include <Color.hpp>

Inheritance diagram for astra::RawColorFrame:
astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR >

Public Member Functions

RawColorFrame (astra_imageframe_t frame)
- Public Member Functions inherited from astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR >
ImageFrame (astra_imageframe_t frame, astra_pixel_format_t expected_format)
Default constructs. More...
const bool | is_valid () const
get is vaild More...
const int | width () const
get width More...
const int | height () const
get height More...
const std::uint8_t | bytes_per_pixel () const
get bytes per pixel More...
const astra_frame_index_t | frame_index () const
get frame index More...
const astra_imageframe_t | handle () const
get handle More...
const uint8_t * | data () const
get data pointer More...
const size_t | byte_length () const
get byte length More...
const size_t | length () const
get length More...
void | copy_to (uint8_t *buffer) const
copy to buffer More...

Additional Inherited Members

- Static Public Member Functions inherited from astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR >
static astra_stream_type_t | stream_type ()
get stream type More...
static TFrameType | acquire (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype)
acquire frame More...

Detailed Description

color frame of raw format

color frame of raw format

The documentation for this class was generated from the following file:
  • Color.hpp


Astra SDK: astra::ColorizedBodyStream Class Reference

  • astra
  • ColorizedBodyStream
Public Member Functions | Static Public Attributes | List of all members
astra::ColorizedBodyStream Class Reference
C++ Reference

A Colorized Body Stream. More...

#include <ColorizedBody.hpp>

Inheritance diagram for astra::ColorizedBodyStream:
astra::DataStream

Public Member Functions

ColorizedBodyStream (astra_streamconnection_t connection)
- Public Member Functions inherited from astra::DataStream
DataStream (astra_streamconnection_t connection)
default constructs More...
bool | is_available ()
start stream More...
void | start ()
start stream
void | stop ()
stop stream

Static Public Attributes

static const astra_stream_type_t id = ASTRA_STREAM_COLORIZED_BODY

Detailed Description

A Colorized Body Stream.

A Colorized Body Stream

Examples:
ColorizedBodyViewer-SFML\main.cpp.
The documentation for this class was generated from the following file:
  • ColorizedBody.hpp


Astra SDK: astra::ColorizedBodyFrame Class Reference

  • astra
  • ColorizedBodyFrame
Public Member Functions | List of all members
astra::ColorizedBodyFrame Class Reference
C++ Reference

A Colorized Body Frame. More...

#include <ColorizedBody.hpp>

Inheritance diagram for astra::ColorizedBodyFrame:
astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY >

Public Member Functions

ColorizedBodyFrame (astra_imageframe_t frame)
- Public Member Functions inherited from astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY >
ImageFrame (astra_imageframe_t frame, astra_pixel_format_t expected_format)
Default constructs. More...
const bool | is_valid () const
get is vaild More...
const int | width () const
get width More...
const int | height () const
get height More...
const std::uint8_t | bytes_per_pixel () const
get bytes per pixel More...
const astra_frame_index_t | frame_index () const
get frame index More...
const astra_imageframe_t | handle () const
get handle More...
const RgbaPixel * | data () const
get data pointer More...
const size_t | byte_length () const
get byte length More...
const size_t | length () const
get length More...
void | copy_to (RgbaPixel *buffer) const
copy to buffer More...

Additional Inherited Members

- Static Public Member Functions inherited from astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY >
static astra_stream_type_t | stream_type ()
get stream type More...
static TFrameType | acquire (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype)
acquire frame More...

Detailed Description

A Colorized Body Frame.

A Colorized Body Frame

Examples:
ColorizedBodyViewer-SFML\main.cpp.
The documentation for this class was generated from the following file:
  • ColorizedBody.hpp


Astra SDK: astra::DebugHandStream Class Reference

  • astra
  • DebugHandStream
Public Member Functions | Static Public Attributes | List of all members
astra::DebugHandStream Class Reference
C++ Reference

A Debug Hand Stream. More...

#include <DebugHand.hpp>

Inheritance diagram for astra::DebugHandStream:
astra::DataStream

Public Member Functions

DebugHandStream (astra_streamconnection_t connection)
default constructs More...
void | set_view_type (DebugHandViewType view)
set view type More...
void | set_use_mouse_probe (bool useMouseProbe)
set is use mouse probe More...
void | set_mouse_position (Vector2f position)
set mouse position More...
void | set_pause_input (bool pauseInput)
set pause input More...
void | set_lock_spawn_point (bool lockSpawnPoint)
set lock spawn point More...
DebugHandViewType | get_view_type () const
get view type More...
- Public Member Functions inherited from astra::DataStream
DataStream (astra_streamconnection_t connection)
default constructs More...
bool | is_available ()
start stream More...
void | start ()
start stream
void | stop ()
stop stream

Static Public Attributes

static const astra_stream_type_t id = ASTRA_STREAM_DEBUG_HAND

Detailed Description

A Debug Hand Stream.

A Debug Hand Stream. for debug use

Constructor & Destructor Documentation

◆ DebugHandStream()

astra::DebugHandStream::DebugHandStream ( astra_streamconnection_t connection )
inlineexplicit

default constructs

Parameters
[in] connection

Member Function Documentation

◆ get_view_type()

DebugHandViewType astra::DebugHandStream::get_view_type ( ) const
inline

get view type

Returns
Debug Hand View Type

◆ set_lock_spawn_point()

void astra::DebugHandStream::set_lock_spawn_point ( bool lockSpawnPoint )
inline

set lock spawn point

Parameters
[in] lock spawn point

◆ set_mouse_position()

void astra::DebugHandStream::set_mouse_position ( Vector2f position )
inline

set mouse position

Parameters
[in] mouse position

◆ set_pause_input()

void astra::DebugHandStream::set_pause_input ( bool pauseInput )
inline

set pause input

Parameters
[in] pause input

◆ set_use_mouse_probe()

void astra::DebugHandStream::set_use_mouse_probe ( bool useMouseProbe )
inline

set is use mouse probe

Parameters
[in] is use mouse probe

◆ set_view_type()

void astra::DebugHandStream::set_view_type ( DebugHandViewType view )
inline

set view type

Parameters
[in] Debug Hand View Type
The documentation for this class was generated from the following file:
  • DebugHand.hpp


Astra SDK: astra::DebugHandFrame Class Reference

  • astra
  • DebugHandFrame
Public Member Functions | List of all members
astra::DebugHandFrame Class Reference
C++ Reference

A Debug Hand Frame. More...

#include <DebugHand.hpp>

Inheritance diagram for astra::DebugHandFrame:
astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND >

Public Member Functions

DebugHandFrame (astra_imageframe_t frame)
default constructs More...
- Public Member Functions inherited from astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND >
ImageFrame (astra_imageframe_t frame, astra_pixel_format_t expected_format)
Default constructs. More...
const bool | is_valid () const
get is vaild More...
const int | width () const
get width More...
const int | height () const
get height More...
const std::uint8_t | bytes_per_pixel () const
get bytes per pixel More...
const astra_frame_index_t | frame_index () const
get frame index More...
const astra_imageframe_t | handle () const
get handle More...
const RgbPixel * | data () const
get data pointer More...
const size_t | byte_length () const
get byte length More...
const size_t | length () const
get length More...
void | copy_to (RgbPixel *buffer) const
copy to buffer More...

Additional Inherited Members

- Static Public Member Functions inherited from astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND >
static astra_stream_type_t | stream_type ()
get stream type More...
static TFrameType | acquire (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype)
acquire frame More...

Detailed Description

A Debug Hand Frame.

A Debug Hand Frame

Constructor & Destructor Documentation

◆ DebugHandFrame()

astra::DebugHandFrame::DebugHandFrame ( astra_imageframe_t frame )
inline

default constructs

Parameters
[in] frame
The documentation for this class was generated from the following file:
  • DebugHand.hpp


Astra SDK: astra::CoordinateMapper Class Reference

  • astra
  • CoordinateMapper
Public Member Functions | List of all members
astra::CoordinateMapper Class Reference
C++ Reference

CoordinateMapper. More...

#include <Depth.hpp>

Public Member Functions

CoordinateMapper (astra_depthstream_t depthStream)
Constructs.
CoordinateMapper (const CoordinateMapper &rhs)
copy Constructs
CoordinateMapper | operator= (const CoordinateMapper &rhs)
copy Constructs
astra::Vector3f | convert_depth_to_world (astra::Vector3f depthPosition) const
convert depth coor to world coor More...
Vector3f | convert_world_to_depth (Vector3f worldPosition) const
convert depth coor to world coor More...
void | convert_depth_to_world (float depthX, float depthY, float depthZ, float &worldX, float &worldY, float &worldZ) const
convert depth coor to world coor More...
void | convert_world_to_depth (float worldX, float worldY, float worldZ, float &depthX, float &depthY, float &depthZ) const
convert world coor to depth coor More...

Detailed Description

CoordinateMapper.

Can convert coordinate system of point.

Examples:
ColorizedBodyViewer-SFML\main.cpp, DepthReaderEventCPP\main.cpp, MaskedColorViewer-SFML\main.cpp, and SimpleDepthViewer-SFML\main.cpp.

Member Function Documentation

◆ convert_depth_to_world() [1/2]

astra::Vector3f astra::CoordinateMapper::convert_depth_to_world ( astra::Vector3f depthPosition ) const
inline

convert depth coor to world coor

Parameters
[in] dpeth position
Returns
world position
Examples:
DepthReaderEventCPP\main.cpp, and SimpleDepthViewer-SFML\main.cpp.

◆ convert_depth_to_world() [2/2]

void astra::CoordinateMapper::convert_depth_to_world | ( | float | depthX,
 |  | float | depthY,
 |  | float | depthZ,
 |  | float & | worldX,
 |  | float & | worldY,
 |  | float & | worldZ
 | ) |  | const
 inline

convert depth coor to world coor

Parameters
[in] | depth | x
[in] | depth | y
[in] | depth | z
[out] | world | x
[out] | world | y
[out] | world | z

◆ convert_world_to_depth() [1/2]

Vector3f astra::CoordinateMapper::convert_world_to_depth ( Vector3f worldPosition ) const
inline

convert depth coor to world coor

Parameters
[in] world position
Returns
dpeth position
Examples:
DepthReaderEventCPP\main.cpp.

◆ convert_world_to_depth() [2/2]

void astra::CoordinateMapper::convert_world_to_depth | ( | float | worldX,
 |  | float | worldY,
 |  | float | worldZ,
 |  | float & | depthX,
 |  | float & | depthY,
 |  | float & | depthZ
 | ) |  | const
 inline

convert world coor to depth coor

Parameters
[in] | world | x
[in] | world | y
[in] | world | z
[out] | depth | x
[out] | depth | y
[out] | depth | z
The documentation for this class was generated from the following file:
  • Depth.hpp


Astra SDK: astra::DepthStream Class Reference

  • astra
  • DepthStream
Public Member Functions | Static Public Attributes | List of all members
astra::DepthStream Class Reference
C++ Reference

A Depth Stream. More...

#include <Depth.hpp>

Inheritance diagram for astra::DepthStream:
astra::ImageStream astra::DataStream

Public Member Functions

DepthStream (astra_streamconnection_t connection)
astra_conversion_cache_t | depth_to_world_data () const
get world conversion More...
bool | registration_enabled () const
return is registration enabled More...
void | enable_registration (bool enable)
enable registration More...
void | serial_number (char *serialnumber, uint32_t length) const
get serial number More...
std::string | serial_number () const
get serial number More...
std::uint32_t | chip_id () const
get chip id More...
const CoordinateMapper & | coordinateMapper () const
get Coordinate Mapper More...
- Public Member Functions inherited from astra::ImageStream
ImageStream (astra_streamconnection_t connection)
float | hFov () const
get horizontal fov More...
float | vFov () const
get vertical fov More...
astra_usb_info_t | usb_info () const
get usb_info More...
bool | mirroring_enabled () const
get is mirroring More...
void | enable_mirroring (bool mirroring)
enable mirroring More...
std::vector< ImageStreamMode > | available_modes () const
get available_modes More...
ImageStreamMode | mode () const
get current image mode More...
void | set_mode (const ImageStreamMode &mode)
set current image mode More...
- Public Member Functions inherited from astra::DataStream
DataStream (astra_streamconnection_t connection)
default constructs More...
bool | is_available ()
start stream More...
void | start ()
start stream
void | stop ()
stop stream

Static Public Attributes

static const astra_stream_type_t id = ASTRA_STREAM_DEPTH

Detailed Description

A Depth Stream.

Depth Stream is a stream form depth sensor device.

Examples:
ColorizedBodyViewer-SFML\main.cpp, DepthReaderEventCPP\main.cpp, MaskedColorViewer-SFML\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleBodyViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

Member Function Documentation

◆ chip_id()

std::uint32_t astra::DepthStream::chip_id ( ) const
inline

get chip id

Returns
chip id
Examples:
DepthReaderEventCPP\main.cpp.

◆ coordinateMapper()

const CoordinateMapper& astra::DepthStream::coordinateMapper ( ) const
inline

get Coordinate Mapper

Returns
Coordinate Mapper

◆ depth_to_world_data()

astra_conversion_cache_t astra::DepthStream::depth_to_world_data ( ) const
inline

get world conversion

Returns
world conversion

◆ enable_registration()

void astra::DepthStream::enable_registration ( bool enable )
inline

enable registration

Parameters
[in] enable

◆ registration_enabled()

bool astra::DepthStream::registration_enabled ( ) const
inline

return is registration enabled

Returns
registration enabled

◆ serial_number() [1/2]

void astra::DepthStream::serial_number | ( | char * | serialnumber,
 |  | uint32_t | length
 | ) |  | const
 inline

get serial number

Parameters

◆ serial_number() [2/2]

std::string astra::DepthStream::serial_number ( ) const
inline

get serial number

Returns
serial number
The documentation for this class was generated from the following file:
  • Depth.hpp


Astra SDK: astra::DepthFrame Class Reference

  • astra
  • DepthFrame
Public Member Functions | List of all members
astra::DepthFrame Class Reference
C++ Reference

A Depth Frame. More...

#include <Depth.hpp>

Inheritance diagram for astra::DepthFrame:
astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH >

Public Member Functions

DepthFrame (astra_imageframe_t frame)
- Public Member Functions inherited from astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH >
ImageFrame (astra_imageframe_t frame, astra_pixel_format_t expected_format)
Default constructs. More...
const bool | is_valid () const
get is vaild More...
const int | width () const
get width More...
const int | height () const
get height More...
const std::uint8_t | bytes_per_pixel () const
get bytes per pixel More...
const astra_frame_index_t | frame_index () const
get frame index More...
const astra_imageframe_t | handle () const
get handle More...
const int16_t * | data () const
get data pointer More...
const size_t | byte_length () const
get byte length More...
const size_t | length () const
get length More...
void | copy_to (int16_t *buffer) const
copy to buffer More...

Additional Inherited Members

- Static Public Member Functions inherited from astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH >
static astra_stream_type_t | stream_type ()
get stream type More...
static TFrameType | acquire (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype)
acquire frame More...

Detailed Description

A Depth Frame.

Depth Frame of short format, 1 mm per value;

Examples:
ColorizedBodyViewer-SFML\main.cpp, DepthReaderEventCPP\main.cpp, MaskedColorViewer-SFML\main.cpp, SimpleBodyViewer-SFML\main.cpp, and SimpleDepthViewer-SFML\main.cpp.
The documentation for this class was generated from the following file:
  • Depth.hpp


Astra SDK: astra::HandPoint Class Reference

  • astra
  • HandPoint
Public Member Functions | List of all members
astra::HandPoint Class Reference
C++ Reference

Hand Point struct. More...

#include <Hand.hpp>

Inheritance diagram for astra::HandPoint:
astra_handpoint_t

Public Member Functions

HandPoint (std::int32_t trackingId, astra_handstatus_t status, Vector2i depthPosition, Vector3f worldPosition, Vector3f worldDeltaPosition)
constructs More...
HandPoint (const astra_handpoint_t &handPoint)
constructs More...
HandPoint & | operator= (const ::astra_handpoint_t &handPoint)
copy constructs More...
operator::astra_handpoint_t * ()
get astra_handpoint_t point More...
operator const ::astra_handpoint_t * () const
get astra_handpoint_t point More...
std::int32_t | tracking_id () const
get tracking id More...
astra_handstatus_t | status () const
get status More...
Vector2i | depth_position () const
get depth position More...
Vector3f | world_position () const
get world position More...
Vector3f | world_delta_position () const
get world delta position More...

Additional Inherited Members

- Public Attributes inherited from astra_handpoint_t
int32_t | trackingId
astra_handstatus_t | status
astra_vector2i_t | depthPosition
astra_vector3f_t | worldPosition
astra_vector3f_t | worldDeltaPosition

Detailed Description

Hand Point struct.

Hand Point struct

Examples:
SimpleHandViewer-SFML\main.cpp.

Constructor & Destructor Documentation

◆ HandPoint() [1/2]

astra::HandPoint::HandPoint | ( | std::int32_t | trackingId,
 |  | astra_handstatus_t | status,
 |  | Vector2i | depthPosition,
 |  | Vector3f | worldPosition,
 |  | Vector3f | worldDeltaPosition
 | ) |  |
inline

constructs

Parameters
[in] | tracking | id
[in] | status
[in] | depth | position
[in] | world | position
[in] | world | delta position

◆ HandPoint() [2/2]

astra::HandPoint::HandPoint ( const astra_handpoint_t & handPoint )
inline

constructs

Parameters
[in] handPoint

Member Function Documentation

◆ depth_position()

Vector2i astra::HandPoint::depth_position ( ) const
inline

get depth position

Returns
depth position
Examples:
SimpleHandViewer-SFML\main.cpp.

◆ operator const ::astra_handpoint_t *()

astra::HandPoint::operator const ::astra_handpoint_t * ( ) const
inline

get astra_handpoint_t point

Returns
const astra_handpoint_t point

◆ operator::astra_handpoint_t *()

astra::HandPoint::operator::astra_handpoint_t * ( )
inline

get astra_handpoint_t point

Returns
astra_handpoint_t point

◆ operator=()

HandPoint& astra::HandPoint::operator= ( const ::astra_handpoint_t & handPoint )
inline

copy constructs

Parameters
[in] handPoint

◆ status()

astra_handstatus_t astra::HandPoint::status ( ) const
inline

get status

Returns
status
Examples:
SimpleHandViewer-SFML\main.cpp.

◆ tracking_id()

std::int32_t astra::HandPoint::tracking_id ( ) const
inline

get tracking id

Returns
tracking_id
Examples:
SimpleHandViewer-SFML\main.cpp.

◆ world_delta_position()

Vector3f astra::HandPoint::world_delta_position ( ) const
inline

get world delta position

Returns
world delta position

◆ world_position()

Vector3f astra::HandPoint::world_position ( ) const
inline

get world position

Returns
world position
Examples:
SimpleHandViewer-SFML\main.cpp.
The documentation for this class was generated from the following file:
  • Hand.hpp


Astra SDK: astra::HandStream Class Reference

  • astra
  • HandStream
Public Member Functions | Static Public Attributes | List of all members
astra::HandStream Class Reference
C++ Reference

A Hand Stream. More...

#include <Hand.hpp>

Inheritance diagram for astra::HandStream:
astra::DataStream

Public Member Functions

HandStream (astra_streamconnection_t connection)
constructs More...
bool | get_include_candidate_points () const
get is include candidate points More...
void | set_include_candidate_points (bool includeCandidatePoints)
set is include candidate points More...
- Public Member Functions inherited from astra::DataStream
DataStream (astra_streamconnection_t connection)
default constructs More...
bool | is_available ()
start stream More...
void | start ()
start stream
void | stop ()
stop stream

Static Public Attributes

static const astra_stream_type_t id = ASTRA_STREAM_HAND

Detailed Description

A Hand Stream.

A Hand Stream

Examples:
SimpleHandViewer-SFML\main.cpp.

Constructor & Destructor Documentation

◆ HandStream()

astra::HandStream::HandStream ( astra_streamconnection_t connection )
inlineexplicit

constructs

Parameters
[in] stream connection

Member Function Documentation

◆ get_include_candidate_points()

bool astra::HandStream::get_include_candidate_points ( ) const
inline

get is include candidate points

Returns
is include candidate points

◆ set_include_candidate_points()

void astra::HandStream::set_include_candidate_points ( bool includeCandidatePoints )
inline

set is include candidate points

Parameters
[in] is include candidate points
The documentation for this class was generated from the following file:
  • Hand.hpp


Astra SDK: astra::HandFrame Class Reference

  • astra
  • HandFrame
Public Types | Public Member Functions | Static Public Member Functions | List of all members
astra::HandFrame Class Reference
C++ Reference

A Hand Data Frame. More...

#include <Hand.hpp>

Public Types

using HandPointList = std::vector< HandPoint >

Public Member Functions

HandFrame (astra_handframe_t handFrame)
constructs More...
bool | is_valid () const
get is valid More...
astra_handframe_t | handle () const
get handle More...
size_t | handpoint_count () const
get hand Points count More...
const HandPointList & | handpoints () const
get hand Points More...
astra_frame_index_t | frame_index () const
get frame index More...

Static Public Member Functions

template<typename TFrameType >
static TFrameType acquire (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype)
set is include candidate points More...

Detailed Description

A Hand Data Frame.

A Hand Data Frame

Examples:
SimpleHandViewer-SFML\main.cpp.

Constructor & Destructor Documentation

◆ HandFrame()

astra::HandFrame::HandFrame ( astra_handframe_t handFrame )
inline

constructs

Parameters
[in] handFrame

Member Function Documentation

◆ acquire()

template<typename TFrameType >
static TFrameType astra::HandFrame::acquire | ( | astra_reader_frame_t | readerFrame,
 |  | astra_stream_subtype_t | subtype
 | ) |  |
inlinestatic

set is include candidate points

Parameters
[in] is include candidate points

◆ frame_index()

astra_frame_index_t astra::HandFrame::frame_index ( ) const
inline

get frame index

Returns
frame index

◆ handle()

astra_handframe_t astra::HandFrame::handle ( ) const
inline

get handle

Returns
handle

◆ handpoint_count()

size_t astra::HandFrame::handpoint_count ( ) const
inline

get hand Points count

Returns
hand Points count

◆ handpoints()

const HandPointList& astra::HandFrame::handpoints ( ) const
inline

get hand Points

Returns
hand Points
Examples:
SimpleHandViewer-SFML\main.cpp.

◆ is_valid()

bool astra::HandFrame::is_valid ( ) const
inline

get is valid

Returns
is valid
The documentation for this class was generated from the following file:
  • Hand.hpp


Astra SDK: astra::RgbPixel Struct Reference

  • astra
  • RgbPixel
Public Member Functions | List of all members
astra::RgbPixel Struct Reference
C++ Reference

rgb pixel struct More...

#include <Image.hpp>

Inheritance diagram for astra::RgbPixel:
astra_rgb_pixel_t

Public Member Functions

RgbPixel ()
Default constructs all zero.
RgbPixel (std::uint8_t r, std::uint8_t g, std::uint8_t b)
constructs More...

Additional Inherited Members

- Public Attributes inherited from astra_rgb_pixel_t
uint8_t | r
uint8_t | g
uint8_t | b

Detailed Description

rgb pixel struct

Examples:
ColorReaderEventCPP\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleColorViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, SimpleHandViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

Constructor & Destructor Documentation

◆ RgbPixel()

astra::RgbPixel::RgbPixel | ( | std::uint8_t | r,
 |  | std::uint8_t | g,
 |  | std::uint8_t | b
 | ) |  |
inline

constructs

Parameters
[in] | red | value
[in] | green | value
[in] | blue | value
The documentation for this struct was generated from the following file:
  • Image.hpp


Astra SDK: astra::RgbaPixel Struct Reference

  • astra
  • RgbaPixel
Public Member Functions | List of all members
astra::RgbaPixel Struct Reference
C++ Reference

rgba pixel struct More...

#include <Image.hpp>

Inheritance diagram for astra::RgbaPixel:
astra_rgba_pixel_t

Public Member Functions

RgbaPixel ()
Default constructs all zero.
RgbaPixel (std::uint8_t r, std::uint8_t g, std::uint8_t b, std::uint8_t alpha)
constructs More...

Additional Inherited Members

- Public Attributes inherited from astra_rgba_pixel_t
uint8_t | r
uint8_t | g
uint8_t | b
uint8_t | alpha

Detailed Description

rgba pixel struct

Examples:
ColorizedBodyViewer-SFML\main.cpp, and MaskedColorViewer-SFML\main.cpp.

Constructor & Destructor Documentation

◆ RgbaPixel()

astra::RgbaPixel::RgbaPixel | ( | std::uint8_t | r,
 |  | std::uint8_t | g,
 |  | std::uint8_t | b,
 |  | std::uint8_t | alpha
 | ) |  |
inline

constructs

Parameters
[in] | red | value
[in] | green | value
[in] | blue | value
[in] | alpha | value
The documentation for this struct was generated from the following file:
  • Image.hpp


Astra SDK: astra::ImageStreamMode Class Reference

  • astra
  • ImageStreamMode
Public Member Functions | Friends | List of all members
astra::ImageStreamMode Class Reference
C++ Reference

Image Stream Mode. More...

#include <Image.hpp>

Inheritance diagram for astra::ImageStreamMode:
astra_imagestream_mode_t

Public Member Functions

ImageStreamMode ()
Default constructs.
ImageStreamMode (std::uint32_t width, std::uint32_t height, std::uint8_t fps, astra_pixel_format_t format)
constructs More...
ImageStreamMode (const ::astra_imagestream_mode_t &mode)
copy constructs More...
ImageStreamMode & | operator= (const ::astra_imagestream_mode_t &mode)
copy constructs More...
operator::astra_imagestream_mode_t * ()
operator const ::astra_imagestream_mode_t * () const
std::uint8_t | fps () const
get fps More...
void | set_fps (std::uint8_t fps)
set fps More...
const std::uint8_t | bytes_per_pixel () const
get bytes per pixel More...
std::uint32_t | width () const
get width More...
void | set_width (std::uint32_t width)
set width More...
std::uint32_t | height () const
get height More...
void | set_height (std::uint32_t height)
set height More...
astra_pixel_format_t | pixel_format () const
get height More...
void | set_pixel_format (astra_pixel_format_t format)
set fps More...

Friends

std::ostream & operator<< (std::ostream &os, const ImageStreamMode &ism)

Detailed Description

Image Stream Mode.

Examples:
ColorizedBodyViewer-SFML\main.cpp, MaskedColorViewer-SFML\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleBodyViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

Constructor & Destructor Documentation

◆ ImageStreamMode() [1/2]

astra::ImageStreamMode::ImageStreamMode | ( | std::uint32_t | width,
 |  | std::uint32_t | height,
 |  | std::uint8_t | fps,
 |  | astra_pixel_format_t | format
 | ) |  |
inline

constructs

Parameters
[in] | width
[in] | height
[in] | fps
[in] | format

◆ ImageStreamMode() [2/2]

astra::ImageStreamMode::ImageStreamMode ( const ::astra_imagestream_mode_t & mode )
inline

copy constructs

Parameters
[in] other mode

Member Function Documentation

◆ bytes_per_pixel()

const std::uint8_t astra::ImageStreamMode::bytes_per_pixel ( ) const
inline

get bytes per pixel

Returns
bytes per pixel

◆ fps()

std::uint8_t astra::ImageStreamMode::fps ( ) const
inline

get fps

Returns
fps

◆ height()

std::uint32_t astra::ImageStreamMode::height ( ) const
inline

get height

Returns
height

◆ operator=()

ImageStreamMode& astra::ImageStreamMode::operator= ( const ::astra_imagestream_mode_t & mode )
inline

copy constructs

Parameters
[in] other mode

◆ pixel_format()

astra_pixel_format_t astra::ImageStreamMode::pixel_format ( ) const
inline

get height

Returns
pixel format

◆ set_fps()

void astra::ImageStreamMode::set_fps ( std::uint8_t fps )
inline

set fps

Parameters
[in] fps
Examples:
SimpleDepthViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

◆ set_height()

void astra::ImageStreamMode::set_height ( std::uint32_t height )
inline

set height

Parameters
[in] height
Examples:
SimpleDepthViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

◆ set_pixel_format()

void astra::ImageStreamMode::set_pixel_format ( astra_pixel_format_t format )
inline

set fps

Parameters
[in] pixel format
Examples:
SimpleDepthViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

◆ set_width()

void astra::ImageStreamMode::set_width ( std::uint32_t width )
inline

set width

Parameters
[in] width
Examples:
ColorizedBodyViewer-SFML\main.cpp, MaskedColorViewer-SFML\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleBodyViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

◆ width()

std::uint32_t astra::ImageStreamMode::width ( ) const
inline

get width

Returns
width
The documentation for this class was generated from the following file:
  • Image.hpp


Astra SDK: astra::ImageStream Class Reference

  • astra
  • ImageStream
Public Member Functions | List of all members
astra::ImageStream Class Reference
C++ Reference

basic Image Stream More...

#include <Image.hpp>

Inheritance diagram for astra::ImageStream:
astra::DataStream astra::ColorStream astra::DepthStream astra::InfraredStream

Public Member Functions

ImageStream (astra_streamconnection_t connection)
float | hFov () const
get horizontal fov More...
float | vFov () const
get vertical fov More...
astra_usb_info_t | usb_info () const
get usb_info More...
bool | mirroring_enabled () const
get is mirroring More...
void | enable_mirroring (bool mirroring)
enable mirroring More...
std::vector< ImageStreamMode > | available_modes () const
get available_modes More...
ImageStreamMode | mode () const
get current image mode More...
void | set_mode (const ImageStreamMode &mode)
set current image mode More...
- Public Member Functions inherited from astra::DataStream
DataStream (astra_streamconnection_t connection)
default constructs More...
bool | is_available ()
start stream More...
void | start ()
start stream
void | stop ()
stop stream

Detailed Description

basic Image Stream

Member Function Documentation

◆ available_modes()

std::vector<ImageStreamMode> astra::ImageStream::available_modes ( ) const
inline

get available_modes

Returns
available modes

◆ enable_mirroring()

void astra::ImageStream::enable_mirroring ( bool mirroring )
inline

enable mirroring

Parameters

◆ hFov()

float astra::ImageStream::hFov ( ) const
inline

get horizontal fov

Returns
horizontal fov

◆ mirroring_enabled()

bool astra::ImageStream::mirroring_enabled ( ) const
inline

get is mirroring

Returns
is mirroring

◆ mode()

ImageStreamMode astra::ImageStream::mode ( ) const
inline

get current image mode

Returns
current image mode
Examples:
SimpleDepthViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

◆ set_mode()

void astra::ImageStream::set_mode ( const ImageStreamMode & mode )
inline

set current image mode

Parameters
[in] image mode

◆ usb_info()

astra_usb_info_t astra::ImageStream::usb_info ( ) const
inline

get usb_info

Returns
usb_info

◆ vFov()

float astra::ImageStream::vFov ( ) const
inline

get vertical fov

Returns
vertical fov
The documentation for this class was generated from the following file:
  • Image.hpp


Astra SDK: astra::ImageFrame< TDataType, TStreamType > Class Template Reference

  • astra
  • ImageFrame
Public Member Functions | Static Public Member Functions | List of all members
astra::ImageFrame< TDataType, TStreamType > Class Template Reference
C++ Reference

Basic Image Frame. More...

#include <Image.hpp>

Public Member Functions

ImageFrame (astra_imageframe_t frame, astra_pixel_format_t expected_format)
Default constructs. More...
const bool | is_valid () const
get is vaild More...
const int | width () const
get width More...
const int | height () const
get height More...
const std::uint8_t | bytes_per_pixel () const
get bytes per pixel More...
const astra_frame_index_t | frame_index () const
get frame index More...
const astra_imageframe_t | handle () const
get handle More...
const TDataType * | data () const
get data pointer More...
const size_t | byte_length () const
get byte length More...
const size_t | length () const
get length More...
void | copy_to (TDataType *buffer) const
copy to buffer More...

Static Public Member Functions

static astra_stream_type_t | stream_type ()
get stream type More...
template<typename TFrameType >
static TFrameType | acquire (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype)
acquire frame More...

Detailed Description

template<typename TDataType, astra_stream_type_t TStreamType>
class astra::ImageFrame< TDataType, TStreamType >

Basic Image Frame.

Constructor & Destructor Documentation

◆ ImageFrame()

template<typename TDataType, astra_stream_type_t TStreamType>
astra::ImageFrame< TDataType, TStreamType >::ImageFrame | ( | astra_imageframe_t | frame,
 |  | astra_pixel_format_t | expected_format
 | ) |  |
inline

Default constructs.

Parameters
[in] | frame
[in] | expected_format

Member Function Documentation

◆ acquire()

template<typename TDataType, astra_stream_type_t TStreamType>
template<typename TFrameType >
static TFrameType astra::ImageFrame< TDataType, TStreamType >::acquire | ( | astra_reader_frame_t | readerFrame,
 |  | astra_stream_subtype_t | subtype
 | ) |  |
inlinestatic

acquire frame

Returns
a frame

◆ byte_length()

template<typename TDataType, astra_stream_type_t TStreamType>
const size_t astra::ImageFrame< TDataType, TStreamType >::byte_length ( ) const
inline

get byte length

Returns
byte length

◆ bytes_per_pixel()

template<typename TDataType, astra_stream_type_t TStreamType>
const std::uint8_t astra::ImageFrame< TDataType, TStreamType >::bytes_per_pixel ( ) const
inline

get bytes per pixel

Returns
bytes per pixel

◆ copy_to()

template<typename TDataType, astra_stream_type_t TStreamType>
void astra::ImageFrame< TDataType, TStreamType >::copy_to ( TDataType * buffer ) const
inline

copy to buffer

Parameters

◆ data()

template<typename TDataType, astra_stream_type_t TStreamType>
const TDataType* astra::ImageFrame< TDataType, TStreamType >::data ( ) const
inline

get data pointer

Returns
data pointer

◆ frame_index()

template<typename TDataType, astra_stream_type_t TStreamType>
const astra_frame_index_t astra::ImageFrame< TDataType, TStreamType >::frame_index ( ) const
inline

get frame index

Returns
frame index

◆ handle()

template<typename TDataType, astra_stream_type_t TStreamType>
const astra_imageframe_t astra::ImageFrame< TDataType, TStreamType >::handle ( ) const
inline

get handle

Returns
handle

◆ height()

template<typename TDataType, astra_stream_type_t TStreamType>
const int astra::ImageFrame< TDataType, TStreamType >::height ( ) const
inline

get height

Returns
height

◆ is_valid()

template<typename TDataType, astra_stream_type_t TStreamType>
const bool astra::ImageFrame< TDataType, TStreamType >::is_valid ( ) const
inline

get is vaild

Returns
is vaild

◆ length()

template<typename TDataType, astra_stream_type_t TStreamType>
const size_t astra::ImageFrame< TDataType, TStreamType >::length ( ) const
inline

get length

Returns
length

◆ stream_type()

template<typename TDataType, astra_stream_type_t TStreamType>
static astra_stream_type_t astra::ImageFrame< TDataType, TStreamType >::stream_type ( )
inlinestatic

get stream type

Returns
stream type

◆ width()

template<typename TDataType, astra_stream_type_t TStreamType>
const int astra::ImageFrame< TDataType, TStreamType >::width ( ) const
inline

get width

Returns
width
The documentation for this class was generated from the following file:
  • Image.hpp


Astra SDK: astra::InfraredStream Class Reference

  • astra
  • InfraredStream
Public Member Functions | Static Public Attributes | List of all members
astra::InfraredStream Class Reference
C++ Reference

A Infrared Stream. More...

#include <Infrared.hpp>

Inheritance diagram for astra::InfraredStream:
astra::ImageStream astra::DataStream

Public Member Functions

InfraredStream (astra_streamconnection_t connection)
- Public Member Functions inherited from astra::ImageStream
ImageStream (astra_streamconnection_t connection)
float | hFov () const
get horizontal fov More...
float | vFov () const
get vertical fov More...
astra_usb_info_t | usb_info () const
get usb_info More...
bool | mirroring_enabled () const
get is mirroring More...
void | enable_mirroring (bool mirroring)
enable mirroring More...
std::vector< ImageStreamMode > | available_modes () const
get available_modes More...
ImageStreamMode | mode () const
get current image mode More...
void | set_mode (const ImageStreamMode &mode)
set current image mode More...
- Public Member Functions inherited from astra::DataStream
DataStream (astra_streamconnection_t connection)
default constructs More...
bool | is_available ()
start stream More...
void | start ()
start stream
void | stop ()
stop stream

Static Public Attributes

static const astra_stream_type_t id = ASTRA_STREAM_INFRARED

Detailed Description

A Infrared Stream.

A Infrared Stream.

Examples:
MultiSensorViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.
The documentation for this class was generated from the following file:
  • Infrared.hpp


Astra SDK: astra::InfraredFrame16 Class Reference

  • astra
  • InfraredFrame16
Public Member Functions | List of all members
astra::InfraredFrame16 Class Reference
C++ Reference

A Infrared Frame use 16bit unsigned short format. More...

#include <Infrared.hpp>

Inheritance diagram for astra::InfraredFrame16:
astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED >

Public Member Functions

InfraredFrame16 (astra_imageframe_t frame)
- Public Member Functions inherited from astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED >
ImageFrame (astra_imageframe_t frame, astra_pixel_format_t expected_format)
Default constructs. More...
const bool | is_valid () const
get is vaild More...
const int | width () const
get width More...
const int | height () const
get height More...
const std::uint8_t | bytes_per_pixel () const
get bytes per pixel More...
const astra_frame_index_t | frame_index () const
get frame index More...
const astra_imageframe_t | handle () const
get handle More...
const uint16_t * | data () const
get data pointer More...
const size_t | byte_length () const
get byte length More...
const size_t | length () const
get length More...
void | copy_to (uint16_t *buffer) const
copy to buffer More...

Additional Inherited Members

- Static Public Member Functions inherited from astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED >
static astra_stream_type_t | stream_type ()
get stream type More...
static TFrameType | acquire (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype)
acquire frame More...

Detailed Description

A Infrared Frame use 16bit unsigned short format.

A Infrared Frame use 16bit unsigned short format.

Examples:
MultiSensorViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.
The documentation for this class was generated from the following file:
  • Infrared.hpp


Astra SDK: astra::InfraredFrameRgb Class Reference

  • astra
  • InfraredFrameRgb
Public Member Functions | List of all members
astra::InfraredFrameRgb Class Reference
C++ Reference

A Infrared Frame use rgb format. More...

#include <Infrared.hpp>

Inheritance diagram for astra::InfraredFrameRgb:
astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED >

Public Member Functions

InfraredFrameRgb (astra_imageframe_t frame)
- Public Member Functions inherited from astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED >
ImageFrame (astra_imageframe_t frame, astra_pixel_format_t expected_format)
Default constructs. More...
const bool | is_valid () const
get is vaild More...
const int | width () const
get width More...
const int | height () const
get height More...
const std::uint8_t | bytes_per_pixel () const
get bytes per pixel More...
const astra_frame_index_t | frame_index () const
get frame index More...
const astra_imageframe_t | handle () const
get handle More...
const RgbPixel * | data () const
get data pointer More...
const size_t | byte_length () const
get byte length More...
const size_t | length () const
get length More...
void | copy_to (RgbPixel *buffer) const
copy to buffer More...

Additional Inherited Members

- Static Public Member Functions inherited from astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED >
static astra_stream_type_t | stream_type ()
get stream type More...
static TFrameType | acquire (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype)
acquire frame More...

Detailed Description

A Infrared Frame use rgb format.

A Infrared Frame use rgb format.

Examples:
MultiSensorViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.
The documentation for this class was generated from the following file:
  • Infrared.hpp


Astra SDK: astra::MaskedColorStream Class Reference

  • astra
  • MaskedColorStream
Public Member Functions | Static Public Attributes | List of all members
astra::MaskedColorStream Class Reference
C++ Reference

A Masked Color Stream. More...

#include <MaskedColor.hpp>

Inheritance diagram for astra::MaskedColorStream:
astra::DataStream

Public Member Functions

MaskedColorStream (astra_streamconnection_t connection)
- Public Member Functions inherited from astra::DataStream
DataStream (astra_streamconnection_t connection)
default constructs More...
bool | is_available ()
start stream More...
void | start ()
start stream
void | stop ()
stop stream

Static Public Attributes

static const astra_stream_type_t id = ASTRA_STREAM_MASKED_COLOR

Detailed Description

A Masked Color Stream.

A Masked Color Stream.

Examples:
MaskedColorViewer-SFML\main.cpp.
The documentation for this class was generated from the following file:
  • MaskedColor.hpp


Astra SDK: astra::MaskedColorFrame Class Reference

  • astra
  • MaskedColorFrame
Public Member Functions | List of all members
astra::MaskedColorFrame Class Reference
C++ Reference

A Masked Color Frame of Masked Color Stream. More...

#include <MaskedColor.hpp>

Inheritance diagram for astra::MaskedColorFrame:
astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR >

Public Member Functions

MaskedColorFrame (astra_imageframe_t frame)
- Public Member Functions inherited from astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR >
ImageFrame (astra_imageframe_t frame, astra_pixel_format_t expected_format)
Default constructs. More...
const bool | is_valid () const
get is vaild More...
const int | width () const
get width More...
const int | height () const
get height More...
const std::uint8_t | bytes_per_pixel () const
get bytes per pixel More...
const astra_frame_index_t | frame_index () const
get frame index More...
const astra_imageframe_t | handle () const
get handle More...
const RgbaPixel * | data () const
get data pointer More...
const size_t | byte_length () const
get byte length More...
const size_t | length () const
get length More...
void | copy_to (RgbaPixel *buffer) const
copy to buffer More...

Additional Inherited Members

- Static Public Member Functions inherited from astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR >
static astra_stream_type_t | stream_type ()
get stream type More...
static TFrameType | acquire (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype)
acquire frame More...

Detailed Description

A Masked Color Frame of Masked Color Stream.

A Masked Color Frame of Masked Color Stream

Examples:
MaskedColorViewer-SFML\main.cpp.
The documentation for this class was generated from the following file:
  • MaskedColor.hpp


Astra SDK: astra::PointStream Class Reference

  • astra
  • PointStream
Public Member Functions | Static Public Attributes | List of all members
astra::PointStream Class Reference
C++ Reference

A Point Data Stream. More...

#include <Point.hpp>

Inheritance diagram for astra::PointStream:
astra::DataStream

Public Member Functions

PointStream (astra_streamconnection_t connection)
default constructs More...
- Public Member Functions inherited from astra::DataStream
DataStream (astra_streamconnection_t connection)
default constructs More...
bool | is_available ()
start stream More...
void | start ()
start stream
void | stop ()
stop stream

Static Public Attributes

static const astra_stream_type_t id = ASTRA_STREAM_POINT

Detailed Description

A Point Data Stream.

A Point Data Stream.

Examples:
MultiSensorViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, SimpleHandViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

Constructor & Destructor Documentation

◆ PointStream()

astra::PointStream::PointStream ( astra_streamconnection_t connection )
inlineexplicit

default constructs

Parameters
[in] connection
The documentation for this class was generated from the following file:
  • Point.hpp


Astra SDK: astra::PointFrame Class Reference

  • astra
  • PointFrame
Public Member Functions | List of all members
astra::PointFrame Class Reference
C++ Reference

A Point Data Frame. More...

#include <Point.hpp>

Inheritance diagram for astra::PointFrame:
astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT >

Public Member Functions

PointFrame (astra_imageframe_t frame)
default constructs More...
- Public Member Functions inherited from astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT >
ImageFrame (astra_imageframe_t frame, astra_pixel_format_t expected_format)
Default constructs. More...
const bool | is_valid () const
get is vaild More...
const int | width () const
get width More...
const int | height () const
get height More...
const std::uint8_t | bytes_per_pixel () const
get bytes per pixel More...
const astra_frame_index_t | frame_index () const
get frame index More...
const astra_imageframe_t | handle () const
get handle More...
const Vector3f * | data () const
get data pointer More...
const size_t | byte_length () const
get byte length More...
const size_t | length () const
get length More...
void | copy_to (Vector3f *buffer) const
copy to buffer More...

Additional Inherited Members

- Static Public Member Functions inherited from astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT >
static astra_stream_type_t | stream_type ()
get stream type More...
static TFrameType | acquire (astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype)
acquire frame More...

Detailed Description

A Point Data Frame.

A Point Data Frame

Examples:
MultiSensorViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, SimpleHandViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

Constructor & Destructor Documentation

◆ PointFrame()

astra::PointFrame::PointFrame ( astra_imageframe_t frame )
inline

default constructs

Parameters
[in] frame
The documentation for this class was generated from the following file:
  • Point.hpp


Astra SDK: astra::DataStream Class Reference

  • astra
  • DataStream
Public Member Functions | List of all members
astra::DataStream Class Reference
C++ Reference

Data Stream. More...

#include <DataStream.hpp>

Inheritance diagram for astra::DataStream:
astra::BodyStream astra::ColorizedBodyStream astra::DebugHandStream astra::HandStream astra::ImageStream astra::MaskedColorStream astra::PointStream astra::ColorStream astra::DepthStream astra::InfraredStream

Public Member Functions

DataStream (astra_streamconnection_t connection)
default constructs More...
bool | is_available ()
start stream More...
void | start ()
start stream
void | stop ()
stop stream

Detailed Description

Data Stream.

Basic stream class of Data Stream.

Constructor & Destructor Documentation

◆ DataStream()

astra::DataStream::DataStream ( astra_streamconnection_t connection )
inline

default constructs

Parameters
[in] connection

Member Function Documentation

◆ is_available()

bool astra::DataStream::is_available ( )
inline

start stream

Returns
is stream available
The documentation for this class was generated from the following file:
  • DataStream.hpp


Astra SDK: astra::Frame Class Reference

  • astra
  • Frame
Classes | Public Member Functions | List of all members
astra::Frame Class Reference
C++ Reference

Frame class. More...

#include <Frame.hpp>

Public Member Functions

Frame (astra_reader_frame_t readerFrame, const bool autoCloseFrame)
constructs More...
Frame (astra_reader_frame_t readerFrame)
constructs More...
template<typename T >
T | get ()
get data template More...
template<typename T >
T | get (astra_stream_subtype_t subtype)
get data template More...
bool | is_valid ()
get frame is valid More...
operator bool ()
operator to bool More...

Detailed Description

Frame class.

Basic frame class of frame

Examples:
ColorizedBodyViewer-SFML\main.cpp, ColorReaderEventCPP\main.cpp, DepthReaderEventCPP\main.cpp, MaskedColorViewer-SFML\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleBodyViewer-SFML\main.cpp, SimpleColorViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, SimpleHandViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

Constructor & Destructor Documentation

◆ Frame() [1/2]

astra::Frame::Frame | ( | astra_reader_frame_t | readerFrame,
 |  | const bool | autoCloseFrame
 | ) |  |
inline

constructs

Parameters
[in] | frame | reader
[in] | is | auto close

◆ Frame() [2/2]

astra::Frame::Frame ( astra_reader_frame_t readerFrame )
inline

constructs

Parameters
[in] frame reader

Member Function Documentation

◆ get() [1/2]

template<typename T >
T astra::Frame::get ( )
inline

get data template

Returns
data
Examples:
ColorizedBodyViewer-SFML\main.cpp, ColorReaderEventCPP\main.cpp, DepthReaderEventCPP\main.cpp, MaskedColorViewer-SFML\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleBodyViewer-SFML\main.cpp, SimpleColorViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, SimpleHandViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

◆ get() [2/2]

template<typename T >
T astra::Frame::get ( astra_stream_subtype_t subtype )
inline

get data template

Parameters
[in] subtype
Returns
data

◆ is_valid()

bool astra::Frame::is_valid ( )
inline

get frame is valid

Returns
is valid

◆ operator bool()

astra::Frame::operator bool ( )
inline

operator to bool

Returns
is valid
The documentation for this class was generated from the following file:
  • Frame.hpp


Astra SDK: astra::FrameListener Class Reference

  • astra
  • FrameListener
Public Member Functions | List of all members
astra::FrameListener Class Referenceabstract
C++ Reference

Frame Listener class. More...

#include <FrameListener.hpp>

Public Member Functions

virtual void on_frame_ready (StreamReader &reader, Frame &frame)=0

Detailed Description

Frame Listener class.

inherits this class to receive data and regist it,then when astra update has data,we will call on_frame_ready

Examples:
ColorizedBodyViewer-SFML\main.cpp, ColorReaderEventCPP\main.cpp, DepthReaderEventCPP\main.cpp, MaskedColorViewer-SFML\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleBodyViewer-SFML\main.cpp, SimpleColorViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, SimpleHandViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.
The documentation for this class was generated from the following file:
  • FrameListener.hpp


Astra SDK: astra::StreamDescription Class Reference

  • astra
  • StreamDescription
Public Member Functions | List of all members
astra::StreamDescription Class Reference
C++ Reference

Stream Description class. More...

#include <StreamDescription.hpp>

Inheritance diagram for astra::StreamDescription:
astra_stream_desc_t

Public Member Functions

StreamDescription (::astra_stream_type_t type, ::astra_stream_subtype_t subtype=DEFAULT_SUBTYPE)
default constructs More...
StreamDescription (const ::astra_stream_desc_t &desc)
copy constructs More...
StreamDescription & | operator= (const ::astra_stream_desc_t &desc)
copy constructs More...
operator::astra_stream_desc_t * ()
operator const ::astra_stream_desc_t * () const
astra_stream_type_t | type () const
get type More...
astra_stream_subtype_t | subtype () const
get sub type More...

Detailed Description

Stream Description class.

some info about stream

Constructor & Destructor Documentation

◆ StreamDescription() [1/2]

astra::StreamDescription::StreamDescription | ( | ::astra_stream_type_t | type,
 |  | ::astra_stream_subtype_t | subtype = DEFAULT_SUBTYPE
 | ) |  |
inline

default constructs

Parameters
[in] | type
[in] | sub | type

◆ StreamDescription() [2/2]

astra::StreamDescription::StreamDescription ( const ::astra_stream_desc_t & desc )
inline

copy constructs

Parameters
[in] desc

Member Function Documentation

◆ operator=()

StreamDescription& astra::StreamDescription::operator= ( const ::astra_stream_desc_t & desc )
inline

copy constructs

Parameters
[in] desc

◆ subtype()

astra_stream_subtype_t astra::StreamDescription::subtype ( ) const
inline

get sub type

Returns
sub type

◆ type()

astra_stream_type_t astra::StreamDescription::type ( ) const
inline

get type

Returns
type
The documentation for this class was generated from the following file:
  • StreamDescription.hpp


Astra SDK: astra::StreamReader Class Reference

  • astra
  • StreamReader
Classes | Public Member Functions | Friends | List of all members
astra::StreamReader Class Reference
C++ Reference

Stream Reader class. More...

#include <StreamReader.hpp>

Public Member Functions

StreamReader ()
default constructs
StreamReader (astra_reader_t reader)
constructs More...
StreamReader (const StreamReader &reader)
constructs More...
StreamReader & | operator= (const StreamReader &reader)
copy constructs More...
template<typename T >
T | stream ()
get stream template More...
template<typename T >
T | stream (astra_stream_subtype_t subtype)
get stream template More...
void | add_listener (FrameListener &listener)
add listener More...
void | remove_listener (FrameListener &listener)
remove listener More...
bool | is_valid ()
get is reader available More...
bool | has_new_frame ()
get is new frame ready More...
Frame | get_latest_frame (int timeoutMillis=ASTRA_TIMEOUT_FOREVER)
get is latest frame More...

Friends

bool operator== (const StreamReader &lhs, const StreamReader &rhs)

Detailed Description

Stream Reader class.

Stream Reader class StreamReader.

Examples:
ColorizedBodyViewer-SFML\main.cpp, ColorReaderEventCPP\main.cpp, DepthReaderEventCPP\main.cpp, MaskedColorViewer-SFML\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleBodyViewer-SFML\main.cpp, SimpleColorViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, SimpleHandViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

Constructor & Destructor Documentation

◆ StreamReader() [1/2]

astra::StreamReader::StreamReader ( astra_reader_t reader )
inline

constructs

Parameters
[in] reader

◆ StreamReader() [2/2]

astra::StreamReader::StreamReader ( const StreamReader & reader )
inline

constructs

Parameters
[in] reader

Member Function Documentation

◆ add_listener()

void astra::StreamReader::add_listener ( FrameListener & listener )
inline

add listener

Registers a callback function to StreamReader.

Parameters
[in] listener
Examples:
ColorizedBodyViewer-SFML\main.cpp, ColorReaderEventCPP\main.cpp, DepthReaderEventCPP\main.cpp, MaskedColorViewer-SFML\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleBodyViewer-SFML\main.cpp, SimpleColorViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, SimpleHandViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

◆ get_latest_frame()

Frame astra::StreamReader::get_latest_frame ( int timeoutMillis = ASTRA_TIMEOUT_FOREVER )
inline

get is latest frame

Returns
latest frame

◆ has_new_frame()

bool astra::StreamReader::has_new_frame ( )
inline

get is new frame ready

Returns
is new frame ready

◆ is_valid()

bool astra::StreamReader::is_valid ( )
inline

get is reader available

Returns
is reader available

◆ operator=()

StreamReader& astra::StreamReader::operator= ( const StreamReader & reader )
inline

copy constructs

Parameters
[in] reader

◆ remove_listener()

void astra::StreamReader::remove_listener ( FrameListener & listener )
inline

remove listener

Unregisters the callback function.

Parameters
[in] listener
Examples:
ColorReaderEventCPP\main.cpp, and DepthReaderEventCPP\main.cpp.

◆ stream() [1/2]

template<typename T >
T astra::StreamReader::stream ( )
inline

get stream template

Returns
stream T with DEFAULT_SUBTYPE
Examples:
ColorizedBodyViewer-SFML\main.cpp, ColorReaderEventCPP\main.cpp, DepthReaderEventCPP\main.cpp, MaskedColorViewer-SFML\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleBodyViewer-SFML\main.cpp, SimpleColorViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, SimpleHandViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

◆ stream() [2/2]

template<typename T >
T astra::StreamReader::stream ( astra_stream_subtype_t subtype )
inline

get stream template

Parameters
[in] sub type
Returns
stream T
The documentation for this class was generated from the following file:
  • StreamReader.hpp


Astra SDK: astra::StreamServiceProxy Class Reference

  • astra
  • StreamServiceProxy
Public Member Functions | List of all members
astra::StreamServiceProxy Class Reference
C++ Reference

Stream Service Proxy Class. More...

#include <StreamServiceProxy.hpp>

Inheritance diagram for astra::StreamServiceProxy:
astra_streamservice_proxy_t

Public Member Functions

astra_status_t | notify_plugin_event (astra_event_id id, const void *data, uint32_t dataSize)
notify plugin event More...
astra_status_t | streamset_is_available (astra_streamsetconnection_t connection, bool *isAvailable)
get streamset is available More...
astra_status_t | streamset_open (const char *connectionString, astra_streamsetconnection_t *streamSet)
open streamset More...
astra_status_t | streamset_close (astra_streamsetconnection_t *streamSet)
close streamset More...
astra_status_t | streamset_get_uri (astra_streamsetconnection_t connection, char *uri, int32_t size)
get streamset uri More...
astra_status_t | reader_create (astra_streamsetconnection_t streamSet, astra_reader_t *reader)
create reader More...
astra_status_t | reader_destroy (astra_reader_t *reader)
destroy reader More...
astra_status_t | reader_get_stream (astra_reader_t reader, astra_stream_type_t type, astra_stream_subtype_t subtype, astra_streamconnection_t *connection)
get stream More...
astra_status_t | stream_get_description (astra_streamconnection_t connection, astra_stream_desc_t *description)
get stream description More...
astra_status_t | stream_is_available (astra_streamconnection_t connection, bool *isAvailable)
get stream is description More...
astra_status_t | stream_start (astra_streamconnection_t connection)
start stream More...
astra_status_t | stream_stop (astra_streamconnection_t connection)
stop stream More...
astra_status_t | reader_has_new_frame (astra_reader_t reader, bool *hasNewFrame)
get is reader has new frame More...
astra_status_t | reader_open_frame (astra_reader_t reader, int timeoutMillis, astra_reader_frame_t *frame)
open a frame in timeout ms More...
astra_status_t | reader_close_frame (astra_reader_frame_t *frame)
close frame More...
astra_status_t | reader_register_frame_ready_callback (astra_reader_t reader, astra_frame_ready_callback_t callback, void *clientTag, astra_reader_callback_id_t *callbackId)
register reader frame ready callback More...
astra_status_t | reader_unregister_frame_ready_callback (astra_reader_callback_id_t *callbackId)
unregister reader frame ready callback More...
astra_status_t | reader_get_frame (astra_reader_frame_t frame, astra_stream_type_t type, astra_stream_subtype_t subtype, astra_frame_t **subFrame)
get sub frame int frame More...
astra_status_t | stream_set_parameter (astra_streamconnection_t connection, astra_parameter_id parameterId, uint32_t inByteLength, astra_parameter_data_t inData)
set connection param More...
astra_status_t | stream_get_parameter (astra_streamconnection_t connection, astra_parameter_id parameterId, uint32_t *resultByteLength, astra_result_token_t *token)
get connection param More...
astra_status_t | stream_get_result (astra_streamconnection_t connection, astra_result_token_t token, uint32_t dataByteLength, astra_parameter_data_t dataDestination)
get stream result More...
astra_status_t | stream_invoke (astra_streamconnection_t connection, astra_command_id commandId, uint32_t inByteLength, astra_parameter_data_t inData, uint32_t *resultByteLength, astra_result_token_t *token)
call stream command by id More...
astra_status_t | update ()
update
- Public Member Functions inherited from astra_streamservice_proxy_t
astra_status_t (ASTRA_CALLBACK *notify_plugin_event)(void *
astra_status_t (ASTRA_CALLBACK *streamset_is_available)(void *
bool * | astra_status_t (ASTRA_CALLBACK *streamset_open)(void *
bool const char astra_streamsetconnection_t * | astra_status_t (ASTRA_CALLBACK *streamset_close)(void *
bool const char astra_streamsetconnection_t astra_streamsetconnection_t * | astra_status_t (ASTRA_CALLBACK *streamset_get_uri)(void *
astra_status_t (ASTRA_CALLBACK *reader_create)(void *
astra_reader_t * | astra_status_t (ASTRA_CALLBACK *reader_destroy)(void *
astra_reader_t astra_reader_t * | astra_status_t (ASTRA_CALLBACK *reader_get_stream)(void *
astra_reader_t astra_reader_t astra_streamconnection_t * | astra_status_t (ASTRA_CALLBACK *stream_get_description)(void *
astra_reader_t astra_reader_t astra_streamconnection_t astra_stream_desc_t * | astra_status_t (ASTRA_CALLBACK *stream_is_available)(void *
astra_reader_t astra_reader_t astra_streamconnection_t astra_stream_desc_t bool * | astra_status_t (ASTRA_CALLBACK *stream_start)(void *
astra_status_t (ASTRA_CALLBACK *stream_stop)(void *
astra_status_t (ASTRA_CALLBACK *reader_has_new_frame)(void *
bool * | astra_status_t (ASTRA_CALLBACK *reader_open_frame)(void *
bool astra_reader_frame_t * | astra_status_t (ASTRA_CALLBACK *reader_close_frame)(void *
bool astra_reader_frame_t astra_reader_frame_t * | astra_status_t (ASTRA_CALLBACK *reader_register_frame_ready_callback)(void *
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t * | astra_status_t (ASTRA_CALLBACK *reader_unregister_frame_ready_callback)(void *
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t * | astra_status_t (ASTRA_CALLBACK *reader_get_frame)(void *
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t astra_frame_t ** | astra_status_t (ASTRA_CALLBACK *stream_set_parameter)(void *
astra_status_t (ASTRA_CALLBACK *stream_get_parameter)(void *
uint32_t astra_result_token_t * | astra_status_t (ASTRA_CALLBACK *stream_get_result)(void *
astra_status_t (ASTRA_CALLBACK *stream_invoke)(void *
uint32_t astra_result_token_t * | astra_status_t (ASTRA_CALLBACK *update)(void *)

Additional Inherited Members

- Public Attributes inherited from astra_streamservice_proxy_t
void * | streamService
astra_event_id
const void | uint32_t
astra_streamsetconnection_t
bool const char astra_streamsetconnection_t astra_streamsetconnection_t | astra_streamsetconnection_t
bool const char astra_streamsetconnection_t astra_streamsetconnection_t char | int32_t
astra_reader_t astra_reader_t | astra_reader_t
astra_reader_t astra_reader_t | astra_stream_type_t
astra_reader_t astra_reader_t | astra_stream_subtype_t
astra_reader_t astra_reader_t astra_streamconnection_t | astra_streamconnection_t
astra_reader_t astra_reader_t astra_streamconnection_t astra_stream_desc_t | astra_streamconnection_t
astra_reader_t astra_reader_t astra_streamconnection_t astra_stream_desc_t bool | astra_streamconnection_t
astra_streamconnection_t
astra_reader_t
bool | astra_reader_t
bool | int
bool astra_reader_frame_t astra_reader_frame_t | astra_reader_t
bool astra_reader_frame_t astra_reader_frame_t | astra_frame_ready_callback_t
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t | astra_reader_frame_t
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t | astra_stream_type_t
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t | astra_stream_subtype_t
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t astra_frame_t | astra_streamconnection_t
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t astra_frame_t | astra_parameter_id
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t astra_frame_t | uint32_t
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t astra_frame_t | astra_parameter_data_t
astra_parameter_id
uint32_t astra_result_token_t | astra_streamconnection_t
uint32_t astra_result_token_t | astra_result_token_t
uint32_t astra_result_token_t | uint32_t
uint32_t astra_result_token_t | astra_parameter_data_t
astra_command_id
uint32_t
astra_parameter_data_t

Detailed Description

Stream Service Proxy Class.

Stream Service Proxy is use to proxy a connection

Member Function Documentation

◆ notify_plugin_event()

astra_status_t astra::StreamServiceProxy::notify_plugin_event | ( | astra_event_id | id,
 |  | const void * | data,
 |  | uint32_t | dataSize
 | ) |  |
inline

notify plugin event

Parameters
[in] | id
[in] | data
[in] | data | size

◆ reader_close_frame()

astra_status_t astra::StreamServiceProxy::reader_close_frame ( astra_reader_frame_t * frame )
inline

close frame

Parameters
[in] frame

◆ reader_create()

astra_status_t astra::StreamServiceProxy::reader_create | ( | astra_streamsetconnection_t | streamSet,
 |  | astra_reader_t * | reader
 | ) |  |
inline

create reader

Parameters
[in] | streamSet
[out] | reader

◆ reader_destroy()

astra_status_t astra::StreamServiceProxy::reader_destroy ( astra_reader_t * reader )
inline

destroy reader

Parameters
[in] reader

◆ reader_get_frame()

astra_status_t astra::StreamServiceProxy::reader_get_frame | ( | astra_reader_frame_t | frame,
 |  | astra_stream_type_t | type,
 |  | astra_stream_subtype_t | subtype,
 |  | astra_frame_t ** | subFrame
 | ) |  |
inline

get sub frame int frame

Parameters
[in] | reader
[in] | type
[in] | subtype
[out] | subFrame

◆ reader_get_stream()

astra_status_t astra::StreamServiceProxy::reader_get_stream | ( | astra_reader_t | reader,
 |  | astra_stream_type_t | type,
 |  | astra_stream_subtype_t | subtype,
 |  | astra_streamconnection_t * | connection
 | ) |  |
inline

get stream

Parameters
[in] | reader
[in] | type
[in] | subtype
[out] | connection

◆ reader_has_new_frame()

astra_status_t astra::StreamServiceProxy::reader_has_new_frame | ( | astra_reader_t | reader,
 |  | bool * | hasNewFrame
 | ) |  |
inline

get is reader has new frame

Parameters
[in] | reader
[out] | hasNewFrame

◆ reader_open_frame()

astra_status_t astra::StreamServiceProxy::reader_open_frame | ( | astra_reader_t | reader,
 |  | int | timeoutMillis,
 |  | astra_reader_frame_t * | frame
 | ) |  |
inline

open a frame in timeout ms

Parameters
[in] | reader
[in] | timeout | ms
[out] | frame

◆ reader_register_frame_ready_callback()

astra_status_t astra::StreamServiceProxy::reader_register_frame_ready_callback | ( | astra_reader_t | reader,
 |  | astra_frame_ready_callback_t | callback,
 |  | void * | clientTag,
 |  | astra_reader_callback_id_t * | callbackId
 | ) |  |
inline

register reader frame ready callback

Parameters
[in] | reader
[in] | callback
[in] | clientTag
[out] | callbackId

◆ reader_unregister_frame_ready_callback()

astra_status_t astra::StreamServiceProxy::reader_unregister_frame_ready_callback ( astra_reader_callback_id_t * callbackId )
inline

unregister reader frame ready callback

Parameters
[in] callbackId

◆ stream_get_description()

astra_status_t astra::StreamServiceProxy::stream_get_description | ( | astra_streamconnection_t | connection,
 |  | astra_stream_desc_t * | description
 | ) |  |
inline

get stream description

Parameters
[in] | connection
[out] | description

◆ stream_get_parameter()

astra_status_t astra::StreamServiceProxy::stream_get_parameter | ( | astra_streamconnection_t | connection,
 |  | astra_parameter_id | parameterId,
 |  | uint32_t * | resultByteLength,
 |  | astra_result_token_t * | token
 | ) |  |
inline

get connection param

Parameters
[in] | connection
[in] | parameterId
[out] | result | buffer length
[out] | result

◆ stream_get_result()

astra_status_t astra::StreamServiceProxy::stream_get_result | ( | astra_streamconnection_t | connection,
 |  | astra_result_token_t | token,
 |  | uint32_t | dataByteLength,
 |  | astra_parameter_data_t | dataDestination
 | ) |  |
inline

get stream result

Parameters
[in] | connection
[in] | token
[in] | dataByteLength
[in] | dataDestination

◆ stream_invoke()

astra_status_t astra::StreamServiceProxy::stream_invoke | ( | astra_streamconnection_t | connection,
 |  | astra_command_id | commandId,
 |  | uint32_t | inByteLength,
 |  | astra_parameter_data_t | inData,
 |  | uint32_t * | resultByteLength,
 |  | astra_result_token_t * | token
 | ) |  |
inline

call stream command by id

Parameters
[in] | connection
[in] | commandId
[in] | inByteLength
[in] | inData
[out] | result | buffer length
[out] | result

◆ stream_is_available()

astra_status_t astra::StreamServiceProxy::stream_is_available | ( | astra_streamconnection_t | connection,
 |  | bool * | isAvailable
 | ) |  |
inline

get stream is description

Parameters
[in] | connection
[out] | isAvailable

◆ stream_set_parameter()

astra_status_t astra::StreamServiceProxy::stream_set_parameter | ( | astra_streamconnection_t | connection,
 |  | astra_parameter_id | parameterId,
 |  | uint32_t | inByteLength,
 |  | astra_parameter_data_t | inData
 | ) |  |
inline

set connection param

Parameters
[in] | connection
[in] | parameterId
[in] | inByteLength
[in] | inData

◆ stream_start()

astra_status_t astra::StreamServiceProxy::stream_start ( astra_streamconnection_t connection )
inline

start stream

Parameters
[in] connection

◆ stream_stop()

astra_status_t astra::StreamServiceProxy::stream_stop ( astra_streamconnection_t connection )
inline

stop stream

Parameters
[in] connection

◆ streamset_close()

astra_status_t astra::StreamServiceProxy::streamset_close ( astra_streamsetconnection_t * streamSet )
inline

close streamset

Parameters
[in] streamSet

◆ streamset_get_uri()

astra_status_t astra::StreamServiceProxy::streamset_get_uri | ( | astra_streamsetconnection_t | connection,
 |  | char * | uri,
 |  | int32_t | size
 | ) |  |
inline

get streamset uri

Parameters
[in] | streamSet
[out] | point | to uri
[in] | uri | size

◆ streamset_is_available()

astra_status_t astra::StreamServiceProxy::streamset_is_available | ( | astra_streamsetconnection_t | connection,
 |  | bool * | isAvailable
 | ) |  |
inline

get streamset is available

Parameters
[in] | connection
[out] | isAvailable

◆ streamset_open()

astra_status_t astra::StreamServiceProxy::streamset_open | ( | const char * | connectionString,
 |  | astra_streamsetconnection_t * | streamSet
 | ) |  |
inline

open streamset

Parameters
[in] | connectionString
[out] | streamSet
The documentation for this class was generated from the following file:
  • StreamServiceProxy.hpp


Astra SDK: astra::StreamSet Class Reference

  • astra
  • StreamSet
Classes | Public Member Functions | Friends | List of all members
astra::StreamSet Class Reference
C++ Reference

Stream Set Class. More...

#include <StreamSet.hpp>

Public Member Functions

StreamSet ()
default constructs
StreamSet (const char *uri)
constructs More...
StreamSet (const StreamSet &other)
copy constructs More...
StreamSet & | operator= (const StreamSet &rhs)
copy constructs More...
std::string | uri ()
get device uri More...
bool | is_valid ()
get is valid More...
bool | is_available ()
get is available More...
StreamReader create_reader ()
create and return reader More...
astra_streamsetconnection_t | get_handle () const
get handle More...

Friends

bool | operator== (const StreamSet &lhs, const StreamSet &rhs)
bool | operator!= (const StreamSet &lhs, const StreamSet &rhs)

Detailed Description

Stream Set Class.

Stream Set StreamSet.

Examples:
ColorizedBodyViewer-SFML\main.cpp, ColorReaderEventCPP\main.cpp, DepthReaderEventCPP\main.cpp, MaskedColorViewer-SFML\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleBodyViewer-SFML\main.cpp, SimpleColorViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, SimpleHandViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

Constructor & Destructor Documentation

◆ StreamSet() [1/2]

astra::StreamSet::StreamSet ( const char * uri )
inline

constructs

Parameters
[in] device uri

◆ StreamSet() [2/2]

astra::StreamSet::StreamSet ( const StreamSet & other )
inline

copy constructs

Parameters
[in] stream set

Member Function Documentation

◆ create_reader()

StreamReader astra::StreamSet::create_reader ( )
inline

create and return reader

Returns
reader
Examples:
ColorizedBodyViewer-SFML\main.cpp, ColorReaderEventCPP\main.cpp, DepthReaderEventCPP\main.cpp, MaskedColorViewer-SFML\main.cpp, MultiSensorViewer-SFML\main.cpp, SimpleBodyViewer-SFML\main.cpp, SimpleColorViewer-SFML\main.cpp, SimpleDepthViewer-SFML\main.cpp, SimpleHandViewer-SFML\main.cpp, and SimpleStreamViewer-SFML\main.cpp.

◆ get_handle()

astra_streamsetconnection_t astra::StreamSet::get_handle ( ) const
inline

get handle

Returns
handle

◆ is_available()

bool astra::StreamSet::is_available ( )
inline

get is available

Returns
is available

◆ is_valid()

bool astra::StreamSet::is_valid ( )
inline

get is valid

Returns
is valid

◆ operator=()

StreamSet& astra::StreamSet::operator= ( const StreamSet & rhs )
inline

copy constructs

Parameters
[in] stream set

◆ uri()

std::string astra::StreamSet::uri ( )
inline

get device uri

Returns
device uri
The documentation for this class was generated from the following file:
  • StreamSet.hpp


Astra SDK: C# Reference

Namespaces
C# Reference

Namespaces

Detailed Description

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: Astra Namespace Reference

Namespaces | Classes | Enumerations
Astra Namespace Reference
C# Reference

Namespaces

Classes

struct | ApiStatus
class | AstraException
class | Body
class | BodyFrame
struct | BodyFrameInfo
class | BodyMask
class | BodyStream
class | BodyTracking
class | ColorFrame
class | ColorizedBodyFrame
class | ColorizedBodyStream
class | ColorStream
class | Context
class | CoordinateMapper
class | DataFrame
class | DataStream
class | DepthFrame
class | DepthStream
class | FloorInfo
class | FloorMask
class | FrameReadyEventArgs
struct | HandPoseInfo
class | ImageFrame
class | ImageMode
class | ImageStream
class | InfraredFrame
class | InfraredStream
class | Joint
class | MaskedColorFrame
class | MaskedColorStream
struct | Matrix3x3
Represents a 3x3 rotation matrix. More...
class | Plane
3D geometric plane Represents a 3D plane. The normal of the plane is defined to be(A, B, C). The plane coefficients and real world coordinates(x, y, and z) are related by the plane equation: Ax + By + Cz + D = 0 More...
class | PointFrame
class | PointStream
class | ReaderFrame
Contains frames from opened streams. More...
class | StreamDescription
class | StreamReader
class | StreamSet
A StreamSet represents a logical group of related streams, the most common of these being an Astra camera device More...
class | StreamTypeInfo
class | StreamTypeRegistry
class | USBInfo
struct | Vector2D
Represents a float 2d vector More...
struct | Vector3D
Represents a float 3d vector More...

Enumerations

enum | BodyFeatures { BodyFeatures.Segmentation = 0, BodyFeatures.Joints = 1, BodyFeatures.HandPoses = 3 }
enum | BodyStatus { BodyStatus.NotTracking = 0, BodyStatus.Lost = 1, BodyStatus.TrackingStarted = 2, BodyStatus.Tracking = 3 }
enum | BodyTrackingFeatures { BodyTrackingFeatures.Segmentation = 0, BodyTrackingFeatures.Joints = 1, BodyTrackingFeatures.HandPose = 3 }
enum | HandPose { HandPose.Unknown, HandPose.Grip }
enum | JointStatus { JointStatus.NotTracked = 0, JointStatus.LowConfidence = 1, JointStatus.Tracked = 2 }
enum JointType {
Head = 0, ShoulderSpine = 1, LeftShoulder = 2, LeftElbow = 3,
LeftHand = 4, RightShoulder = 5, RightElbow = 6, RightHand = 7,
MidSpine = 8, BaseSpine = 9, LeftHip = 10, LeftKnee = 11,
LeftFoot = 12, RightHip = 13, RightKnee = 14, RightFoot = 15,
LeftWrist = 16, RightWrist = 17, Neck = 18, Unknown = 255
}
enum PixelFormat {
Unknown = 0, DepthMM = 100, RGB888 = 200, YUV422 = 201,
YUVY = 202, RGBA = 203, NV21 = 204, Gray8 = 300,
Gray16 = 301, Point = 400
}
enum SkeletonOptimization {
Optimization1 = 1, SkeletonOptimization.MinimizeMemory = 2, Optimization2 = 2, Optimization3 = 3,
Optimization4 = 4, Optimization5 = 5, SkeletonOptimization.Balanced = 5, Optimization6 = 6,
Optimization7 = 7, Optimization8 = 8, Optimization9 = 9, SkeletonOptimization.BestAccuracy = 9
}
Represents the body tracking configuration that trades-off tracking accuracy, memory, and CPU usage. More...
enum | SkeletonProfile { SkeletonProfile.Full = 0, SkeletonProfile.UpperBody = 1, SkeletonProfile.Basic = 2 }
Skeleton profile representing the set of joints to be tracked. More...

Enumeration Type Documentation

◆ BodyFeatures

enum Astra.BodyFeatures
strong
Enumerator
Segmentation | No features beyond minimal body mask segmentation
Joints | Tracking of joints
HandPoses | Recognition of hand poses

◆ BodyStatus

enum Astra.BodyStatus
strong
Enumerator
NotTracking | Body is not currently tracked
Lost | Tracking of body was lost
TrackingStarted | Tracking of body has begun
Tracking | Body is currently being tracked

◆ BodyTrackingFeatures

enum Astra.BodyTrackingFeatures
strong
Enumerator
Segmentation | No features beyond minimal body mask segmentation
Joints | Tracking of joints
HandPose | Recognition of hand poses

◆ HandPose

enum Astra.HandPose
strong
Enumerator
Unknown | Hand pose is not known or unrecognized
Grip | Grip pose

◆ JointStatus

enum Astra.JointStatus
strong
Enumerator
NotTracked | Joint not currently tracked.
LowConfidence | Joint is currently tracked with low confidence possibly due to an occlusion.
Tracked | Joint is currently tracked.

◆ SkeletonOptimization

enum Astra.SkeletonOptimization
strong

Represents the body tracking configuration that trades-off tracking accuracy, memory, and CPU usage.

Enumerator
MinimizeMemory | Configuration that minimizes memory usage at a cost of lower tracking accuracy
Balanced | Configuration that balances accuracy with lower memory and CPU usage
BestAccuracy | Configuration that produces the best tracking accuracy

◆ SkeletonProfile

enum Astra.SkeletonProfile
strong

Skeleton profile representing the set of joints to be tracked.

Enumerator
Full | Full skeleton profile.
UpperBody | Upper body skeleton profile.
Basic | Basic skeleton profile, only four joints: Head, MidSpine, LeftHand, RightHand .


Astra SDK: Astra.Core Namespace Reference

  • Astra
  • Core
Classes | Enumerations
Astra.Core Namespace Reference
C# Reference

Classes

class | GcHandleWrapper
struct | ImageMetadata
class | Native
class | NativeHandle

Enumerations

enum StreamType {
Depth = 1, Color = 2, Infrared = 3, Hand = 4,
Body = 5, StylizedDepth = 6, Point = 7, MaskedColor = 8,
ColorizedBody = 9, DebugHand = 3001
}
enum StreamSubType { DEFAULT_SUBTYPE = 0, COLOR_NV21_SUBTYPE = 1 }


Astra SDK: Java Reference

Classes
Java Reference

Classes

class | com.orbbec.astra.Astra
class | com.orbbec.astra.Body
class | com.orbbec.astra.BodyFrame
class | com.orbbec.astra.BodyFrameInfo
class | com.orbbec.astra.BodyMask
enum | com.orbbec.astra.BodyStatus
class | com.orbbec.astra.BodyStream
class | com.orbbec.astra.BodyTracking
enum | com.orbbec.astra.BodyTrackingFeatureFlags
class | com.orbbec.astra.ColorFrame
class | com.orbbec.astra.ColorizedBodyFrame
class | com.orbbec.astra.ColorizedBodyStream
class | com.orbbec.astra.ColorStream
class | com.orbbec.astra.CoordinateMapper
class | com.orbbec.astra.DataFrame
class | com.orbbec.astra.DataStream
class | com.orbbec.astra.DepthFrame
class | com.orbbec.astra.DepthStream
class | com.orbbec.astra.FloorInfo
class | com.orbbec.astra.FloorMask
enum | com.orbbec.astra.HandPose
class | com.orbbec.astra.HandPoseInfo
class | com.orbbec.astra.ImageFrame
class | com.orbbec.astra.ImageMetadata
class | com.orbbec.astra.ImageStream
class | com.orbbec.astra.ImageStreamMode
class | com.orbbec.astra.InfraredFrame
class | com.orbbec.astra.InfraredStream
class | com.orbbec.astra.Joint
enum | com.orbbec.astra.JointStatus
enum | com.orbbec.astra.JointType
class | com.orbbec.astra.MaskedColorFrame
class | com.orbbec.astra.MaskedColorStream
class | com.orbbec.astra.Matrix3
enum | com.orbbec.astra.PixelFormat
class | com.orbbec.astra.Plane
class | com.orbbec.astra.PointFrame
class | com.orbbec.astra.PointStream
class | com.orbbec.astra.ReaderFrame
enum | com.orbbec.astra.SkeletonOptimization
enum | com.orbbec.astra.SkeletonProfile
class | com.orbbec.astra.StreamDescription
interface | com.orbbec.astra.StreamReader.FrameListener
class | com.orbbec.astra.StreamReader
class | com.orbbec.astra.StreamSet
enum | com.orbbec.astra.StreamType
class | com.orbbec.astra.UsbDeviceInfo
class | com.orbbec.astra.Vector2D
class | com.orbbec.astra.Vector3D

Detailed Description

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: com.orbbec.astra.Astra Class Reference

  • com
  • orbbec
  • astra
  • Astra
Static Public Member Functions | List of all members
com.orbbec.astra.Astra Class Reference
Java Reference

Static Public Member Functions

static void | initialize ()
static void | terminate ()
static void | update ()
static void | notifyResourceAvailable (String resourceUri)
static void | notifyResourceUnavailable (String resourceUri)

Detailed Description

The type Astra.

Member Function Documentation

◆ initialize()

static void com.orbbec.astra.Astra.initialize ( )
inlinestatic

Initializes the library. This function must be called before calling any other function.

◆ terminate()

static void com.orbbec.astra.Astra.terminate ( )
inlinestatic

Terminate the library. Usually call this when app exits.

◆ update()

static void com.orbbec.astra.Astra.update ( )
inlinestatic

Drive the library to get a new frame of stream.

The documentation for this class was generated from the following file:
  • Astra.java


Astra SDK: com.orbbec.astra.Body Class Reference

  • com
  • orbbec
  • astra
  • Body
Public Member Functions | List of all members
com.orbbec.astra.Body Class Reference
Java Reference

Public Member Functions

Body (int id, int status, int bodyFeatureFlag, Vector3D centerOfMass, Joint[] joints, HandPoseInfo handPoseInfo)
int | getId ()
BodyStatus getStatus ()
Vector3D getCenterOfMass ()
Joint [] getJoints ()
HandPoseInfo getHandPoseInfo ()
boolean | areJointsEnabled ()
boolean | areHandPosesEnabled ()
String | toString ()

Detailed Description

The type Body.

Constructor & Destructor Documentation

◆ Body()

com.orbbec.astra.Body.Body | ( | int | id,
 |  | int | status,
 |  | int | bodyFeatureFlag,
 |  | Vector3D | centerOfMass,
 |  | Joint [] | joints,
 |  | HandPoseInfo | handPoseInfo
 | ) |  |
inline

Instantiates a new Body. Internal Usage.

Parameters
id | the id
status | the status
bodyFeatureFlag | the body feature flag
centerOfMass | the center of mass
joints | the joints
handPoseInfo | the hand pose info

Member Function Documentation

◆ areHandPosesEnabled()

boolean com.orbbec.astra.Body.areHandPosesEnabled ( )
inline

Are hand poses enabled, see BodyTrackingFeatureFlags. Can change this with setBodyFeatures or setDefaultBodyFeatures.

Returns
the boolean

◆ areJointsEnabled()

boolean com.orbbec.astra.Body.areJointsEnabled ( )
inline

Are joints enabled, see BodyTrackingFeatureFlags. Can change this with setBodyFeatures or setDefaultBodyFeatures.

Returns
the boolean

◆ getCenterOfMass()

Vector3D com.orbbec.astra.Body.getCenterOfMass ( )
inline

Get center of mass.

Returns
the center of mass

◆ getHandPoseInfo()

HandPoseInfo com.orbbec.astra.Body.getHandPoseInfo ( )
inline

Gets hand pose info.

Returns
the hand pose info

◆ getId()

int com.orbbec.astra.Body.getId ( )
inline

Get id of the body.

Returns
the id

◆ getJoints()

Joint [] com.orbbec.astra.Body.getJoints ( )
inline

Get joints.

Returns
the joints

◆ getStatus()

BodyStatus com.orbbec.astra.Body.getStatus ( )
inline

Get tracking status.

Returns
the status

◆ toString()

String com.orbbec.astra.Body.toString ( )
inline

To string.

Returns
the string
The documentation for this class was generated from the following file:
  • Body.java


Astra SDK: com.orbbec.astra.BodyFrame Class Reference

  • com
  • orbbec
  • astra
  • BodyFrame
Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
com.orbbec.astra.BodyFrame Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.BodyFrame:
com.orbbec.astra.DataFrame

Public Member Functions

int | getWidth ()
int | getHeight ()
boolean | getIsEstimated ()
BodyMask getBodyMask ()
FloorInfo getFloorInfo ()
Iterable< Body > | getBodies ()
- Public Member Functions inherited from com.orbbec.astra.DataFrame
int | getFrameIndex ()
boolean | isValid ()

Static Public Member Functions

static BodyFrame | get (ReaderFrame readerFrame, int subtype)
static BodyFrame | get (ReaderFrame readerFrame)

Static Public Attributes

static final StreamType STREAM_TYPE = BodyStream.STREAM_TYPE

Additional Inherited Members

- Protected Member Functions inherited from com.orbbec.astra.DataFrame
DataFrame (long handle)
- Protected Attributes inherited from com.orbbec.astra.DataFrame
long handle

Detailed Description

The type Body frame.

Member Function Documentation

◆ get() [1/2]

static BodyFrame com.orbbec.astra.BodyFrame.get | ( | ReaderFrame | readerFrame,
 |  | int | subtype
 | ) |  |
inlinestatic

Get body frame with subtype.

Parameters
readerFrame | the reader frame
subtype | the subtype
Returns
the body frame

◆ get() [2/2]

static BodyFrame com.orbbec.astra.BodyFrame.get ( ReaderFrame readerFrame )
inlinestatic

Get body frame.

Parameters
readerFrame the reader frame
Returns
the body frame

◆ getBodies()

Iterable<Body> com.orbbec.astra.BodyFrame.getBodies ( )
inline

Gets bodies.

Returns
the bodies

◆ getBodyMask()

BodyMask com.orbbec.astra.BodyFrame.getBodyMask ( )
inline

Gets body mask.

Returns
the body mask

◆ getFloorInfo()

FloorInfo com.orbbec.astra.BodyFrame.getFloorInfo ( )
inline

Gets floor info.

Returns
the floor info

◆ getHeight()

int com.orbbec.astra.BodyFrame.getHeight ( )
inline

Gets height of BodyFrame. Currently the same as height of BodyMask.

Returns
the height

◆ getIsEstimated()

boolean com.orbbec.astra.BodyFrame.getIsEstimated ( )
inline

Gets if the frame was estimated due to a slow CPU. .

Returns
the boolean

◆ getWidth()

int com.orbbec.astra.BodyFrame.getWidth ( )
inline

Gets width of BodyFrame. Currently the same as width of BodyMask.

Returns
the width
The documentation for this class was generated from the following file:
  • BodyFrame.java


Astra SDK: com.orbbec.astra.BodyFrameInfo Class Reference

  • com
  • orbbec
  • astra
  • BodyFrameInfo
Public Member Functions | List of all members
com.orbbec.astra.BodyFrameInfo Class Reference
Java Reference

Public Member Functions

int | getWidth ()
int | getHeight ()
boolean | getIsEstimated ()
String | toString ()

Detailed Description

The type Body frame info.

Member Function Documentation

◆ getHeight()

int com.orbbec.astra.BodyFrameInfo.getHeight ( )
inline

Gets height.

Returns
the height

◆ getIsEstimated()

boolean com.orbbec.astra.BodyFrameInfo.getIsEstimated ( )
inline

Gets is estimated.

Returns
the is estimated

◆ getWidth()

int com.orbbec.astra.BodyFrameInfo.getWidth ( )
inline

Gets width.

Returns
the width

◆ toString()

String com.orbbec.astra.BodyFrameInfo.toString ( )
inline

To string.

Returns
the string
The documentation for this class was generated from the following file:
  • BodyFrameInfo.java


Astra SDK: com.orbbec.astra.BodyMask Class Reference

  • com
  • orbbec
  • astra
  • BodyMask
Public Member Functions | List of all members
com.orbbec.astra.BodyMask Class Reference
Java Reference

Public Member Functions

int | getWidth ()
int | getHeight ()
ByteBuffer | getMask ()
String | toString ()

Detailed Description

The type Body mask.

Member Function Documentation

◆ getHeight()

int com.orbbec.astra.BodyMask.getHeight ( )
inline

Gets height of mask.

Returns
the height

◆ getMask()

ByteBuffer com.orbbec.astra.BodyMask.getMask ( )
inline

Gets mask.

Returns
the mask

◆ getWidth()

int com.orbbec.astra.BodyMask.getWidth ( )
inline

Gets width of mask.

Returns
the width

◆ toString()

String com.orbbec.astra.BodyMask.toString ( )
inline

To string.

Returns
the string
The documentation for this class was generated from the following file:
  • BodyMask.java


Astra SDK: com.orbbec.astra.BodyStatus Enum Reference

  • com
  • orbbec
  • astra
  • BodyStatus
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
com.orbbec.astra.BodyStatus Enum Reference
Java Reference

Public Member Functions

int getCode ()

Static Public Member Functions

static BodyStatus fromNativeCode (int code)

Public Attributes

NOT_TRACKING =(0)
LOST =(1)
TRACKING_STARTED =(2)
TRACKING =(3)

Detailed Description

The enum Body status.

Member Function Documentation

◆ fromNativeCode()

static BodyStatus com.orbbec.astra.BodyStatus.fromNativeCode ( int code )
inlinestatic

From native code body status.

Parameters
code the code
Returns
the body status

◆ getCode()

int com.orbbec.astra.BodyStatus.getCode ( )
inline

Gets code.

Returns
the code

Member Data Documentation

◆ LOST

com.orbbec.astra.BodyStatus.LOST =(1)

Body is lost.

◆ NOT_TRACKING

com.orbbec.astra.BodyStatus.NOT_TRACKING =(0)

Body is not tracking.

◆ TRACKING

com.orbbec.astra.BodyStatus.TRACKING =(3)

Body is tracked.

◆ TRACKING_STARTED

com.orbbec.astra.BodyStatus.TRACKING_STARTED =(2)

Body is tracked for first time.

The documentation for this enum was generated from the following file:
  • BodyStatus.java


Astra SDK: com.orbbec.astra.BodyStream Class Reference

  • com
  • orbbec
  • astra
  • BodyStream
Public Member Functions | Static Public Member Functions | Static Public Attributes | Protected Member Functions | List of all members
com.orbbec.astra.BodyStream Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.BodyStream:
com.orbbec.astra.DataStream

Public Member Functions

BodyTrackingFeatureFlags getDefaultBodyFeatures ()
void | setDefaultBodyFeatures (BodyTrackingFeatureFlags features)
SkeletonProfile getSkeletonProfile ()
void | setSkeletonProfile (SkeletonProfile profile)
SkeletonOptimization getSkeletonOptimization ()
void | setSkeletonOptimization (SkeletonOptimization optimization)
BodyTrackingFeatureFlags | getBodyFeatures (int bodyId)
void | setBodyFeatures (int bodyId, BodyTrackingFeatureFlags features)
- Public Member Functions inherited from com.orbbec.astra.DataStream
void | start ()
void | stop ()
StreamType getType ()
int | getSubtype ()
boolean | getIsAvailable ()

Static Public Member Functions

static BodyStream | get (StreamReader reader, int subtype)
static BodyStream | get (StreamReader reader)

Static Public Attributes

static final StreamType STREAM_TYPE = StreamType.BODY

Protected Member Functions

BodyStream (long handle)
- Protected Member Functions inherited from com.orbbec.astra.DataStream
DataStream (long handle)

Additional Inherited Members

- Static Protected Member Functions inherited from com.orbbec.astra.DataStream
static long | getFrameHandle (ReaderFrame frame, int type, int subtype)
- Protected Attributes inherited from com.orbbec.astra.DataStream
long | handle

Detailed Description

The type Body stream.

Member Function Documentation

◆ get() [1/2]

static BodyStream com.orbbec.astra.BodyStream.get | ( | StreamReader | reader,
 |  | int | subtype
 | ) |  |
inlinestatic

Get body stream.

Parameters
reader | the reader
subtype | the subtype
Returns
the body stream

◆ get() [2/2]

static BodyStream com.orbbec.astra.BodyStream.get ( StreamReader reader )
inlinestatic

Get body stream.

Parameters
reader the reader
Returns
the body stream

◆ getBodyFeatures()

BodyTrackingFeatureFlags com.orbbec.astra.BodyStream.getBodyFeatures ( int bodyId )
inline

Gets body features.

Parameters
bodyId the body id
Returns
the body features

◆ getDefaultBodyFeatures()

BodyTrackingFeatureFlags com.orbbec.astra.BodyStream.getDefaultBodyFeatures ( )
inline

Gets default body features.

Returns
the default body features

◆ getSkeletonOptimization()

SkeletonOptimization com.orbbec.astra.BodyStream.getSkeletonOptimization ( )
inline

Gets skeleton optimization.

Returns
the skeleton optimization

◆ getSkeletonProfile()

SkeletonProfile com.orbbec.astra.BodyStream.getSkeletonProfile ( )
inline

Gets skeleton profile.

Returns
the skeleton profile

◆ setBodyFeatures()

void com.orbbec.astra.BodyStream.setBodyFeatures | ( | int | bodyId,
 |  | BodyTrackingFeatureFlags | features
 | ) |  |
inline

Sets body features.

Parameters
bodyId | the body id
features | the features

◆ setDefaultBodyFeatures()

void com.orbbec.astra.BodyStream.setDefaultBodyFeatures ( BodyTrackingFeatureFlags features )
inline

Sets default body features.

Parameters
features the features

◆ setSkeletonOptimization()

void com.orbbec.astra.BodyStream.setSkeletonOptimization ( SkeletonOptimization optimization )
inline

Sets skeleton optimization. Will effect the accuracy of bodies.

Parameters
optimization the optimization

◆ setSkeletonProfile()

void com.orbbec.astra.BodyStream.setSkeletonProfile ( SkeletonProfile profile )
inline

Sets skeleton profile. Will effect the joints num of bodies.

Parameters
profile the profile
The documentation for this class was generated from the following file:
  • BodyStream.java


Astra SDK: com.orbbec.astra.BodyTracking Class Reference

  • com
  • orbbec
  • astra
  • BodyTracking
Static Public Member Functions | List of all members
com.orbbec.astra.BodyTracking Class Reference
Java Reference

Static Public Member Functions

static void setLicense (String licenseString)

Detailed Description

The type Body tracking.

Member Function Documentation

◆ setLicense()

static void com.orbbec.astra.BodyTracking.setLicense ( String licenseString )
inlinestatic

Sets license. Call this function after initialize and before openning stream. When trial expired, you should call this to continue use this version of sdk.

Parameters
licenseString the license string, not name of the license file.
The documentation for this class was generated from the following file:
  • BodyTracking.java


Astra SDK: com.orbbec.astra.BodyTrackingFeatureFlags Enum Reference

  • com
  • orbbec
  • astra
  • BodyTrackingFeatureFlags
Public Member Functions | Public Attributes | List of all members
com.orbbec.astra.BodyTrackingFeatureFlags Enum Reference
Java Reference

Public Member Functions

BodyTrackingFeatureFlags (int code)
boolean | hasSegmentation ()
boolean | hasJoints ()
boolean | hasHandPoses ()
int | getCode ()

Public Attributes

SEGMENTATION =(0)
JOINTS =(1)
HAND_POSES =(3)

Detailed Description

The enum Body tracking feature flags.

Member Function Documentation

◆ hasHandPoses()

boolean com.orbbec.astra.BodyTrackingFeatureFlags.hasHandPoses ( )
inline

Has hand poses boolean.

Returns
the boolean

◆ hasJoints()

boolean com.orbbec.astra.BodyTrackingFeatureFlags.hasJoints ( )
inline

Has joints boolean.

Returns
the boolean

◆ hasSegmentation()

boolean com.orbbec.astra.BodyTrackingFeatureFlags.hasSegmentation ( )
inline

Has segmentation boolean.

Returns
the boolean

Member Data Documentation

◆ HAND_POSES

com.orbbec.astra.BodyTrackingFeatureFlags.HAND_POSES =(3)

segmentation, joints and hand poses.

◆ JOINTS

com.orbbec.astra.BodyTrackingFeatureFlags.JOINTS =(1)

only segmentation and joints.

◆ SEGMENTATION

com.orbbec.astra.BodyTrackingFeatureFlags.SEGMENTATION =(0)

only segmentation.

The documentation for this enum was generated from the following file:
  • BodyTrackingFeatureFlags.java


Astra SDK: com.orbbec.astra.ColorFrame Class Reference

  • com
  • orbbec
  • astra
  • ColorFrame
Static Public Member Functions | Static Public Attributes | List of all members
com.orbbec.astra.ColorFrame Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.ColorFrame:
com.orbbec.astra.ImageFrame com.orbbec.astra.DataFrame

Static Public Member Functions

static ColorFrame | get (ReaderFrame readerFrame, int subtype)
static ColorFrame | get (ReaderFrame readerFrame)
static ColorFrame | getNV21ColorFrame (ReaderFrame readerFrame)

Static Public Attributes

static final StreamType STREAM_TYPE = ColorStream.STREAM_TYPE

Additional Inherited Members

- Public Member Functions inherited from com.orbbec.astra.ImageFrame
int | getWidth ()
int | getHeight ()
PixelFormat getPixelFormat ()
int | getBytesPerPixel ()
ByteBuffer | getByteBuffer ()
- Public Member Functions inherited from com.orbbec.astra.DataFrame
int | getFrameIndex ()
boolean | isValid ()
- Protected Member Functions inherited from com.orbbec.astra.ImageFrame
ImageFrame (long handle)
- Protected Member Functions inherited from com.orbbec.astra.DataFrame
DataFrame (long handle)
- Static Protected Member Functions inherited from com.orbbec.astra.ImageFrame
static long | getImageFrameHandle (ReaderFrame frame, int type, int subtype)
- Protected Attributes inherited from com.orbbec.astra.DataFrame
long | handle

Detailed Description

The type Color frame.

Member Function Documentation

◆ get() [1/2]

static ColorFrame com.orbbec.astra.ColorFrame.get | ( | ReaderFrame | readerFrame,
 |  | int | subtype
 | ) |  |
inlinestatic

Get color frame with subtype.

Parameters
readerFrame | the reader frame
subtype | the subtype
Returns
the color frame

◆ get() [2/2]

static ColorFrame com.orbbec.astra.ColorFrame.get ( ReaderFrame readerFrame )
inlinestatic

Get default color frame, format is rgb.

Parameters
readerFrame the reader frame
Returns
the color frame

◆ getNV21ColorFrame()

static ColorFrame com.orbbec.astra.ColorFrame.getNV21ColorFrame ( ReaderFrame readerFrame )
inlinestatic

Get color frame, format is nv21. Only can be used when using astra device or astra pro device on Android platform.

Parameters
readerFrame the reader frame
Returns
the color frame
The documentation for this class was generated from the following file:
  • ColorFrame.java


Astra SDK: com.orbbec.astra.ColorizedBodyFrame Class Reference

  • com
  • orbbec
  • astra
  • ColorizedBodyFrame
Static Public Member Functions | Static Public Attributes | List of all members
com.orbbec.astra.ColorizedBodyFrame Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.ColorizedBodyFrame:
com.orbbec.astra.ImageFrame com.orbbec.astra.DataFrame

Static Public Member Functions

static ColorizedBodyFrame | get (ReaderFrame readerFrame, int subtype)
static ColorizedBodyFrame | get (ReaderFrame readerFrame)

Static Public Attributes

static final StreamType STREAM_TYPE = ColorizedBodyStream.STREAM_TYPE

Additional Inherited Members

- Public Member Functions inherited from com.orbbec.astra.ImageFrame
int | getWidth ()
int | getHeight ()
PixelFormat getPixelFormat ()
int | getBytesPerPixel ()
ByteBuffer | getByteBuffer ()
- Public Member Functions inherited from com.orbbec.astra.DataFrame
int | getFrameIndex ()
boolean | isValid ()
- Protected Member Functions inherited from com.orbbec.astra.ImageFrame
ImageFrame (long handle)
- Protected Member Functions inherited from com.orbbec.astra.DataFrame
DataFrame (long handle)
- Static Protected Member Functions inherited from com.orbbec.astra.ImageFrame
static long | getImageFrameHandle (ReaderFrame frame, int type, int subtype)
- Protected Attributes inherited from com.orbbec.astra.DataFrame
long | handle

Detailed Description

The type Colorized body frame.

Member Function Documentation

◆ get() [1/2]

static ColorizedBodyFrame com.orbbec.astra.ColorizedBodyFrame.get | ( | ReaderFrame | readerFrame,
 |  | int | subtype
 | ) |  |
inlinestatic

Get colorized body frame.

Parameters
readerFrame | the reader frame
subtype | the subtype
Returns
the colorized body frame

◆ get() [2/2]

static ColorizedBodyFrame com.orbbec.astra.ColorizedBodyFrame.get ( ReaderFrame readerFrame )
inlinestatic

Get colorized body frame.

Parameters
readerFrame the reader frame
Returns
the colorized body frame
The documentation for this class was generated from the following file:
  • ColorizedBodyFrame.java


Astra SDK: com.orbbec.astra.ColorizedBodyStream Class Reference

  • com
  • orbbec
  • astra
  • ColorizedBodyStream
Static Public Member Functions | Static Public Attributes | Protected Member Functions | List of all members
com.orbbec.astra.ColorizedBodyStream Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.ColorizedBodyStream:
com.orbbec.astra.DataStream

Static Public Member Functions

static ColorizedBodyStream | get (StreamReader reader, int subtype)
static ColorizedBodyStream | get (StreamReader reader)

Static Public Attributes

static final StreamType STREAM_TYPE = StreamType.COLORIZED_BODY

Protected Member Functions

ColorizedBodyStream (long handle)
- Protected Member Functions inherited from com.orbbec.astra.DataStream
DataStream (long handle)

Additional Inherited Members

- Public Member Functions inherited from com.orbbec.astra.DataStream
void | start ()
void | stop ()
StreamType getType ()
int | getSubtype ()
boolean | getIsAvailable ()
- Static Protected Member Functions inherited from com.orbbec.astra.DataStream
static long | getFrameHandle (ReaderFrame frame, int type, int subtype)
- Protected Attributes inherited from com.orbbec.astra.DataStream
long | handle

Detailed Description

The type Colorized body stream.

Member Function Documentation

◆ get() [1/2]

static ColorizedBodyStream com.orbbec.astra.ColorizedBodyStream.get | ( | StreamReader | reader,
 |  | int | subtype
 | ) |  |
inlinestatic

Get colorized body stream.

Parameters
reader | the reader
subtype | the subtype
Returns
the colorized body stream

◆ get() [2/2]

static ColorizedBodyStream com.orbbec.astra.ColorizedBodyStream.get ( StreamReader reader )
inlinestatic

Get colorized body stream.

Parameters
reader the reader
Returns
the colorized body stream
The documentation for this class was generated from the following file:
  • ColorizedBodyStream.java


Astra SDK: com.orbbec.astra.ColorStream Class Reference

  • com
  • orbbec
  • astra
  • ColorStream
Static Public Member Functions | Static Public Attributes | Protected Member Functions | List of all members
com.orbbec.astra.ColorStream Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.ColorStream:
com.orbbec.astra.ImageStream com.orbbec.astra.DataStream

Static Public Member Functions

static ColorStream | get (StreamReader reader, int subtype)
static ColorStream | get (StreamReader reader)
static ColorStream | getNV21ColorStream (StreamReader reader)

Static Public Attributes

static final StreamType STREAM_TYPE = StreamType.COLOR

Protected Member Functions

ColorStream (long handle)
- Protected Member Functions inherited from com.orbbec.astra.ImageStream
ImageStream (long handle)
- Protected Member Functions inherited from com.orbbec.astra.DataStream
DataStream (long handle)

Additional Inherited Members

- Public Member Functions inherited from com.orbbec.astra.ImageStream
Iterable< ImageStreamMode > | getAvailableModes ()
ImageStreamMode getMode ()
void | setMode (ImageStreamMode mode)
float | getHorizontalFieldOfView ()
float | getVerticalFieldOfView ()
void | setMirroring (boolean mirroring)
boolean | getMirroring ()
UsbDeviceInfo getUsbDeviceInfo ()
- Public Member Functions inherited from com.orbbec.astra.DataStream
void | start ()
void | stop ()
StreamType getType ()
int | getSubtype ()
boolean | getIsAvailable ()
- Static Protected Member Functions inherited from com.orbbec.astra.DataStream
static long | getFrameHandle (ReaderFrame frame, int type, int subtype)
- Protected Attributes inherited from com.orbbec.astra.DataStream
long | handle

Detailed Description

The type Color stream.

Member Function Documentation

◆ get() [1/2]

static ColorStream com.orbbec.astra.ColorStream.get | ( | StreamReader | reader,
 |  | int | subtype
 | ) |  |
inlinestatic

Get color stream.

Parameters
reader | the reader
subtype | the subtype
Returns
the color stream

◆ get() [2/2]

static ColorStream com.orbbec.astra.ColorStream.get ( StreamReader reader )
inlinestatic

Get color stream, format is rgb.

Parameters
reader the reader
Returns
the color stream

◆ getNV21ColorStream()

static ColorStream com.orbbec.astra.ColorStream.getNV21ColorStream ( StreamReader reader )
inlinestatic

Get color stream, format is nv21. Only can be used when using astra device or astra pro device on Android platform.

Parameters
reader the reader
Returns
the color stream
The documentation for this class was generated from the following file:
  • ColorStream.java


Astra SDK: com.orbbec.astra.CoordinateMapper Class Reference

  • com
  • orbbec
  • astra
  • CoordinateMapper
Public Member Functions | List of all members
com.orbbec.astra.CoordinateMapper Class Reference
Java Reference

Public Member Functions

CoordinateMapper (int resolutionX, int resolutionY, float hFov, float vFov)
Vector3D | mapDepthPointToWorldSpace (Vector3D depthPoint)
Vector3D | mapWorldPointToDepthSpace (Vector3D worldPoint)
String | toString ()

Detailed Description

The type Coordinate mapper. get world position from depth or get depth position from world.

Constructor & Destructor Documentation

◆ CoordinateMapper()

com.orbbec.astra.CoordinateMapper.CoordinateMapper | ( | int | resolutionX,
 |  | int | resolutionY,
 |  | float | hFov,
 |  | float | vFov
 | ) |  |
inline

Instantiates a new Coordinate mapper.

Parameters
resolutionX | the resolution x
resolutionY | the resolution y
hFov | the h fov
vFov | the v fov

Member Function Documentation

◆ mapDepthPointToWorldSpace()

Vector3D com.orbbec.astra.CoordinateMapper.mapDepthPointToWorldSpace ( Vector3D depthPoint )
inline

Map depth point to world space vector3d.

Parameters
depthPoint the depth point
Returns
the vector 3 d

◆ mapWorldPointToDepthSpace()

Vector3D com.orbbec.astra.CoordinateMapper.mapWorldPointToDepthSpace ( Vector3D worldPoint )
inline

Map world point to depth space vector3d.

Parameters
worldPoint the world point
Returns
the vector 3 d

◆ toString()

String com.orbbec.astra.CoordinateMapper.toString ( )
inline

To string.

Returns
the string
The documentation for this class was generated from the following file:
  • CoordinateMapper.java


Astra SDK: com.orbbec.astra.DataFrame Class Reference

  • com
  • orbbec
  • astra
  • DataFrame
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
com.orbbec.astra.DataFrame Class Referenceabstract
Java Reference
Inheritance diagram for com.orbbec.astra.DataFrame:
com.orbbec.astra.BodyFrame com.orbbec.astra.ImageFrame com.orbbec.astra.ColorFrame com.orbbec.astra.ColorizedBodyFrame com.orbbec.astra.DepthFrame com.orbbec.astra.InfraredFrame com.orbbec.astra.MaskedColorFrame com.orbbec.astra.PointFrame

Public Member Functions

int | getFrameIndex ()
boolean | isValid ()

Protected Member Functions

DataFrame (long handle)

Protected Attributes

long handle

Detailed Description

The type Data frame. All other frame extends this.

Member Function Documentation

◆ getFrameIndex()

int com.orbbec.astra.DataFrame.getFrameIndex ( )
inline

Gets frame index.

Returns
the frame index

◆ isValid()

boolean com.orbbec.astra.DataFrame.isValid ( )
inline

Is valid.

Returns
the boolean
The documentation for this class was generated from the following file:
  • DataFrame.java


Astra SDK: com.orbbec.astra.DataStream Class Reference

  • com
  • orbbec
  • astra
  • DataStream
Public Member Functions | Protected Member Functions | Static Protected Member Functions | Protected Attributes | List of all members
com.orbbec.astra.DataStream Class Referenceabstract
Java Reference
Inheritance diagram for com.orbbec.astra.DataStream:
com.orbbec.astra.BodyStream com.orbbec.astra.ColorizedBodyStream com.orbbec.astra.ImageStream com.orbbec.astra.MaskedColorStream com.orbbec.astra.PointStream com.orbbec.astra.ColorStream com.orbbec.astra.DepthStream com.orbbec.astra.InfraredStream

Public Member Functions

void | start ()
void | stop ()
StreamType getType ()
int | getSubtype ()
boolean | getIsAvailable ()

Protected Member Functions

DataStream (long handle)

Static Protected Member Functions

static long getFrameHandle (ReaderFrame frame, int type, int subtype)

Protected Attributes

long handle

Detailed Description

The type Data stream. All other stream extends this.

Member Function Documentation

◆ getIsAvailable()

boolean com.orbbec.astra.DataStream.getIsAvailable ( )
inline

Gets is available.

Returns
the is available

◆ getSubtype()

int com.orbbec.astra.DataStream.getSubtype ( )
inline

Gets subtype.

Returns
the subtype

◆ getType()

StreamType com.orbbec.astra.DataStream.getType ( )
inline

Gets type.

Returns
the type

◆ start()

void com.orbbec.astra.DataStream.start ( )
inline

Start.

◆ stop()

void com.orbbec.astra.DataStream.stop ( )
inline

Stop.

The documentation for this class was generated from the following file:
  • DataStream.java


Astra SDK: com.orbbec.astra.DepthFrame Class Reference

  • com
  • orbbec
  • astra
  • DepthFrame
Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
com.orbbec.astra.DepthFrame Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.DepthFrame:
com.orbbec.astra.ImageFrame com.orbbec.astra.DataFrame

Public Member Functions

ShortBuffer | getDepthBuffer ()
- Public Member Functions inherited from com.orbbec.astra.ImageFrame
int | getWidth ()
int | getHeight ()
PixelFormat getPixelFormat ()
int | getBytesPerPixel ()
ByteBuffer | getByteBuffer ()
- Public Member Functions inherited from com.orbbec.astra.DataFrame
int | getFrameIndex ()
boolean | isValid ()

Static Public Member Functions

static DepthFrame | get (ReaderFrame readerFrame, int subtype)
static DepthFrame | get (ReaderFrame readerFrame)

Static Public Attributes

static final StreamType STREAM_TYPE = DepthStream.STREAM_TYPE

Additional Inherited Members

- Protected Member Functions inherited from com.orbbec.astra.ImageFrame
ImageFrame (long handle)
- Protected Member Functions inherited from com.orbbec.astra.DataFrame
DataFrame (long handle)
- Static Protected Member Functions inherited from com.orbbec.astra.ImageFrame
static long | getImageFrameHandle (ReaderFrame frame, int type, int subtype)
- Protected Attributes inherited from com.orbbec.astra.DataFrame
long | handle

Detailed Description

The type Depth frame.

Member Function Documentation

◆ get() [1/2]

static DepthFrame com.orbbec.astra.DepthFrame.get | ( | ReaderFrame | readerFrame,
 |  | int | subtype
 | ) |  |
inlinestatic

Get depth frame.

Parameters
readerFrame | the reader frame
subtype | the subtype
Returns
the depth frame

◆ get() [2/2]

static DepthFrame com.orbbec.astra.DepthFrame.get ( ReaderFrame readerFrame )
inlinestatic

Get depth frame.

Parameters
readerFrame the reader frame
Returns
the depth frame

◆ getDepthBuffer()

ShortBuffer com.orbbec.astra.DepthFrame.getDepthBuffer ( )
inline

Gets depth buffer.

Returns
the depth buffer
The documentation for this class was generated from the following file:
  • DepthFrame.java


Astra SDK: com.orbbec.astra.DepthStream Class Reference

  • com
  • orbbec
  • astra
  • DepthStream
Public Member Functions | Static Public Member Functions | List of all members
com.orbbec.astra.DepthStream Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.DepthStream:
com.orbbec.astra.ImageStream com.orbbec.astra.DataStream

Public Member Functions

void | setRegistration (boolean registration)
boolean | getRegistration ()
int | getDeviceChipId ()
String | getDeviceSerialNumber ()
- Public Member Functions inherited from com.orbbec.astra.ImageStream
Iterable< ImageStreamMode > | getAvailableModes ()
ImageStreamMode getMode ()
void | setMode (ImageStreamMode mode)
float | getHorizontalFieldOfView ()
float | getVerticalFieldOfView ()
void | setMirroring (boolean mirroring)
boolean | getMirroring ()
UsbDeviceInfo getUsbDeviceInfo ()
- Public Member Functions inherited from com.orbbec.astra.DataStream
void | start ()
void | stop ()
StreamType getType ()
int | getSubtype ()
boolean | getIsAvailable ()

Static Public Member Functions

static DepthStream | get (StreamReader reader, int subtype)
static DepthStream | get (StreamReader reader)

Additional Inherited Members

- Protected Member Functions inherited from com.orbbec.astra.ImageStream
ImageStream (long handle)
- Protected Member Functions inherited from com.orbbec.astra.DataStream
DataStream (long handle)
- Static Protected Member Functions inherited from com.orbbec.astra.DataStream
static long | getFrameHandle (ReaderFrame frame, int type, int subtype)
- Protected Attributes inherited from com.orbbec.astra.DataStream
long | handle

Detailed Description

The type Depth stream.

Member Function Documentation

◆ get() [1/2]

static DepthStream com.orbbec.astra.DepthStream.get | ( | StreamReader | reader,
 |  | int | subtype
 | ) |  |
inlinestatic

Get depth stream.

Parameters
reader | the reader
subtype | the subtype
Returns
the depth stream

◆ get() [2/2]

static DepthStream com.orbbec.astra.DepthStream.get ( StreamReader reader )
inlinestatic

Get depth stream.

Parameters
reader the reader
Returns
the depth stream

◆ getDeviceChipId()

int com.orbbec.astra.DepthStream.getDeviceChipId ( )
inline

Gets device chip id.

Returns
the device chip id

◆ getDeviceSerialNumber()

String com.orbbec.astra.DepthStream.getDeviceSerialNumber ( )
inline

Gets device serial number.

Returns
the device serial number

◆ getRegistration()

boolean com.orbbec.astra.DepthStream.getRegistration ( )
inline

Gets registration.

Returns
the registration

◆ setRegistration()

void com.orbbec.astra.DepthStream.setRegistration ( boolean registration )
inline

Sets registration.

Parameters
registration the registration
The documentation for this class was generated from the following file:
  • DepthStream.java


Astra SDK: com.orbbec.astra.FloorInfo Class Reference

  • com
  • orbbec
  • astra
  • FloorInfo
Public Member Functions | List of all members
com.orbbec.astra.FloorInfo Class Reference
Java Reference

Public Member Functions

FloorMask getMask ()
boolean | isDetected ()
Plane getPlane ()
String | toString ()

Detailed Description

The type Floor info.

Member Function Documentation

◆ getMask()

FloorMask com.orbbec.astra.FloorInfo.getMask ( )
inline

Gets mask.

Returns
the mask

◆ getPlane()

Plane com.orbbec.astra.FloorInfo.getPlane ( )
inline

Gets plane.

Returns
the plane

◆ isDetected()

boolean com.orbbec.astra.FloorInfo.isDetected ( )
inline

Is detected boolean.

Returns
the boolean

◆ toString()

String com.orbbec.astra.FloorInfo.toString ( )
inline

To string.

Returns
the string
The documentation for this class was generated from the following file:
  • FloorInfo.java


Astra SDK: com.orbbec.astra.FloorMask Class Reference

  • com
  • orbbec
  • astra
  • FloorMask
Public Member Functions | List of all members
com.orbbec.astra.FloorMask Class Reference
Java Reference

Public Member Functions

int | getWidth ()
int | getHeight ()
ByteBuffer | getMask ()
String | toString ()

Detailed Description

The mask of floor.

Member Function Documentation

◆ getHeight()

int com.orbbec.astra.FloorMask.getHeight ( )
inline

Gets height.

Returns
the height

◆ getMask()

ByteBuffer com.orbbec.astra.FloorMask.getMask ( )
inline

Gets mask.

Returns
the mask

◆ getWidth()

int com.orbbec.astra.FloorMask.getWidth ( )
inline

Gets width.

Returns
the width

◆ toString()

String com.orbbec.astra.FloorMask.toString ( )
inline

To string.

Returns
the string
The documentation for this class was generated from the following file:
  • FloorMask.java


Astra SDK: com.orbbec.astra.HandPose Enum Reference

  • com
  • orbbec
  • astra
  • HandPose
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
com.orbbec.astra.HandPose Enum Reference
Java Reference

Public Member Functions

HandPose (int code)
int getCode ()

Static Public Member Functions

static HandPose fromNativeCode (int code)

Public Attributes

UNKNOWN =(0)
GRIP =(1)

Detailed Description

The enum Hand pose.

Member Data Documentation

◆ GRIP

com.orbbec.astra.HandPose.GRIP =(1)

Grip hand pose.

◆ UNKNOWN

com.orbbec.astra.HandPose.UNKNOWN =(0)

Unknown hand pose.

The documentation for this enum was generated from the following file:
  • HandPose.java


Astra SDK: com.orbbec.astra.HandPoseInfo Class Reference

  • com
  • orbbec
  • astra
  • HandPoseInfo
Public Member Functions | List of all members
com.orbbec.astra.HandPoseInfo Class Reference
Java Reference

Public Member Functions

HandPoseInfo (int leftHand, int rightHand)
HandPose getLeftHand ()
HandPose getRightHand ()
String toString ()

Detailed Description

The type Hand pose info.

Member Function Documentation

◆ getLeftHand()

HandPose com.orbbec.astra.HandPoseInfo.getLeftHand ( )
inline

Gets pose of left hand.

Returns
the pose of left hand

◆ getRightHand()

HandPose com.orbbec.astra.HandPoseInfo.getRightHand ( )
inline

Gets pose of right hand.

Returns
the pose of right hand

◆ toString()

String com.orbbec.astra.HandPoseInfo.toString ( )
inline

To string.

Returns
the string
The documentation for this class was generated from the following file:
  • HandPoseInfo.java


Astra SDK: com.orbbec.astra.ImageFrame Class Reference

  • com
  • orbbec
  • astra
  • ImageFrame
Public Member Functions | Protected Member Functions | Static Protected Member Functions | List of all members
com.orbbec.astra.ImageFrame Class Referenceabstract
Java Reference
Inheritance diagram for com.orbbec.astra.ImageFrame:
com.orbbec.astra.DataFrame com.orbbec.astra.ColorFrame com.orbbec.astra.ColorizedBodyFrame com.orbbec.astra.DepthFrame com.orbbec.astra.InfraredFrame com.orbbec.astra.MaskedColorFrame com.orbbec.astra.PointFrame

Public Member Functions

int | getWidth ()
int | getHeight ()
PixelFormat getPixelFormat ()
int | getBytesPerPixel ()
ByteBuffer | getByteBuffer ()
- Public Member Functions inherited from com.orbbec.astra.DataFrame
int | getFrameIndex ()
boolean | isValid ()

Protected Member Functions

ImageFrame (long handle)
- Protected Member Functions inherited from com.orbbec.astra.DataFrame
DataFrame (long handle)

Static Protected Member Functions

static long getImageFrameHandle (ReaderFrame frame, int type, int subtype)

Additional Inherited Members

- Protected Attributes inherited from com.orbbec.astra.DataFrame
long handle

Detailed Description

The type Image frame.

Member Function Documentation

◆ getByteBuffer()

ByteBuffer com.orbbec.astra.ImageFrame.getByteBuffer ( )
inline

Gets byte buffer.

Returns
the byte buffer

◆ getBytesPerPixel()

int com.orbbec.astra.ImageFrame.getBytesPerPixel ( )
inline

Gets bytes per pixel.

Returns
the bytes per pixel

◆ getHeight()

int com.orbbec.astra.ImageFrame.getHeight ( )
inline

Gets height.

Returns
the height

◆ getPixelFormat()

PixelFormat com.orbbec.astra.ImageFrame.getPixelFormat ( )
inline

Gets pixel format.

Returns
the pixel format

◆ getWidth()

int com.orbbec.astra.ImageFrame.getWidth ( )
inline

Gets width.

Returns
the width
The documentation for this class was generated from the following file:
  • ImageFrame.java


Astra SDK: com.orbbec.astra.ImageMetadata Class Reference

  • com
  • orbbec
  • astra
  • ImageMetadata
Public Member Functions | List of all members
com.orbbec.astra.ImageMetadata Class Reference
Java Reference

Public Member Functions

int | getWidth ()
int | getHeight ()
PixelFormat getFormat ()
String | toString ()

Detailed Description

The type Image metadata.

Member Function Documentation

◆ getFormat()

PixelFormat com.orbbec.astra.ImageMetadata.getFormat ( )
inline

Gets format.

Returns
the format

◆ getHeight()

int com.orbbec.astra.ImageMetadata.getHeight ( )
inline

Gets height.

Returns
the height

◆ getWidth()

int com.orbbec.astra.ImageMetadata.getWidth ( )
inline

Gets width.

Returns
the width

◆ toString()

String com.orbbec.astra.ImageMetadata.toString ( )
inline

To string.

Returns
the string
The documentation for this class was generated from the following file:
  • ImageMetadata.java


Astra SDK: com.orbbec.astra.ImageStream Class Reference

  • com
  • orbbec
  • astra
  • ImageStream
Public Member Functions | Protected Member Functions | List of all members
com.orbbec.astra.ImageStream Class Referenceabstract
Java Reference
Inheritance diagram for com.orbbec.astra.ImageStream:
com.orbbec.astra.DataStream com.orbbec.astra.ColorStream com.orbbec.astra.DepthStream com.orbbec.astra.InfraredStream

Public Member Functions

Iterable< ImageStreamMode > | getAvailableModes ()
ImageStreamMode getMode ()
void | setMode (ImageStreamMode mode)
float | getHorizontalFieldOfView ()
float | getVerticalFieldOfView ()
void | setMirroring (boolean mirroring)
boolean | getMirroring ()
UsbDeviceInfo getUsbDeviceInfo ()
- Public Member Functions inherited from com.orbbec.astra.DataStream
void | start ()
void | stop ()
StreamType getType ()
int | getSubtype ()
boolean | getIsAvailable ()

Protected Member Functions

ImageStream (long handle)
- Protected Member Functions inherited from com.orbbec.astra.DataStream
DataStream (long handle)

Additional Inherited Members

- Static Protected Member Functions inherited from com.orbbec.astra.DataStream
static long | getFrameHandle (ReaderFrame frame, int type, int subtype)
- Protected Attributes inherited from com.orbbec.astra.DataStream
long | handle

Detailed Description

The type Image stream.

Member Function Documentation

◆ getAvailableModes()

Iterable<ImageStreamMode> com.orbbec.astra.ImageStream.getAvailableModes ( )
inline

Gets available modes.

Returns
the available modes

◆ getHorizontalFieldOfView()

float com.orbbec.astra.ImageStream.getHorizontalFieldOfView ( )
inline

Gets horizontal field of view.

Returns
the horizontal field of view

◆ getMirroring()

boolean com.orbbec.astra.ImageStream.getMirroring ( )
inline

Gets mirroring.

Returns
the mirroring

◆ getMode()

ImageStreamMode com.orbbec.astra.ImageStream.getMode ( )
inline

Gets mode.

Returns
the mode

◆ getUsbDeviceInfo()

UsbDeviceInfo com.orbbec.astra.ImageStream.getUsbDeviceInfo ( )
inline

Gets usb device info.

Returns
the usb device info

◆ getVerticalFieldOfView()

float com.orbbec.astra.ImageStream.getVerticalFieldOfView ( )
inline

Gets vertical field of view.

Returns
the vertical field of view

◆ setMirroring()

void com.orbbec.astra.ImageStream.setMirroring ( boolean mirroring )
inline

Sets mirroring.

Parameters
mirroring the mirroring

◆ setMode()

void com.orbbec.astra.ImageStream.setMode ( ImageStreamMode mode )
inline

Sets mode.

Parameters
mode the mode
The documentation for this class was generated from the following file:
  • ImageStream.java


Astra SDK: com.orbbec.astra.ImageStreamMode Class Reference

  • com
  • orbbec
  • astra
  • ImageStreamMode
Public Member Functions | List of all members
com.orbbec.astra.ImageStreamMode Class Reference
Java Reference

Public Member Functions

ImageStreamMode (int id, int width, int height, int format, int framesPerSecond)
int | getId ()
int | getWidth ()
int | getHeight ()
PixelFormat getFormat ()
int | getFramesPerSecond ()
String | toString ()

Detailed Description

The type Image stream mode.

Constructor & Destructor Documentation

◆ ImageStreamMode()

com.orbbec.astra.ImageStreamMode.ImageStreamMode | ( | int | id,
 |  | int | width,
 |  | int | height,
 |  | int | format,
 |  | int | framesPerSecond
 | ) |  |
inline

Instantiates a new Image stream mode. You'd better get this with getAvailableModes on stream.

Parameters
id | the id
width | the width
height | the height
format | the format
framesPerSecond | the frames per second

Member Function Documentation

◆ getFormat()

PixelFormat com.orbbec.astra.ImageStreamMode.getFormat ( )
inline

Gets format.

Returns
the format

◆ getFramesPerSecond()

int com.orbbec.astra.ImageStreamMode.getFramesPerSecond ( )
inline

Gets frames per second.

Returns
the frames per second

◆ getHeight()

int com.orbbec.astra.ImageStreamMode.getHeight ( )
inline

Gets height.

Returns
the height

◆ getId()

int com.orbbec.astra.ImageStreamMode.getId ( )
inline

Gets id. Not used.

Returns
the id

◆ getWidth()

int com.orbbec.astra.ImageStreamMode.getWidth ( )
inline

Gets width.

Returns
the width

◆ toString()

String com.orbbec.astra.ImageStreamMode.toString ( )
inline

To string.

Returns
the string
The documentation for this class was generated from the following file:
  • ImageStreamMode.java


Astra SDK: com.orbbec.astra.InfraredFrame Class Reference

  • com
  • orbbec
  • astra
  • InfraredFrame
Static Public Member Functions | Static Public Attributes | List of all members
com.orbbec.astra.InfraredFrame Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.InfraredFrame:
com.orbbec.astra.ImageFrame com.orbbec.astra.DataFrame

Static Public Member Functions

static InfraredFrame | get (ReaderFrame readerFrame, int subtype)
static InfraredFrame | get (ReaderFrame readerFrame)

Static Public Attributes

static final StreamType STREAM_TYPE = InfraredStream.STREAM_TYPE

Additional Inherited Members

- Public Member Functions inherited from com.orbbec.astra.ImageFrame
int | getWidth ()
int | getHeight ()
PixelFormat getPixelFormat ()
int | getBytesPerPixel ()
ByteBuffer | getByteBuffer ()
- Public Member Functions inherited from com.orbbec.astra.DataFrame
int | getFrameIndex ()
boolean | isValid ()
- Protected Member Functions inherited from com.orbbec.astra.ImageFrame
ImageFrame (long handle)
- Protected Member Functions inherited from com.orbbec.astra.DataFrame
DataFrame (long handle)
- Static Protected Member Functions inherited from com.orbbec.astra.ImageFrame
static long | getImageFrameHandle (ReaderFrame frame, int type, int subtype)
- Protected Attributes inherited from com.orbbec.astra.DataFrame
long | handle

Detailed Description

The type Infrared frame.

Member Function Documentation

◆ get() [1/2]

static InfraredFrame com.orbbec.astra.InfraredFrame.get | ( | ReaderFrame | readerFrame,
 |  | int | subtype
 | ) |  |
inlinestatic

Get infrared frame.

Parameters
readerFrame | the reader frame
subtype | the subtype
Returns
the infrared frame

◆ get() [2/2]

static InfraredFrame com.orbbec.astra.InfraredFrame.get ( ReaderFrame readerFrame )
inlinestatic

Get infrared frame.

Parameters
readerFrame the reader frame
Returns
the infrared frame
The documentation for this class was generated from the following file:
  • InfraredFrame.java


Astra SDK: com.orbbec.astra.InfraredStream Class Reference

  • com
  • orbbec
  • astra
  • InfraredStream
Static Public Member Functions | Static Public Attributes | Protected Member Functions | List of all members
com.orbbec.astra.InfraredStream Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.InfraredStream:
com.orbbec.astra.ImageStream com.orbbec.astra.DataStream

Static Public Member Functions

static InfraredStream | get (StreamReader reader, int subtype)
static InfraredStream | get (StreamReader reader)

Static Public Attributes

static final StreamType STREAM_TYPE = StreamType.INFRARED

Protected Member Functions

InfraredStream (long handle)
- Protected Member Functions inherited from com.orbbec.astra.ImageStream
ImageStream (long handle)
- Protected Member Functions inherited from com.orbbec.astra.DataStream
DataStream (long handle)

Additional Inherited Members

- Public Member Functions inherited from com.orbbec.astra.ImageStream
Iterable< ImageStreamMode > | getAvailableModes ()
ImageStreamMode getMode ()
void | setMode (ImageStreamMode mode)
float | getHorizontalFieldOfView ()
float | getVerticalFieldOfView ()
void | setMirroring (boolean mirroring)
boolean | getMirroring ()
UsbDeviceInfo getUsbDeviceInfo ()
- Public Member Functions inherited from com.orbbec.astra.DataStream
void | start ()
void | stop ()
StreamType getType ()
int | getSubtype ()
boolean | getIsAvailable ()
- Static Protected Member Functions inherited from com.orbbec.astra.DataStream
static long | getFrameHandle (ReaderFrame frame, int type, int subtype)
- Protected Attributes inherited from com.orbbec.astra.DataStream
long | handle

Detailed Description

The type Infrared stream.

Member Function Documentation

◆ get() [1/2]

static InfraredStream com.orbbec.astra.InfraredStream.get | ( | StreamReader | reader,
 |  | int | subtype
 | ) |  |
inlinestatic

Get infrared stream.

Parameters
reader | the reader
subtype | the subtype
Returns
the infrared stream

◆ get() [2/2]

static InfraredStream com.orbbec.astra.InfraredStream.get ( StreamReader reader )
inlinestatic

Get infrared stream.

Parameters
reader the reader
Returns
the infrared stream
The documentation for this class was generated from the following file:
  • InfraredStream.java


Astra SDK: com.orbbec.astra.Joint Class Reference

  • com
  • orbbec
  • astra
  • Joint
Public Member Functions | List of all members
com.orbbec.astra.Joint Class Reference
Java Reference

Public Member Functions

JointType getType ()
JointStatus getStatus ()
Vector2D getDepthPosition ()
Vector3D getWorldPosition ()
Matrix3 getOrientation ()
String toString ()

Detailed Description

The type Joint.

Member Function Documentation

◆ getDepthPosition()

Vector2D com.orbbec.astra.Joint.getDepthPosition ( )
inline

Gets depth position.

Returns
the depth position

◆ getOrientation()

Matrix3 com.orbbec.astra.Joint.getOrientation ( )
inline

Gets orientation.

Returns
the orientation

◆ getStatus()

JointStatus com.orbbec.astra.Joint.getStatus ( )
inline

Gets status.

Returns
the status

◆ getType()

JointType com.orbbec.astra.Joint.getType ( )
inline

Gets type.

Returns
the type

◆ getWorldPosition()

Vector3D com.orbbec.astra.Joint.getWorldPosition ( )
inline

Gets world position.

Returns
the world position

◆ toString()

String com.orbbec.astra.Joint.toString ( )
inline

To string.

Returns
the string
The documentation for this class was generated from the following file:
  • Joint.java


Astra SDK: com.orbbec.astra.JointStatus Enum Reference

  • com
  • orbbec
  • astra
  • JointStatus
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
com.orbbec.astra.JointStatus Enum Reference
Java Reference

Public Member Functions

int getCode ()

Static Public Member Functions

static JointStatus fromNativeCode (int code)

Public Attributes

NOT_TRACKED =(0)
LOW_CONFIDENCE =(1)
TRACKED =(2)

Detailed Description

The enum Joint status.

Member Data Documentation

◆ LOW_CONFIDENCE

com.orbbec.astra.JointStatus.LOW_CONFIDENCE =(1)

Low confidence joint status.

◆ NOT_TRACKED

com.orbbec.astra.JointStatus.NOT_TRACKED =(0)

Not tracked joint status.

◆ TRACKED

com.orbbec.astra.JointStatus.TRACKED =(2)

Tracked joint status.

The documentation for this enum was generated from the following file:
  • JointStatus.java


Astra SDK: com.orbbec.astra.JointType Enum Reference

  • com
  • orbbec
  • astra
  • JointType
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
com.orbbec.astra.JointType Enum Reference
Java Reference

Public Member Functions

JointType (int code)
int getCode ()

Static Public Member Functions

[static initializer]

Public Attributes

HEAD =(0)
SHOULDER_SPINE =(1)
LEFT_SHOULDER =(2)
LEFT_ELBOW =(3)
LEFT_HAND =(4)
RIGHT_SHOULDER =(5)
RIGHT_ELBOW =(6)
RIGHT_HAND =(7)
MID_SPINE =(8)
BASE_SPINE =(9)
LEFT_HIP =(10)
LEFT_KNEE =(11)
LEFT_FOOT =(12)
RIGHT_HIP =(13)
RIGHT_KNEE =(14)
RIGHT_FOOT =(15)
LEFT_WRIST =(16)
RIGHT_WRIST =(17)
NECK =(18)
UNKNOWN =(255)
The documentation for this enum was generated from the following file:
  • JointType.java


Astra SDK: com.orbbec.astra.MaskedColorFrame Class Reference

  • com
  • orbbec
  • astra
  • MaskedColorFrame
Static Public Member Functions | Static Public Attributes | List of all members
com.orbbec.astra.MaskedColorFrame Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.MaskedColorFrame:
com.orbbec.astra.ImageFrame com.orbbec.astra.DataFrame

Static Public Member Functions

static MaskedColorFrame | get (ReaderFrame readerFrame, int subtype)
static MaskedColorFrame | get (ReaderFrame readerFrame)

Static Public Attributes

static final StreamType STREAM_TYPE = MaskedColorStream.STREAM_TYPE

Additional Inherited Members

- Public Member Functions inherited from com.orbbec.astra.ImageFrame
int | getWidth ()
int | getHeight ()
PixelFormat getPixelFormat ()
int | getBytesPerPixel ()
ByteBuffer | getByteBuffer ()
- Public Member Functions inherited from com.orbbec.astra.DataFrame
int | getFrameIndex ()
boolean | isValid ()
- Protected Member Functions inherited from com.orbbec.astra.ImageFrame
ImageFrame (long handle)
- Protected Member Functions inherited from com.orbbec.astra.DataFrame
DataFrame (long handle)
- Static Protected Member Functions inherited from com.orbbec.astra.ImageFrame
static long | getImageFrameHandle (ReaderFrame frame, int type, int subtype)
- Protected Attributes inherited from com.orbbec.astra.DataFrame
long | handle

Detailed Description

The type Masked color frame.

Member Function Documentation

◆ get() [1/2]

static MaskedColorFrame com.orbbec.astra.MaskedColorFrame.get | ( | ReaderFrame | readerFrame,
 |  | int | subtype
 | ) |  |
inlinestatic

Get masked color frame.

Parameters
readerFrame | the reader frame
subtype | the subtype
Returns
the masked color frame

◆ get() [2/2]

static MaskedColorFrame com.orbbec.astra.MaskedColorFrame.get ( ReaderFrame readerFrame )
inlinestatic

Get masked color frame.

Parameters
readerFrame the reader frame
Returns
the masked color frame
The documentation for this class was generated from the following file:
  • MaskedColorFrame.java


Astra SDK: com.orbbec.astra.MaskedColorStream Class Reference

  • com
  • orbbec
  • astra
  • MaskedColorStream
Static Public Member Functions | Static Public Attributes | Protected Member Functions | List of all members
com.orbbec.astra.MaskedColorStream Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.MaskedColorStream:
com.orbbec.astra.DataStream

Static Public Member Functions

static MaskedColorStream | get (StreamReader reader, int subtype)
static MaskedColorStream | get (StreamReader reader)

Static Public Attributes

static final StreamType STREAM_TYPE = StreamType.MASKED_COLOR

Protected Member Functions

MaskedColorStream (long handle)
- Protected Member Functions inherited from com.orbbec.astra.DataStream
DataStream (long handle)

Additional Inherited Members

- Public Member Functions inherited from com.orbbec.astra.DataStream
void | start ()
void | stop ()
StreamType getType ()
int | getSubtype ()
boolean | getIsAvailable ()
- Static Protected Member Functions inherited from com.orbbec.astra.DataStream
static long | getFrameHandle (ReaderFrame frame, int type, int subtype)
- Protected Attributes inherited from com.orbbec.astra.DataStream
long | handle

Detailed Description

The type Masked color stream.

Member Function Documentation

◆ get() [1/2]

static MaskedColorStream com.orbbec.astra.MaskedColorStream.get | ( | StreamReader | reader,
 |  | int | subtype
 | ) |  |
inlinestatic

Get masked color stream.

Parameters
reader | the reader
subtype | the subtype
Returns
the masked color stream

◆ get() [2/2]

static MaskedColorStream com.orbbec.astra.MaskedColorStream.get ( StreamReader reader )
inlinestatic

Get masked color stream.

Parameters
reader the reader
Returns
the masked color stream
The documentation for this class was generated from the following file:
  • MaskedColorStream.java


Astra SDK: com.orbbec.astra.Matrix3 Class Reference

  • com
  • orbbec
  • astra
  • Matrix3
Public Member Functions | Static Public Attributes | List of all members
com.orbbec.astra.Matrix3 Class Reference
Java Reference

Public Member Functions

Matrix3 (float[] values)
float [] | getValues ()
void | setValues (float[] values)
Vector3D | getAxisX ()
Vector3D | getAxisY ()
Vector3D | getAxisZ ()
String | toString ()

Static Public Attributes

static final int | M00 = 0
static final int | M10 = 1
static final int | M20 = 2
static final int | M01 = 3
static final int | M11 = 4
static final int | M21 = 5
static final int | M02 = 6
static final int | M12 = 7
static final int | M22 = 8
The documentation for this class was generated from the following file:
  • Matrix3.java


Astra SDK: com.orbbec.astra.PixelFormat Enum Reference

  • com
  • orbbec
  • astra
  • PixelFormat
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
com.orbbec.astra.PixelFormat Enum Reference
Java Reference

Public Member Functions

int | getBytesPerPixel ()
int | getCode ()

Static Public Member Functions

static PixelFormat fromNativeCode (int code)

Public Attributes

UNKNOWN =(0)
DEPTH_MM =(100)
RGB888 =(200)
YUV422 =(201)
YUVY =(202)
RGBA =(203)
GRAY8 =(300)
GRAY16 =(301)
POINT =(400)
The documentation for this enum was generated from the following file:
  • PixelFormat.java


Astra SDK: com.orbbec.astra.Plane Class Reference

  • com
  • orbbec
  • astra
  • Plane
Public Member Functions | List of all members
com.orbbec.astra.Plane Class Reference
Java Reference

Public Member Functions

Plane (float a, float b, float c, float d)
float | getA ()
float | getB ()
float | getC ()
float | getD ()
String | toString ()

Detailed Description

3D geometric plane Represents a 3D plane. The normal of the plane is defined to be(A, B, C). The plane coefficients and real world coordinates(x, y, and z) are related by the plane equation: Ax + By + Cz + D = 0

The documentation for this class was generated from the following file:
  • Plane.java


Astra SDK: com.orbbec.astra.PointFrame Class Reference

  • com
  • orbbec
  • astra
  • PointFrame
Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
com.orbbec.astra.PointFrame Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.PointFrame:
com.orbbec.astra.ImageFrame com.orbbec.astra.DataFrame

Public Member Functions

FloatBuffer | getPointBuffer ()
- Public Member Functions inherited from com.orbbec.astra.ImageFrame
int | getWidth ()
int | getHeight ()
PixelFormat getPixelFormat ()
int | getBytesPerPixel ()
ByteBuffer | getByteBuffer ()
- Public Member Functions inherited from com.orbbec.astra.DataFrame
int | getFrameIndex ()
boolean | isValid ()

Static Public Member Functions

static PointFrame | get (ReaderFrame readerFrame, int subtype)
static PointFrame | get (ReaderFrame readerFrame)

Static Public Attributes

static final StreamType STREAM_TYPE = PointStream.STREAM_TYPE

Additional Inherited Members

- Protected Member Functions inherited from com.orbbec.astra.ImageFrame
ImageFrame (long handle)
- Protected Member Functions inherited from com.orbbec.astra.DataFrame
DataFrame (long handle)
- Static Protected Member Functions inherited from com.orbbec.astra.ImageFrame
static long | getImageFrameHandle (ReaderFrame frame, int type, int subtype)
- Protected Attributes inherited from com.orbbec.astra.DataFrame
long | handle

Detailed Description

The type Point frame.

Member Function Documentation

◆ get() [1/2]

static PointFrame com.orbbec.astra.PointFrame.get | ( | ReaderFrame | readerFrame,
 |  | int | subtype
 | ) |  |
inlinestatic

Get point frame.

Parameters
readerFrame | the reader frame
subtype | the subtype
Returns
the point frame

◆ get() [2/2]

static PointFrame com.orbbec.astra.PointFrame.get ( ReaderFrame readerFrame )
inlinestatic

Get point frame.

Parameters
readerFrame the reader frame
Returns
the point frame

◆ getPointBuffer()

FloatBuffer com.orbbec.astra.PointFrame.getPointBuffer ( )
inline

Gets point buffer.

Returns
the point buffer
The documentation for this class was generated from the following file:
  • PointFrame.java


Astra SDK: com.orbbec.astra.PointStream Class Reference

  • com
  • orbbec
  • astra
  • PointStream
Static Public Member Functions | Static Public Attributes | Protected Member Functions | List of all members
com.orbbec.astra.PointStream Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.PointStream:
com.orbbec.astra.DataStream

Static Public Member Functions

static PointStream | get (StreamReader reader, int subtype)
static PointStream | get (StreamReader reader)

Static Public Attributes

static final StreamType STREAM_TYPE = StreamType.POINT

Protected Member Functions

PointStream (long handle)
- Protected Member Functions inherited from com.orbbec.astra.DataStream
DataStream (long handle)

Additional Inherited Members

- Public Member Functions inherited from com.orbbec.astra.DataStream
void | start ()
void | stop ()
StreamType getType ()
int | getSubtype ()
boolean | getIsAvailable ()
- Static Protected Member Functions inherited from com.orbbec.astra.DataStream
static long | getFrameHandle (ReaderFrame frame, int type, int subtype)
- Protected Attributes inherited from com.orbbec.astra.DataStream
long | handle

Detailed Description

The type Point stream.

Member Function Documentation

◆ get() [1/2]

static PointStream com.orbbec.astra.PointStream.get | ( | StreamReader | reader,
 |  | int | subtype
 | ) |  |
inlinestatic

Get point stream.

Parameters
reader | the reader
subtype | the subtype
Returns
the point stream

◆ get() [2/2]

static PointStream com.orbbec.astra.PointStream.get ( StreamReader reader )
inlinestatic

Get point stream.

Parameters
reader the reader
Returns
the point stream
The documentation for this class was generated from the following file:
  • PointStream.java


Astra SDK: com.orbbec.astra.ReaderFrame Class Reference

  • com
  • orbbec
  • astra
  • ReaderFrame
Public Member Functions | Protected Member Functions | List of all members
com.orbbec.astra.ReaderFrame Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.ReaderFrame:

Public Member Functions

void close ()

Protected Member Functions

void finalize () throws Throwable

Detailed Description

The type Reader frame. Get frames of started streams.

Member Function Documentation

◆ close()

void com.orbbec.astra.ReaderFrame.close ( )
inline

Close.

The documentation for this class was generated from the following file:
  • ReaderFrame.java


Astra SDK: com.orbbec.astra.SkeletonOptimization Enum Reference

  • com
  • orbbec
  • astra
  • SkeletonOptimization
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
com.orbbec.astra.SkeletonOptimization Enum Reference
Java Reference

Public Member Functions

int getCode ()

Static Public Member Functions

static SkeletonOptimization fromNativeCode (int code)

Public Attributes

OPTIMIZATION1 =(1)
MINIMIZE_MEMORY =(2)
OPTIMIZATION2 =(2)
OPTIMIZATION3 =(3)
OPTIMIZATION4 =(4)
OPTIMIZATION5 =(5)
BALANCED =(5)
OPTIMIZATION6 =(6)
OPTIMIZATION7 =(7)
OPTIMIZATION8 =(8)
OPTIMIZATION9 =(9)
BEST_ACCURACY =(9)

Member Data Documentation

◆ BALANCED

com.orbbec.astra.SkeletonOptimization.BALANCED =(5)

Configuration that balances accuracy with lower memory and CPU usage

◆ BEST_ACCURACY

com.orbbec.astra.SkeletonOptimization.BEST_ACCURACY =(9)

Configuration that produces the best tracking accuracy

◆ MINIMIZE_MEMORY

com.orbbec.astra.SkeletonOptimization.MINIMIZE_MEMORY =(2)

Configuration that minimizes memory usage at a cost of lower tracking accuracy

The documentation for this enum was generated from the following file:
  • SkeletonOptimization.java


Astra SDK: com.orbbec.astra.SkeletonProfile Enum Reference

  • com
  • orbbec
  • astra
  • SkeletonProfile
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
com.orbbec.astra.SkeletonProfile Enum Reference
Java Reference

Public Member Functions

int getCode ()

Static Public Member Functions

static SkeletonProfile fromNativeCode (int code)

Public Attributes

FULL =(0)
UPPER_BODY =(1)
BASIC =(2)

Detailed Description

The enum Skeleton profile.

Member Data Documentation

◆ BASIC

com.orbbec.astra.SkeletonProfile.BASIC =(2)

Basic skeleton profile, only four joints: Head, MidSpine, LeftHand, RightHand.

◆ FULL

com.orbbec.astra.SkeletonProfile.FULL =(0)

Full skeleton profile.

◆ UPPER_BODY

com.orbbec.astra.SkeletonProfile.UPPER_BODY =(1)

Upper body skeleton profile.

The documentation for this enum was generated from the following file:
  • SkeletonProfile.java


Astra SDK: com.orbbec.astra.StreamDescription Class Reference

  • com
  • orbbec
  • astra
  • StreamDescription
Public Member Functions | List of all members
com.orbbec.astra.StreamDescription Class Reference
Java Reference

Public Member Functions

StreamType getType ()
int | getTypeCode ()
int | getSubtype ()
String | toString ()

Detailed Description

The type Stream description.

Member Function Documentation

◆ getSubtype()

int com.orbbec.astra.StreamDescription.getSubtype ( )
inline

Gets subtype.

Returns
the subtype

◆ getType()

StreamType com.orbbec.astra.StreamDescription.getType ( )
inline

Gets type.

Returns
the type

◆ getTypeCode()

int com.orbbec.astra.StreamDescription.getTypeCode ( )
inline

Gets type code.

Returns
the type code

◆ toString()

String com.orbbec.astra.StreamDescription.toString ( )
inline

To string.

Returns
the string
The documentation for this class was generated from the following file:
  • StreamDescription.java


Astra SDK: com.orbbec.astra.StreamReader.FrameListener Interface Reference

  • com
  • orbbec
  • astra
  • StreamReader
  • FrameListener
Public Member Functions | List of all members
com.orbbec.astra.StreamReader.FrameListener Interface Reference
Java Reference

Public Member Functions

void onFrameReady (StreamReader reader, ReaderFrame frame)

Detailed Description

The interface Frame listener.

Member Function Documentation

◆ onFrameReady()

void com.orbbec.astra.StreamReader.FrameListener.onFrameReady | ( | StreamReader | reader,
 |  | ReaderFrame | frame
 | ) |  |

On frame ready.

Parameters
reader | the reader
frame | the frame
The documentation for this interface was generated from the following file:
  • StreamReader.java


Astra SDK: com.orbbec.astra.StreamReader Class Reference

  • com
  • orbbec
  • astra
  • StreamReader
Classes | Public Member Functions | Protected Member Functions | List of all members
com.orbbec.astra.StreamReader Class Reference
Java Reference

Classes

interface FrameListener

Public Member Functions

void | addFrameListener (FrameListener listener)
void | removeFrameListener (FrameListener listener)
boolean | hasNewFrame ()
ReaderFrame openFrame ()
void | destroy ()

Protected Member Functions

void finalize () throws Throwable

Detailed Description

The type Stream reader.

Member Function Documentation

◆ addFrameListener()

void com.orbbec.astra.StreamReader.addFrameListener ( FrameListener listener )
inline

Add frame listener.

Parameters
listener the listener

◆ destroy()

void com.orbbec.astra.StreamReader.destroy ( )
inline

Destroy.

◆ finalize()

void com.orbbec.astra.StreamReader.finalize ( ) throws Throwable
inlineprotected

Finalize. Will call destroy.

Exceptions
Throwable the throwable

◆ hasNewFrame()

boolean com.orbbec.astra.StreamReader.hasNewFrame ( )
inline

Has new frame boolean.

Returns
the boolean

◆ openFrame()

ReaderFrame com.orbbec.astra.StreamReader.openFrame ( )
inline

Open frame.

Returns
the frame

◆ removeFrameListener()

void com.orbbec.astra.StreamReader.removeFrameListener ( FrameListener listener )
inline

Remove frame listener.

Parameters
listener the listener
The documentation for this class was generated from the following file:
  • StreamReader.java


Astra SDK: com.orbbec.astra.StreamSet Class Reference

  • com
  • orbbec
  • astra
  • StreamSet
Public Member Functions | Static Public Member Functions | Protected Member Functions | List of all members
com.orbbec.astra.StreamSet Class Reference
Java Reference
Inheritance diagram for com.orbbec.astra.StreamSet:

Public Member Functions

String | getUri ()
StreamReader createReader ()
boolean | getIsAvailable ()
void | close () throws IOException

Static Public Member Functions

static StreamSet | open (String connectionString)
static StreamSet | open ()

Protected Member Functions

void finalize () throws Throwable

Detailed Description

The type Stream set.

Member Function Documentation

◆ close()

void com.orbbec.astra.StreamSet.close ( ) throws IOException
inline

Close.

Exceptions
IOException the io exception

◆ createReader()

StreamReader com.orbbec.astra.StreamSet.createReader ( )
inline

Create stream reader.

Returns
the stream reader

◆ finalize()

void com.orbbec.astra.StreamSet.finalize ( ) throws Throwable
inlineprotected

Finalize. Will call close.

Exceptions
Throwable the throwable

◆ getIsAvailable()

boolean com.orbbec.astra.StreamSet.getIsAvailable ( )
inline

Gets is available. Only when the return value is true, you can call /ref getUri or /ref createReader.

Returns
the is available

◆ getUri()

String com.orbbec.astra.StreamSet.getUri ( )
inline

Gets uri of device.

Returns
the uri

◆ open() [1/2]

static StreamSet com.orbbec.astra.StreamSet.open ( String connectionString )
inlinestatic

Open stream set.

Parameters
connectionString the connection string, like "device/sensor0", "device/sensor1" and so on
Returns
the stream set

◆ open() [2/2]

static StreamSet com.orbbec.astra.StreamSet.open ( )
inlinestatic

Open stream set. will open default device.

Returns
the stream set
The documentation for this class was generated from the following file:
  • StreamSet.java


Astra SDK: com.orbbec.astra.StreamType Enum Reference

  • com
  • orbbec
  • astra
  • StreamType
Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | List of all members
com.orbbec.astra.StreamType Enum Reference
Java Reference

Public Member Functions

int getCode ()

Static Public Member Functions

static StreamType fromNativeStatus (int code)

Public Attributes

UNKNOWN =(0)
DEPTH =(1)
COLOR =(2)
INFRARED =(3)
HAND =(4)
BODY =(5)
STYLIZED_DEPTH =(6)
POINT =(7)
MASKED_COLOR =(8)
COLORIZED_BODY =(9)

Static Public Attributes

static final int DEFAULT_SUBTYPE = 0
The documentation for this enum was generated from the following file:
  • StreamType.java


Astra SDK: com.orbbec.astra.UsbDeviceInfo Class Reference

  • com
  • orbbec
  • astra
  • UsbDeviceInfo
Public Member Functions | List of all members
com.orbbec.astra.UsbDeviceInfo Class Reference
Java Reference

Public Member Functions

int | getProductId ()
int | getVendorId ()
String | toString ()

Detailed Description

The type Usb device info.

Member Function Documentation

◆ getProductId()

int com.orbbec.astra.UsbDeviceInfo.getProductId ( )
inline

Gets product id.

Returns
the product id

◆ getVendorId()

int com.orbbec.astra.UsbDeviceInfo.getVendorId ( )
inline

Gets vendor id.

Returns
the vendor id

◆ toString()

String com.orbbec.astra.UsbDeviceInfo.toString ( )
inline

To string.

Returns
the string
The documentation for this class was generated from the following file:
  • src/main/java/com/orbbec/astra/UsbDeviceInfo.java


Astra SDK: com.orbbec.astra.Vector2D Class Reference

  • com
  • orbbec
  • astra
  • Vector2D
Public Member Functions | List of all members
com.orbbec.astra.Vector2D Class Reference
Java Reference

Public Member Functions

Vector2D (float x, float y)
float | getX ()
void | setX (float x)
float | getY ()
void | setY (float y)
String | toString ()
The documentation for this class was generated from the following file:
  • Vector2D.java


Astra SDK: com.orbbec.astra.Vector3D Class Reference

  • com
  • orbbec
  • astra
  • Vector3D
Public Member Functions | List of all members
com.orbbec.astra.Vector3D Class Reference
Java Reference

Public Member Functions

Vector3D (float x, float y, float z)
float | getX ()
void | setX (float x)
float | getY ()
void | setY (float y)
float | getZ ()
void | setZ (float z)
String | toString ()
The documentation for this class was generated from the following file:
  • Vector3D.java


Astra SDK: Android Reference

Classes
Android Reference

Classes

class | com.orbbec.astra.android.AstraAndroidContext
interface | com.orbbec.astra.android.AstraDeviceManagerListener

Detailed Description

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: com.orbbec.astra.android.AstraAndroidContext Class Reference

  • com
  • orbbec
  • astra
  • android
  • AstraAndroidContext
Public Member Functions | Static Public Member Functions | List of all members
com.orbbec.astra.android.AstraAndroidContext Class Reference
Android Reference

Public Member Functions

AstraAndroidContext (Context androidContext)
AstraAndroidContext (Context androidContext, final AstraDeviceManagerListener listener)
int | getAvailableDevicesSize ()
void | initialize ()
void | openAllDevices ()
void | terminate ()

Static Public Member Functions

static native void set_android_context (Context appContext, String packageName)

Detailed Description

The class responsible for initializing and terminating the native portion of the Astra SDK on Android.

Additionally it provides support for permissions acquisition from Android when opening Astra devices

Constructor & Destructor Documentation

◆ AstraAndroidContext() [1/2]

com.orbbec.astra.android.AstraAndroidContext.AstraAndroidContext ( Context androidContext )
inline

Instantiates a new Astra android context.

Parameters
androidContext the android context

◆ AstraAndroidContext() [2/2]

com.orbbec.astra.android.AstraAndroidContext.AstraAndroidContext | ( | Context | androidContext,
 |  | final AstraDeviceManagerListener | listener
 | ) |  |
inline

Instantiates a new Astra android context.

Parameters
androidContext | the android context
listener | the listener

Member Function Documentation

◆ getAvailableDevicesSize()

int com.orbbec.astra.android.AstraAndroidContext.getAvailableDevicesSize ( )
inline

Gets number of available devices.

Returns
the number

◆ initialize()

void com.orbbec.astra.android.AstraAndroidContext.initialize ( )
inline

Initializes the Astra SDK. Use this instead of Astra.initialize() on Android.

◆ openAllDevices()

void com.orbbec.astra.android.AstraAndroidContext.openAllDevices ( )
inline

Opens all Orbbec Astra devices connected to Android device. If you instantiate this context with AstraDeviceManagerListener, you can get states of openning devices.

◆ terminate()

void com.orbbec.astra.android.AstraAndroidContext.terminate ( )
inline

Terminates the Astra SDK Use this instead of Astra.terminate() on Android.

The documentation for this class was generated from the following file:
  • AstraAndroidContext.java


Astra SDK: com.orbbec.astra.android.AstraDeviceManagerListener Interface Reference

  • com
  • orbbec
  • astra
  • android
  • AstraDeviceManagerListener
Public Member Functions | List of all members
com.orbbec.astra.android.AstraDeviceManagerListener Interface Reference
Android Reference

Public Member Functions

void | onOpenAllDevicesCompleted (Iterable< UsbDevice > availableDevices)
void | onOpenDeviceCompleted (UsbDevice device, boolean opened)
void | onNoDevice ()
void | onPermissionDenied (UsbDevice device)

Detailed Description

The interface Astra device manager listener.

Member Function Documentation

◆ onNoDevice()

void com.orbbec.astra.android.AstraDeviceManagerListener.onNoDevice ( )

On no device.

◆ onOpenAllDevicesCompleted()

void com.orbbec.astra.android.AstraDeviceManagerListener.onOpenAllDevicesCompleted ( Iterable< UsbDevice > availableDevices )

On open all devices completed. If availableDevices contains at least one device, you can continue.

Parameters
availableDevices the available devices

◆ onOpenDeviceCompleted()

void com.orbbec.astra.android.AstraDeviceManagerListener.onOpenDeviceCompleted | ( | UsbDevice | device,
 |  | boolean | opened
 | ) |  |

On open device completed. Not used currently.

Parameters
device | the device
opened | the opened

◆ onPermissionDenied()

void com.orbbec.astra.android.AstraDeviceManagerListener.onPermissionDenied ( UsbDevice device )

On permission denied.

Parameters
device the device
The documentation for this interface was generated from the following file:
  • AstraDeviceManagerListener.java


Astra SDK: Namespace Members

Here is a list of all documented namespace members with links to the namespaces they belong to:
  • BodyFeatures : Astra
  • BodyStatus : Astra
  • BodyTrackingFeatures : Astra
  • HandPose : Astra
  • JointStatus : Astra
  • SkeletonOptimization : Astra
  • SkeletonProfile : Astra


Astra SDK: Namespace Members

  • BodyFeatures : Astra
  • BodyStatus : Astra
  • BodyTrackingFeatures : Astra
  • HandPose : Astra
  • JointStatus : Astra
  • SkeletonOptimization : Astra
  • SkeletonProfile : Astra


Astra SDK: Class List

Class List
Here are the classes, structs, unions and interfaces with brief descriptions:
[detail level 123456]
►N Astra |
►N Core |
C GcHandleWrapper |
C ImageMetadata |
►N Extensions |
C IntPtrExtensions |
C AstraException |
C Body |
C BodyFrame |
C BodyFrameInfo |
C BodyMask |
C BodyStream |
C BodyTracking |
C ColorFrame |
C ColorizedBodyFrame |
C ColorizedBodyStream |
C ColorStream |
C Context |
C CoordinateMapper |
C DataFrame |
C DataStream |
C DepthFrame |
C DepthStream |
C FloorInfo |
C FloorMask |
C FrameReadyEventArgs |
C HandPoseInfo |
C ImageFrame |
C ImageMode |
C ImageStream |
C InfraredFrame |
C InfraredStream |
C Joint |
C MaskedColorFrame |
C MaskedColorStream |
C Matrix3x3 | Represents a 3x3 rotation matrix.
C Plane | 3D geometric plane Represents a 3D plane. The normal of the plane is defined to be(A, B, C). The plane coefficients and real world coordinates(x, y, and z) are related by the plane equation: Ax + By + Cz + D = 0
C PointFrame |
C PointStream |
C ReaderFrame | Contains frames from opened streams.
C StreamDescription |
C StreamReader |
C StreamSet | A StreamSet represents a logical group of related streams, the most common of these being an Astra camera device
C StreamTypeRegistry |
C USBInfo |
C Vector2D | Represents a float 2d vector
C Vector3D | Represents a float 3d vector
►N astra |
C _Unique_if |
C _Unique_if< _Ty[]> |
C _Unique_if< _Ty[N]> |
C Array | Simple wrapper around primitive arrays
C BitmapMask | Bitmap representing a 2d mask
C Body | Human body
C BodyFrame | Body tracking information produced by a BodyTracker instance
C BodyFrameInfo |
C BodyStream | A Body Data Stream
C ColorFrame | Color frame of rgb format
C ColorizedBodyFrame | A Colorized Body Frame
C ColorizedBodyStream | A Colorized Body Stream
C ColorStream | A color stream
C CoordinateMapper | CoordinateMapper
C DataStream | Data Stream
C DebugHandFrame | A Debug Hand Frame
C DebugHandStream | A Debug Hand Stream
C DepthFrame | A Depth Frame
C DepthStream | A Depth Stream
C FloorInfo |
C Frame | Frame class
C FrameListener | Frame Listener class
C HandFrame | A Hand Data Frame
C HandPoint | Hand Point struct
C HandPoseInfo |
C HandStream | A Hand Stream
C ImageFrame | Basic Image Frame
C ImageStream | Basic Image Stream
C ImageStreamMode | Image Stream Mode
C InfraredFrame16 | A Infrared Frame use 16bit unsigned short format
C InfraredFrameRgb | A Infrared Frame use rgb format
C InfraredStream | A Infrared Stream
C Joint | Body joint
C MaskedColorFrame | A Masked Color Frame of Masked Color Stream
C MaskedColorStream | A Masked Color Stream
C Matrix3x3 | Represents a 3x3 rotation matrix
C Plane | 3D geometric plane
C PointFrame | A Point Data Frame
C PointStream | A Point Data Stream
C RawColorFrame | Color frame of raw format
C RgbaPixel | Rgba pixel struct
C RgbPixel | Rgb pixel struct
C StreamDescription | Stream Description class
C StreamReader | Stream Reader class
C StreamServiceProxy | Stream Service Proxy Class
C StreamSet | Stream Set Class
C Vector2f | Represents a float 2d vector
C Vector2i | Represents a float 2d vector
C Vector3f | Represents a float 3d vector
C Vector3i | Represents a float 3d vector
►N com |
►N orbbec |
►N astra |
►N android |
►N unity3d |
C AstraUnityPlayerActivity |
C AndroidCamera |
C AstraAndroidContext |
C AstraDeviceManager |
C AstraDeviceManagerListener |
C AstraDeviceMonitorActivity |
►C UsbDeviceAccessBroker |
C UsbDeviceAccessEventListener |
C UsbDeviceInfo |
C ApiStatus |
C Astra |
C Body |
C BodyFrame |
C BodyFrameInfo |
C BodyMask |
C BodyStatus |
C BodyStream |
C BodyTracking |
C BodyTrackingFeatureFlags |
C ColorFrame |
C ColorizedBodyFrame |
C ColorizedBodyStream |
C ColorStream |
C CoordinateMapper |
C DataFrame |
C DataStream |
C DepthFrame |
C DepthStream |
C FloorInfo |
C FloorMask |
C HandPose |
C HandPoseInfo |
C ImageFrame |
C ImageMetadata |
C ImageStream |
C ImageStreamMode |
C InfraredFrame |
C InfraredStream |
C Joint |
C JointStatus |
C JointType |
C MaskedColorFrame |
C MaskedColorStream |
C Matrix3 |
C PixelFormat |
C Plane |
C PointFrame |
C PointStream |
C ReaderFrame |
C SkeletonOptimization |
C SkeletonProfile |
C StreamDescription |
►C StreamReader |
C FrameListener |
C StreamSet |
C StreamType |
C UsbDeviceInfo |
C Vector2D |
C Vector3D |
C _astra_bitmapmask | Struct representing a 2-dimensional bitmask
C _astra_body | Struct containing body tracking information
C _astra_body_list | Struct containing a variable-sized array of astra_body_t structs
C _astra_bodyframe |
C _astra_bodyframe_info | Struct containing general body frame information
C _astra_bodyframe_wrapper |
C _astra_floor_info | Struct containing floor information about the scene
C _astra_frame |
C _astra_handframe |
C _astra_handframe_wrapper |
C _astra_handpose_info |
C _astra_imageframe |
C _astra_imageframe_wrapper |
C _astra_joint | Joint information
C _astra_matrix3x3 | Represents a 3x3 rotation matrix
C _astra_plane | Struct representing a geometric 3-dimensional plane
C _astra_reader_callback_id |
C _astra_streamconnection |
C astra_body_feature_command_t |
C astra_conversion_cache_t |
C astra_handpoint_t |
C astra_image_metadata_t |
C astra_imagestream_mode_t |
C astra_plugin_info_t |
C astra_pluginservice_proxy_t |
C astra_rgb_pixel_t |
C astra_rgba_pixel_t |
C astra_stream_desc_t |
C astra_streamservice_proxy_t |
C astra_usb_info_t |
C astra_vector2f_t |
C astra_vector2i_t |
C astra_vector3f_t |
C astra_vector3i_t |
C astra_version_info_t |
C stream_callbacks_t |


Astra SDK: Astra.Core.GcHandleWrapper Class Reference

  • Astra
  • Core
  • GcHandleWrapper
Public Member Functions | Properties | List of all members
Astra.Core.GcHandleWrapper Class Reference
Inheritance diagram for Astra.Core.GcHandleWrapper:

Public Member Functions

GcHandleWrapper (GCHandle handle)
IntPtr | AddrOfPinnedObject ()
void | Dispose ()

Properties

bool | IsAllocated [get]
object | Target [get]
The documentation for this class was generated from the following file:
  • GCHandleWrapper.cs


Astra SDK: Astra.Core.ImageMetadata Struct Reference

  • Astra
  • Core
  • ImageMetadata
Public Member Functions | Properties | List of all members
Astra.Core.ImageMetadata Struct Reference

Public Member Functions

ImageMetadata (int width, int height, PixelFormat pixelFormat)

Properties

int | Width [get]
int | Height [get]
PixelFormat | PixelFormat [get]
The documentation for this struct was generated from the following file:
  • ImageMetadata.cs


Astra SDK: Astra.Extensions Namespace Reference

  • Astra
  • Extensions
Classes
Astra.Extensions Namespace Reference

Classes

class IntPtrExtensions


Astra SDK: Astra.Extensions.IntPtrExtensions Class Reference

  • Astra
  • Extensions
  • IntPtrExtensions
Static Public Member Functions | List of all members
Astra.Extensions.IntPtrExtensions Class Reference

Static Public Member Functions

static void | ThrowIfNull (this IntPtr ptr)
static void | ThrowIfNull (this IntPtr ptr, string message)
The documentation for this class was generated from the following file:
  • IntPtrExtensions.cs


Astra SDK: Astra.AstraException Class Reference

  • Astra
  • AstraException
Public Member Functions | Protected Member Functions | List of all members
Astra.AstraException Class Reference
Inheritance diagram for Astra.AstraException:

Public Member Functions

AstraException (string message)
AstraException (string message, Exception innerException)

Protected Member Functions

AstraException (SerializationInfo info, StreamingContext context)
The documentation for this class was generated from the following file:
  • AstraException.cs


Astra SDK: Astra.Body Class Reference

  • Astra
  • Body
Public Member Functions | Properties | List of all members
Astra.Body Class Reference

Public Member Functions

Body (byte id, BodyStatus status, BodyFeatures features, Vector3D centerOfMass, Joint[] joints, HandPoseInfo handPoseInfo)
override string ToString ()

Properties

byte | Id [get]
BodyStatus | Status [get]
Vector3D | CenterOfMass [get]
Joint [] | Joints [get]
HandPoseInfo | HandPoseInfo [get]
bool | AreJointsEnabled [get]
bool | AreHandPosesEnabled [get]

Property Documentation

◆ AreHandPosesEnabled

bool Astra.Body.AreHandPosesEnabled
get

Return if enabled to recognizing hand poses

◆ AreJointsEnabled

bool Astra.Body.AreJointsEnabled
get

Return if enabled to tracking Joints

The documentation for this class was generated from the following file:
  • Body.cs


Astra SDK: Astra.BodyFrame Class Reference

  • Astra
  • BodyFrame
Public Member Functions | Public Attributes | Properties | List of all members
Astra.BodyFrame Class Reference
Inheritance diagram for Astra.BodyFrame:
Astra.DataFrame

Public Member Functions

void CopyBodyData (ref Body[] bodies)
BodyFrame (IntPtr handle)

Public Attributes

const int | MaxBodies = Native.BodyFrame.MaxBodies
const int | BodyCount = 6

Properties

override int | StreamType [get]
int | Width [get]
int | Height [get]
bool | IsEstimated [get]
BodyMask | BodyMask [get]
FloorInfo | FloorInfo [get]
- Properties inherited from Astra.DataFrame
long | FrameIndex [get]
abstract int | StreamType [get]
IntPtr | Handle [get]

Additional Inherited Members

- Protected Member Functions inherited from Astra.DataFrame
DataFrame (IntPtr handle)

Property Documentation

◆ BodyMask

BodyMask Astra.BodyFrame.BodyMask
get

Gets body mask.

Returns
the body mask

◆ FloorInfo

FloorInfo Astra.BodyFrame.FloorInfo
get

Gets floor info.

Returns
the floor info

◆ Height

int Astra.BodyFrame.Height
get

Gets height of BodyFrame. Currently the same as height of BodyMask.

Returns
the height

◆ IsEstimated

bool Astra.BodyFrame.IsEstimated
get

Gets if the frame was estimated due to a slow CPU. .

Returns
the bool

◆ Width

int Astra.BodyFrame.Width
get

Gets width of BodyFrame. Currently the same as width of BodyMask.

Returns
the width
The documentation for this class was generated from the following file:
  • BodyFrame.cs


Astra SDK: Astra.BodyFrameInfo Struct Reference

  • Astra
  • BodyFrameInfo
Public Member Functions | Properties | List of all members
Astra.BodyFrameInfo Struct Reference

Public Member Functions

BodyFrameInfo (int width, int height, bool isEstimated)

Properties

int | Width [get]
int | Height [get]
bool | IsEstimated [get]
The documentation for this struct was generated from the following file:
  • BodyFrameInfo.cs


Astra SDK: Astra.BodyMask Class Reference

  • Astra
  • BodyMask
Public Member Functions | Properties | List of all members
Astra.BodyMask Class Reference

Public Member Functions

BodyMask (IntPtr handle, int width, int height, IntPtr dataPtr)
virtual void CopyData (ref byte[] data)

Properties

int | Width [get]
int | Height [get]
IntPtr | DataPtr [get]
The documentation for this class was generated from the following file:
  • BodyMask.cs


Astra SDK: Astra.BodyStream Class Reference

  • Astra
  • BodyStream
Public Member Functions | List of all members
Astra.BodyStream Class Reference
Inheritance diagram for Astra.BodyStream:
Astra.DataStream

Public Member Functions

BodyStream (IntPtr handle)
BodyTrackingFeatures | GetDefaultBodyFeatures ()
void | SetDefaultBodyFeatures (BodyTrackingFeatures features)
SkeletonProfile | GetSkeletonProfile ()
void | SetSkeletonProfile (SkeletonProfile skeletonProfile)
SkeletonOptimization | GetSkeletonOptimization ()
void | SetSkeletonOptimization (SkeletonOptimization skeletonOptimization)
BodyTrackingFeatures | GetBodyFeatures (byte bodyId)
void | SetBodyFeatures (byte bodyId, BodyTrackingFeatures features)
- Public Member Functions inherited from Astra.DataStream
void | Start ()
void | Stop ()
void | SetParameter< T > (int parameterId, T parameterValue)
T | GetParameter< T > (int parameterId)

Additional Inherited Members

- Protected Member Functions inherited from Astra.DataStream
DataStream (IntPtr handle)
- Properties inherited from Astra.DataStream
StreamDescription | Description [get]
bool | IsAvailable [get]
IntPtr | Handle [get]

Member Function Documentation

◆ SetSkeletonOptimization()

void Astra.BodyStream.SetSkeletonOptimization ( SkeletonOptimization skeletonOptimization )
inline

Sets skeleton optimization. Will effect the accuracy of bodies.

Parameters
skeletonOptimization the optimization

◆ SetSkeletonProfile()

void Astra.BodyStream.SetSkeletonProfile ( SkeletonProfile skeletonProfile )
inline

Sets skeleton profile. Will effect the joints num of bodies.

Parameters
skeletonProfile the profile
The documentation for this class was generated from the following file:
  • BodyStream.cs


Astra SDK: Astra.BodyTracking Class Reference

  • Astra
  • BodyTracking
Static Public Member Functions | List of all members
Astra.BodyTracking Class Reference

Static Public Member Functions

static void SetLicense (String licenseString)

Member Function Documentation

◆ SetLicense()

static void Astra.BodyTracking.SetLicense ( String licenseString )
inlinestatic

Sets license. Call this function after initialize and before openning stream. When trial expired, you should call this to continue use this version of sdk.

Parameters
licenseString the license string, not name of the license file.
The documentation for this class was generated from the following file:
  • BodyTracking.cs


Astra SDK: Astra.ColorFrame Class Reference

  • Astra
  • ColorFrame
Properties | List of all members
Astra.ColorFrame Class Reference
Inheritance diagram for Astra.ColorFrame:
Astra.ImageFrame< byte >

Properties

override int | StreamType [get]
- Properties inherited from Astra.ImageFrame< byte >
int | Width [get]
int | Height [get]
PixelFormat | PixelFormat [get]
IntPtr | DataPtr [get]
long | ByteLength [get]

Additional Inherited Members

- Public Member Functions inherited from Astra.ImageFrame< byte >
virtual void CopyData (ref T[] data)
- Protected Member Functions inherited from Astra.ImageFrame< byte >
ImageFrame (IntPtr handle)
The documentation for this class was generated from the following file:
  • ColorFrame.cs


Astra SDK: Astra.ColorizedBodyFrame Class Reference

  • Astra
  • ColorizedBodyFrame
Properties | List of all members
Astra.ColorizedBodyFrame Class Reference
Inheritance diagram for Astra.ColorizedBodyFrame:
Astra.ImageFrame< byte >

Properties

override int | StreamType [get]
- Properties inherited from Astra.ImageFrame< byte >
int | Width [get]
int | Height [get]
PixelFormat | PixelFormat [get]
IntPtr | DataPtr [get]
long | ByteLength [get]

Additional Inherited Members

- Public Member Functions inherited from Astra.ImageFrame< byte >
virtual void CopyData (ref T[] data)
- Protected Member Functions inherited from Astra.ImageFrame< byte >
ImageFrame (IntPtr handle)
The documentation for this class was generated from the following file:
  • ColorizedBodyFrame.cs


Astra SDK: Astra.ColorizedBodyStream Class Reference

  • Astra
  • ColorizedBodyStream
Public Attributes | List of all members
Astra.ColorizedBodyStream Class Reference
Inheritance diagram for Astra.ColorizedBodyStream:
Astra.ImageStream Astra.DataStream

Public Attributes

const int StreamType = (int)Core.StreamType.ColorizedBody

Additional Inherited Members

- Public Member Functions inherited from Astra.ImageStream
ImageMode | GetMode ()
void | SetMode (ImageMode mode)
- Public Member Functions inherited from Astra.DataStream
void | Start ()
void | Stop ()
void | SetParameter< T > (int parameterId, T parameterValue)
T | GetParameter< T > (int parameterId)
- Protected Member Functions inherited from Astra.ImageStream
ImageStream (IntPtr handle)
- Protected Member Functions inherited from Astra.DataStream
DataStream (IntPtr handle)
- Properties inherited from Astra.ImageStream
float | VerticalFieldOfView [get]
float | HorizontalFieldOfView [get]
USBInfo | usbInfo [get]
bool | IsMirroring [get, set]
ImageMode [] | AvailableModes [get]
- Properties inherited from Astra.DataStream
StreamDescription | Description [get]
bool | IsAvailable [get]
IntPtr | Handle [get]
The documentation for this class was generated from the following file:
  • ColorizedBodyStream.cs


Astra SDK: Astra.ColorStream Class Reference

  • Astra
  • ColorStream
Public Attributes | List of all members
Astra.ColorStream Class Reference
Inheritance diagram for Astra.ColorStream:
Astra.ImageStream Astra.DataStream

Public Attributes

const int StreamType = (int)Core.StreamType.Color

Additional Inherited Members

- Public Member Functions inherited from Astra.ImageStream
ImageMode | GetMode ()
void | SetMode (ImageMode mode)
- Public Member Functions inherited from Astra.DataStream
void | Start ()
void | Stop ()
void | SetParameter< T > (int parameterId, T parameterValue)
T | GetParameter< T > (int parameterId)
- Protected Member Functions inherited from Astra.ImageStream
ImageStream (IntPtr handle)
- Protected Member Functions inherited from Astra.DataStream
DataStream (IntPtr handle)
- Properties inherited from Astra.ImageStream
float | VerticalFieldOfView [get]
float | HorizontalFieldOfView [get]
USBInfo | usbInfo [get]
bool | IsMirroring [get, set]
ImageMode [] | AvailableModes [get]
- Properties inherited from Astra.DataStream
StreamDescription | Description [get]
bool | IsAvailable [get]
IntPtr | Handle [get]
The documentation for this class was generated from the following file:
  • ColorStream.cs


Astra SDK: Astra.Context Class Reference

  • Astra
  • Context
Static Public Member Functions | List of all members
Astra.Context Class Reference

Static Public Member Functions

static void | Initialize ()
static void | Terminate ()
static void | Update ()

Detailed Description

The type Context.

Member Function Documentation

◆ Initialize()

static void Astra.Context.Initialize ( )
inlinestatic

Initializes the library. This function must be called before calling any other function.

◆ Terminate()

static void Astra.Context.Terminate ( )
inlinestatic

Terminate the library. Usually call this when app exits.

◆ Update()

static void Astra.Context.Update ( )
inlinestatic

Drive the library to get a new frame of stream.

The documentation for this class was generated from the following file:
  • Context.cs


Astra SDK: Astra.CoordinateMapper Class Reference

  • Astra
  • CoordinateMapper
Public Member Functions | List of all members
Astra.CoordinateMapper Class Reference

Public Member Functions

CoordinateMapper (int resolutionX, int resolutionY, float hFov, float vFov)
Vector3D | MapDepthPointToWorldSpace (Vector3D depthPoint)
Vector3D | MapWorldPointToDepthSpace (Vector3D worldPoint)

Detailed Description

The type Coordinate mapper. get world position from depth or get depth position from world.

Constructor & Destructor Documentation

◆ CoordinateMapper()

Astra.CoordinateMapper.CoordinateMapper | ( | int | resolutionX,
 |  | int | resolutionY,
 |  | float | hFov,
 |  | float | vFov
 | ) |  |
inline

Instantiates a new Coordinate mapper.

Parameters
resolutionX | the resolution x
resolutionY | the resolution y
hFov | the h fov
vFov | the v fov

Member Function Documentation

◆ MapDepthPointToWorldSpace()

Vector3D Astra.CoordinateMapper.MapDepthPointToWorldSpace ( Vector3D depthPoint )
inline

Map depth point to world space vector3d.

Parameters
depthPoint the depth point
Returns
the vector 3 d

◆ MapWorldPointToDepthSpace()

Vector3D Astra.CoordinateMapper.MapWorldPointToDepthSpace ( Vector3D worldPoint )
inline

Map world point to depth space vector3d.

Parameters
worldPoint the world point
Returns
the vector 3 d
The documentation for this class was generated from the following file:
  • CoordinateMapper.cs


Astra SDK: Astra.DataFrame Class Reference

  • Astra
  • DataFrame
Protected Member Functions | Properties | List of all members
Astra.DataFrame Class Reference
Inheritance diagram for Astra.DataFrame:
Astra.BodyFrame Astra.ImageFrame< T >

Protected Member Functions

DataFrame (IntPtr handle)

Properties

long | FrameIndex [get]
abstract int | StreamType [get]
IntPtr | Handle [get]
The documentation for this class was generated from the following file:
  • DataFrame.cs


Astra SDK: Astra.DataStream Class Reference

  • Astra
  • DataStream
Public Member Functions | Protected Member Functions | Properties | List of all members
Astra.DataStream Class Referenceabstract
Inheritance diagram for Astra.DataStream:
Astra.BodyStream Astra.ImageStream Astra.PointStream Astra.ColorizedBodyStream Astra.ColorStream Astra.DepthStream Astra.InfraredStream Astra.MaskedColorStream

Public Member Functions

void | Start ()
void | Stop ()
void | SetParameter< T > (int parameterId, T parameterValue)
T | GetParameter< T > (int parameterId)

Protected Member Functions

DataStream (IntPtr handle)

Properties

StreamDescription | Description [get]
bool | IsAvailable [get]
IntPtr | Handle [get]

Detailed Description

The type Data stream. All other stream extends this.

The documentation for this class was generated from the following file:
  • DataStream.cs


Astra SDK: Astra.DepthFrame Class Reference

  • Astra
  • DepthFrame
Properties | List of all members
Astra.DepthFrame Class Reference
Inheritance diagram for Astra.DepthFrame:
Astra.ImageFrame< short >

Properties

override int | StreamType [get]
- Properties inherited from Astra.ImageFrame< short >
int | Width [get]
int | Height [get]
PixelFormat | PixelFormat [get]
IntPtr | DataPtr [get]
long | ByteLength [get]

Additional Inherited Members

- Public Member Functions inherited from Astra.ImageFrame< short >
virtual void CopyData (ref T[] data)
- Protected Member Functions inherited from Astra.ImageFrame< short >
ImageFrame (IntPtr handle)
The documentation for this class was generated from the following file:
  • DepthFrame.cs


Astra SDK: Astra.DepthStream Class Reference

  • Astra
  • DepthStream
Public Attributes | Properties | List of all members
Astra.DepthStream Class Reference
Inheritance diagram for Astra.DepthStream:
Astra.ImageStream Astra.DataStream

Public Attributes

const int StreamType = (int)Core.StreamType.Depth

Properties

int | ChipId [get]
- Properties inherited from Astra.ImageStream
float | VerticalFieldOfView [get]
float | HorizontalFieldOfView [get]
USBInfo | usbInfo [get]
bool | IsMirroring [get, set]
ImageMode [] | AvailableModes [get]
- Properties inherited from Astra.DataStream
StreamDescription | Description [get]
bool | IsAvailable [get]
IntPtr | Handle [get]

Additional Inherited Members

- Public Member Functions inherited from Astra.ImageStream
ImageMode | GetMode ()
void | SetMode (ImageMode mode)
- Public Member Functions inherited from Astra.DataStream
void | Start ()
void | Stop ()
void | SetParameter< T > (int parameterId, T parameterValue)
T | GetParameter< T > (int parameterId)
- Protected Member Functions inherited from Astra.ImageStream
ImageStream (IntPtr handle)
- Protected Member Functions inherited from Astra.DataStream
DataStream (IntPtr handle)
The documentation for this class was generated from the following file:
  • DepthStream.cs


Astra SDK: Astra.FloorInfo Class Reference

  • Astra
  • FloorInfo
Public Member Functions | Properties | List of all members
Astra.FloorInfo Class Reference

Public Member Functions

FloorInfo (FloorMask floorMask, Plane floorPlane, bool isFloorDetected)
override string ToString ()

Properties

FloorMask | FloorMask [get]
Plane | FloorPlane [get]
bool | IsFloorDetected [get]
The documentation for this class was generated from the following file:
  • FloorInfo.cs


Astra SDK: Astra.FloorMask Class Reference

  • Astra
  • FloorMask
Public Member Functions | Properties | List of all members
Astra.FloorMask Class Reference

Public Member Functions

FloorMask (IntPtr handle, int width, int height, IntPtr dataPtr)
virtual void CopyData (ref byte[] data)

Properties

int | Width [get]
int | Height [get]
IntPtr | DataPtr [get]
The documentation for this class was generated from the following file:
  • FloorMask.cs


Astra SDK: Astra.FrameReadyEventArgs Class Reference

  • Astra
  • FrameReadyEventArgs
Public Member Functions | Properties | List of all members
Astra.FrameReadyEventArgs Class Reference
Inheritance diagram for Astra.FrameReadyEventArgs:

Public Member Functions

FrameReadyEventArgs (ReaderFrame frame)

Properties

ReaderFrame Frame [get]
The documentation for this class was generated from the following file:
  • StreamReader.cs


Astra SDK: Astra.HandPoseInfo Struct Reference

  • Astra
  • HandPoseInfo
Public Member Functions | Properties | List of all members
Astra.HandPoseInfo Struct Reference

Public Member Functions

HandPoseInfo (HandPose leftHand, HandPose rightHand)

Properties

HandPose | LeftHand [get]
HandPose | RightHand [get]
The documentation for this struct was generated from the following file:
  • HandPoseInfo.cs


Astra SDK: Astra.ImageFrame< T > Class Template Reference

  • Astra
  • ImageFrame
Public Member Functions | Protected Member Functions | Properties | List of all members
Astra.ImageFrame< T > Class Template Reference
Inheritance diagram for Astra.ImageFrame< T >:
Astra.DataFrame

Public Member Functions

virtual void CopyData (ref T[] data)

Protected Member Functions

ImageFrame (IntPtr handle)
- Protected Member Functions inherited from Astra.DataFrame
DataFrame (IntPtr handle)

Properties

int | Width [get]
int | Height [get]
PixelFormat | PixelFormat [get]
IntPtr | DataPtr [get]
long | ByteLength [get]
- Properties inherited from Astra.DataFrame
long | FrameIndex [get]
abstract int | StreamType [get]
IntPtr | Handle [get]
The documentation for this class was generated from the following file:
  • ImageFrame.cs


Astra SDK: Astra.ImageMode Class Reference

  • Astra
  • ImageMode
Public Member Functions | Properties | List of all members
Astra.ImageMode Class Reference

Public Member Functions

override string ToString ()

Properties

int | Id [get]
int | Width [get]
int | Height [get]
PixelFormat | PixelFormat [get]
int | FramesPerSecond [get]
The documentation for this class was generated from the following file:
  • ImageMode.cs


Astra SDK: Astra.ImageStream Class Reference

  • Astra
  • ImageStream
Public Member Functions | Protected Member Functions | Properties | List of all members
Astra.ImageStream Class Reference
Inheritance diagram for Astra.ImageStream:
Astra.DataStream Astra.ColorizedBodyStream Astra.ColorStream Astra.DepthStream Astra.InfraredStream Astra.MaskedColorStream

Public Member Functions

ImageMode | GetMode ()
void | SetMode (ImageMode mode)
- Public Member Functions inherited from Astra.DataStream
void | Start ()
void | Stop ()
void | SetParameter< T > (int parameterId, T parameterValue)
T | GetParameter< T > (int parameterId)

Protected Member Functions

ImageStream (IntPtr handle)
- Protected Member Functions inherited from Astra.DataStream
DataStream (IntPtr handle)

Properties

float | VerticalFieldOfView [get]
float | HorizontalFieldOfView [get]
USBInfo | usbInfo [get]
bool | IsMirroring [get, set]
ImageMode [] | AvailableModes [get]
- Properties inherited from Astra.DataStream
StreamDescription | Description [get]
bool | IsAvailable [get]
IntPtr | Handle [get]
The documentation for this class was generated from the following file:
  • ImageStream.cs


Astra SDK: Astra.InfraredFrame Class Reference

  • Astra
  • InfraredFrame
Properties | List of all members
Astra.InfraredFrame Class Reference
Inheritance diagram for Astra.InfraredFrame:
Astra.ImageFrame< short >

Properties

override int | StreamType [get]
- Properties inherited from Astra.ImageFrame< short >
int | Width [get]
int | Height [get]
PixelFormat | PixelFormat [get]
IntPtr | DataPtr [get]
long | ByteLength [get]

Additional Inherited Members

- Public Member Functions inherited from Astra.ImageFrame< short >
virtual void CopyData (ref T[] data)
- Protected Member Functions inherited from Astra.ImageFrame< short >
ImageFrame (IntPtr handle)
The documentation for this class was generated from the following file:
  • InfraredFrame.cs


Astra SDK: Astra.InfraredStream Class Reference

  • Astra
  • InfraredStream
Public Attributes | List of all members
Astra.InfraredStream Class Reference
Inheritance diagram for Astra.InfraredStream:
Astra.ImageStream Astra.DataStream

Public Attributes

const int StreamType = (int)Core.StreamType.Infrared

Additional Inherited Members

- Public Member Functions inherited from Astra.ImageStream
ImageMode | GetMode ()
void | SetMode (ImageMode mode)
- Public Member Functions inherited from Astra.DataStream
void | Start ()
void | Stop ()
void | SetParameter< T > (int parameterId, T parameterValue)
T | GetParameter< T > (int parameterId)
- Protected Member Functions inherited from Astra.ImageStream
ImageStream (IntPtr handle)
- Protected Member Functions inherited from Astra.DataStream
DataStream (IntPtr handle)
- Properties inherited from Astra.ImageStream
float | VerticalFieldOfView [get]
float | HorizontalFieldOfView [get]
USBInfo | usbInfo [get]
bool | IsMirroring [get, set]
ImageMode [] | AvailableModes [get]
- Properties inherited from Astra.DataStream
StreamDescription | Description [get]
bool | IsAvailable [get]
IntPtr | Handle [get]
The documentation for this class was generated from the following file:
  • InfraredStream.cs


Astra SDK: Astra.Joint Class Reference

  • Astra
  • Joint
Public Member Functions | Properties | List of all members
Astra.Joint Class Reference

Public Member Functions

Joint (JointType type, JointStatus status, Vector2D depthPosition, Vector3D worldPosition, Matrix3x3 orientation)
override string ToString ()

Properties

JointType | Type [get]
JointStatus | Status [get]
Vector2D | DepthPosition [get]
Vector3D | WorldPosition [get]
Matrix3x3 | Orientation [get]
The documentation for this class was generated from the following file:
  • Joint.cs


Astra SDK: Astra.MaskedColorFrame Class Reference

  • Astra
  • MaskedColorFrame
Properties | List of all members
Astra.MaskedColorFrame Class Reference
Inheritance diagram for Astra.MaskedColorFrame:
Astra.ImageFrame< byte >

Properties

override int | StreamType [get]
- Properties inherited from Astra.ImageFrame< byte >
int | Width [get]
int | Height [get]
PixelFormat | PixelFormat [get]
IntPtr | DataPtr [get]
long | ByteLength [get]

Additional Inherited Members

- Public Member Functions inherited from Astra.ImageFrame< byte >
virtual void CopyData (ref T[] data)
- Protected Member Functions inherited from Astra.ImageFrame< byte >
ImageFrame (IntPtr handle)
The documentation for this class was generated from the following file:
  • MaskedColorFrame.cs


Astra SDK: Astra.MaskedColorStream Class Reference

  • Astra
  • MaskedColorStream
Public Attributes | List of all members
Astra.MaskedColorStream Class Reference
Inheritance diagram for Astra.MaskedColorStream:
Astra.ImageStream Astra.DataStream

Public Attributes

const int StreamType = (int)Core.StreamType.MaskedColor

Additional Inherited Members

- Public Member Functions inherited from Astra.ImageStream
ImageMode | GetMode ()
void | SetMode (ImageMode mode)
- Public Member Functions inherited from Astra.DataStream
void | Start ()
void | Stop ()
void | SetParameter< T > (int parameterId, T parameterValue)
T | GetParameter< T > (int parameterId)
- Protected Member Functions inherited from Astra.ImageStream
ImageStream (IntPtr handle)
- Protected Member Functions inherited from Astra.DataStream
DataStream (IntPtr handle)
- Properties inherited from Astra.ImageStream
float | VerticalFieldOfView [get]
float | HorizontalFieldOfView [get]
USBInfo | usbInfo [get]
bool | IsMirroring [get, set]
ImageMode [] | AvailableModes [get]
- Properties inherited from Astra.DataStream
StreamDescription | Description [get]
bool | IsAvailable [get]
IntPtr | Handle [get]
The documentation for this class was generated from the following file:
  • MaskedColorStream.cs


Astra SDK: Astra.Matrix3x3 Struct Reference

  • Astra
  • Matrix3x3
Public Attributes | Properties | List of all members
Astra.Matrix3x3 Struct Reference

Represents a 3x3 rotation matrix. More...

Public Attributes

float | M00
float | M10
float | M20
float | M01
float | M11
float | M21
float | M02
float | M12
float | M22

Properties

Vector3D | AxisX [get]
X axis basis vector, or the first column vector. More...
Vector3D | AxisY [get]
Y axis basis vector, or the second column vector. More...
Vector3D | AxisZ [get]
Z axis basis vector, or the third column vector. More...

Detailed Description

Represents a 3x3 rotation matrix.

Property Documentation

◆ AxisX

Vector3D Astra.Matrix3x3.AxisX
get

X axis basis vector, or the first column vector.

◆ AxisY

Vector3D Astra.Matrix3x3.AxisY
get

Y axis basis vector, or the second column vector.

◆ AxisZ

Vector3D Astra.Matrix3x3.AxisZ
get

Z axis basis vector, or the third column vector.

The documentation for this struct was generated from the following file:
  • Matrix3x3.cs


Astra SDK: Astra.Plane Class Reference

  • Astra
  • Plane
Public Member Functions | Public Attributes | List of all members
Astra.Plane Class Reference

3D geometric plane Represents a 3D plane. The normal of the plane is defined to be(A, B, C). The plane coefficients and real world coordinates(x, y, and z) are related by the plane equation: Ax + By + Cz + D = 0 More...

Public Member Functions

Plane (float a, float b, float c, float d)
override string ToString ()

Public Attributes

float | A
float | B
float | C
float | D

Detailed Description

3D geometric plane Represents a 3D plane. The normal of the plane is defined to be(A, B, C). The plane coefficients and real world coordinates(x, y, and z) are related by the plane equation: Ax + By + Cz + D = 0

The documentation for this class was generated from the following file:
  • Plane.cs


Astra SDK: Astra.PointFrame Class Reference

  • Astra
  • PointFrame
Public Member Functions | Properties | List of all members
Astra.PointFrame Class Reference
Inheritance diagram for Astra.PointFrame:
Astra.ImageFrame< Vector3D >

Public Member Functions

override void | CopyData (ref Vector3D[] data)
- Public Member Functions inherited from Astra.ImageFrame< Vector3D >
virtual void | CopyData (ref T[] data)

Properties

override int | StreamType [get]
- Properties inherited from Astra.ImageFrame< Vector3D >
int | Width [get]
int | Height [get]
PixelFormat | PixelFormat [get]
IntPtr | DataPtr [get]
long | ByteLength [get]

Additional Inherited Members

- Protected Member Functions inherited from Astra.ImageFrame< Vector3D >
ImageFrame (IntPtr handle)
The documentation for this class was generated from the following file:
  • PointFrame.cs


Astra SDK: Astra.PointStream Class Reference

  • Astra
  • PointStream
Public Member Functions | Public Attributes | List of all members
Astra.PointStream Class Reference
Inheritance diagram for Astra.PointStream:
Astra.DataStream

Public Member Functions

PointStream (IntPtr handle)
- Public Member Functions inherited from Astra.DataStream
void | Start ()
void | Stop ()
void | SetParameter< T > (int parameterId, T parameterValue)
T | GetParameter< T > (int parameterId)

Public Attributes

const int StreamType = (int)Core.StreamType.Point

Additional Inherited Members

- Protected Member Functions inherited from Astra.DataStream
DataStream (IntPtr handle)
- Properties inherited from Astra.DataStream
StreamDescription | Description [get]
bool | IsAvailable [get]
IntPtr | Handle [get]
The documentation for this class was generated from the following file:
  • PointStream.cs


Astra SDK: Astra.ReaderFrame Class Reference

  • Astra
  • ReaderFrame
Public Member Functions | List of all members
Astra.ReaderFrame Class Reference

Contains frames from opened streams. More...

Inheritance diagram for Astra.ReaderFrame:

Public Member Functions

TFrame | GetFrame< TFrame > ()
Get default subtype of a frame, must from an opened stream. More...
TFrame | GetFrame< TFrame > (StreamSubType subType)
Get frame with subtype, must from an opened stream. More...
void | Dispose ()

Detailed Description

Contains frames from opened streams.

Member Function Documentation

◆ GetFrame< TFrame >() [1/2]

TFrame Astra.ReaderFrame.GetFrame< TFrame > ( )
inline

Get default subtype of a frame, must from an opened stream.

Type Constraints
TFrame : DataFrame

◆ GetFrame< TFrame >() [2/2]

TFrame Astra.ReaderFrame.GetFrame< TFrame > ( StreamSubType subType )
inline

Get frame with subtype, must from an opened stream.

Type Constraints
TFrame : DataFrame
The documentation for this class was generated from the following file:
  • ReaderFrame.cs


Astra SDK: Astra.StreamDescription Class Reference

  • Astra
  • StreamDescription
Public Member Functions | Properties | List of all members
Astra.StreamDescription Class Reference

Public Member Functions

StreamDescription (int type, int subType)

Properties

int | Type [get]
int | SubType [get]
The documentation for this class was generated from the following file:
  • StreamDescription.cs


Astra SDK: Astra.StreamReader Class Reference

  • Astra
  • StreamReader
Public Member Functions | Protected Member Functions | Properties | List of all members
Astra.StreamReader Class Reference
Inheritance diagram for Astra.StreamReader:

Public Member Functions

TStream | GetStream< TStream > ()
Get default subtype of a stream More...
TStream | GetStream< TStream > (StreamSubType subType)
Get a stream with subtype. More...
bool | HasNewFrame ()
bool | TryOpenFrame (int timeoutMillis, out ReaderFrame frame)
try to get a frame. More...
void | Dispose ()

Protected Member Functions

virtual void RaiseFrameReady (ReaderFrame frame)

Properties

EventHandler< FrameReadyEventArgs > FrameReady

Member Function Documentation

◆ GetStream< TStream >() [1/2]

TStream Astra.StreamReader.GetStream< TStream > ( )
inline

Get default subtype of a stream

Returns
The newly stream
Type Constraints
TStream : DataStream

◆ GetStream< TStream >() [2/2]

TStream Astra.StreamReader.GetStream< TStream > ( StreamSubType subType )
inline

Get a stream with subtype.

Parameters
subType A specifically StreamSubType
Returns
The newly stream
Type Constraints
TStream : DataStream

◆ TryOpenFrame()

bool Astra.StreamReader.TryOpenFrame | ( | int | timeoutMillis,
 |  | out ReaderFrame | frame
 | ) |  |
inline

try to get a frame.

Parameters
timeoutMillis | time to wait for frame
frame | the frame or null
Returns
true if frame is valid.
The documentation for this class was generated from the following file:
  • StreamReader.cs


Astra SDK: Astra.StreamSet Class Reference

  • Astra
  • StreamSet
Public Member Functions | Static Public Member Functions | Properties | List of all members
Astra.StreamSet Class Reference

A StreamSet represents a logical group of related streams, the most common of these being an Astra camera device More...

Inheritance diagram for Astra.StreamSet:

Public Member Functions

StreamReader CreateReader ()
Creates a StreamReader associated with the StreamSet. More...
void Dispose ()
Disposes a StreamSet and freeing all associated native resources. More...

Static Public Member Functions

static StreamSet | Open (string connectionString)
Opens a StreamSet using the connectionString to provide any additional options. More...
static StreamSet | Open ()
Opens a StreamSet with the default connection string. More...

Properties

bool | IsAvailable [get]
string | Uri [get]

Detailed Description

A StreamSet represents a logical group of related streams, the most common of these being an Astra camera device

Member Function Documentation

◆ CreateReader()

StreamReader Astra.StreamSet.CreateReader ( )
inline

Creates a StreamReader associated with the StreamSet.

Returns
A StreamReader for accessing the frames of StreamSet streams

◆ Dispose()

void Astra.StreamSet.Dispose ( )
inline

Disposes a StreamSet and freeing all associated native resources.

◆ Open() [1/2]

static StreamSet Astra.StreamSet.Open ( string connectionString )
inlinestatic

Opens a StreamSet using the connectionString to provide any additional options.

Parameters
connectionString A specifically formatted string
Returns
The newly opened StreamSet

◆ Open() [2/2]

static StreamSet Astra.StreamSet.Open ( )
inlinestatic

Opens a StreamSet with the default connection string.

Returns
The newly opened StreamSet
The documentation for this class was generated from the following file:
  • StreamSet.cs


Astra SDK: Astra.StreamTypeRegistry Class Reference

  • Astra
  • StreamTypeRegistry
Classes | Public Member Functions | Properties | List of all members
Astra.StreamTypeRegistry Class Reference

Public Member Functions

void Register< TStream > (int type, Func< IntPtr, DataStream > streamCreate)

Properties

static StreamTypeRegistry Instance [get]
The documentation for this class was generated from the following file:
  • StreamTypeRegistry.cs


Astra SDK: Astra.USBInfo Class Reference

  • Astra
  • USBInfo
Public Member Functions | Properties | List of all members
Astra.USBInfo Class Reference

Public Member Functions

USBInfo (int pid, int vid)

Properties

int | Pid [get]
int | Vid [get]
The documentation for this class was generated from the following file:
  • USBInfo.cs


Astra SDK: Astra.Vector2D Struct Reference

  • Astra
  • Vector2D
Public Member Functions | Public Attributes | List of all members
Astra.Vector2D Struct Reference

Represents a float 2d vector More...

Public Member Functions

Vector2D (float x, float y)
override string ToString ()

Public Attributes

float | X
float | Y

Detailed Description

Represents a float 2d vector

The documentation for this struct was generated from the following file:
  • Vector2D.cs


Astra SDK: Astra.Vector3D Struct Reference

  • Astra
  • Vector3D
Public Member Functions | Public Attributes | List of all members
Astra.Vector3D Struct Reference

Represents a float 3d vector More...

Public Member Functions

Vector3D (float x, float y, float z)
override string ToString ()

Public Attributes

float | X
float | Y
float | Z

Detailed Description

Represents a float 3d vector

The documentation for this struct was generated from the following file:
  • Vector3D.cs


Astra SDK: astra::_Unique_if< _Ty > Struct Template Reference

  • astra
  • _Unique_if
Public Types | List of all members
astra::_Unique_if< _Ty > Struct Template Reference

Public Types

typedef std::unique_ptr< _Ty > _Single_object
The documentation for this struct was generated from the following file:
  • astra_cxx_make_unique.hpp


Astra SDK: astra::_Unique_if< _Ty[]> Struct Template Reference

  • astra
  • _Unique_if< _Ty[]>
Public Types | List of all members
astra::_Unique_if< _Ty[]> Struct Template Reference

Public Types

typedef std::unique_ptr< _Ty[]> _Unknown_bound
The documentation for this struct was generated from the following file:
  • astra_cxx_make_unique.hpp


Astra SDK: astra::_Unique_if< _Ty[N]> Struct Template Reference

  • astra
  • _Unique_if< _Ty[N]>
Public Types | List of all members
astra::_Unique_if< _Ty[N]> Struct Template Reference

Public Types

typedef void _Known_bound
The documentation for this struct was generated from the following file:
  • astra_cxx_make_unique.hpp


Astra SDK: astra::BodyFrameInfo Class Reference

  • astra
  • BodyFrameInfo
Public Member Functions | Friends | List of all members
astra::BodyFrameInfo Class Reference
Inheritance diagram for astra::BodyFrameInfo:
_astra_bodyframe_info

Public Member Functions

std::int32_t | width () const
std::int32_t | height () const
bool | is_estimated () const

Friends

class BodyFrame
The documentation for this class was generated from the following file:
  • Body.hpp


Astra SDK: astra::FloorInfo Class Reference

  • astra
  • FloorInfo
Public Member Functions | Friends | List of all members
astra::FloorInfo Class Reference
Inheritance diagram for astra::FloorInfo:
_astra_floor_info

Public Member Functions

const FloorMask & | floor_mask () const
const Plane & | floor_plane () const
bool | floor_detected () const

Friends

class BodyFrame
The documentation for this class was generated from the following file:
  • Body.hpp


Astra SDK: astra::HandPoseInfo Class Reference

  • astra
  • HandPoseInfo
Public Member Functions | Friends | List of all members
astra::HandPoseInfo Class Reference
Inheritance diagram for astra::HandPoseInfo:
_astra_handpose_info

Public Member Functions

HandPose | left_hand () const
HandPose | right_hand () const

Friends

class Body
The documentation for this class was generated from the following file:
  • Body.hpp


Astra SDK: com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity Class Reference

  • com
  • orbbec
  • astra
  • android
  • unity3d
  • AstraUnityPlayerActivity
Public Member Functions | Static Public Attributes | Protected Member Functions | List of all members
com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity Class Reference
Inheritance diagram for com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity:

Public Member Functions

void openAllDevices ()

Static Public Attributes

static AstraUnityPlayerActivity Instance

Protected Member Functions

void | onCreate (Bundle savedInstanceState)
void | onDestroy ()
The documentation for this class was generated from the following file:
  • AstraUnityPlayerActivity.java


Astra SDK: com.orbbec.astra.android.AndroidCamera Class Reference

  • com
  • orbbec
  • astra
  • android
  • AndroidCamera
Public Member Functions | Static Public Member Functions | List of all members
com.orbbec.astra.android.AndroidCamera Class Reference
Inheritance diagram for com.orbbec.astra.android.AndroidCamera:

Public Member Functions

boolean | openCamera ()
boolean | closeCamera ()
boolean | startCamera ()
boolean | stopCamera ()
ImageStreamMode [] | getAvailableCameraModes ()
ImageStreamMode | getCameraMode ()
void | setCameraMode (ImageStreamMode mode)
void | onPreviewFrame (byte[] data, Camera myCamera)

Static Public Member Functions

static synchronized AndroidCamera getInstance ()
The documentation for this class was generated from the following file:
  • AndroidCamera.java


Astra SDK: com.orbbec.astra.android.AstraDeviceManager Class Reference

  • com
  • orbbec
  • astra
  • android
  • AstraDeviceManager
Public Member Functions | List of all members
com.orbbec.astra.android.AstraDeviceManager Class Reference

Public Member Functions

AstraDeviceManager (Context androidContext, AstraDeviceManagerListener listener)
Iterable< UsbDevice > | getAvailableDevices ()
int | getAvailableDevicesSize ()
void | tryOpenDevice (UsbDevice device)
void | openAllDevices ()
void | closeAllDevices ()
void | release ()
The documentation for this class was generated from the following file:
  • AstraDeviceManager.java


Astra SDK: com.orbbec.astra.android.AstraDeviceMonitorActivity Class Reference

  • com
  • orbbec
  • astra
  • android
  • AstraDeviceMonitorActivity
Public Member Functions | Static Public Attributes | Protected Member Functions | List of all members
com.orbbec.astra.android.AstraDeviceMonitorActivity Class Reference
Inheritance diagram for com.orbbec.astra.android.AstraDeviceMonitorActivity:

Public Member Functions

void onCreate (Bundle savedInstanceState)

Static Public Attributes

static final String ACTION_USB_DEVICE_ATTACHED = "com.orbbec.ACTION_USB_DEVICE_ATTACHED"

Protected Member Functions

void onResume ()
The documentation for this class was generated from the following file:
  • AstraDeviceMonitorActivity.java


Astra SDK: com.orbbec.astra.android.UsbDeviceAccessBroker Class Reference

  • com
  • orbbec
  • astra
  • android
  • UsbDeviceAccessBroker
Classes | Public Member Functions | List of all members
com.orbbec.astra.android.UsbDeviceAccessBroker Class Reference

Classes

interface UsbDeviceAccessEventListener

Public Member Functions

UsbDeviceAccessBroker (Context androidContext)
void | open (UsbDevice device, UsbDeviceAccessEventListener listener)
void | release ()
The documentation for this class was generated from the following file:
  • UsbDeviceAccessBroker.java


Astra SDK: com.orbbec.astra.android.UsbDeviceAccessBroker.UsbDeviceAccessEventListener Interface Reference

  • com
  • orbbec
  • astra
  • android
  • UsbDeviceAccessBroker
  • UsbDeviceAccessEventListener
Public Member Functions | List of all members
com.orbbec.astra.android.UsbDeviceAccessBroker.UsbDeviceAccessEventListener Interface Reference

Public Member Functions

void | onDeviceOpened (UsbDevice device, UsbDeviceConnection connection)
void | onDeviceOpenFailed (UsbDevice device)
void | onPermissionDenied (UsbDevice device)
The documentation for this interface was generated from the following file:
  • UsbDeviceAccessBroker.java


Astra SDK: com.orbbec.astra.android.UsbDeviceInfo Class Reference

  • com
  • orbbec
  • astra
  • android
  • UsbDeviceInfo
Public Member Functions | List of all members
com.orbbec.astra.android.UsbDeviceInfo Class Reference

Public Member Functions

int | getVendorId ()
int | getProductId ()
String | getDeviceName ()
UsbDeviceInfo (int vendorId, int productId)
UsbDeviceInfo (int vendorId, int productId, String deviceName)
String | toString ()
boolean | equals (Object o)
int | hashCode ()
The documentation for this class was generated from the following file:
  • android/src/main/java/com/orbbec/astra/android/UsbDeviceInfo.java


Astra SDK: com.orbbec.astra.ApiStatus Enum Reference

  • com
  • orbbec
  • astra
  • ApiStatus
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
com.orbbec.astra.ApiStatus Enum Reference

Public Member Functions

int | getCode ()
void | throwIfError ()

Static Public Member Functions

static ApiStatus fromNativeStatus (int code)

Public Attributes

SUCCESS =(0)
INVALID_PARAMETER =(1)
DEVICE_ERROR =(2)
TIMEOUT =(3)
INVALID_PARAMETER_TOKEN =(4)
INVALID_OPERATION =(5)
INTERNAL_ERROR =(6)
UNINITIALIZED =(7)
The documentation for this enum was generated from the following file:
  • ApiStatus.java


Astra SDK: _astra_bitmapmask Struct Reference

Public Attributes | List of all members
_astra_bitmapmask Struct Reference

Struct representing a 2-dimensional bitmask. More...

#include <body_types.h>

Inheritance diagram for _astra_bitmapmask:
astra::BitmapMask

Public Attributes

uint8_t | data [ASTRA_TEMP_IMAGE_LENGTH]
mask pixels
int32_t | width
width in pixels
int32_t | height
height in pixels

Detailed Description

Struct representing a 2-dimensional bitmask.

A mask pixel is a uint8_t. All non-zero values are considered to be part of the mask.

Examples:
BodyReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • body_types.h


Astra SDK: _astra_body Struct Reference

Public Attributes | List of all members
_astra_body Struct Reference

Struct containing body tracking information. More...

#include <body_types.h>

Inheritance diagram for _astra_body:
astra::Body

Public Attributes

astra_body_tracking_feature_flags_t | features
Bitmask of features that are enabled. More...
astra_vector3f_t centerOfMass
Single point describing the center of mass of a body. More...
astra_joint_t | joints [ASTRA_MAX_JOINTS]
Array of tracked joints.
astra_handpose_info_t handPoses
Hand poses.
astra_body_id_t | id
Persistent Id. More...
astra_body_status_t | status
Tracking status. More...

Detailed Description

Struct containing body tracking information.

Examples:
BodyReaderPoll\main.c.

Member Data Documentation

◆ centerOfMass

astra_vector3f_t _astra_body::centerOfMass

Single point describing the center of mass of a body.

Always present, even if ASTRA_BODY_TRACKING_JOINTS is not enabled. Useful for doing general calculations about the relative positions of bodies.

Examples:
BodyReaderPoll\main.c.

◆ features

astra_body_tracking_feature_flags_t _astra_body::features

Bitmask of features that are enabled.

See also
astra_body_tracking_feature_flags_v for possible values
Examples:
BodyReaderPoll\main.c.

◆ id

astra_body_id_t _astra_body::id

Persistent Id.

An astra_body_id_t value can be used to match a particular active astra_body_t across frames. Additionally, astra_body_id_t values match the values in a astra_bodymask_t

Examples:
BodyReaderPoll\main.c.

◆ status

astra_body_status_t _astra_body::status

Tracking status.

See also
astra_body_status_v for possible values
Examples:
BodyReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • body_types.h


Astra SDK: _astra_body_list Struct Reference

Public Attributes | List of all members
_astra_body_list Struct Reference

Struct containing a variable-sized array of astra_body_t structs. More...

#include <body_types.h>

Public Attributes

astra_body_t | bodies [ASTRA_MAX_BODIES]
Pointer to an array of astra_body_t.
int32_t | count
Number of astra_body_t in bodies.

Detailed Description

Struct containing a variable-sized array of astra_body_t structs.

Examples:
BodyReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • body_types.h


Astra SDK: _astra_bodyframe Struct Reference

Public Member Functions | Public Attributes | List of all members
_astra_bodyframe Struct Reference

Public Member Functions

ASTRA_ALIGN (32) astra_bodymask_t bodyMask

Public Attributes

union {
astra_frame_t * frame
uint64_t pad0
};
astra_bodyframe_info_t | info
astra_floor_info_t | floorInfo
astra_body_list_t | bodyList

Detailed Description

Examples:
BodyReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • stream_types.h


Astra SDK: _astra_bodyframe_info Struct Reference

Public Attributes | List of all members
_astra_bodyframe_info Struct Reference

Struct containing general body frame information. More...

#include <body_types.h>

Inheritance diagram for _astra_bodyframe_info:
astra::BodyFrameInfo

Public Attributes

int32_t | width
Frame width.
int32_t | height
Frame height.
int8_t | isEstimated
If the frame was estimated due to a slow CPU.

Detailed Description

Struct containing general body frame information.

Examples:
BodyReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • body_types.h


Astra SDK: _astra_bodyframe_wrapper Struct Reference

Public Attributes | List of all members
_astra_bodyframe_wrapper Struct Reference

Public Attributes

_astra_bodyframe | frame
char | frame_data []
The documentation for this struct was generated from the following file:
  • stream_types.h


Astra SDK: _astra_floor_info Struct Reference

Public Attributes | List of all members
_astra_floor_info Struct Reference

Struct containing floor information about the scene. More...

#include <body_types.h>

Inheritance diagram for _astra_floor_info:
astra::FloorInfo

Public Attributes

astra_floormask_t floorMask
Floor mask.
astra_plane_t floorPlane
Floor plane.
astra_bool_t floorDetected
If the floor is detected, ASTRA_TRUE. Otherwise, ASTRA_FALSE. More...

Detailed Description

Struct containing floor information about the scene.

Examples:
BodyReaderPoll\main.c.

Member Data Documentation

◆ floorDetected

astra_bool_t _astra_floor_info::floorDetected

If the floor is detected, ASTRA_TRUE. Otherwise, ASTRA_FALSE.

If a floor is not detected, floorPlane and floorMask will not contain meaningful data.

Examples:
BodyReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • body_types.h


Astra SDK: _astra_frame Struct Reference

Public Attributes | List of all members
_astra_frame Struct Reference

Public Attributes

uint32_t | byteLength
astra_frame_index_t | frameIndex
union {
void * data
uint64_t pad0
};
The documentation for this struct was generated from the following file:
  • astra_plugin.h


Astra SDK: _astra_handframe Struct Reference

Public Attributes | List of all members
_astra_handframe Struct Reference

Public Attributes

union {
astra_frame_t * frame
uint64_t pad0
};
size_t handCount
union {
astra_handpoint_t * handpoints
uint64_t pad1
};

Detailed Description

Examples:
HandReader\main.c.
The documentation for this struct was generated from the following file:
  • stream_types.h


Astra SDK: _astra_handframe_wrapper Struct Reference

Public Attributes | List of all members
_astra_handframe_wrapper Struct Reference

Public Attributes

_astra_handframe | frame
char | frame_data []
The documentation for this struct was generated from the following file:
  • stream_types.h


Astra SDK: _astra_handpose_info Struct Reference

Public Attributes | List of all members
_astra_handpose_info Struct Reference
Inheritance diagram for _astra_handpose_info:
astra::HandPoseInfo

Public Attributes

astra_handpose_t | leftHand
astra_handpose_t | rightHand

Detailed Description

Examples:
BodyReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • body_types.h


Astra SDK: _astra_imageframe Struct Reference

Public Attributes | List of all members
_astra_imageframe Struct Reference

Public Attributes

union {
astra_frame_t * frame
uint64_t pad0
};
astra_image_metadata_t metadata
union {
void * data
uint64_t pad1
};

Detailed Description

Examples:
ColorReaderEvent\main.c, ColorReaderPoll\main.c, DepthReaderEvent\main.c, DepthReaderPoll\main.c, HandReader\main.c, InfraredColorReaderEvent\main.c, InfraredReaderEvent\main.c, and InfraredReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • stream_types.h


Astra SDK: _astra_imageframe_wrapper Struct Reference

Public Member Functions | Public Attributes | List of all members
_astra_imageframe_wrapper Struct Reference

Public Member Functions

ASTRA_ALIGN (32) char frame_data[]

Public Attributes

_astra_imageframe frame
The documentation for this struct was generated from the following file:
  • stream_types.h


Astra SDK: _astra_joint Struct Reference

Public Attributes | List of all members
_astra_joint Struct Reference

Joint information. More...

#include <body_types.h>

Inheritance diagram for _astra_joint:
astra::Joint

Public Attributes

astra_joint_type_t | type
Joint type. More...
astra_joint_status_t | status
Joint status. More...
astra_vector2f_t depthPosition
Depth ("projective") position of joint.
astra_vector3f_t worldPosition
Real world position of joint.
astra_matrix3x3_t orientation
3x3 Rotation matrix representing the rotation of this joint.

Detailed Description

Joint information.

Examples:
BodyReaderPoll\main.c.

Member Data Documentation

◆ status

astra_joint_status_t _astra_joint::status

Joint status.

See also
astra_joint_status_v for potential values
Examples:
BodyReaderPoll\main.c.

◆ type

astra_joint_type_t _astra_joint::type

Joint type.

See also
astra_joint_type_v for potential values
Examples:
BodyReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • body_types.h


Astra SDK: _astra_matrix3x3 Struct Reference

Public Attributes | List of all members
_astra_matrix3x3 Struct Reference

Represents a 3x3 rotation matrix. More...

#include <astra_ctypes.h>

Inheritance diagram for _astra_matrix3x3:
astra::Matrix3x3

Public Attributes

union {
struct {
astra_vector3f_t xAxis
astra_vector3f_t yAxis
astra_vector3f_t zAxis
}
struct {
float m00
float m10
float m20
float m01
float m11
float m21
float m02
float m12
float m22
}
};

Detailed Description

Represents a 3x3 rotation matrix.

Examples:
BodyReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • astra_ctypes.h


Astra SDK: _astra_plane Struct Reference

Public Attributes | List of all members
_astra_plane Struct Reference

Struct representing a geometric 3-dimensional plane. More...

#include <body_types.h>

Inheritance diagram for _astra_plane:
astra::Plane

Public Attributes

float | a
A coefficient.
float | b
B coefficient.
float | c
C coefficient.
float | d
D coefficient.

Detailed Description

Struct representing a geometric 3-dimensional plane.

The normal of the plane is defined to be (A, B, C). The plane coefficients and real world coordinates (x, y, and z) are related by the plane equation:

Ax + By + Cz + D = 0

Remarks
The vector v = (A, B, C) represents the normal to the plane and D represents the signed distance along the normal between the plane and the origin of the coordinate system. The the origin of the coordinate system is the camera's depth sensor
Examples:
BodyReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • body_types.h


Astra SDK: _astra_reader_callback_id Struct Reference

Public Attributes | List of all members
_astra_reader_callback_id Struct Reference

Public Attributes

astra_reader_t | reader
astra_callback_id_t | callbackId

Detailed Description

Examples:
ColorReaderEvent\main.c, DepthReaderEvent\main.c, InfraredColorReaderEvent\main.c, and InfraredReaderEvent\main.c.
The documentation for this struct was generated from the following file:
  • astra_plugin.h


Astra SDK: _astra_streamconnection Struct Reference

Public Attributes | List of all members
_astra_streamconnection Struct Reference

Public Attributes

astra_streamconnection_handle_t | handle
astra_stream_desc_t | desc

Detailed Description

Examples:
BodyReaderPoll\main.c, ColorReaderEvent\main.c, ColorReaderPoll\main.c, DepthReaderEvent\main.c, DepthReaderPoll\main.c, HandReader\main.c, InfraredColorReaderEvent\main.c, InfraredReaderEvent\main.c, and InfraredReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • astra_plugin.h


Astra SDK: astra_body_feature_command_t Struct Reference

Public Attributes | List of all members
astra_body_feature_command_t Struct Reference

Public Attributes

astra_body_id_t | bodyId
astra_body_tracking_feature_flags_t | feature
The documentation for this struct was generated from the following file:
  • body_types.h


Astra SDK: astra_conversion_cache_t Struct Reference

Public Attributes | List of all members
astra_conversion_cache_t Struct Reference

Public Attributes

float | xzFactor
float | yzFactor
float | coeffX
float | coeffY
int | resolutionX
int | resolutionY
int | halfResX
int | halfResY
The documentation for this struct was generated from the following file:
  • depth_types.h


Astra SDK: astra_handpoint_t Struct Reference

Public Attributes | List of all members
astra_handpoint_t Struct Reference
Inheritance diagram for astra_handpoint_t:
astra::HandPoint

Public Attributes

int32_t | trackingId
astra_handstatus_t | status
astra_vector2i_t | depthPosition
astra_vector3f_t | worldPosition
astra_vector3f_t | worldDeltaPosition

Detailed Description

Examples:
HandReader\main.c.
The documentation for this struct was generated from the following file:
  • hand_types.h


Astra SDK: astra_image_metadata_t Struct Reference

Public Attributes | List of all members
astra_image_metadata_t Struct Reference

Public Attributes

uint32_t | width
uint32_t | height
astra_pixel_format_t | pixelFormat

Detailed Description

Examples:
ColorReaderEvent\main.c, ColorReaderPoll\main.c, DepthReaderEvent\main.c, DepthReaderPoll\main.c, HandReader\main.c, InfraredColorReaderEvent\main.c, InfraredReaderEvent\main.c, and InfraredReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • image_types.h


Astra SDK: astra_imagestream_mode_t Struct Reference

Public Attributes | List of all members
astra_imagestream_mode_t Struct Reference
Inheritance diagram for astra_imagestream_mode_t:
astra::ImageStreamMode

Public Attributes

uint32_t | id
uint32_t | width
uint32_t | height
astra_pixel_format_t | pixelFormat
uint8_t | fps

Detailed Description

Examples:
InfraredColorReaderEvent\main.c, InfraredReaderEvent\main.c, and InfraredReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • image_types.h


Astra SDK: astra_plugin_info_t Struct Reference

Public Attributes | List of all members
astra_plugin_info_t Struct Reference

Public Attributes

astra_version_info_t versionInfo
The documentation for this struct was generated from the following file:
  • astra_plugin.h


Astra SDK: astra_pluginservice_proxy_t Struct Reference

Public Member Functions | Public Attributes | List of all members
astra_pluginservice_proxy_t Struct Reference

Public Member Functions

astra_status_t (ASTRA_CALLBACK *register_stream_registered_callback)(void *
void astra_callback_id_t * | astra_status_t (ASTRA_CALLBACK *register_stream_unregistering_callback)(void *
void astra_callback_id_t void astra_callback_id_t * | astra_status_t (ASTRA_CALLBACK *register_host_event_callback)(void *
void astra_callback_id_t void astra_callback_id_t void astra_callback_id_t * | astra_status_t (ASTRA_CALLBACK *unregister_host_event_callback)(void *
astra_status_t (ASTRA_CALLBACK *unregister_stream_registered_callback)(void *
astra_status_t (ASTRA_CALLBACK *unregister_stream_unregistering_callback)(void *
astra_status_t (ASTRA_CALLBACK *create_stream_set)(void *
const char astra_streamset_t & | astra_status_t (ASTRA_CALLBACK *destroy_stream_set)(void *
const char astra_streamset_t astra_streamset_t & | astra_status_t (ASTRA_CALLBACK *get_streamset_uri)(void *
const char astra_streamset_t astra_streamset_t const char ** | astra_status_t (ASTRA_CALLBACK *create_stream)(void *
const char astra_streamset_t astra_streamset_t const char astra_stream_t * | astra_status_t (ASTRA_CALLBACK *register_stream)(void *
astra_status_t (ASTRA_CALLBACK *unregister_stream)(void *
astra_status_t (ASTRA_CALLBACK *destroy_stream)(void *
astra_stream_t & | astra_status_t (ASTRA_CALLBACK *create_stream_bin)(void *
astra_stream_t astra_bin_t astra_frame_t ** | astra_status_t (ASTRA_CALLBACK *destroy_stream_bin)(void *
astra_stream_t astra_bin_t astra_frame_t astra_bin_t astra_frame_t ** | astra_status_t (ASTRA_CALLBACK *bin_has_connections)(void *
astra_stream_t astra_bin_t astra_frame_t astra_bin_t astra_frame_t bool * | astra_status_t (ASTRA_CALLBACK *cycle_bin_buffers)(void *
astra_stream_t astra_bin_t astra_frame_t astra_bin_t astra_frame_t bool astra_frame_t ** | astra_status_t (ASTRA_CALLBACK *link_connection_to_bin)(void *
astra_status_t (ASTRA_CALLBACK *get_parameter_bin)(void *
astra_parameter_bin_t astra_parameter_data_t * | astra_status_t (ASTRA_CALLBACK *log)(void *

Public Attributes

void * | pluginService
stream_registered_callback_t
void astra_callback_id_t | stream_unregistering_callback_t
void astra_callback_id_t void astra_callback_id_t | host_event_callback_t
void astra_callback_id_t void astra_callback_id_t void astra_callback_id_t | astra_callback_id_t
astra_callback_id_t
const char astra_streamset_t astra_streamset_t | astra_streamset_t
const char astra_streamset_t astra_streamset_t const char | astra_streamset_t
const char astra_streamset_t astra_streamset_t const char | astra_stream_desc_t
const char astra_streamset_t astra_streamset_t const char astra_stream_t | astra_stream_t
const char astra_streamset_t astra_streamset_t const char astra_stream_t | stream_callbacks_t
astra_stream_t
astra_stream_t | astra_stream_t
astra_stream_t | uint32_t
astra_stream_t astra_bin_t astra_frame_t | astra_stream_t
astra_stream_t astra_bin_t astra_frame_t astra_bin_t astra_frame_t | astra_bin_t
astra_stream_t astra_bin_t astra_frame_t astra_bin_t astra_frame_t bool | astra_bin_t
astra_stream_t astra_bin_t astra_frame_t astra_bin_t astra_frame_t bool astra_frame_t | astra_streamconnection_t
astra_stream_t astra_bin_t astra_frame_t astra_bin_t astra_frame_t bool astra_frame_t | astra_bin_t
uint32_t
astra_parameter_bin_t astra_parameter_data_t const char | astra_log_severity_t
astra_parameter_bin_t astra_parameter_data_t const char const char | int
astra_parameter_bin_t astra_parameter_data_t const char const char const char const char | va_list
The documentation for this struct was generated from the following file:
  • astra_pluginservice_proxy.h


Astra SDK: astra_rgb_pixel_t Struct Reference

Public Attributes | List of all members
astra_rgb_pixel_t Struct Reference
Inheritance diagram for astra_rgb_pixel_t:
astra::RgbPixel

Public Attributes

uint8_t | r
uint8_t | g
uint8_t | b

Detailed Description

Examples:
ColorReaderEvent\main.c, ColorReaderPoll\main.c, and InfraredColorReaderEvent\main.c.
The documentation for this struct was generated from the following file:
  • image_types.h


Astra SDK: astra_rgba_pixel_t Struct Reference

Public Attributes | List of all members
astra_rgba_pixel_t Struct Reference
Inheritance diagram for astra_rgba_pixel_t:
astra::RgbaPixel

Public Attributes

uint8_t | r
uint8_t | g
uint8_t | b
uint8_t | alpha
The documentation for this struct was generated from the following file:
  • image_types.h


Astra SDK: astra_stream_desc_t Struct Reference

Public Attributes | List of all members
astra_stream_desc_t Struct Reference
Inheritance diagram for astra_stream_desc_t:
astra::StreamDescription

Public Attributes

astra_stream_type_t | type
astra_stream_subtype_t | subtype
The documentation for this struct was generated from the following file:
  • astra_types.h


Astra SDK: astra_streamservice_proxy_t Struct Reference

Public Member Functions | Public Attributes | List of all members
astra_streamservice_proxy_t Struct Reference
Inheritance diagram for astra_streamservice_proxy_t:
astra::StreamServiceProxy

Public Member Functions

astra_status_t (ASTRA_CALLBACK *notify_plugin_event)(void *
astra_status_t (ASTRA_CALLBACK *streamset_is_available)(void *
bool * | astra_status_t (ASTRA_CALLBACK *streamset_open)(void *
bool const char astra_streamsetconnection_t * | astra_status_t (ASTRA_CALLBACK *streamset_close)(void *
bool const char astra_streamsetconnection_t astra_streamsetconnection_t * | astra_status_t (ASTRA_CALLBACK *streamset_get_uri)(void *
astra_status_t (ASTRA_CALLBACK *reader_create)(void *
astra_reader_t * | astra_status_t (ASTRA_CALLBACK *reader_destroy)(void *
astra_reader_t astra_reader_t * | astra_status_t (ASTRA_CALLBACK *reader_get_stream)(void *
astra_reader_t astra_reader_t astra_streamconnection_t * | astra_status_t (ASTRA_CALLBACK *stream_get_description)(void *
astra_reader_t astra_reader_t astra_streamconnection_t astra_stream_desc_t * | astra_status_t (ASTRA_CALLBACK *stream_is_available)(void *
astra_reader_t astra_reader_t astra_streamconnection_t astra_stream_desc_t bool * | astra_status_t (ASTRA_CALLBACK *stream_start)(void *
astra_status_t (ASTRA_CALLBACK *stream_stop)(void *
astra_status_t (ASTRA_CALLBACK *reader_has_new_frame)(void *
bool * | astra_status_t (ASTRA_CALLBACK *reader_open_frame)(void *
bool astra_reader_frame_t * | astra_status_t (ASTRA_CALLBACK *reader_close_frame)(void *
bool astra_reader_frame_t astra_reader_frame_t * | astra_status_t (ASTRA_CALLBACK *reader_register_frame_ready_callback)(void *
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t * | astra_status_t (ASTRA_CALLBACK *reader_unregister_frame_ready_callback)(void *
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t * | astra_status_t (ASTRA_CALLBACK *reader_get_frame)(void *
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t astra_frame_t ** | astra_status_t (ASTRA_CALLBACK *stream_set_parameter)(void *
astra_status_t (ASTRA_CALLBACK *stream_get_parameter)(void *
uint32_t astra_result_token_t * | astra_status_t (ASTRA_CALLBACK *stream_get_result)(void *
astra_status_t (ASTRA_CALLBACK *stream_invoke)(void *
uint32_t astra_result_token_t * | astra_status_t (ASTRA_CALLBACK *update)(void *)

Public Attributes

void * | streamService
astra_event_id
const void | uint32_t
astra_streamsetconnection_t
bool const char astra_streamsetconnection_t astra_streamsetconnection_t | astra_streamsetconnection_t
bool const char astra_streamsetconnection_t astra_streamsetconnection_t char | int32_t
astra_reader_t astra_reader_t | astra_reader_t
astra_reader_t astra_reader_t | astra_stream_type_t
astra_reader_t astra_reader_t | astra_stream_subtype_t
astra_reader_t astra_reader_t astra_streamconnection_t | astra_streamconnection_t
astra_reader_t astra_reader_t astra_streamconnection_t astra_stream_desc_t | astra_streamconnection_t
astra_reader_t astra_reader_t astra_streamconnection_t astra_stream_desc_t bool | astra_streamconnection_t
astra_streamconnection_t
astra_reader_t
bool | astra_reader_t
bool | int
bool astra_reader_frame_t astra_reader_frame_t | astra_reader_t
bool astra_reader_frame_t astra_reader_frame_t | astra_frame_ready_callback_t
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t | astra_reader_frame_t
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t | astra_stream_type_t
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t | astra_stream_subtype_t
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t astra_frame_t | astra_streamconnection_t
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t astra_frame_t | astra_parameter_id
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t astra_frame_t | uint32_t
bool astra_reader_frame_t astra_reader_frame_t void astra_reader_callback_id_t astra_reader_callback_id_t astra_frame_t | astra_parameter_data_t
astra_parameter_id
uint32_t astra_result_token_t | astra_streamconnection_t
uint32_t astra_result_token_t | astra_result_token_t
uint32_t astra_result_token_t | uint32_t
uint32_t astra_result_token_t | astra_parameter_data_t
astra_command_id
uint32_t
astra_parameter_data_t
The documentation for this struct was generated from the following file:
  • astra_streamservice_proxy.h


Astra SDK: astra_usb_info_t Struct Reference

Public Attributes | List of all members
astra_usb_info_t Struct Reference

Public Attributes

int32_t | pid
int32_t | vid

Detailed Description

Examples:
DepthReaderEventCPP\main.cpp.
The documentation for this struct was generated from the following file:
  • astra_ctypes.h


Astra SDK: astra_vector2f_t Struct Reference

Public Attributes | List of all members
astra_vector2f_t Struct Reference
Inheritance diagram for astra_vector2f_t:
astra::Vector2f

Public Attributes

float | x
float | y

Detailed Description

Examples:
BodyReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • astra_ctypes.h


Astra SDK: astra_vector2i_t Struct Reference

Public Attributes | List of all members
astra_vector2i_t Struct Reference
Inheritance diagram for astra_vector2i_t:
astra::Vector2i

Public Attributes

int32_t | x
int32_t | y
The documentation for this struct was generated from the following file:
  • astra_ctypes.h


Astra SDK: astra_vector3f_t Struct Reference

Public Attributes | List of all members
astra_vector3f_t Struct Reference
Inheritance diagram for astra_vector3f_t:
astra::Vector3f

Public Attributes

float | x
float | y
float | z

Detailed Description

Examples:
BodyReaderPoll\main.c.
The documentation for this struct was generated from the following file:
  • astra_ctypes.h


Astra SDK: astra_vector3i_t Struct Reference

Public Attributes | List of all members
astra_vector3i_t Struct Reference
Inheritance diagram for astra_vector3i_t:
astra::Vector3i

Public Attributes

int32_t | x
int32_t | y
int32_t | z
The documentation for this struct was generated from the following file:
  • astra_ctypes.h


Astra SDK: astra_version_info_t Struct Reference

Public Attributes | List of all members
astra_version_info_t Struct Reference

Public Attributes

int32_t | majorVersion
int32_t | minorVersion
int32_t | patchVersion
char * | versionSuffix
char * | gitCommitSha1
char * | friendlyVersionString
int32_t | apiLevel
The documentation for this struct was generated from the following file:
  • astra_types.h


Astra SDK: stream_callbacks_t Struct Reference

Public Attributes | List of all members
stream_callbacks_t Struct Reference

Public Attributes

void * | context
set_parameter_callback_t | set_parameter_callback
get_parameter_callback_t | get_parameter_callback
invoke_callback_t | invoke_callback
connection_added_callback_t | connection_added_callback
connection_removed_callback_t | connection_removed_callback
connection_started_callback_t | connection_started_callback
connection_stopped_callback_t | connection_stopped_callback
The documentation for this struct was generated from the following file:
  • astra_plugin_callbacks.h


Astra SDK: Class Index

Class Index
_ | a | b | c | d | f | g | h | i | j | m | p | r | s | u | v
_
astra_version_info_t CoordinateMapper (com.orbbec.astra) ImageMetadata (com.orbbec.astra)
r
AstraAndroidContext (com.orbbec.astra.android)
d
ImageMode (Astra)
_astra_bitmapmask | AstraDeviceManager (com.orbbec.astra.android) | ImageStream (astra) | RawColorFrame (astra)
_astra_body | AstraDeviceManagerListener (com.orbbec.astra.android) | DataFrame (Astra) | ImageStream (Astra) | ReaderFrame (com.orbbec.astra)
_astra_body_list | AstraDeviceMonitorActivity (com.orbbec.astra.android) | DataFrame (com.orbbec.astra) | ImageStream (com.orbbec.astra) | ReaderFrame (Astra)
_astra_bodyframe | AstraException (Astra) | DataStream (astra) | ImageStreamMode (astra) | RgbaPixel (astra)
_astra_bodyframe_info | AstraUnityPlayerActivity (com.orbbec.astra.android.unity3d) | DataStream (Astra) | ImageStreamMode (com.orbbec.astra) | RgbPixel (astra)
_astra_bodyframe_wrapper
b
DataStream (com.orbbec.astra) InfraredFrame (Astra)
s
_astra_floor_info | DebugHandFrame (astra) | InfraredFrame (com.orbbec.astra)
_astra_frame | BitmapMask (astra) | DebugHandStream (astra) | InfraredFrame16 (astra) | SkeletonOptimization (com.orbbec.astra)
_astra_handframe | Body (Astra) | DepthFrame (astra) | InfraredFrameRgb (astra) | SkeletonProfile (com.orbbec.astra)
_astra_handframe_wrapper | Body (com.orbbec.astra) | DepthFrame (Astra) | InfraredStream (com.orbbec.astra) | stream_callbacks_t
_astra_handpose_info | Body (astra) | DepthFrame (com.orbbec.astra) | InfraredStream (astra) | StreamDescription (astra)
_astra_imageframe | BodyFrame (Astra) | DepthStream (astra) | InfraredStream (Astra) | StreamDescription (com.orbbec.astra)
_astra_imageframe_wrapper | BodyFrame (com.orbbec.astra) | DepthStream (Astra) | IntPtrExtensions (Astra.Extensions) | StreamDescription (Astra)
_astra_joint BodyFrame (astra) DepthStream (com.orbbec.astra)
j
StreamReader (astra)
_astra_matrix3x3 BodyFrameInfo (Astra)
f
StreamReader (Astra)
_astra_plane | BodyFrameInfo (com.orbbec.astra) | Joint (com.orbbec.astra) | StreamReader (com.orbbec.astra)
_astra_reader_callback_id | BodyFrameInfo (astra) | FloorInfo (Astra) | Joint (Astra) | StreamServiceProxy (astra)
_astra_streamconnection | BodyMask (Astra) | FloorInfo (astra) | Joint (astra) | StreamSet (Astra)
_Unique_if (astra) | BodyMask (com.orbbec.astra) | FloorInfo (com.orbbec.astra) | JointStatus (com.orbbec.astra) | StreamSet (astra)
_Unique_if< _Ty[]> (astra) | BodyStatus (com.orbbec.astra) | FloorMask (Astra) | JointType (com.orbbec.astra) | StreamSet (com.orbbec.astra)
_Unique_if< _Ty[N]> (astra) BodyStream (Astra) FloorMask (com.orbbec.astra)
m
StreamType (com.orbbec.astra)
a
BodyStream (com.orbbec.astra) Frame (astra) StreamTypeRegistry (Astra)
BodyStream (astra) StreamReader.FrameListener (com.orbbec.astra) MaskedColorFrame (com.orbbec.astra)
u
AndroidCamera (com.orbbec.astra.android) | BodyTracking (Astra) | FrameListener (astra) | MaskedColorFrame (astra)
ApiStatus (com.orbbec.astra) | BodyTracking (com.orbbec.astra) | FrameReadyEventArgs (Astra) | MaskedColorFrame (Astra) | UsbDeviceAccessBroker (com.orbbec.astra.android)
Array (astra) BodyTrackingFeatureFlags (com.orbbec.astra)
g
MaskedColorStream (com.orbbec.astra) UsbDeviceAccessBroker.UsbDeviceAccessEventListener (com.orbbec.astra.android)
Astra (com.orbbec.astra)
c
MaskedColorStream (astra) UsbDeviceInfo (com.orbbec.astra.android)
astra_body_feature_command_t | GcHandleWrapper (Astra.Core) | MaskedColorStream (Astra) | UsbDeviceInfo (com.orbbec.astra)
astra_conversion_cache_t ColorFrame (Astra)
h
Matrix3 (com.orbbec.astra) USBInfo (Astra)
astra_handpoint_t ColorFrame (com.orbbec.astra) Matrix3x3 (Astra)
v
astra_image_metadata_t | ColorFrame (astra) | HandFrame (astra) | Matrix3x3 (astra)
astra_imagestream_mode_t ColorizedBodyFrame (astra) HandPoint (astra)
p
Vector2D (com.orbbec.astra)
astra_plugin_info_t | ColorizedBodyFrame (Astra) | HandPose (com.orbbec.astra) | Vector2D (Astra)
astra_pluginservice_proxy_t | ColorizedBodyFrame (com.orbbec.astra) | HandPoseInfo (Astra) | PixelFormat (com.orbbec.astra) | Vector2f (astra)
astra_rgb_pixel_t | ColorizedBodyStream (astra) | HandPoseInfo (astra) | Plane (Astra) | Vector2i (astra)
astra_rgba_pixel_t | ColorizedBodyStream (Astra) | HandPoseInfo (com.orbbec.astra) | Plane (com.orbbec.astra) | Vector3D (com.orbbec.astra)
astra_stream_desc_t | ColorizedBodyStream (com.orbbec.astra) | HandStream (astra) | Plane (astra) | Vector3D (Astra)
astra_streamservice_proxy_t ColorStream (Astra)
i
PointFrame (Astra) Vector3f (astra)
astra_usb_info_t | ColorStream (com.orbbec.astra) | PointFrame (astra) | Vector3i (astra)
astra_vector2f_t | ColorStream (astra) | ImageFrame (com.orbbec.astra) | PointFrame (com.orbbec.astra)
astra_vector2i_t | Context (Astra) | ImageFrame (Astra) | PointStream (com.orbbec.astra)
astra_vector3f_t | CoordinateMapper (astra) | ImageFrame (astra) | PointStream (astra)
astra_vector3i_t CoordinateMapper (Astra) ImageMetadata (Astra.Core) PointStream (Astra)
_ | a | b | c | d | f | g | h | i | j | m | p | r | s | u | v


Astra SDK: Class Hierarchy

Class Hierarchy
This inheritance list is sorted roughly, but not completely, alphabetically:
[detail level 123]
►C _astra_bitmapmask | Struct representing a 2-dimensional bitmask
C astra::BitmapMask | Bitmap representing a 2d mask
►C _astra_body | Struct containing body tracking information
C astra::Body | Human body
C _astra_body_list | Struct containing a variable-sized array of astra_body_t structs
C _astra_bodyframe |
►C _astra_bodyframe_info | Struct containing general body frame information
C astra::BodyFrameInfo |
C _astra_bodyframe_wrapper |
►C _astra_floor_info | Struct containing floor information about the scene
C astra::FloorInfo |
C _astra_frame |
C _astra_handframe |
C _astra_handframe_wrapper |
►C _astra_handpose_info |
C astra::HandPoseInfo |
C _astra_imageframe |
C _astra_imageframe_wrapper |
►C _astra_joint | Joint information
C astra::Joint | Body joint
►C _astra_matrix3x3 | Represents a 3x3 rotation matrix
C astra::Matrix3x3 | Represents a 3x3 rotation matrix
►C _astra_plane | Struct representing a geometric 3-dimensional plane
C astra::Plane | 3D geometric plane
C _astra_reader_callback_id |
C _astra_streamconnection |
C astra::_Unique_if< _Ty > |
C astra::_Unique_if< _Ty[]> |
C astra::_Unique_if< _Ty[N]> |
C com.orbbec.astra.ApiStatus |
C astra::Array< T > | Simple wrapper around primitive arrays
C com.orbbec.astra.Astra |
C astra_body_feature_command_t |
C astra_conversion_cache_t |
►C astra_handpoint_t |
C astra::HandPoint | Hand Point struct
C astra_image_metadata_t |
►C astra_imagestream_mode_t |
C astra::ImageStreamMode | Image Stream Mode
C astra_plugin_info_t |
C astra_pluginservice_proxy_t |
►C astra_rgb_pixel_t |
C astra::RgbPixel | Rgb pixel struct
►C astra_rgba_pixel_t |
C astra::RgbaPixel | Rgba pixel struct
►C astra_stream_desc_t |
C astra::StreamDescription | Stream Description class
►C astra_streamservice_proxy_t |
C astra::StreamServiceProxy | Stream Service Proxy Class
C astra_usb_info_t |
►C astra_vector2f_t |
C astra::Vector2f | Represents a float 2d vector
►C astra_vector2i_t |
C astra::Vector2i | Represents a float 2d vector
►C astra_vector3f_t |
C astra::Vector3f | Represents a float 3d vector
►C astra_vector3i_t |
C astra::Vector3i | Represents a float 3d vector
C astra_version_info_t |
C com.orbbec.astra.android.AstraAndroidContext |
C com.orbbec.astra.android.AstraDeviceManager |
C com.orbbec.astra.android.AstraDeviceManagerListener |
C Astra.Body |
C com.orbbec.astra.Body |
C astra::BodyFrame | Body tracking information produced by a BodyTracker instance
C Astra.BodyFrameInfo |
C com.orbbec.astra.BodyFrameInfo |
C Astra.BodyMask |
C com.orbbec.astra.BodyMask |
C com.orbbec.astra.BodyStatus |
C Astra.BodyTracking |
C com.orbbec.astra.BodyTracking |
C com.orbbec.astra.BodyTrackingFeatureFlags |
C Astra.Context |
C astra::CoordinateMapper | CoordinateMapper
C Astra.CoordinateMapper |
C com.orbbec.astra.CoordinateMapper |
►C Astra.DataFrame |
C Astra.BodyFrame |
C Astra.ImageFrame< T > |
►C com.orbbec.astra.DataFrame |
C com.orbbec.astra.BodyFrame |
►C com.orbbec.astra.ImageFrame |
C com.orbbec.astra.ColorFrame |
C com.orbbec.astra.ColorizedBodyFrame |
C com.orbbec.astra.DepthFrame |
C com.orbbec.astra.InfraredFrame |
C com.orbbec.astra.MaskedColorFrame |
C com.orbbec.astra.PointFrame |
►C astra::DataStream | Data Stream
C astra::BodyStream | A Body Data Stream
C astra::ColorizedBodyStream | A Colorized Body Stream
C astra::DebugHandStream | A Debug Hand Stream
C astra::HandStream | A Hand Stream
►C astra::ImageStream | Basic Image Stream
C astra::ColorStream | A color stream
C astra::DepthStream | A Depth Stream
C astra::InfraredStream | A Infrared Stream
C astra::MaskedColorStream | A Masked Color Stream
C astra::PointStream | A Point Data Stream
►C Astra.DataStream |
C Astra.BodyStream |
►C Astra.ImageStream |
C Astra.ColorizedBodyStream |
C Astra.ColorStream |
C Astra.DepthStream |
C Astra.InfraredStream |
C Astra.MaskedColorStream |
C Astra.PointStream |
►C com.orbbec.astra.DataStream |
C com.orbbec.astra.BodyStream |
C com.orbbec.astra.ColorizedBodyStream |
►C com.orbbec.astra.ImageStream |
C com.orbbec.astra.ColorStream |
C com.orbbec.astra.DepthStream |
C com.orbbec.astra.InfraredStream |
C com.orbbec.astra.MaskedColorStream |
C com.orbbec.astra.PointStream |
►C EventArgs |
C Astra.FrameReadyEventArgs |
►C Exception |
C Astra.AstraException |
C Astra.FloorInfo |
C com.orbbec.astra.FloorInfo |
C Astra.FloorMask |
C com.orbbec.astra.FloorMask |
C astra::Frame | Frame class
C com.orbbec.astra.StreamReader.FrameListener |
C astra::FrameListener | Frame Listener class
C astra::HandFrame | A Hand Data Frame
C com.orbbec.astra.HandPose |
C Astra.HandPoseInfo |
C com.orbbec.astra.HandPoseInfo |
►C IDisposable |
C Astra.Core.GcHandleWrapper |
C Astra.ReaderFrame | Contains frames from opened streams.
C Astra.StreamReader |
C Astra.StreamSet | A StreamSet represents a logical group of related streams, the most common of these being an Astra camera device
C astra::ImageFrame< TDataType, TStreamType > | Basic Image Frame
►C Astra.ImageFrame< byte > |
C Astra.ColorFrame |
C Astra.ColorizedBodyFrame |
C Astra.MaskedColorFrame |
►C astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH > |
C astra::DepthFrame | A Depth Frame
►C astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY > |
C astra::ColorizedBodyFrame | A Colorized Body Frame
►C astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR > |
C astra::MaskedColorFrame | A Masked Color Frame of Masked Color Stream
►C astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR > |
C astra::ColorFrame | Color frame of rgb format
►C astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND > |
C astra::DebugHandFrame | A Debug Hand Frame
►C astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED > |
C astra::InfraredFrameRgb | A Infrared Frame use rgb format
►C Astra.ImageFrame< short > |
C Astra.DepthFrame |
C Astra.InfraredFrame |
►C astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED > |
C astra::InfraredFrame16 | A Infrared Frame use 16bit unsigned short format
►C astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR > |
C astra::RawColorFrame | Color frame of raw format
►C Astra.ImageFrame< Vector3D > |
C Astra.PointFrame |
►C astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT > |
C astra::PointFrame | A Point Data Frame
C Astra.Core.ImageMetadata |
C com.orbbec.astra.ImageMetadata |
C Astra.ImageMode |
C com.orbbec.astra.ImageStreamMode |
C Astra.Extensions.IntPtrExtensions |
C com.orbbec.astra.Joint |
C Astra.Joint |
C com.orbbec.astra.JointStatus |
C com.orbbec.astra.JointType |
C com.orbbec.astra.Matrix3 |
C Astra.Matrix3x3 | Represents a 3x3 rotation matrix.
C com.orbbec.astra.PixelFormat |
C Astra.Plane | 3D geometric plane Represents a 3D plane. The normal of the plane is defined to be(A, B, C). The plane coefficients and real world coordinates(x, y, and z) are related by the plane equation: Ax + By + Cz + D = 0
C com.orbbec.astra.Plane |
►C PreviewCallback |
C com.orbbec.astra.android.AndroidCamera |
C com.orbbec.astra.SkeletonOptimization |
C com.orbbec.astra.SkeletonProfile |
C stream_callbacks_t |
C com.orbbec.astra.StreamDescription |
C Astra.StreamDescription |
C astra::StreamReader | Stream Reader class
C com.orbbec.astra.StreamReader |
C astra::StreamSet | Stream Set Class
C com.orbbec.astra.StreamType |
C Astra.StreamTypeRegistry |
C com.orbbec.astra.android.UsbDeviceAccessBroker |
C com.orbbec.astra.android.UsbDeviceAccessBroker.UsbDeviceAccessEventListener |
C com.orbbec.astra.android.UsbDeviceInfo |
C com.orbbec.astra.UsbDeviceInfo |
C Astra.USBInfo |
C com.orbbec.astra.Vector2D |
C Astra.Vector2D | Represents a float 2d vector
C com.orbbec.astra.Vector3D |
C Astra.Vector3D | Represents a float 3d vector
►C Activity |
C com.orbbec.astra.android.AstraDeviceMonitorActivity |
►C Closeable |
C com.orbbec.astra.ReaderFrame |
C com.orbbec.astra.StreamSet |
►C UnityPlayerActivity |
C com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity |


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- a -

  • a : _astra_plane , astra::Plane
  • acquire()
: astra::HandFrame
, astra::ImageFrame< TDataType, TStreamType >
  • add_listener() : astra::StreamReader
  • addFrameListener() : com.orbbec.astra.StreamReader
  • AreHandPosesEnabled : Astra.Body
  • areHandPosesEnabled() : com.orbbec.astra.Body
  • AreJointsEnabled : Astra.Body
  • areJointsEnabled() : com.orbbec.astra.Body
  • Array() : astra::Array< T >
  • AstraAndroidContext() : com.orbbec.astra.android.AstraAndroidContext
  • available_modes() : astra::ImageStream
  • AxisX : Astra.Matrix3x3
  • AxisY : Astra.Matrix3x3
  • AxisZ : Astra.Matrix3x3


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- b -

  • b : _astra_plane , astra::Plane
  • back() : astra::Array< T >
  • BALANCED : com.orbbec.astra.SkeletonOptimization
  • BASIC : com.orbbec.astra.SkeletonProfile
  • begin() : astra::Array< T >
  • BEST_ACCURACY : com.orbbec.astra.SkeletonOptimization
  • BitmapMask() : astra::BitmapMask
  • bodies : _astra_body_list , astra::BodyFrame
  • Body() : com.orbbec.astra.Body
  • body_mask() : astra::BodyFrame
  • BodyFrame() : astra::BodyFrame
  • BodyMask : Astra.BodyFrame
  • BodyStream() : astra::BodyStream
  • bpp() : astra::BitmapMask
  • byte_length()
: astra::BitmapMask
, astra::ImageFrame< TDataType, TStreamType >
  • bytes_per_pixel()
: astra::ImageFrame< TDataType, TStreamType >
, astra::ImageStreamMode


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- c -

  • c : _astra_plane , astra::Plane
  • center_of_mass() : astra::Body
  • centerOfMass : _astra_body
  • chip_id() : astra::DepthStream
  • close() : com.orbbec.astra.ReaderFrame , com.orbbec.astra.StreamSet
  • convert_depth_to_world() : astra::CoordinateMapper
  • convert_world_to_depth() : astra::CoordinateMapper
  • CoordinateMapper() : Astra.CoordinateMapper , astra::CoordinateMapper
  • coordinateMapper() : astra::DepthStream
  • CoordinateMapper() : com.orbbec.astra.CoordinateMapper
  • copy_to() : astra::ImageFrame< TDataType, TStreamType >
  • count : _astra_body_list
  • create_reader() : astra::StreamSet
  • CreateReader() : Astra.StreamSet
  • createReader() : com.orbbec.astra.StreamSet
  • cross()
: astra::Vector3f
, astra::Vector3i


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- d -

  • d : _astra_plane , astra::Plane
  • data
: _astra_bitmapmask
, astra::Array< T >
, astra::BitmapMask
, astra::ImageFrame< TDataType, TStreamType >
  • DataStream() : astra::DataStream
  • DebugHandFrame() : astra::DebugHandFrame
  • DebugHandStream() : astra::DebugHandStream
  • depth_position()
: astra::HandPoint
, astra::Joint
  • depth_to_world_data() : astra::DepthStream
  • depthPosition : _astra_joint
  • destroy() : com.orbbec.astra.StreamReader
  • Dispose() : Astra.StreamSet
  • dot()
: astra::Vector2f
, astra::Vector2i
, astra::Vector3f
, astra::Vector3i


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- e -

  • empty() : astra::Array< T >
  • enable_mirroring() : astra::ImageStream
  • enable_registration() : astra::DepthStream
  • end() : astra::Array< T >


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- f -

  • features : _astra_body
  • finalize() : com.orbbec.astra.StreamReader , com.orbbec.astra.StreamSet
  • floorDetected : _astra_floor_info
  • FloorInfo : Astra.BodyFrame
  • floorMask : _astra_floor_info
  • floorPlane : _astra_floor_info
  • fps() : astra::ImageStreamMode
  • Frame() : astra::Frame
  • frame_index()
: astra::BodyFrame
, astra::HandFrame
, astra::ImageFrame< TDataType, TStreamType >
  • fromNativeCode() : com.orbbec.astra.BodyStatus
  • front() : astra::Array< T >
  • FULL : com.orbbec.astra.SkeletonProfile


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- g -

  • get() : astra::Frame , com.orbbec.astra.BodyFrame , com.orbbec.astra.BodyStream , com.orbbec.astra.ColorFrame , com.orbbec.astra.ColorizedBodyFrame , com.orbbec.astra.ColorizedBodyStream , com.orbbec.astra.ColorStream , com.orbbec.astra.DepthFrame , com.orbbec.astra.DepthStream , com.orbbec.astra.InfraredFrame , com.orbbec.astra.InfraredStream , com.orbbec.astra.MaskedColorFrame , com.orbbec.astra.MaskedColorStream , com.orbbec.astra.PointFrame , com.orbbec.astra.PointStream
  • get_body_features() : astra::BodyStream
  • get_default_body_features() : astra::BodyStream
  • get_handle() : astra::StreamSet
  • get_include_candidate_points() : astra::HandStream
  • get_latest_frame() : astra::StreamReader
  • get_skeleton_optimization() : astra::BodyStream
  • get_skeleton_profile() : astra::BodyStream
  • get_view_type() : astra::DebugHandStream
  • getAvailableDevicesSize() : com.orbbec.astra.android.AstraAndroidContext
  • getAvailableModes() : com.orbbec.astra.ImageStream
  • getBodies() : com.orbbec.astra.BodyFrame
  • getBodyFeatures() : com.orbbec.astra.BodyStream
  • getBodyMask() : com.orbbec.astra.BodyFrame
  • getByteBuffer() : com.orbbec.astra.ImageFrame
  • getBytesPerPixel() : com.orbbec.astra.ImageFrame
  • getCenterOfMass() : com.orbbec.astra.Body
  • getCode() : com.orbbec.astra.BodyStatus
  • getDefaultBodyFeatures() : com.orbbec.astra.BodyStream
  • getDepthBuffer() : com.orbbec.astra.DepthFrame
  • getDepthPosition() : com.orbbec.astra.Joint
  • getDeviceChipId() : com.orbbec.astra.DepthStream
  • getDeviceSerialNumber() : com.orbbec.astra.DepthStream
  • getFloorInfo() : com.orbbec.astra.BodyFrame
  • getFormat() : com.orbbec.astra.ImageMetadata , com.orbbec.astra.ImageStreamMode
  • GetFrame< TFrame >() : Astra.ReaderFrame
  • getFrameIndex() : com.orbbec.astra.DataFrame
  • getFramesPerSecond() : com.orbbec.astra.ImageStreamMode
  • getHandPoseInfo() : com.orbbec.astra.Body
  • getHeight() : com.orbbec.astra.BodyFrame , com.orbbec.astra.BodyFrameInfo , com.orbbec.astra.BodyMask , com.orbbec.astra.FloorMask , com.orbbec.astra.ImageFrame , com.orbbec.astra.ImageMetadata , com.orbbec.astra.ImageStreamMode
  • getHorizontalFieldOfView() : com.orbbec.astra.ImageStream
  • getId() : com.orbbec.astra.Body , com.orbbec.astra.ImageStreamMode
  • getIsAvailable() : com.orbbec.astra.DataStream , com.orbbec.astra.StreamSet
  • getIsEstimated() : com.orbbec.astra.BodyFrame , com.orbbec.astra.BodyFrameInfo
  • getJoints() : com.orbbec.astra.Body
  • getLeftHand() : com.orbbec.astra.HandPoseInfo
  • getMask() : com.orbbec.astra.BodyMask , com.orbbec.astra.FloorInfo , com.orbbec.astra.FloorMask
  • getMirroring() : com.orbbec.astra.ImageStream
  • getMode() : com.orbbec.astra.ImageStream
  • getNV21ColorFrame() : com.orbbec.astra.ColorFrame
  • getNV21ColorStream() : com.orbbec.astra.ColorStream
  • getOrientation() : com.orbbec.astra.Joint
  • getPixelFormat() : com.orbbec.astra.ImageFrame
  • getPlane() : com.orbbec.astra.FloorInfo
  • getPointBuffer() : com.orbbec.astra.PointFrame
  • getProductId() : com.orbbec.astra.UsbDeviceInfo
  • getRegistration() : com.orbbec.astra.DepthStream
  • getRightHand() : com.orbbec.astra.HandPoseInfo
  • getSkeletonOptimization() : com.orbbec.astra.BodyStream
  • getSkeletonProfile() : com.orbbec.astra.BodyStream
  • getStatus() : com.orbbec.astra.Body , com.orbbec.astra.Joint
  • GetStream< TStream >() : Astra.StreamReader
  • getSubtype() : com.orbbec.astra.DataStream , com.orbbec.astra.StreamDescription
  • getType() : com.orbbec.astra.DataStream , com.orbbec.astra.Joint , com.orbbec.astra.StreamDescription
  • getTypeCode() : com.orbbec.astra.StreamDescription
  • getUri() : com.orbbec.astra.StreamSet
  • getUsbDeviceInfo() : com.orbbec.astra.ImageStream
  • getVendorId() : com.orbbec.astra.UsbDeviceInfo
  • getVerticalFieldOfView() : com.orbbec.astra.ImageStream
  • getWidth() : com.orbbec.astra.BodyFrame , com.orbbec.astra.BodyFrameInfo , com.orbbec.astra.BodyMask , com.orbbec.astra.FloorMask , com.orbbec.astra.ImageFrame , com.orbbec.astra.ImageMetadata , com.orbbec.astra.ImageStreamMode
  • getWorldPosition() : com.orbbec.astra.Joint
  • GRIP : com.orbbec.astra.HandPose


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- h -

  • HAND_POSES : com.orbbec.astra.BodyTrackingFeatureFlags
  • HandFrame() : astra::HandFrame
  • handle()
: astra::HandFrame
, astra::ImageFrame< TDataType, TStreamType >
  • HandPoint() : astra::HandPoint
  • handpoint_count() : astra::HandFrame
  • handpoints() : astra::HandFrame
  • handPoses : _astra_body
  • HandStream() : astra::HandStream
  • has_new_frame() : astra::StreamReader
  • hasHandPoses() : com.orbbec.astra.BodyTrackingFeatureFlags
  • hasJoints() : com.orbbec.astra.BodyTrackingFeatureFlags
  • hasNewFrame() : com.orbbec.astra.StreamReader
  • hasSegmentation() : com.orbbec.astra.BodyTrackingFeatureFlags
  • height : _astra_bitmapmask , _astra_bodyframe_info
  • Height : Astra.BodyFrame
  • height()
: astra::BitmapMask
, astra::ImageFrame< TDataType, TStreamType >
, astra::ImageStreamMode
  • hFov() : astra::ImageStream


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- i -

  • id : _astra_body , astra::Body
  • ImageFrame() : astra::ImageFrame< TDataType, TStreamType >
  • ImageStreamMode() : astra::ImageStreamMode , com.orbbec.astra.ImageStreamMode
  • info() : astra::BodyFrame
  • Initialize() : Astra.Context
  • initialize() : com.orbbec.astra.android.AstraAndroidContext , com.orbbec.astra.Astra
  • is_available()
: astra::DataStream
, astra::StreamSet
  • is_degenerate() : astra::Plane
  • is_valid()
: astra::BodyFrame
, astra::Frame
, astra::HandFrame
, astra::ImageFrame< TDataType, TStreamType >
, astra::StreamReader
, astra::StreamSet
  • is_zero()
: astra::Vector2f
, astra::Vector2i
, astra::Vector3f
, astra::Vector3i
  • isDetected() : com.orbbec.astra.FloorInfo
  • isEstimated : _astra_bodyframe_info
  • IsEstimated : Astra.BodyFrame
  • isValid() : com.orbbec.astra.DataFrame


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- j -

  • joints : _astra_body , astra::Body
  • JOINTS : com.orbbec.astra.BodyTrackingFeatureFlags


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- l -

  • length()
: astra::BitmapMask
, astra::ImageFrame< TDataType, TStreamType >
, astra::Vector2f
, astra::Vector2i
, astra::Vector3f
, astra::Vector3i
  • length_squared()
: astra::Vector2f
, astra::Vector2i
, astra::Vector3f
, astra::Vector3i
  • LOST : com.orbbec.astra.BodyStatus
  • LOW_CONFIDENCE : com.orbbec.astra.JointStatus


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- m -

  • m00() : astra::Matrix3x3
  • m01() : astra::Matrix3x3
  • m02() : astra::Matrix3x3
  • m10() : astra::Matrix3x3
  • m11() : astra::Matrix3x3
  • m12() : astra::Matrix3x3
  • m20() : astra::Matrix3x3
  • m21() : astra::Matrix3x3
  • m22() : astra::Matrix3x3
  • MapDepthPointToWorldSpace() : Astra.CoordinateMapper
  • mapDepthPointToWorldSpace() : com.orbbec.astra.CoordinateMapper
  • MapWorldPointToDepthSpace() : Astra.CoordinateMapper
  • mapWorldPointToDepthSpace() : com.orbbec.astra.CoordinateMapper
  • Matrix3x3() : astra::Matrix3x3
  • MINIMIZE_MEMORY : com.orbbec.astra.SkeletonOptimization
  • mirroring_enabled() : astra::ImageStream
  • mode() : astra::ImageStream


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- n -

  • normal() : astra::Plane
  • normalize()
: astra::Vector2f
, astra::Vector2i
, astra::Vector3f
, astra::Vector3i
  • NOT_TRACKED : com.orbbec.astra.JointStatus
  • NOT_TRACKING : com.orbbec.astra.BodyStatus
  • notify_plugin_event() : astra::StreamServiceProxy


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- o -

  • onFrameReady() : com.orbbec.astra.StreamReader.FrameListener
  • onNoDevice() : com.orbbec.astra.android.AstraDeviceManagerListener
  • onOpenAllDevicesCompleted() : com.orbbec.astra.android.AstraDeviceManagerListener
  • onOpenDeviceCompleted() : com.orbbec.astra.android.AstraDeviceManagerListener
  • onPermissionDenied() : com.orbbec.astra.android.AstraDeviceManagerListener
  • Open() : Astra.StreamSet
  • open() : com.orbbec.astra.StreamSet
  • openAllDevices() : com.orbbec.astra.android.AstraAndroidContext
  • openFrame() : com.orbbec.astra.StreamReader
  • operator bool() : astra::Frame
  • operator const ::astra_handpoint_t *() : astra::HandPoint
  • operator!=() : astra::Array< T >
  • operator::astra_handpoint_t *() : astra::HandPoint
  • operator=()
: astra::BodyFrame
, astra::CoordinateMapper
, astra::HandPoint
, astra::ImageStreamMode
, astra::StreamDescription
, astra::StreamReader
, astra::StreamSet
, astra::Vector2f
, astra::Vector2i
, astra::Vector3f
, astra::Vector3i
  • operator==() : astra::Array< T >
  • operator[]() : astra::Array< T >
  • orientation : _astra_joint , astra::Joint


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- p -

  • pixel_format() : astra::ImageStreamMode
  • Plane() : astra::Plane
  • PointFrame() : astra::PointFrame
  • PointStream() : astra::PointStream


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- r -

  • reader_close_frame() : astra::StreamServiceProxy
  • reader_create() : astra::StreamServiceProxy
  • reader_destroy() : astra::StreamServiceProxy
  • reader_get_frame() : astra::StreamServiceProxy
  • reader_get_stream() : astra::StreamServiceProxy
  • reader_has_new_frame() : astra::StreamServiceProxy
  • reader_open_frame() : astra::StreamServiceProxy
  • reader_register_frame_ready_callback() : astra::StreamServiceProxy
  • reader_unregister_frame_ready_callback() : astra::StreamServiceProxy
  • registration_enabled() : astra::DepthStream
  • remove_listener() : astra::StreamReader
  • removeFrameListener() : com.orbbec.astra.StreamReader
  • RgbaPixel() : astra::RgbaPixel
  • RgbPixel() : astra::RgbPixel


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- s -

  • SEGMENTATION : com.orbbec.astra.BodyTrackingFeatureFlags
  • serial_number() : astra::DepthStream
  • set_body_features() : astra::BodyStream
  • set_default_body_features() : astra::BodyStream
  • set_fps() : astra::ImageStreamMode
  • set_height() : astra::ImageStreamMode
  • set_include_candidate_points() : astra::HandStream
  • set_lock_spawn_point() : astra::DebugHandStream
  • set_mode() : astra::ImageStream
  • set_mouse_position() : astra::DebugHandStream
  • set_pause_input() : astra::DebugHandStream
  • set_pixel_format() : astra::ImageStreamMode
  • set_skeleton_optimization() : astra::BodyStream
  • set_skeleton_profile() : astra::BodyStream
  • set_use_mouse_probe() : astra::DebugHandStream
  • set_view_type() : astra::DebugHandStream
  • set_width() : astra::ImageStreamMode
  • setBodyFeatures() : com.orbbec.astra.BodyStream
  • setDefaultBodyFeatures() : com.orbbec.astra.BodyStream
  • SetLicense() : Astra.BodyTracking
  • setLicense() : com.orbbec.astra.BodyTracking
  • setMirroring() : com.orbbec.astra.ImageStream
  • setMode() : com.orbbec.astra.ImageStream
  • setRegistration() : com.orbbec.astra.DepthStream
  • SetSkeletonOptimization() : Astra.BodyStream
  • setSkeletonOptimization() : com.orbbec.astra.BodyStream
  • SetSkeletonProfile() : Astra.BodyStream
  • setSkeletonProfile() : com.orbbec.astra.BodyStream
  • size() : astra::Array< T >
  • slice() : astra::Array< T >
  • start() : astra::DataStream , com.orbbec.astra.DataStream
  • status : _astra_body , _astra_joint , astra::Body , astra::HandPoint , astra::Joint
  • stop() : astra::DataStream , com.orbbec.astra.DataStream
  • stream() : astra::StreamReader
  • stream_get_description() : astra::StreamServiceProxy
  • stream_get_parameter() : astra::StreamServiceProxy
  • stream_get_result() : astra::StreamServiceProxy
  • stream_invoke() : astra::StreamServiceProxy
  • stream_is_available() : astra::StreamServiceProxy
  • stream_set_parameter() : astra::StreamServiceProxy
  • stream_start() : astra::StreamServiceProxy
  • stream_stop() : astra::StreamServiceProxy
  • stream_type() : astra::ImageFrame< TDataType, TStreamType >
  • StreamDescription() : astra::StreamDescription
  • StreamReader() : astra::StreamReader
  • StreamSet() : astra::StreamSet
  • streamset_close() : astra::StreamServiceProxy
  • streamset_get_uri() : astra::StreamServiceProxy
  • streamset_is_available() : astra::StreamServiceProxy
  • streamset_open() : astra::StreamServiceProxy
  • subtype() : astra::StreamDescription


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- t -

  • Terminate() : Astra.Context
  • terminate() : com.orbbec.astra.android.AstraAndroidContext , com.orbbec.astra.Astra
  • toString() : com.orbbec.astra.Body , com.orbbec.astra.BodyFrameInfo , com.orbbec.astra.BodyMask , com.orbbec.astra.CoordinateMapper , com.orbbec.astra.FloorInfo , com.orbbec.astra.FloorMask , com.orbbec.astra.HandPoseInfo , com.orbbec.astra.ImageMetadata , com.orbbec.astra.ImageStreamMode , com.orbbec.astra.Joint , com.orbbec.astra.StreamDescription , com.orbbec.astra.UsbDeviceInfo
  • TRACKED : com.orbbec.astra.JointStatus
  • TRACKING : com.orbbec.astra.BodyStatus
  • tracking_id() : astra::HandPoint
  • TRACKING_STARTED : com.orbbec.astra.BodyStatus
  • TryOpenFrame() : Astra.StreamReader
  • type : _astra_joint , astra::Joint , astra::StreamDescription


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- u -

  • UNKNOWN : com.orbbec.astra.HandPose
  • Update() : Astra.Context
  • update() : astra::StreamServiceProxy , com.orbbec.astra.Astra
  • UPPER_BODY : com.orbbec.astra.SkeletonProfile
  • uri() : astra::StreamSet
  • usb_info() : astra::ImageStream


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- v -

  • Vector2f() : astra::Vector2f
  • Vector2i() : astra::Vector2i
  • Vector3f() : astra::Vector3f
  • Vector3i() : astra::Vector3i
  • vFov() : astra::ImageStream


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- w -

  • width : _astra_bitmapmask , _astra_bodyframe_info
  • Width : Astra.BodyFrame
  • width()
: astra::BitmapMask
, astra::ImageFrame< TDataType, TStreamType >
, astra::ImageStreamMode
  • world_delta_position() : astra::HandPoint
  • world_position()
: astra::HandPoint
, astra::Joint
  • worldPosition : _astra_joint


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- x -

  • x_axis() : astra::Matrix3x3


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- y -

  • y_axis() : astra::Matrix3x3


Astra SDK: Class Members

Here is a list of all documented class members with links to the class documentation for each member:

- z -

  • z_axis() : astra::Matrix3x3
  • zero()
: astra::Vector2f
, astra::Vector2i
, astra::Vector3f
, astra::Vector3i


Astra SDK: Class Members - Functions

- a -

  • a() : astra::Plane
  • acquire()
: astra::HandFrame
, astra::ImageFrame< TDataType, TStreamType >
  • add_listener() : astra::StreamReader
  • addFrameListener() : com.orbbec.astra.StreamReader
  • areHandPosesEnabled() : com.orbbec.astra.Body
  • areJointsEnabled() : com.orbbec.astra.Body
  • Array() : astra::Array< T >
  • AstraAndroidContext() : com.orbbec.astra.android.AstraAndroidContext
  • available_modes() : astra::ImageStream


Astra SDK: Class Members - Functions

- b -

  • b() : astra::Plane
  • back() : astra::Array< T >
  • begin() : astra::Array< T >
  • BitmapMask() : astra::BitmapMask
  • bodies() : astra::BodyFrame
  • Body() : com.orbbec.astra.Body
  • body_mask() : astra::BodyFrame
  • BodyFrame() : astra::BodyFrame
  • BodyStream() : astra::BodyStream
  • bpp() : astra::BitmapMask
  • byte_length()
: astra::BitmapMask
, astra::ImageFrame< TDataType, TStreamType >
  • bytes_per_pixel()
: astra::ImageFrame< TDataType, TStreamType >
, astra::ImageStreamMode


Astra SDK: Class Members - Functions

- c -

  • c() : astra::Plane
  • center_of_mass() : astra::Body
  • chip_id() : astra::DepthStream
  • close() : com.orbbec.astra.ReaderFrame , com.orbbec.astra.StreamSet
  • convert_depth_to_world() : astra::CoordinateMapper
  • convert_world_to_depth() : astra::CoordinateMapper
  • CoordinateMapper() : Astra.CoordinateMapper , astra::CoordinateMapper
  • coordinateMapper() : astra::DepthStream
  • CoordinateMapper() : com.orbbec.astra.CoordinateMapper
  • copy_to() : astra::ImageFrame< TDataType, TStreamType >
  • create_reader() : astra::StreamSet
  • CreateReader() : Astra.StreamSet
  • createReader() : com.orbbec.astra.StreamSet
  • cross()
: astra::Vector3f
, astra::Vector3i


Astra SDK: Class Members - Functions

- d -

  • d() : astra::Plane
  • data()
: astra::Array< T >
, astra::BitmapMask
, astra::ImageFrame< TDataType, TStreamType >
  • DataStream() : astra::DataStream
  • DebugHandFrame() : astra::DebugHandFrame
  • DebugHandStream() : astra::DebugHandStream
  • depth_position()
: astra::HandPoint
, astra::Joint
  • depth_to_world_data() : astra::DepthStream
  • destroy() : com.orbbec.astra.StreamReader
  • Dispose() : Astra.StreamSet
  • dot()
: astra::Vector2f
, astra::Vector2i
, astra::Vector3f
, astra::Vector3i


Astra SDK: Class Members - Functions

- e -

  • empty() : astra::Array< T >
  • enable_mirroring() : astra::ImageStream
  • enable_registration() : astra::DepthStream
  • end() : astra::Array< T >


Astra SDK: Class Members - Functions

- f -

  • finalize() : com.orbbec.astra.StreamReader , com.orbbec.astra.StreamSet
  • fps() : astra::ImageStreamMode
  • Frame() : astra::Frame
  • frame_index()
: astra::BodyFrame
, astra::HandFrame
, astra::ImageFrame< TDataType, TStreamType >
  • fromNativeCode() : com.orbbec.astra.BodyStatus
  • front() : astra::Array< T >


Astra SDK: Class Members - Functions

- g -

  • get() : astra::Frame , com.orbbec.astra.BodyFrame , com.orbbec.astra.BodyStream , com.orbbec.astra.ColorFrame , com.orbbec.astra.ColorizedBodyFrame , com.orbbec.astra.ColorizedBodyStream , com.orbbec.astra.ColorStream , com.orbbec.astra.DepthFrame , com.orbbec.astra.DepthStream , com.orbbec.astra.InfraredFrame , com.orbbec.astra.InfraredStream , com.orbbec.astra.MaskedColorFrame , com.orbbec.astra.MaskedColorStream , com.orbbec.astra.PointFrame , com.orbbec.astra.PointStream
  • get_body_features() : astra::BodyStream
  • get_default_body_features() : astra::BodyStream
  • get_handle() : astra::StreamSet
  • get_include_candidate_points() : astra::HandStream
  • get_latest_frame() : astra::StreamReader
  • get_skeleton_optimization() : astra::BodyStream
  • get_skeleton_profile() : astra::BodyStream
  • get_view_type() : astra::DebugHandStream
  • getAvailableDevicesSize() : com.orbbec.astra.android.AstraAndroidContext
  • getAvailableModes() : com.orbbec.astra.ImageStream
  • getBodies() : com.orbbec.astra.BodyFrame
  • getBodyFeatures() : com.orbbec.astra.BodyStream
  • getBodyMask() : com.orbbec.astra.BodyFrame
  • getByteBuffer() : com.orbbec.astra.ImageFrame
  • getBytesPerPixel() : com.orbbec.astra.ImageFrame
  • getCenterOfMass() : com.orbbec.astra.Body
  • getCode() : com.orbbec.astra.BodyStatus
  • getDefaultBodyFeatures() : com.orbbec.astra.BodyStream
  • getDepthBuffer() : com.orbbec.astra.DepthFrame
  • getDepthPosition() : com.orbbec.astra.Joint
  • getDeviceChipId() : com.orbbec.astra.DepthStream
  • getDeviceSerialNumber() : com.orbbec.astra.DepthStream
  • getFloorInfo() : com.orbbec.astra.BodyFrame
  • getFormat() : com.orbbec.astra.ImageMetadata , com.orbbec.astra.ImageStreamMode
  • GetFrame< TFrame >() : Astra.ReaderFrame
  • getFrameIndex() : com.orbbec.astra.DataFrame
  • getFramesPerSecond() : com.orbbec.astra.ImageStreamMode
  • getHandPoseInfo() : com.orbbec.astra.Body
  • getHeight() : com.orbbec.astra.BodyFrame , com.orbbec.astra.BodyFrameInfo , com.orbbec.astra.BodyMask , com.orbbec.astra.FloorMask , com.orbbec.astra.ImageFrame , com.orbbec.astra.ImageMetadata , com.orbbec.astra.ImageStreamMode
  • getHorizontalFieldOfView() : com.orbbec.astra.ImageStream
  • getId() : com.orbbec.astra.Body , com.orbbec.astra.ImageStreamMode
  • getIsAvailable() : com.orbbec.astra.DataStream , com.orbbec.astra.StreamSet
  • getIsEstimated() : com.orbbec.astra.BodyFrame , com.orbbec.astra.BodyFrameInfo
  • getJoints() : com.orbbec.astra.Body
  • getLeftHand() : com.orbbec.astra.HandPoseInfo
  • getMask() : com.orbbec.astra.BodyMask , com.orbbec.astra.FloorInfo , com.orbbec.astra.FloorMask
  • getMirroring() : com.orbbec.astra.ImageStream
  • getMode() : com.orbbec.astra.ImageStream
  • getNV21ColorFrame() : com.orbbec.astra.ColorFrame
  • getNV21ColorStream() : com.orbbec.astra.ColorStream
  • getOrientation() : com.orbbec.astra.Joint
  • getPixelFormat() : com.orbbec.astra.ImageFrame
  • getPlane() : com.orbbec.astra.FloorInfo
  • getPointBuffer() : com.orbbec.astra.PointFrame
  • getProductId() : com.orbbec.astra.UsbDeviceInfo
  • getRegistration() : com.orbbec.astra.DepthStream
  • getRightHand() : com.orbbec.astra.HandPoseInfo
  • getSkeletonOptimization() : com.orbbec.astra.BodyStream
  • getSkeletonProfile() : com.orbbec.astra.BodyStream
  • getStatus() : com.orbbec.astra.Body , com.orbbec.astra.Joint
  • GetStream< TStream >() : Astra.StreamReader
  • getSubtype() : com.orbbec.astra.DataStream , com.orbbec.astra.StreamDescription
  • getType() : com.orbbec.astra.DataStream , com.orbbec.astra.Joint , com.orbbec.astra.StreamDescription
  • getTypeCode() : com.orbbec.astra.StreamDescription
  • getUri() : com.orbbec.astra.StreamSet
  • getUsbDeviceInfo() : com.orbbec.astra.ImageStream
  • getVendorId() : com.orbbec.astra.UsbDeviceInfo
  • getVerticalFieldOfView() : com.orbbec.astra.ImageStream
  • getWidth() : com.orbbec.astra.BodyFrame , com.orbbec.astra.BodyFrameInfo , com.orbbec.astra.BodyMask , com.orbbec.astra.FloorMask , com.orbbec.astra.ImageFrame , com.orbbec.astra.ImageMetadata , com.orbbec.astra.ImageStreamMode
  • getWorldPosition() : com.orbbec.astra.Joint


Astra SDK: Class Members - Functions

- h -

  • HandFrame() : astra::HandFrame
  • handle()
: astra::HandFrame
, astra::ImageFrame< TDataType, TStreamType >
  • HandPoint() : astra::HandPoint
  • handpoint_count() : astra::HandFrame
  • handpoints() : astra::HandFrame
  • HandStream() : astra::HandStream
  • has_new_frame() : astra::StreamReader
  • hasHandPoses() : com.orbbec.astra.BodyTrackingFeatureFlags
  • hasJoints() : com.orbbec.astra.BodyTrackingFeatureFlags
  • hasNewFrame() : com.orbbec.astra.StreamReader
  • hasSegmentation() : com.orbbec.astra.BodyTrackingFeatureFlags
  • height()
: astra::BitmapMask
, astra::ImageFrame< TDataType, TStreamType >
, astra::ImageStreamMode
  • hFov() : astra::ImageStream


Astra SDK: Class Members - Functions

- i -

  • id() : astra::Body
  • ImageFrame() : astra::ImageFrame< TDataType, TStreamType >
  • ImageStreamMode() : astra::ImageStreamMode , com.orbbec.astra.ImageStreamMode
  • info() : astra::BodyFrame
  • Initialize() : Astra.Context
  • initialize() : com.orbbec.astra.android.AstraAndroidContext , com.orbbec.astra.Astra
  • is_available()
: astra::DataStream
, astra::StreamSet
  • is_degenerate() : astra::Plane
  • is_valid()
: astra::BodyFrame
, astra::Frame
, astra::HandFrame
, astra::ImageFrame< TDataType, TStreamType >
, astra::StreamReader
, astra::StreamSet
  • is_zero()
: astra::Vector2f
, astra::Vector2i
, astra::Vector3f
, astra::Vector3i
  • isDetected() : com.orbbec.astra.FloorInfo
  • isValid() : com.orbbec.astra.DataFrame


Astra SDK: Class Members - Functions

- j -

  • joints() : astra::Body


Astra SDK: Class Members - Functions

- l -

  • length()
: astra::BitmapMask
, astra::ImageFrame< TDataType, TStreamType >
, astra::Vector2f
, astra::Vector2i
, astra::Vector3f
, astra::Vector3i
  • length_squared()
: astra::Vector2f
, astra::Vector2i
, astra::Vector3f
, astra::Vector3i


Astra SDK: Class Members - Functions

- m -

  • m00() : astra::Matrix3x3
  • m01() : astra::Matrix3x3
  • m02() : astra::Matrix3x3
  • m10() : astra::Matrix3x3
  • m11() : astra::Matrix3x3
  • m12() : astra::Matrix3x3
  • m20() : astra::Matrix3x3
  • m21() : astra::Matrix3x3
  • m22() : astra::Matrix3x3
  • MapDepthPointToWorldSpace() : Astra.CoordinateMapper
  • mapDepthPointToWorldSpace() : com.orbbec.astra.CoordinateMapper
  • MapWorldPointToDepthSpace() : Astra.CoordinateMapper
  • mapWorldPointToDepthSpace() : com.orbbec.astra.CoordinateMapper
  • Matrix3x3() : astra::Matrix3x3
  • mirroring_enabled() : astra::ImageStream
  • mode() : astra::ImageStream


Astra SDK: Class Members - Functions

- n -

  • normal() : astra::Plane
  • normalize()
: astra::Vector2f
, astra::Vector2i
, astra::Vector3f
, astra::Vector3i
  • notify_plugin_event() : astra::StreamServiceProxy


Astra SDK: Class Members - Functions

- o -

  • onFrameReady() : com.orbbec.astra.StreamReader.FrameListener
  • onNoDevice() : com.orbbec.astra.android.AstraDeviceManagerListener
  • onOpenAllDevicesCompleted() : com.orbbec.astra.android.AstraDeviceManagerListener
  • onOpenDeviceCompleted() : com.orbbec.astra.android.AstraDeviceManagerListener
  • onPermissionDenied() : com.orbbec.astra.android.AstraDeviceManagerListener
  • Open() : Astra.StreamSet
  • open() : com.orbbec.astra.StreamSet
  • openAllDevices() : com.orbbec.astra.android.AstraAndroidContext
  • openFrame() : com.orbbec.astra.StreamReader
  • operator bool() : astra::Frame
  • operator const ::astra_handpoint_t *() : astra::HandPoint
  • operator!=() : astra::Array< T >
  • operator::astra_handpoint_t *() : astra::HandPoint
  • operator=()
: astra::BodyFrame
, astra::CoordinateMapper
, astra::HandPoint
, astra::ImageStreamMode
, astra::StreamDescription
, astra::StreamReader
, astra::StreamSet
, astra::Vector2f
, astra::Vector2i
, astra::Vector3f
, astra::Vector3i
  • operator==() : astra::Array< T >
  • operator[]() : astra::Array< T >
  • orientation() : astra::Joint


Astra SDK: Class Members - Functions

- p -

  • pixel_format() : astra::ImageStreamMode
  • Plane() : astra::Plane
  • PointFrame() : astra::PointFrame
  • PointStream() : astra::PointStream


Astra SDK: Class Members - Functions

- r -

  • reader_close_frame() : astra::StreamServiceProxy
  • reader_create() : astra::StreamServiceProxy
  • reader_destroy() : astra::StreamServiceProxy
  • reader_get_frame() : astra::StreamServiceProxy
  • reader_get_stream() : astra::StreamServiceProxy
  • reader_has_new_frame() : astra::StreamServiceProxy
  • reader_open_frame() : astra::StreamServiceProxy
  • reader_register_frame_ready_callback() : astra::StreamServiceProxy
  • reader_unregister_frame_ready_callback() : astra::StreamServiceProxy
  • registration_enabled() : astra::DepthStream
  • remove_listener() : astra::StreamReader
  • removeFrameListener() : com.orbbec.astra.StreamReader
  • RgbaPixel() : astra::RgbaPixel
  • RgbPixel() : astra::RgbPixel


Astra SDK: Class Members - Functions

- s -

  • serial_number() : astra::DepthStream
  • set_body_features() : astra::BodyStream
  • set_default_body_features() : astra::BodyStream
  • set_fps() : astra::ImageStreamMode
  • set_height() : astra::ImageStreamMode
  • set_include_candidate_points() : astra::HandStream
  • set_lock_spawn_point() : astra::DebugHandStream
  • set_mode() : astra::ImageStream
  • set_mouse_position() : astra::DebugHandStream
  • set_pause_input() : astra::DebugHandStream
  • set_pixel_format() : astra::ImageStreamMode
  • set_skeleton_optimization() : astra::BodyStream
  • set_skeleton_profile() : astra::BodyStream
  • set_use_mouse_probe() : astra::DebugHandStream
  • set_view_type() : astra::DebugHandStream
  • set_width() : astra::ImageStreamMode
  • setBodyFeatures() : com.orbbec.astra.BodyStream
  • setDefaultBodyFeatures() : com.orbbec.astra.BodyStream
  • SetLicense() : Astra.BodyTracking
  • setLicense() : com.orbbec.astra.BodyTracking
  • setMirroring() : com.orbbec.astra.ImageStream
  • setMode() : com.orbbec.astra.ImageStream
  • setRegistration() : com.orbbec.astra.DepthStream
  • SetSkeletonOptimization() : Astra.BodyStream
  • setSkeletonOptimization() : com.orbbec.astra.BodyStream
  • SetSkeletonProfile() : Astra.BodyStream
  • setSkeletonProfile() : com.orbbec.astra.BodyStream
  • size() : astra::Array< T >
  • slice() : astra::Array< T >
  • start() : astra::DataStream , com.orbbec.astra.DataStream
  • status()
: astra::Body
, astra::HandPoint
, astra::Joint
  • stop() : astra::DataStream , com.orbbec.astra.DataStream
  • stream() : astra::StreamReader
  • stream_get_description() : astra::StreamServiceProxy
  • stream_get_parameter() : astra::StreamServiceProxy
  • stream_get_result() : astra::StreamServiceProxy
  • stream_invoke() : astra::StreamServiceProxy
  • stream_is_available() : astra::StreamServiceProxy
  • stream_set_parameter() : astra::StreamServiceProxy
  • stream_start() : astra::StreamServiceProxy
  • stream_stop() : astra::StreamServiceProxy
  • stream_type() : astra::ImageFrame< TDataType, TStreamType >
  • StreamDescription() : astra::StreamDescription
  • StreamReader() : astra::StreamReader
  • StreamSet() : astra::StreamSet
  • streamset_close() : astra::StreamServiceProxy
  • streamset_get_uri() : astra::StreamServiceProxy
  • streamset_is_available() : astra::StreamServiceProxy
  • streamset_open() : astra::StreamServiceProxy
  • subtype() : astra::StreamDescription


Astra SDK: Class Members - Functions

- t -

  • Terminate() : Astra.Context
  • terminate() : com.orbbec.astra.android.AstraAndroidContext , com.orbbec.astra.Astra
  • toString() : com.orbbec.astra.Body , com.orbbec.astra.BodyFrameInfo , com.orbbec.astra.BodyMask , com.orbbec.astra.CoordinateMapper , com.orbbec.astra.FloorInfo , com.orbbec.astra.FloorMask , com.orbbec.astra.HandPoseInfo , com.orbbec.astra.ImageMetadata , com.orbbec.astra.ImageStreamMode , com.orbbec.astra.Joint , com.orbbec.astra.StreamDescription , com.orbbec.astra.UsbDeviceInfo
  • tracking_id() : astra::HandPoint
  • TryOpenFrame() : Astra.StreamReader
  • type()
: astra::Joint
, astra::StreamDescription


Astra SDK: Class Members - Functions

- u -

  • Update() : Astra.Context
  • update() : astra::StreamServiceProxy , com.orbbec.astra.Astra
  • uri() : astra::StreamSet
  • usb_info() : astra::ImageStream


Astra SDK: Class Members - Functions

- v -

  • Vector2f() : astra::Vector2f
  • Vector2i() : astra::Vector2i
  • Vector3f() : astra::Vector3f
  • Vector3i() : astra::Vector3i
  • vFov() : astra::ImageStream


Astra SDK: Class Members - Functions

- w -

  • width()
: astra::BitmapMask
, astra::ImageFrame< TDataType, TStreamType >
, astra::ImageStreamMode
  • world_delta_position() : astra::HandPoint
  • world_position()
: astra::HandPoint
, astra::Joint


Astra SDK: Class Members - Functions

- x -

  • x_axis() : astra::Matrix3x3


Astra SDK: Class Members - Functions

- y -

  • y_axis() : astra::Matrix3x3


Astra SDK: Class Members - Functions

- z -

  • z_axis() : astra::Matrix3x3
  • zero()
: astra::Vector2f
, astra::Vector2i
, astra::Vector3f
, astra::Vector3i


Astra SDK: Class Members - Variables

- a -

  • a : _astra_plane

- b -

  • b : _astra_plane
  • BALANCED : com.orbbec.astra.SkeletonOptimization
  • BASIC : com.orbbec.astra.SkeletonProfile
  • BEST_ACCURACY : com.orbbec.astra.SkeletonOptimization
  • bodies : _astra_body_list

- c -

  • c : _astra_plane
  • centerOfMass : _astra_body
  • count : _astra_body_list

- d -

  • d : _astra_plane
  • data : _astra_bitmapmask
  • depthPosition : _astra_joint

- f -

  • features : _astra_body
  • floorDetected : _astra_floor_info
  • floorMask : _astra_floor_info
  • floorPlane : _astra_floor_info
  • FULL : com.orbbec.astra.SkeletonProfile

- g -

  • GRIP : com.orbbec.astra.HandPose

- h -

  • HAND_POSES : com.orbbec.astra.BodyTrackingFeatureFlags
  • handPoses : _astra_body
  • height : _astra_bitmapmask , _astra_bodyframe_info

- i -

  • id : _astra_body
  • isEstimated : _astra_bodyframe_info

- j -

  • joints : _astra_body
  • JOINTS : com.orbbec.astra.BodyTrackingFeatureFlags

- l -

  • LOST : com.orbbec.astra.BodyStatus
  • LOW_CONFIDENCE : com.orbbec.astra.JointStatus

- m -

  • MINIMIZE_MEMORY : com.orbbec.astra.SkeletonOptimization

- n -

  • NOT_TRACKED : com.orbbec.astra.JointStatus
  • NOT_TRACKING : com.orbbec.astra.BodyStatus

- o -

  • orientation : _astra_joint

- s -

  • SEGMENTATION : com.orbbec.astra.BodyTrackingFeatureFlags
  • status : _astra_body , _astra_joint

- t -

  • TRACKED : com.orbbec.astra.JointStatus
  • TRACKING : com.orbbec.astra.BodyStatus
  • TRACKING_STARTED : com.orbbec.astra.BodyStatus
  • type : _astra_joint

- u -

  • UNKNOWN : com.orbbec.astra.HandPose
  • UPPER_BODY : com.orbbec.astra.SkeletonProfile

- w -

  • width : _astra_bitmapmask , _astra_bodyframe_info
  • worldPosition : _astra_joint


Astra SDK: Class Members - Properties

  • AreHandPosesEnabled : Astra.Body
  • AreJointsEnabled : Astra.Body
  • AxisX : Astra.Matrix3x3
  • AxisY : Astra.Matrix3x3
  • AxisZ : Astra.Matrix3x3
  • BodyMask : Astra.BodyFrame
  • FloorInfo : Astra.BodyFrame
  • Height : Astra.BodyFrame
  • IsEstimated : Astra.BodyFrame
  • Width : Astra.BodyFrame


Astra SDK: File List

File List
Here is a list of all documented files with brief descriptions:
Array.hpp
astra.h
astra.hpp
astra_core.h
astra_core.hpp
astra_core_version.h
astra_ctypes.h
astra_cxx_make_unique.hpp
astra_defines.h
astra_host_events.h
astra_plugin.h
astra_plugin_callbacks.h
astra_pluginservice_proxy.h
astra_streamservice_proxy.h
astra_types.h
astra_version.h
Body.hpp
body_capi.h
body_parameters.h
body_types.h
Color.hpp
color_capi.h
color_types.h
colorized_body_capi.h
colorized_body_types.h
ColorizedBody.hpp
DataStream.hpp
DebugHand.hpp
Depth.hpp
depth_capi.h
depth_parameters.h
depth_types.h
Frame.hpp
FrameListener.hpp
Hand.hpp
hand_capi.h
hand_parameters.h
hand_types.h
Image.hpp
image_capi.h
image_parameters.h
image_types.h
Infrared.hpp
infrared_capi.h
infrared_types.h
masked_color_capi.h
masked_color_types.h
MaskedColor.hpp
Matrix3x3.hpp
Point.hpp
point_capi.h
point_types.h
stream_types.h
StreamDescription.hpp
StreamReader.hpp
StreamServiceProxy.hpp
StreamSet.hpp
Vector.hpp
Vector2f.hpp
Vector2i.hpp
Vector3f.hpp
Vector3i.hpp


Astra SDK: Array.hpp Source File

  • include
  • astra
Array.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_ARRAY_HPP
18 #define ASTRA_ARRAY_HPP
19
20 namespace astra {
29 template<typename T>
30 class Array
31 {
32 public:
36 inline Array() : ptr_(nullptr), size_(0) {}
40 inline Array(decltype(nullptr)) : ptr_(nullptr), size_(0) {}
44 inline Array(T* ptr, size_t size) : ptr_(ptr), size_(size) {}
48 inline Array(T* begin, T* end) : ptr_(begin), size_(end - begin) {}
52 inline size_t size() const { return size_; }
56 inline bool empty() const { return size_ == 0; }
60 inline T* data() { return ptr_; }
64 inline const T* data() const { return ptr_; }
68 inline T* begin() { return ptr_; }
72 inline const T* begin() const { return ptr_; }
76 inline T* end() { return ptr_ + size_; }
80 inline const T* end() const { return ptr_ + size_; }
84 inline T& front() { return *ptr_; }
88 inline const T& front() const { return *ptr_; }
92 inline T& back() { return ptr_[size_ - 1]; }
96 inline const T& back() const { return ptr_[size_ - 1]; }
101 inline T& operator[](size_t index)
102 {
103 return ptr_[index];
104 }
109 inline const T& operator[](size_t index) const
110 {
111 return ptr_[index];
112 }
113
119 inline Array<T> slice(size_t start, size_t end)
120 {
121 return Array<T>(ptr_ + start, end - start);
122 }
123
130 inline Array<const T> slice(size_t start, size_t end) const
131 {
132 return Array<const T>(ptr_ + start, end - start);
133 }
134
138 inline bool operator==(const Array& other) const
139 {
140 if (this == &other) { return true; }
141 return this->ptr_ == other.ptr_;
142 }
143
147 inline bool operator!=(const Array& other) const { return !(*this == other); }
148
149 private:
150 T* ptr_;
151 size_t size_;
152 };
153
161 template<typename T>
162 inline Array<T> make_array(T* ptr, std::size_t size)
163 {
164 return Array<T>(ptr, size);
165 }
166
167 }
168
169 #endif // ASTRA_ARRAY_HPP
astra::Array::back
const T & back() const
Gets immutable reference to last array element.
Definition: Array.hpp:96
astra::Array
Simple wrapper around primitive arrays.
Definition: Array.hpp:30
astra::Array::slice
Array< T > slice(size_t start, size_t end)
Creates a mutable sub-array of the same type based on a start and end index.
Definition: Array.hpp:119
astra::Array::operator[]
const T & operator[](size_t index) const
Immutable index operator into array.
Definition: Array.hpp:109
astra::Array::Array
Array()
Default constructs zero-length array.
Definition: Array.hpp:36
astra::Array::size
size_t size() const
Gets size of array.
Definition: Array.hpp:52
astra
Definition: Array.hpp:20
astra::Array::back
T & back()
Gets mutable reference to last array element.
Definition: Array.hpp:92
astra::Array::Array
Array(decltype(nullptr))
Implicit conversion constructor from nullptr to a zero-length array.
Definition: Array.hpp:40
astra::Array::operator!=
bool operator!=(const Array &other) const
Identity based inequality operator.
Definition: Array.hpp:147
astra::Array::Array
Array(T *begin, T *end)
Constructs array from begin and end iterators.
Definition: Array.hpp:48
astra::Array::operator==
bool operator==(const Array &other) const
Identity based equality operator.
Definition: Array.hpp:138
astra::Array::operator[]
T & operator[](size_t index)
Mutable index operator into array.
Definition: Array.hpp:101
astra::Array::end
const T * end() const
Gets iterator pointing to one past the end of array.
Definition: Array.hpp:80
astra::Array::end
T * end()
Gets mutable iterator pointing to one past the end of array.
Definition: Array.hpp:76
astra::Array::data
const T * data() const
Gets immutable raw pointer to array data.
Definition: Array.hpp:64
astra::Array::empty
bool empty() const
Returns true if array is zero length.
Definition: Array.hpp:56
astra::Array::slice
Array< const T > slice(size_t start, size_t end) const
Creates an immutable sub-array of the same type based on a start and end index.
Definition: Array.hpp:130
astra::Array::Array
Array(T *ptr, size_t size)
Constructs array from pointer and size.
Definition: Array.hpp:44
astra::Array::front
T & front()
Gets mutable reference to first array element.
Definition: Array.hpp:84
astra::Array::begin
T * begin()
Gets mutable iterator pointing to beginning of array.
Definition: Array.hpp:68
astra::make_array
Array< T > make_array(T *ptr, std::size_t size)
Simplifies Array construction by leveraging function template type deduction.
Definition: Array.hpp:162
astra::Array::begin
const T * begin() const
Gets immutable iterator pointing to beginning of array.
Definition: Array.hpp:72
astra::Array::data
T * data()
Gets mutable raw pointer to array data.
Definition: Array.hpp:60
astra::Array::front
const T & front() const
Gets immutable reference to first array element.
Definition: Array.hpp:88


Astra SDK: astra.h Source File

  • include
  • astra
  • capi
astra.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_H
18 #define ASTRA_H
19
20 #include <astra_core/capi/astra_core.h>
21 #include "astra_ctypes.h"
22 #include "streams/body_capi.h"
23 #include "streams/image_capi.h"
24 #include "streams/depth_capi.h"
25 #include "streams/color_capi.h"
26 #include "streams/infrared_capi.h"
27 #include "streams/hand_capi.h"
28 #include "streams/point_capi.h"
29 #include "streams/masked_color_capi.h"
30 #include "streams/colorized_body_capi.h"
31 #include "astra_version.h"
32
33 #endif /* ASTRA_H */


Astra SDK: astra.hpp Source File

  • include
  • astra
astra.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_HPP
18 #define ASTRA_HPP
19
20 #include "Vector.hpp"
21 #include "Matrix3x3.hpp"
22 #include "streams/Body.hpp"
23 #include "streams/Color.hpp"
24 #include "streams/Depth.hpp"
25 #include "streams/Infrared.hpp"
26 #include "streams/Hand.hpp"
27 #include "streams/DebugHand.hpp"
28 #include "streams/Point.hpp"
29 #include "streams/MaskedColor.hpp"
30 #include "streams/ColorizedBody.hpp"
31
32 #endif /* ASTRA_HPP */


Astra SDK: astra_core.h Source File

  • include
  • astra_core
  • capi
astra_core.h
1 /* THIS FILE AUTO-GENERATED FROM astra_core.h.lpp. DO NOT EDIT. */
2 #ifndef ASTRA_CAPI_H
3 #define ASTRA_CAPI_H
4
5 #include "astra_defines.h"
6 #include "astra_types.h"
7 #include "astra_core_version.h"
8 #include <stdbool.h>
9
10 ASTRA_BEGIN_DECLS
11
22 ASTRA_API astra_status_t astra_initialize();
23
28 ASTRA_API astra_status_t astra_terminate();
29
38 ASTRA_API astra_status_t astra_notify_plugin_event(astra_event_id id,
39 const void* data,
40 uint32_t dataSize);
41
48 ASTRA_API astra_status_t astra_streamset_is_available(astra_streamsetconnection_t streamSet,
49 bool* isAvailable);
50
58 ASTRA_API astra_status_t astra_streamset_open(const char* uri,
59 astra_streamsetconnection_t* streamSet);
60
66 ASTRA_API astra_status_t astra_streamset_close(astra_streamsetconnection_t* streamSet);
67
75 ASTRA_API astra_status_t astra_streamset_get_uri(astra_streamsetconnection_t streamSet,
76 char* uri,
77 int32_t size);
78
85 ASTRA_API astra_status_t astra_reader_create(astra_streamsetconnection_t streamSet,
86 astra_reader_t* reader);
87
94 ASTRA_API astra_status_t astra_reader_destroy(astra_reader_t* reader);
95
104 ASTRA_API astra_status_t astra_reader_get_stream(astra_reader_t reader,
105 astra_stream_type_t type,
106 astra_stream_subtype_t subtype,
107 astra_streamconnection_t* stream);
108
115 ASTRA_API astra_status_t astra_stream_get_description(astra_streamconnection_t stream,
116 astra_stream_desc_t* description);
117
124 ASTRA_API astra_status_t astra_stream_is_available(astra_streamconnection_t stream,
125 bool* isAvailable);
126
133 ASTRA_API astra_status_t astra_stream_start(astra_streamconnection_t stream);
134
141 ASTRA_API astra_status_t astra_stream_stop(astra_streamconnection_t stream);
142
149 ASTRA_API astra_status_t astra_reader_has_new_frame(astra_reader_t reader,
150 bool* hasNewFrame);
151
159 ASTRA_API astra_status_t astra_reader_open_frame(astra_reader_t reader,
160 int timeoutMillis,
161 astra_reader_frame_t* frame);
162
168 ASTRA_API astra_status_t astra_reader_close_frame(astra_reader_frame_t* frame);
169
178 ASTRA_API astra_status_t astra_reader_register_frame_ready_callback(astra_reader_t reader,
179 astra_frame_ready_callback_t callback,
180 void* clientTag,
181 astra_reader_callback_id_t* callbackId);
182
188 ASTRA_API astra_status_t astra_reader_unregister_frame_ready_callback(astra_reader_callback_id_t* callbackId);
189
198 ASTRA_API astra_status_t astra_reader_get_frame(astra_reader_frame_t frame,
199 astra_stream_type_t type,
200 astra_stream_subtype_t subtype,
201 astra_frame_t** subFrame);
202
211 ASTRA_API astra_status_t astra_stream_set_parameter(astra_streamconnection_t connection,
212 astra_parameter_id parameterId,
213 uint32_t inByteLength,
214 astra_parameter_data_t inData);
215
224 ASTRA_API astra_status_t astra_stream_get_parameter(astra_streamconnection_t connection,
225 astra_parameter_id parameterId,
226 uint32_t* resultByteLength,
227 astra_result_token_t* token);
228
229 ASTRA_API astra_status_t astra_stream_get_result(astra_streamconnection_t connection,
230 astra_result_token_t token,
231 uint32_t dataByteLength,
232 astra_parameter_data_t dataDestination);
233
234 ASTRA_API astra_status_t astra_stream_invoke(astra_streamconnection_t connection,
235 astra_command_id commandId,
236 uint32_t inByteLength,
237 astra_parameter_data_t inData,
238 uint32_t* resultByteLength,
239 astra_result_token_t* token);
240
244 ASTRA_API astra_status_t astra_update();
246 ASTRA_END_DECLS
247
248 #endif /* ASTRA_CAPI_H */
astra_reader_register_frame_ready_callback
ASTRA_API astra_status_t astra_reader_register_frame_ready_callback(astra_reader_t reader, astra_frame_ready_callback_t callback, void *clientTag, astra_reader_callback_id_t *callbackId)
Registers a callback function to StreamReader.
astra_reader_get_frame
ASTRA_API astra_status_t astra_reader_get_frame(astra_reader_frame_t frame, astra_stream_type_t type, astra_stream_subtype_t subtype, astra_frame_t **subFrame)
Read a frame.
_astra_streamconnection
Definition: astra_plugin.h:24
astra_streamset_is_available
ASTRA_API astra_status_t astra_streamset_is_available(astra_streamsetconnection_t streamSet, bool *isAvailable)
Test whether the StreamSet is valid.
astra_streamset_close
ASTRA_API astra_status_t astra_streamset_close(astra_streamsetconnection_t *streamSet)
Close the handle to StreamSet.
astra_terminate
ASTRA_API astra_status_t astra_terminate()
Terminate the library, destroying all its streams.
astra_reader_destroy
ASTRA_API astra_status_t astra_reader_destroy(astra_reader_t *reader)
Destroy the handle to StreamReader.
astra_reader_open_frame
ASTRA_API astra_status_t astra_reader_open_frame(astra_reader_t reader, int timeoutMillis, astra_reader_frame_t *frame)
Open.
astra_stream_get_description
ASTRA_API astra_status_t astra_stream_get_description(astra_streamconnection_t stream, astra_stream_desc_t *description)
Get description of Stream.
astra_stream_desc_t
Definition: astra_types.h:38
_astra_frame
Definition: astra_plugin.h:34
astra_reader_create
ASTRA_API astra_status_t astra_reader_create(astra_streamsetconnection_t streamSet, astra_reader_t *reader)
Create a StreamReader in StreamSet.
_astra_reader_callback_id
Definition: astra_plugin.h:29
astra_streamset_open
ASTRA_API astra_status_t astra_streamset_open(const char *uri, astra_streamsetconnection_t *streamSet)
Open a StreamSet.
astra_reader_has_new_frame
ASTRA_API astra_status_t astra_reader_has_new_frame(astra_reader_t reader, bool *hasNewFrame)
Test whether there is a new frame.
astra_stream_get_parameter
ASTRA_API astra_status_t astra_stream_get_parameter(astra_streamconnection_t connection, astra_parameter_id parameterId, uint32_t *resultByteLength, astra_result_token_t *token)
Get parameter from StreamSet.
astra_stream_is_available
ASTRA_API astra_status_t astra_stream_is_available(astra_streamconnection_t stream, bool *isAvailable)
Test whether the handle to Stream is valid.
astra_notify_plugin_event
ASTRA_API astra_status_t astra_notify_plugin_event(astra_event_id id, const void *data, uint32_t dataSize)
Notify plugins an event.
astra_reader_unregister_frame_ready_callback
ASTRA_API astra_status_t astra_reader_unregister_frame_ready_callback(astra_reader_callback_id_t *callbackId)
Unregisters the callback function.
astra_stream_start
ASTRA_API astra_status_t astra_stream_start(astra_streamconnection_t stream)
Start the Stream.
astra_update
ASTRA_API astra_status_t astra_update()
Drive the library to get a new frame of stream.
astra_stream_stop
ASTRA_API astra_status_t astra_stream_stop(astra_streamconnection_t stream)
Stop the Stream.
astra_reader_close_frame
ASTRA_API astra_status_t astra_reader_close_frame(astra_reader_frame_t *frame)
Close.
astra_reader_get_stream
ASTRA_API astra_status_t astra_reader_get_stream(astra_reader_t reader, astra_stream_type_t type, astra_stream_subtype_t subtype, astra_streamconnection_t *stream)
Get specified stream from StreamReader reader.
astra_streamset_get_uri
ASTRA_API astra_status_t astra_streamset_get_uri(astra_streamsetconnection_t streamSet, char *uri, int32_t size)
Get the URI of StreamSet.
astra_initialize
ASTRA_API astra_status_t astra_initialize()
Initializes the library.
astra_stream_set_parameter
ASTRA_API astra_status_t astra_stream_set_parameter(astra_streamconnection_t connection, astra_parameter_id parameterId, uint32_t inByteLength, astra_parameter_data_t inData)
Set parameter to StreamSet.


Astra SDK: astra_core.hpp Source File

  • include
  • astra_core
astra_core.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_CORE_HPP
18 #define ASTRA_CORE_HPP
19
20 #include "StreamSet.hpp"
21 #include "StreamDescription.hpp"
22 #include "Frame.hpp"
23 #include "FrameListener.hpp"
24 #include "StreamReader.hpp"
25 #include "DataStream.hpp"
26 #include "astra_cxx_make_unique.hpp"
27
28 namespace astra {
29
35 inline astra_status_t initialize()
36 {
37 return astra_initialize();
38 }
39
45 inline astra_status_t terminate()
46 {
47 return astra_terminate();
48 }
49 }
50
51 #endif // ASTRA_CORE_HPP
astra::terminate
astra_status_t terminate()
Terminate the library, destroying all its streams.
Definition: astra_core.hpp:45
astra
Definition: Array.hpp:20
astra_terminate
ASTRA_API astra_status_t astra_terminate()
Terminate the library, destroying all its streams.
astra::initialize
astra_status_t initialize()
Initializes the library.
Definition: astra_core.hpp:35
astra_initialize
ASTRA_API astra_status_t astra_initialize()
Initializes the library.


Astra SDK: astra_core_version.h Source File

  • include
  • astra_core
  • capi
astra_core_version.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_CORE_VERSION_HPP
18 #define ASTRA_CORE_VERSION_HPP
19
20 #include "astra_defines.h"
21 #include "astra_types.h"
22
23 ASTRA_BEGIN_DECLS
24
25 ASTRA_API astra_status_t astra_core_version(astra_version_info_t* info);
26
27 ASTRA_END_DECLS
28
29 #endif // ASTRA_CORE_VERSION_HPP
astra_version_info_t
Definition: astra_types.h:43


Astra SDK: astra_ctypes.h Source File

  • include
  • astra
  • capi
astra_ctypes.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_CTYPES_H
18 #define ASTRA_CTYPES_H
19
20 #include <stdint.h>
21
22
23 typedef struct {
24 int32_t x;
25 int32_t y;
26 } astra_vector2i_t;
27
28 typedef struct {
29 float x;
30 float y;
31 } astra_vector2f_t;
32
33 typedef struct {
34 float x;
35 float y;
36 float z;
37 } astra_vector3f_t;
38
39 typedef struct {
40 int32_t x;
41 int32_t y;
42 int32_t z;
43 } astra_vector3i_t;
44
45 typedef struct {
46 int32_t pid;
47 int32_t vid;
48 } astra_usb_info_t;
49
51 typedef struct _astra_matrix3x3 {
52 union {
53 struct {
54 astra_vector3f_t xAxis;
55 astra_vector3f_t yAxis;
56 astra_vector3f_t zAxis;
57 };
58 // TODO: is this notation correct or reversed?
59 struct {
60 float m00, m10, m20;
61 float m01, m11, m21;
62 float m02, m12, m22;
63 };
64 };
65 } astra_matrix3x3_t;
66
67 enum astra_core_stream_types {
68 ASTRA_STREAM_DEPTH = 1,
69 ASTRA_STREAM_COLOR = 2,
70 ASTRA_STREAM_INFRARED = 3,
71 ASTRA_STREAM_HAND = 4,
72 ASTRA_STREAM_BODY = 5,
73 ASTRA_STREAM_STYLIZED_DEPTH = 6,
74 ASTRA_STREAM_POINT = 7,
75 ASTRA_STREAM_MASKED_COLOR = 8,
76 ASTRA_STREAM_COLORIZED_BODY = 9,
77 ASTRA_STREAM_DEBUG_HAND = 3001,
78 };
79
80 #endif /* ASTRA_CTYPES_H */
_astra_matrix3x3
Represents a 3x3 rotation matrix.
Definition: astra_ctypes.h:51
astra_vector3i_t
Definition: astra_ctypes.h:39
astra_usb_info_t
Definition: astra_ctypes.h:45
astra_vector3f_t
Definition: astra_ctypes.h:33
astra_vector2i_t
Definition: astra_ctypes.h:23
astra_vector2f_t
Definition: astra_ctypes.h:28


Astra SDK: astra_cxx_make_unique.hpp Source File

  • include
  • astra_core
astra_cxx_make_unique.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_CXX_MAKE_UNIQUE_H
18 #define ASTRA_CXX_MAKE_UNIQUE_H
19
20 // Implementation of C++14's make_unique for C++11 compilers.
21 //
22 // This has been tested with:
23 // - MSVC 11.0 (Visual Studio 2012)
24 // - gcc 4.6.3
25 // - Xcode 4.4 (with clang "4.0")
26 //
27 // It is based off an implementation proposed by Stephan T. Lavavej for
28 // inclusion in the C++14 standard:
29 // http://isocpp.org/files/papers/N3656.txt
30 // Where appropriate, it borrows the use of MSVC's _VARIADIC_EXPAND_0X macro
31 // machinery to compensate for lack of variadic templates.
32 //
33 // This file injects make_unique into the std namespace, which I acknowledge is
34 // technically forbidden ([C++11: 17.6.4.2.2.1/1]), but is necessary in order
35 // to have syntax compatibility with C++14.
36 //
37 // I perform compiler version checking for MSVC, gcc, and clang to ensure that
38 // we don't add make_unique if it is already there (instead, we include
39 // <memory> to get the compiler-provided one). You can override the compiler
40 // version checking by defining the symbol COMPILER_SUPPORTS_MAKE_UNIQUE.
41 //
42 //
43 // ===============================================================================
44 // This file is released into the public domain. See LICENCE for more information.
45 // ===============================================================================
46
47 // If user hasn't specified COMPILER_SUPPORTS_MAKE_UNIQUE then try to figure out
48 // based on compiler version if std::make_unique is provided.
49 #if !defined(COMPILER_SUPPORTS_MAKE_UNIQUE)
50 #if defined(_MSC_VER)
51 // std::make_unique was added in MSVC 12.0
52 #if _MSC_VER >= 1800 // MSVC 12.0 (Visual Studio 2013)
53 #define COMPILER_SUPPORTS_MAKE_UNIQUE
54 #endif
55 #elif defined(__clang__)
56 // std::make_unique was added in clang 3.4, but not until Xcode 6.
57 // Annoyingly, Apple makes the clang version defines match the version
58 // of Xcode, not the version of clang.
59 #define CLANG_VERSION (__clang_major__ * 10000 + __clang_minor__ * 100 + __clang_patchlevel__)
60 #if defined(__apple_build_verion__) && CLANG_VERSION >= 60000 && __cplusplus > 201103L
61 #define COMPILER_SUPPORTS_MAKE_UNIQUE
62 #elif !defined(__apple_build_verion__) && CLANG_VERSION >= 30400 && __cplusplus > 201103L
63 #define COMPILER_SUPPORTS_MAKE_UNIQUE
64 #endif
65 #elif defined(__GNUC__)
66 // std::make_unique was added in gcc 4.9, for standards versions greater
67 // than -std=c++11.
68 #define GCC_VERSION (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__)
69 #if GCC_VERSION >= 40900 && __cplusplus > 201103L
70 #define COMPILER_SUPPORTS_MAKE_UNIQUE
71 #endif
72 #endif
73 #endif
74
75 #if defined(COMPILER_SUPPORTS_MAKE_UNIQUE)
76
77 // If the compiler supports std::make_unique, then pull in <memory> to get it.
78 #include <memory>
79 #include <utility>
80
81 namespace astra {
82
83 template<typename T, typename... Args>
84 auto make_unique(Args&&... args) -> std::unique_ptr<T>
85 {
86 return std::make_unique<T>(std::forward<Args>(args)...);
87 }
88 }
89
90 #else
91
92 // Otherwise, the compiler doesn't provide it, so implement it ourselves.
93
94 #include <cstddef>
95 #include <memory>
96 #include <type_traits>
97 #include <utility>
98
99 namespace astra {
100
101 template<class _Ty> struct _Unique_if {
102 typedef std::unique_ptr<_Ty> _Single_object;
103 };
104
105 template<class _Ty> struct _Unique_if<_Ty[]> {
106 typedef std::unique_ptr<_Ty[]> _Unknown_bound;
107 };
108
109 template<class _Ty, size_t N> struct _Unique_if<_Ty[N]> {
110 typedef void _Known_bound;
111 };
112
113 //
114 // template< class T, class... Args >
115 // unique_ptr<T> make_unique( Args&&... args);
116 //
117
118 #if defined(_MSC_VER) && (_MSC_VER < 1800)
119
120 // Macro machinery because MSVC 11.0 doesn't support variadic templates.
121 // The _VARIADIC_EXPAND_0X stuff is defined in <xstddef>
122 #define _MAKE_UNIQUE( \
123 TEMPLATE_LIST, PADDING_LIST, LIST, COMMA, X1, X2, X3, X4) \
124 template<class _Ty COMMA LIST(_CLASS_TYPE)> inline \
125 typename _Unique_if<_Ty>::_Single_object make_unique(LIST(_TYPE_REFREF_ARG)) \
126 { \
127 return unique_ptr<_Ty>(new _Ty(LIST(_FORWARD_ARG))); \
128 } \
129
130 _VARIADIC_EXPAND_0X(_MAKE_UNIQUE, , , , )
131 #undef _MAKE_UNIQUE
132
133 #else // not MSVC 11.0 or earlier
134
135 template<class _Ty, class... Args>
136 typename _Unique_if<_Ty>::_Single_object
137 make_unique(Args&&... args) {
138 return std::unique_ptr<_Ty>(new _Ty(std::forward<Args>(args)...));
139 }
140
141 #endif
142
143 // template< class T >
144 // unique_ptr<T> make_unique( std::size_t size );
145
146 template<class _Ty>
147 typename _Unique_if<_Ty>::_Unknown_bound
148 make_unique(size_t n) {
149 typedef typename std::remove_extent<_Ty>::type U;
150 return std::unique_ptr<_Ty>(new U[n]());
151 }
152
153 // template< class T, class... Args >
154 // /* unspecified */ make_unique( Args&&... args ) = delete;
155
156 // MSVC 11.0 doesn't support deleted functions, so the best we can do
157 // is simply not define the function.
158 #if !(defined(_MSC_VER) && (_MSC_VER < 1800))
159
160 template<class T, class... Args>
161 typename _Unique_if<T>::_Known_bound
162 make_unique(Args&&...) = delete;
163
164 #endif
165
166 } // namespace astra
167
168 #endif // !COMPILER_SUPPORTS_MAKE_UNIQUE
169
170 #endif /* ASTRA_CXX_MAKE_UNIQUE_H */
astra
Definition: Array.hpp:20
astra::_Unique_if
Definition: astra_cxx_make_unique.hpp:101


Astra SDK: astra_defines.h Source File

  • include
  • astra_core
  • capi
astra_defines.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_DEFINES_H
18 #define ASTRA_DEFINES_H
19
20 #ifdef __cplusplus
21 #define ASTRA_BEGIN_DECLS extern "C" {
22 #define ASTRA_END_DECLS }
23 #else
24 #define ASTRA_BEGIN_DECLS
25 #define ASTRA_END_DECLS
26 #endif
27
28 #if defined (_MSC_VER)
29 #define ASTRA_EXPORT __declspec(dllexport)
30 #define ASTRA_IMPORT __declspec(dllimport)
31 #define ASTRA_PUBLIC
32 #define ASTRA_LOCAL
33 #define ASTRA_CALLBACK __cdecl
34 #else
35 #if __GNUC__ >= 4 || defined (__clang__)
36 #define ASTRA_PUBLIC __attribute__ ((visibility ("default")))
37 #define ASTRA_LOCAL __attribute__ ((visibility ("hidden")))
38 #define ASTRA_EXPORT ASTRA_PUBLIC
39 #define ASTRA_IMPORT
40 #if defined(__x86_64__) || defined(__ANDROID__)
41 #define ASTRA_CALLBACK
42 #else
43 #define ASTRA_CALLBACK __attribute__ ((__cdecl__))
44 #endif
45 #else
46 #define ASTRA_PUBLIC
47 #define ASTRA_LOCAL
48 #define ASTRA_EXPORT
49 #define ASTRA_IMPORT
50 #define ASTRA_CALLBACK
51 #endif
52 #endif
53
54 #ifndef ASTRA_API
55 #ifdef ASTRA_BUILD
56 #define ASTRA_API ASTRA_PUBLIC ASTRA_EXPORT
57 #else
58 #define ASTRA_API ASTRA_IMPORT
59 #endif
60 #endif
61
62 #ifndef ASTRA_API_EX
63 #ifdef ASTRA_BUILD_EX
64 #define ASTRA_API_EX ASTRA_EXPORT
65 #else
66 #define ASTRA_API_EX ASTRA_IMPORT
67 #endif
68 #endif
69
70 #endif /* ASTRA_DEFINES_H */


Astra SDK: astra_host_events.h Source File

  • include
  • astra_core
  • capi
astra_host_events.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef HOST_EVENTS_H
18 #define HOST_EVENTS_H
19
20 #include "astra_defines.h"
21 #include "astra_types.h"
22 #include <stddef.h>
23 #include <stdint.h>
24
25 ASTRA_BEGIN_DECLS
26
27 ASTRA_API astra_status_t astra_notify_host_event(astra_event_id id, const void* data, uint32_t dataSize);
28 ASTRA_API astra_status_t astra_notify_resource_available(const char* resourceURI);
29 ASTRA_API astra_status_t astra_notify_resource_unavailable(const char* resourceURI);
30
31 enum {
32 ASTRA_EVENT_RESOURCE_AVAILABLE = 1,
33 ASTRA_EVENT_RESOURCE_UNAVAILABLE = 2
34 };
35
36 ASTRA_END_DECLS
37
38 #endif /* HOST_EVENTS_H */


Astra SDK: astra_plugin.h Source File

  • include
  • astra_core
  • capi
  • plugins
astra_plugin.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_PLUGIN_H
18 #define ASTRA_PLUGIN_H
19
20 #include "../astra_core.h"
21 #include "astra_plugin_callbacks.h"
22 #include "astra_pluginservice_proxy.h"
23
24 struct _astra_streamconnection {
25 astra_streamconnection_handle_t handle;
26 astra_stream_desc_t desc;
27 };
28
29 struct _astra_reader_callback_id {
30 astra_reader_t reader;
31 astra_callback_id_t callbackId;
32 };
33
34 struct _astra_frame {
35 uint32_t byteLength;
36 astra_frame_index_t frameIndex;
37 union {
38 void* data;
39 uint64_t pad0;
40 };
41 };
42
43 struct astra_plugin_info_t {
44 astra_version_info_t versionInfo;
45 };
46
47 #endif /* ASTRA_PLUGIN_H */
astra_plugin_info_t
Definition: astra_plugin.h:43
_astra_streamconnection
Definition: astra_plugin.h:24
astra_stream_desc_t
Definition: astra_types.h:38
_astra_frame
Definition: astra_plugin.h:34
_astra_reader_callback_id
Definition: astra_plugin.h:29
astra_version_info_t
Definition: astra_types.h:43


Astra SDK: astra_plugin_callbacks.h Source File

  • include
  • astra_core
  • capi
  • plugins
astra_plugin_callbacks.h
1 /* THIS FILE AUTO-GENERATED FROM astra_plugin_callbacks.h.lpp. DO NOT EDIT. */
2 #ifndef ASTRA_PLUGIN_CALLBACKS_H
3 #define ASTRA_PLUGIN_CALLBACKS_H
4
5 #include "../astra_core.h"
6
7 typedef astra_status_t(ASTRA_CALLBACK *set_parameter_callback_t)(void*,
8 astra_streamconnection_t,
9 astra_parameter_id,
10 uint32_t,
11 astra_parameter_data_t);
12
13 typedef astra_status_t(ASTRA_CALLBACK *get_parameter_callback_t)(void*,
14 astra_streamconnection_t,
15 astra_parameter_id,
16 astra_parameter_bin_t*);
17
18 typedef astra_status_t(ASTRA_CALLBACK *invoke_callback_t)(void*,
19 astra_streamconnection_t,
20 astra_command_id,
21 uint32_t,
22 astra_parameter_data_t,
23 astra_parameter_bin_t*);
24
25 typedef void(ASTRA_CALLBACK *connection_added_callback_t)(void*,
26 astra_stream_t,
27 astra_streamconnection_t);
28
29 typedef void(ASTRA_CALLBACK *connection_removed_callback_t)(void*,
30 astra_stream_t,
31 astra_bin_t,
32 astra_streamconnection_t);
33
34 typedef void(ASTRA_CALLBACK *connection_started_callback_t)(void*,
35 astra_stream_t,
36 astra_streamconnection_t);
37
38 typedef void(ASTRA_CALLBACK *connection_stopped_callback_t)(void*,
39 astra_stream_t,
40 astra_streamconnection_t);
41
42
43 typedef void(ASTRA_CALLBACK *stream_registered_callback_t)(void*,
44 astra_streamset_t,
45 astra_stream_t,
46 astra_stream_desc_t);
47
48 typedef void(ASTRA_CALLBACK *stream_unregistering_callback_t)(void*,
49 astra_streamset_t,
50 astra_stream_t,
51 astra_stream_desc_t);
52
53 typedef void(ASTRA_CALLBACK *host_event_callback_t)(void*,
54 astra_event_id,
55 const void*,
56 uint32_t);
57
58 struct stream_callbacks_t {
59 void* context;
60 set_parameter_callback_t set_parameter_callback;
61 get_parameter_callback_t get_parameter_callback;
62 invoke_callback_t invoke_callback;
63 connection_added_callback_t connection_added_callback;
64 connection_removed_callback_t connection_removed_callback;
65 connection_started_callback_t connection_started_callback;
66 connection_stopped_callback_t connection_stopped_callback;
67 };
68
69 #endif /* ASTRA_PLUGIN_CALLBACKS_H */
_astra_streamconnection
Definition: astra_plugin.h:24
astra_stream_desc_t
Definition: astra_types.h:38
stream_callbacks_t
Definition: astra_plugin_callbacks.h:58


Astra SDK: astra_pluginservice_proxy.h Source File

  • include
  • astra_core
  • capi
  • plugins
astra_pluginservice_proxy.h
1 /* THIS FILE AUTO-GENERATED FROM astra_pluginservice_proxy.h.lpp. DO NOT EDIT. */
2 #ifndef ASTRA_PLUGINSERVICE_PROXY_H
3 #define ASTRA_PLUGINSERVICE_PROXY_H
4
5 #include "../astra_types.h"
6 #include "astra_plugin.h"
7 #include <stdarg.h>
8
9 struct astra_pluginservice_proxy_t
10 {
11 void* pluginService;
12
13 astra_status_t (ASTRA_CALLBACK *register_stream_registered_callback)(void*,
14 stream_registered_callback_t,
15 void*,
16 astra_callback_id_t*);
17
18 astra_status_t (ASTRA_CALLBACK *register_stream_unregistering_callback)(void*,
19 stream_unregistering_callback_t,
20 void*,
21 astra_callback_id_t*);
22
23 astra_status_t (ASTRA_CALLBACK *register_host_event_callback)(void*,
24 host_event_callback_t,
25 void*,
26 astra_callback_id_t*);
27
28 astra_status_t (ASTRA_CALLBACK *unregister_host_event_callback)(void*,
29 astra_callback_id_t);
30
31 astra_status_t (ASTRA_CALLBACK *unregister_stream_registered_callback)(void*,
32 astra_callback_id_t);
33
34 astra_status_t (ASTRA_CALLBACK *unregister_stream_unregistering_callback)(void*,
35 astra_callback_id_t);
36
37 astra_status_t (ASTRA_CALLBACK *create_stream_set)(void*,
38 const char*,
39 astra_streamset_t&);
40
41 astra_status_t (ASTRA_CALLBACK *destroy_stream_set)(void*,
42 astra_streamset_t&);
43
44 astra_status_t (ASTRA_CALLBACK *get_streamset_uri)(void*,
45 astra_streamset_t,
46 const char**);
47
48 astra_status_t (ASTRA_CALLBACK *create_stream)(void*,
49 astra_streamset_t,
50 astra_stream_desc_t,
51 astra_stream_t*);
52
53 astra_status_t (ASTRA_CALLBACK *register_stream)(void*,
54 astra_stream_t,
55 stream_callbacks_t);
56
57 astra_status_t (ASTRA_CALLBACK *unregister_stream)(void*,
58 astra_stream_t);
59
60 astra_status_t (ASTRA_CALLBACK *destroy_stream)(void*,
61 astra_stream_t&);
62
63 astra_status_t (ASTRA_CALLBACK *create_stream_bin)(void*,
64 astra_stream_t,
65 uint32_t,
66 astra_bin_t*,
67 astra_frame_t**);
68
69 astra_status_t (ASTRA_CALLBACK *destroy_stream_bin)(void*,
70 astra_stream_t,
71 astra_bin_t*,
72 astra_frame_t**);
73
74 astra_status_t (ASTRA_CALLBACK *bin_has_connections)(void*,
75 astra_bin_t,
76 bool*);
77
78 astra_status_t (ASTRA_CALLBACK *cycle_bin_buffers)(void*,
79 astra_bin_t,
80 astra_frame_t**);
81
82 astra_status_t (ASTRA_CALLBACK *link_connection_to_bin)(void*,
83 astra_streamconnection_t,
84 astra_bin_t);
85
86 astra_status_t (ASTRA_CALLBACK *get_parameter_bin)(void*,
87 uint32_t,
88 astra_parameter_bin_t*,
89 astra_parameter_data_t*);
90
91 astra_status_t (ASTRA_CALLBACK *log)(void*,
92 const char*,
93 astra_log_severity_t,
94 const char*,
95 int,
96 const char*,
97 const char*,
98 va_list);
99
100 };
101
102 #endif /* ASTRA_PLUGINSERVICE_PROXY_H */
_astra_streamconnection
Definition: astra_plugin.h:24
astra_stream_desc_t
Definition: astra_types.h:38
_astra_frame
Definition: astra_plugin.h:34
stream_callbacks_t
Definition: astra_plugin_callbacks.h:58
astra_pluginservice_proxy_t
Definition: astra_pluginservice_proxy.h:9


Astra SDK: astra_streamservice_proxy.h Source File

  • include
  • astra_core
  • capi
astra_streamservice_proxy.h
1 /* THIS FILE AUTO-GENERATED FROM astra_streamservice_proxy.h.lpp. DO NOT EDIT. */
2 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
3 // Copyright (c) 2015-2017 Orbbec 3D
4 //
5 // Licensed under the Apache License, Version 2.0 (the "License");
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 // http://www.apache.org/licenses/LICENSE-2.0
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 //
17 // Be excellent to each other.
18 #ifndef ASTRA_STREAMSERVICE_PROXY_H
19 #define ASTRA_STREAMSERVICE_PROXY_H
20
21 #include "astra_types.h"
22
23 struct astra_streamservice_proxy_t
24 {
25 void* streamService;
26
27 astra_status_t (ASTRA_CALLBACK *notify_plugin_event)(void*,
28 astra_event_id,
29 const void*,
30 uint32_t);
31
32 astra_status_t (ASTRA_CALLBACK *streamset_is_available)(void*,
33 astra_streamsetconnection_t,
34 bool*);
35
36 astra_status_t (ASTRA_CALLBACK *streamset_open)(void*,
37 const char*,
38 astra_streamsetconnection_t*);
39
40 astra_status_t (ASTRA_CALLBACK *streamset_close)(void*,
41 astra_streamsetconnection_t*);
42
43 astra_status_t (ASTRA_CALLBACK *streamset_get_uri)(void*,
44 astra_streamsetconnection_t,
45 char*,
46 int32_t);
47
48 astra_status_t (ASTRA_CALLBACK *reader_create)(void*,
49 astra_streamsetconnection_t,
50 astra_reader_t*);
51
52 astra_status_t (ASTRA_CALLBACK *reader_destroy)(void*,
53 astra_reader_t*);
54
55 astra_status_t (ASTRA_CALLBACK *reader_get_stream)(void*,
56 astra_reader_t,
57 astra_stream_type_t,
58 astra_stream_subtype_t,
59 astra_streamconnection_t*);
60
61 astra_status_t (ASTRA_CALLBACK *stream_get_description)(void*,
62 astra_streamconnection_t,
63 astra_stream_desc_t*);
64
65 astra_status_t (ASTRA_CALLBACK *stream_is_available)(void*,
66 astra_streamconnection_t,
67 bool*);
68
69 astra_status_t (ASTRA_CALLBACK *stream_start)(void*,
70 astra_streamconnection_t);
71
72 astra_status_t (ASTRA_CALLBACK *stream_stop)(void*,
73 astra_streamconnection_t);
74
75 astra_status_t (ASTRA_CALLBACK *reader_has_new_frame)(void*,
76 astra_reader_t,
77 bool*);
78
79 astra_status_t (ASTRA_CALLBACK *reader_open_frame)(void*,
80 astra_reader_t,
81 int,
82 astra_reader_frame_t*);
83
84 astra_status_t (ASTRA_CALLBACK *reader_close_frame)(void*,
85 astra_reader_frame_t*);
86
87 astra_status_t (ASTRA_CALLBACK *reader_register_frame_ready_callback)(void*,
88 astra_reader_t,
89 astra_frame_ready_callback_t,
90 void*,
91 astra_reader_callback_id_t*);
92
93 astra_status_t (ASTRA_CALLBACK *reader_unregister_frame_ready_callback)(void*,
94 astra_reader_callback_id_t*);
95
96 astra_status_t (ASTRA_CALLBACK *reader_get_frame)(void*,
97 astra_reader_frame_t,
98 astra_stream_type_t,
99 astra_stream_subtype_t,
100 astra_frame_t**);
101
102 astra_status_t (ASTRA_CALLBACK *stream_set_parameter)(void*,
103 astra_streamconnection_t,
104 astra_parameter_id,
105 uint32_t,
106 astra_parameter_data_t);
107
108 astra_status_t (ASTRA_CALLBACK *stream_get_parameter)(void*,
109 astra_streamconnection_t,
110 astra_parameter_id,
111 uint32_t*,
112 astra_result_token_t*);
113
114 astra_status_t (ASTRA_CALLBACK *stream_get_result)(void*,
115 astra_streamconnection_t,
116 astra_result_token_t,
117 uint32_t,
118 astra_parameter_data_t);
119
120 astra_status_t (ASTRA_CALLBACK *stream_invoke)(void*,
121 astra_streamconnection_t,
122 astra_command_id,
123 uint32_t,
124 astra_parameter_data_t,
125 uint32_t*,
126 astra_result_token_t*);
127
128 astra_status_t (ASTRA_CALLBACK *update)(void*);
129
130 };
131
132 #endif /* ASTRA_STREAMSERVICE_PROXY_H */
_astra_streamconnection
Definition: astra_plugin.h:24
astra_stream_desc_t
Definition: astra_types.h:38
_astra_frame
Definition: astra_plugin.h:34
_astra_reader_callback_id
Definition: astra_plugin.h:29
astra_streamservice_proxy_t
Definition: astra_streamservice_proxy.h:23


Astra SDK: astra_types.h Source File

  • include
  • astra_core
  • capi
astra_types.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_TYPES_H
18 #define ASTRA_TYPES_H
19
20 #include <stdint.h>
21 #include <stddef.h>
22
23 const uint32_t ASTRA_STREAMSET_URI_MAX_LENGTH = 256;
24
25 const uint8_t ASTRA_MAX_READER_STREAMS = 16;
26
27 const int ASTRA_TIMEOUT_FOREVER = -1;
28 const int ASTRA_TIMEOUT_RETURN_IMMEDIATELY = 0;
29
30 typedef struct _astra_stream* astra_stream_t;
31
32 typedef int32_t astra_stream_type_t;
33 typedef int32_t astra_stream_subtype_t;
34 typedef int32_t astra_frame_index_t;
35
36 const astra_stream_subtype_t DEFAULT_SUBTYPE = 0;
37
38 typedef struct {
39 astra_stream_type_t type;
40 astra_stream_subtype_t subtype;
41 } astra_stream_desc_t;
42
43 typedef struct {
44 int32_t majorVersion;
45 int32_t minorVersion;
46 int32_t patchVersion;
47 char* versionSuffix;
48 char* gitCommitSha1;
49 char* friendlyVersionString;
50 int32_t apiLevel;
51 } astra_version_info_t;
52
53 typedef struct _astra_streamset* astra_streamset_t;
54 typedef struct _astra_streamconnection_handle* astra_streamconnection_handle_t;
55
56 typedef struct _astra_streamsetconnection* astra_streamsetconnection_t;
57 typedef struct _astra_streamconnection* astra_streamconnection_t;
58
59 typedef struct _astra_frame astra_frame_t;
60
61 typedef struct _astra_reader* astra_reader_t;
62 typedef struct _astra_reader_frame* astra_reader_frame_t;
63
64 typedef void* astra_parameter_data_t;
65 typedef int32_t astra_parameter_id;
66 typedef int32_t astra_command_id;
67
68 typedef struct _astra_parameter_bin* astra_result_token_t;
69 typedef struct _astra_parameter_bin* astra_parameter_bin_t;
70
71 typedef struct _astra_bin* astra_bin_t;
72
73 typedef enum {
74 ASTRA_STATUS_SUCCESS = 0,
75 ASTRA_STATUS_INVALID_PARAMETER = 1,
76 ASTRA_STATUS_DEVICE_ERROR = 2,
77 ASTRA_STATUS_TIMEOUT = 3,
78 ASTRA_STATUS_INVALID_PARAMETER_TOKEN = 4,
79 ASTRA_STATUS_INVALID_OPERATION = 5,
80 ASTRA_STATUS_INTERNAL_ERROR = 6,
81 ASTRA_STATUS_UNINITIALIZED = 7
82 } astra_status_t;
83
84 typedef uint64_t astra_callback_id_t;
85
86 typedef struct _astra_reader_callback_id* astra_reader_callback_id_t;
87
88 typedef void(*astra_frame_ready_callback_t)(void* clientTag,
89 astra_reader_t reader,
90 astra_reader_frame_t frame);
91
92 typedef enum {
93 ASTRA_SEVERITY_UNKNOWN = 0,
94 ASTRA_SEVERITY_FATAL = 1,
95 ASTRA_SEVERITY_ERROR = 2,
96 ASTRA_SEVERITY_WARN = 3,
97 ASTRA_SEVERITY_INFO = 4,
98 ASTRA_SEVERITY_DEBUG = 5,
99 ASTRA_SEVERITY_TRACE = 6
100 } astra_log_severity_t;
101
102 typedef enum {
103 ASTRA_CHIP_ID_UNKNOWN = 0,
104 ASTRA_CHIP_ID_MX400 = 1,
105 ASTRA_CHIP_ID_MX6000 = 2
106 } astra_chip_id_t;
107
108 typedef uint32_t astra_event_id;
109
110 #ifndef ASTRA_TRUE
111 #define ASTRA_TRUE 1
112 #endif
113
114 #ifndef ASTRA_FALSE
115 #define ASTRA_FALSE 0
116 #endif
117
118 #ifndef ASTRA_NULL
119 #ifdef NULL
120 #define ASTRA_NULL NULL
121 #else
122 #define ASTRA_NULL 0
123 #endif
124 #endif
125
126 typedef int8_t astra_bool_t;
127
128 #endif /* ASTRA_TYPES_H */
_astra_streamconnection
Definition: astra_plugin.h:24
astra_stream_desc_t
Definition: astra_types.h:38
_astra_frame
Definition: astra_plugin.h:34
_astra_reader_callback_id
Definition: astra_plugin.h:29
astra_version_info_t
Definition: astra_types.h:43


Astra SDK: astra_version.h Source File

  • include
  • astra
  • capi
astra_version.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_VERSION_H
18 #define ASTRA_VERSION_H
19
20 #include <astra_core/capi/astra_defines.h>
21 #include <astra_core/capi/astra_types.h>
22
23 ASTRA_BEGIN_DECLS
24
30 ASTRA_API_EX astra_status_t astra_version(astra_version_info_t* info);
31
32 ASTRA_END_DECLS
33
34 #endif /* ASTRA_VERSION_H */
astra_version_info_t
Definition: astra_types.h:43
astra_version
ASTRA_API_EX astra_status_t astra_version(astra_version_info_t *info)


Astra SDK: Body.hpp Source File

  • include
  • astra
  • streams
Body.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_BODY_HPP
18 #define ASTRA_BODY_HPP
19
20 #include <stdexcept>
21 #include <cstdint>
22 #include <astra_core/astra_core.hpp>
23 #include <astra/capi/astra_cpp_ref.h>
24 #include <astra/capi/streams/body_capi.h>
25 #include <astra/capi/streams/stream_types.h>
26 #include <astra/Array.hpp>
27 #include <astra/Vector.hpp>
28 #include <astra/Matrix3x3.hpp>
29
30 namespace astra {
31
32 using std::uint8_t;
33 using std::uint16_t;
34 using std::int16_t;
35 using std::int32_t;
36 using std::uint64_t;
37
45 class BitmapMask : private ::astra_bitmapmask_t
46 {
47 public:
51 BitmapMask()
52 {
53 // ::astra_bitmapmask_t::data = nullptr;
54 ::astra_bitmapmask_t::width = 0;
55 ::astra_bitmapmask_t::height = 0;
56 }
57
61 int32_t width() const { return ::astra_bitmapmask_t::width; }
65 int32_t height() const { return ::astra_bitmapmask_t::height; }
69 int32_t bpp() const { return sizeof(uint8_t); }
73 int32_t length() const
74 {
75 return ::astra_bitmapmask_t::width *
76 ::astra_bitmapmask_t::height;
77 }
78
82 int32_t byte_length() const
83 {
84 return ::astra_bitmapmask_t::width *
85 ::astra_bitmapmask_t::height *
86 bpp();
87 }
88
92 const uint8_t* data() const { return ::astra_bitmapmask_t::data; }
93
94 friend class FloorInfo;
95 friend class BodyFrame;
96 };
97
103 using BodyMask = BitmapMask;
109 using FloorMask = BitmapMask;
110
117 enum class BodyTrackingFeatureFlags : ::astra_body_tracking_feature_flags_t
118 {
120 Segmentation = 0,
122 Joints = 1,
124 HandPoses = 3
125 };
126
131 enum class SkeletonProfile : ::astra_skeleton_profile_t {
133 Full = 0,
135 UpperBody = 1,
137 Basic = 2
138 };
139
145 enum class SkeletonOptimization : ::astra_skeleton_optimization_t {
146 Optimization1 = 1,
148 MinimizeMemory = 2,
149 Optimization2 = 2,
150 Optimization3 = 3,
151 Optimization4 = 4,
153 Balanced = 5,
154 Optimization5 = 5,
155 Optimization6 = 6,
156 Optimization7 = 7,
157 Optimization8 = 8,
158 Optimization9 = 9,
160 BestAccuracy = 9,
161 };
162
167 enum class JointStatus : ::astra_joint_status_t
168 {
170 NotTracked = 0,
175 LowConfidence = 1,
177 Tracked = 2
178 };
179
184 enum class JointType : ::astra_joint_type_t
185 {
186 Head = 0,
187 ShoulderSpine = 1,
188 LeftShoulder = 2,
189 LeftElbow = 3,
190 LeftHand = 4,
191 RightShoulder = 5,
192 RightElbow = 6,
193 RightHand = 7,
194 MidSpine = 8,
195 BaseSpine = 9,
196 LeftHip = 10,
197 LeftKnee = 11,
198 LeftFoot = 12,
199 RightHip = 13,
200 RightKnee = 14,
201 RightFoot = 15,
202 LeftWrist = 16,
203 RightWrist = 17,
204 Neck = 18,
205 Unknown = 255,
206 };
207
218 class Joint : private ::astra_joint_t
219 {
220 public:
222 JointType type() const
223 {
224 return static_cast< JointType >(::astra_joint_t::type);
225 }
226
228 JointStatus status() const
229 {
230 return static_cast< JointStatus >(::astra_joint_t::status);
231 }
232
240 const Vector2f& depth_position() const
241 {
242 return *static_cast<const Vector2f*>(&(::astra_joint_t::depthPosition));
243 }
244
246 const Vector3f& world_position() const
247 {
248 return *static_cast<const Vector3f*>(&(::astra_joint_t::worldPosition));
249 }
250
252 const Matrix3x3& orientation() const
253 {
254 return *static_cast<const Matrix3x3*>(&(::astra_joint_t::orientation));
255 }
256
257 friend class Body;
258 };
259
265 enum class HandPose : ::astra_handpose_t
266 {
268 Unknown = 0,
270 Grip = 1,
271 };
272
273 class HandPoseInfo : private ::astra_handpose_info_t
274 {
275 private:
276 using ::astra_handpose_info_t::leftHand;
277 using ::astra_handpose_info_t::rightHand;
278 public:
279 HandPose left_hand() const { return static_cast< HandPose >(this->leftHand); }
280 HandPose right_hand() const { return static_cast< HandPose >(this->rightHand); }
281
282 friend class Body;
283 };
284
289 enum class BodyStatus : ::astra_body_status_t
290 {
292 NotTracking = 0,
294 TrackingLost = 1,
296 TrackingStarted = 2,
298 Tracking = 3,
299 };
300
305 using JointList = Array<const Joint>;
306
310 using BodyId = astra_body_id_t;
311
323 class Body : private ::astra_body_t
324 {
325 public:
333 BodyId id() const { return ::astra_body_t::id; }
334
338 BodyStatus status() const
339 {
340 return static_cast< BodyStatus >(::astra_body_t::status);
341 }
342
346 const Vector3f& center_of_mass() const
347 {
348 return *static_cast<const Vector3f*>(&(::astra_body_t::centerOfMass));
349 }
350
351 bool joints_enabled() const
352 {
353 return (::astra_body_t::features & ASTRA_BODY_TRACKING_JOINTS) == ASTRA_BODY_TRACKING_JOINTS;
354 }
355
356 bool hand_poses_enabled() const
357 {
358 return (::astra_body_t::features & ASTRA_BODY_TRACKING_HAND_POSES) == ASTRA_BODY_TRACKING_HAND_POSES;
359 }
360
364 JointList joints() const
365 {
366 return make_array(
367 static_cast<const Joint*>(&(::astra_body_t::joints[0])), ASTRA_MAX_JOINTS);
368 }
369
370 const HandPoseInfo& hand_poses() const
371 {
372 return *static_cast<const HandPoseInfo*>(&(::astra_body_t::handPoses));
373 }
374
375 friend class BodyFrame;
376 };
377
394 class Plane : private ::astra_plane_t
395 {
396 public:
401 Plane()
402 {
403 ::astra_plane_t::a = 0.f;
404 ::astra_plane_t::b = 0.f;
405 ::astra_plane_t::c = 0.f;
406 ::astra_plane_t::d = 0.f;
407 }
408
412 float a() const { return ::astra_plane_t::a; }
416 float b() const { return ::astra_plane_t::b; }
420 float c() const { return ::astra_plane_t::c; }
424 float d() const { return ::astra_plane_t::d; }
425
429 const Vector3f& normal() const
430 {
431 // a, b, c are the normal x, y, z. Use address of 'a'
432 // for transmutation of a Vector3f from thin air.
433 return *reinterpret_cast<const Vector3f*>(&(::astra_plane_t::a));
434 }
435
439 bool is_degenerate() const
440 {
441 return ::astra_plane_t::a == 0.f &&
442 ::astra_plane_t::b == 0.f &&
443 ::astra_plane_t::c == 0.f;
444 }
445
446 friend class FloorInfo;
447 };
448
449
450 class FloorInfo : private ::astra_floor_info_t
451 {
452 private:
453 using ::astra_floor_info_t::floorMask;
454 using ::astra_floor_info_t::floorPlane;
455 using ::astra_floor_info_t::floorDetected;
456 public:
457 const FloorMask& floor_mask() const
458 {
459 return *static_cast<const FloorMask*>(&this->floorMask);
460 }
461 const Plane& floor_plane() const
462 {
463 return *static_cast<const Plane*>(&this->floorPlane);
464 }
465 bool floor_detected() const { return this->floorDetected != ASTRA_FALSE; }
466
467 friend class BodyFrame;
468 };
469
470 class BodyFrameInfo : private ::astra_bodyframe_info_t
471 {
472 public:
473 std::int32_t width() const { return ::astra_bodyframe_info_t::width; }
474 std::int32_t height() const { return ::astra_bodyframe_info_t::height; }
475 bool is_estimated() const { return ::astra_bodyframe_info_t::isEstimated != 0; }
476 friend class BodyFrame;
477 };
478
484 using BodyList = Array<const Body>;
485
490 class BodyFrame
491 {
492 private:
493 ::astra_bodyframe_t handle_;
494 astra_frame_index_t frameIndex_;
495
496 public:
500 BodyFrame(const BodyFrame&) = delete;
504 BodyFrame& operator=(const BodyFrame&) = delete;
505
509 BodyFrame(BodyFrame&& other)
510 : handle_(other.handle_),
511 frameIndex_(other.frameIndex_)
512 {}
513
517 BodyFrame& operator=(BodyFrame&& other)
518 {
519 handle_ = other.handle_;
520 frameIndex_ = other.frameIndex_;
521
522 return *this;
523 }
524
525 template<typename TFrameType>
526 static TFrameType acquire(astra_reader_frame_t readerFrame,
527 astra_stream_subtype_t subtype)
528 {
529 if (readerFrame != nullptr)
530 {
531 astra_bodyframe_t bodyFrame;
532 astra_frame_get_bodyframe(readerFrame, &bodyFrame);
533 return TFrameType(bodyFrame);
534 }
535
536 return TFrameType(nullptr);
537 }
538
544 bool is_valid() const { return handle_ != nullptr; }
545
551 astra_frame_index_t frame_index() const
552 {
553 throw_if_invalid_frame();
554 return frameIndex_;
555 }
556
562 const BodyFrameInfo& info() const
563 {
564 throw_if_invalid_frame();
565 return *static_cast<const BodyFrameInfo*>(&handle_->info);
566 }
567
571 const BodyMask& body_mask() const
572 {
573 throw_if_invalid_frame();
574 return *static_cast<const BodyMask*>(&handle_->bodyMask);
575 }
576
577 const FloorInfo& floor_info() const
578 {
579 throw_if_invalid_frame();
580 return *static_cast<const FloorInfo*>(&handle_->floorInfo);
581 }
582
589 BodyList bodies() const
590 {
591 throw_if_invalid_frame();
592 const auto& bodyList = handle_->bodyList;
593 return make_array(
594 static_cast<const Body*>(&bodyList.bodies[0]), bodyList.count);
595 }
596
597 private:
598 BodyFrame(astra_bodyframe_t handle)
599 : handle_(handle)
600 {
601 if (handle_)
602 {
603 astra_bodyframe_get_frameindex(handle, &frameIndex_);
604 }
605 }
606
607 void throw_if_invalid_frame() const
608 {
609 if (!is_valid())
610 {
611 throw std::logic_error("Cannot operate on an invalid frame");
612 }
613 }
614 };
615
616
623 class BodyStream : public DataStream
624 {
625 public:
631 explicit BodyStream(astra_streamconnection_t connection)
632 : DataStream(connection),
633 bodyStream_(reinterpret_cast<astra_bodystream_t>(connection))
634 { }
635
641 BodyTrackingFeatureFlags get_body_features(astra_body_id_t id)
642 {
643 astra_body_tracking_feature_flags_t features = ASTRA_BODY_TRACKING_SEGMENTATION;
644 astra_bodystream_get_body_features(bodyStream_, id, &features);
645 return static_cast< BodyTrackingFeatureFlags >(features);
646 }
647
653 void set_body_features(astra_body_id_t id, BodyTrackingFeatureFlags features)
654 {
655 astra_bodystream_set_body_features(bodyStream_,
656 id,
657 static_cast<astra_body_tracking_feature_flags_t>(features));
658 }
659
665 BodyTrackingFeatureFlags get_default_body_features()
666 {
667 astra_body_tracking_feature_flags_t features = ASTRA_BODY_TRACKING_SEGMENTATION;
668 astra_bodystream_get_default_body_features(bodyStream_, &features);
669 return static_cast< BodyTrackingFeatureFlags >(features);
670 }
671
677 void set_default_body_features(BodyTrackingFeatureFlags features)
678 {
679 astra_bodystream_set_default_body_features(bodyStream_,
680 static_cast<astra_body_tracking_feature_flags_t>(features));
681 }
682
688 SkeletonProfile get_skeleton_profile()
689 {
690 astra_skeleton_profile_t skeletonProfileState = ASTRA_SKELETON_PROFILE_FULL;
691 astra_bodystream_get_skeleton_profile(bodyStream_, &skeletonProfileState);
692 return static_cast< SkeletonProfile >(skeletonProfileState);
693 }
694
700 void set_skeleton_profile(SkeletonProfile skeletonProfile)
701 {
702 astra_bodystream_set_skeleton_profile(bodyStream_,
703 static_cast<astra_skeleton_profile_t>(skeletonProfile));
704 }
705
711 SkeletonOptimization get_skeleton_optimization()
712 {
713 astra_skeleton_optimization_t skeletonOptimization = ASTRA_SKELETON_OPTIMIZATION_BEST_ACCURACY;
714 astra_bodystream_get_skeleton_optimization(bodyStream_, &skeletonOptimization);
715 return static_cast< SkeletonOptimization >(skeletonOptimization);
716 }
717
723 void set_skeleton_optimization(SkeletonOptimization skeletonOptimization)
724 {
725 astra_bodystream_set_skeleton_optimization(bodyStream_,
726 static_cast<astra_skeleton_optimization_t>(skeletonOptimization));
727 }
728
729 static const astra_stream_type_t id = ASTRA_STREAM_BODY;
730
731 private:
732 astra_bodystream_t bodyStream_{nullptr};
733 };
734 }
735
736 #endif /* ASTRA_BODY_HPP */
astra::JointStatus::Tracked
astra::JointType::BaseSpine
astra::JointStatus::LowConfidence
astra::JointType::RightHand
astra::Body::joints
JointList joints() const
Gets the current list of joints (Joint) being currently tracked.
Definition: Body.hpp:364
astra::BodyStream::set_default_body_features
void set_default_body_features(BodyTrackingFeatureFlags features)
set default body features
Definition: Body.hpp:677
astra::BodyStream::get_body_features
BodyTrackingFeatureFlags get_body_features(astra_body_id_t id)
get body features
Definition: Body.hpp:641
astra::BodyStream
A Body Data Stream.
Definition: Body.hpp:623
astra::Plane::Plane
Plane()
Default constructs a plane that passes though origin, has a zero-length normal, and is considered deg...
Definition: Body.hpp:401
_astra_body::features
astra_body_tracking_feature_flags_t features
Bitmask of features that are enabled.
Definition: body_types.h:284
astra::FloorInfo
Definition: Body.hpp:450
_astra_joint::depthPosition
astra_vector2f_t depthPosition
Depth ("projective") position of joint.
Definition: body_types.h:135
astra::Array
Simple wrapper around primitive arrays.
Definition: Array.hpp:30
astra::JointType::RightFoot
astra::BodyTrackingFeatureFlags::Joints
astra::SkeletonProfile::Full
_astra_body::handPoses
astra_handpose_info_t handPoses
Hand poses.
Definition: body_types.h:294
astra::BodyStream::BodyStream
BodyStream(astra_streamconnection_t connection)
default constructs
Definition: Body.hpp:631
astra::BodyStatus::Tracking
astra::BitmapMask::data
const uint8_t * data() const
Gets an immutable raw pointer to mask data.
Definition: Body.hpp:92
_astra_bitmapmask::height
int32_t height
height in pixels
Definition: body_types.h:337
astra::BodyTrackingFeatureFlags::Segmentation
astra::JointType::LeftShoulder
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_body::centerOfMass
astra_vector3f_t centerOfMass
Single point describing the center of mass of a body.
Definition: body_types.h:290
astra::Body::id
BodyId id() const
Gets BodyId associated with the Body.
Definition: Body.hpp:333
astra::SkeletonProfile
SkeletonProfile
Skeleton profile representing the set of joints to be tracked.
Definition: Body.hpp:131
_astra_bodyframe
Definition: stream_types.h:62
_astra_joint::worldPosition
astra_vector3f_t worldPosition
Real world position of joint.
Definition: body_types.h:137
astra::JointType::Unknown
astra
Definition: Array.hpp:20
astra::Body
Human body.
Definition: Body.hpp:323
astra::BodyFrame::frame_index
astra_frame_index_t frame_index() const
get body frame index
Definition: Body.hpp:551
_astra_plane::d
float d
D coefficient.
Definition: body_types.h:380
_astra_joint::status
astra_joint_status_t status
Joint status.
Definition: body_types.h:133
astra::Vector2f
Represents a float 2d vector.
Definition: Vector2f.hpp:29
astra::BitmapMask::byte_length
int32_t byte_length() const
Gets the length of the mask in bytes.
Definition: Body.hpp:82
astra::Matrix3x3
Represents a 3x3 rotation matrix.
Definition: Matrix3x3.hpp:30
_astra_joint
Joint information.
Definition: body_types.h:123
astra::Joint
Body joint
Definition: Body.hpp:218
astra::JointType::Head
astra::BitmapMask
Bitmap representing a 2d mask.
Definition: Body.hpp:45
_astra_joint::type
astra_joint_type_t type
Joint type.
Definition: body_types.h:128
astra::BitmapMask::width
int32_t width() const
Gets the width of the mask.
Definition: Body.hpp:61
astra::BodyFrame::bodies
BodyList bodies() const
Gets the current tracked bodies associated with the current BodyFrame.
Definition: Body.hpp:589
astra::Joint::status
JointStatus status() const
Gets the current status of the Joint.
Definition: Body.hpp:228
astra::Plane::is_degenerate
bool is_degenerate() const
Returns whether than plane is considered degenerate (invalid)
Definition: Body.hpp:439
_astra_plane::a
float a
A coefficient.
Definition: body_types.h:374
astra::Body::status
BodyStatus status() const
Gets the tracking status of the body.
Definition: Body.hpp:338
astra::JointType::RightShoulder
_astra_floor_info
Struct containing floor information about the scene.
Definition: body_types.h:400
astra::JointType::ShoulderSpine
astra::BodyStream::set_skeleton_optimization
void set_skeleton_optimization(SkeletonOptimization skeletonOptimization)
set skeleton optimization
Definition: Body.hpp:723
astra::BodyStream::set_body_features
void set_body_features(astra_body_id_t id, BodyTrackingFeatureFlags features)
set body features
Definition: Body.hpp:653
astra::SkeletonOptimization
SkeletonOptimization
Represents the body tracking configuration that trades-off tracking accuracy, memory, and CPU usage.
Definition: Body.hpp:145
astra::JointType::RightElbow
astra::BitmapMask::length
int32_t length() const
Gets the length of the mask in pixels.
Definition: Body.hpp:73
astra::Plane
3D geometric plane
Definition: Body.hpp:394
_astra_plane
Struct representing a geometric 3-dimensional plane.
Definition: body_types.h:372
astra::BodyStatus::TrackingStarted
astra::BodyId
astra_body_id_t BodyId
Identifier type for bodies.
Definition: Body.hpp:310
astra::BodyFrame
Body tracking information produced by a BodyTracker instance
Definition: Body.hpp:490
astra::BodyFrame::operator=
BodyFrame & operator=(BodyFrame &&other)
BodyFrame is move assignable.
Definition: Body.hpp:517
astra::JointType::LeftWrist
astra::BodyStream::get_skeleton_profile
SkeletonProfile get_skeleton_profile()
get skeleton profile
Definition: Body.hpp:688
_astra_body::status
astra_body_status_t status
Tracking status.
Definition: body_types.h:307
astra::BodyFrame::BodyFrame
BodyFrame(BodyFrame &&other)
BodyFrame is move constructible.
Definition: Body.hpp:509
_astra_handpose_info
Definition: body_types.h:187
_astra_bitmapmask
Struct representing a 2-dimensional bitmask.
Definition: body_types.h:330
astra::JointType::LeftFoot
astra::SkeletonOptimization::BestAccuracy
astra::JointType::Neck
astra::Joint::type
JointType type() const
Gets the type of joint.
Definition: Body.hpp:222
_astra_plane::c
float c
C coefficient.
Definition: body_types.h:378
astra::SkeletonProfile::UpperBody
astra::BodyStatus::NotTracking
astra::JointType::MidSpine
astra::BodyStatus::TrackingLost
astra::JointStatus
JointStatus
Joint status enumeration.
Definition: Body.hpp:167
astra::BodyStream::get_skeleton_optimization
SkeletonOptimization get_skeleton_optimization()
get skeleton optimization
Definition: Body.hpp:711
astra::BodyFrame::body_mask
const BodyMask & body_mask() const
Gets the BodyMask of the current tracked bodies.
Definition: Body.hpp:571
astra::BodyFrame::info
const BodyFrameInfo & info() const
get body frame info
Definition: Body.hpp:562
astra::HandPose::Grip
astra::JointType::RightHip
astra::Plane::c
float c() const
Gets the C coefficient.
Definition: Body.hpp:420
astra::JointType
JointType
Joint type enumeration.
Definition: Body.hpp:184
_astra_body::joints
astra_joint_t joints[ASTRA_MAX_JOINTS]
Array of tracked joints.
Definition: body_types.h:292
_astra_body
Struct containing body tracking information.
Definition: body_types.h:279
astra::Vector3f
Represents a float 3d vector.
Definition: Vector3f.hpp:29
astra::BitmapMask::BitmapMask
BitmapMask()
Default constructs an empty zero-sized BitmapMask.
Definition: Body.hpp:51
_astra_joint::orientation
astra_matrix3x3_t orientation
3x3 Rotation matrix representing the rotation of this joint.
Definition: body_types.h:140
astra::BodyTrackingFeatureFlags::HandPoses
astra::SkeletonOptimization::Balanced
astra::make_array
Array< T > make_array(T *ptr, std::size_t size)
Simplifies Array construction by leveraging function template type deduction.
Definition: Array.hpp:162
astra::BodyFrameInfo
Definition: Body.hpp:470
astra::Plane::normal
const Vector3f & normal() const
Gets the plane normal.
Definition: Body.hpp:429
astra::JointType::LeftElbow
astra::BodyTrackingFeatureFlags
BodyTrackingFeatureFlags
Bitmask of body features Represents the possible features that body tracking can produce on a body...
Definition: Body.hpp:117
astra::BitmapMask::bpp
int32_t bpp() const
Gets the bytes per pixel.
Definition: Body.hpp:69
astra::BodyStream::set_skeleton_profile
void set_skeleton_profile(SkeletonProfile skeletonProfile)
set skeleton profile
Definition: Body.hpp:700
astra::DataStream
Data Stream.
Definition: DataStream.hpp:32
astra::Joint::depth_position
const Vector2f & depth_position() const
Gets the depth ("projective") position of the Joint.
Definition: Body.hpp:240
astra::JointType::LeftKnee
_astra_bitmapmask::width
int32_t width
width in pixels
Definition: body_types.h:335
astra::HandPoseInfo
Definition: Body.hpp:273
astra::JointType::RightWrist
_astra_bodyframe_info
Struct containing general body frame information.
Definition: body_types.h:387
astra::SkeletonProfile::Basic
astra::Joint::orientation
const Matrix3x3 & orientation() const
Gets the 3x3 Rotation matrix representing the rotation of this joint.
Definition: Body.hpp:252
astra::BodyStatus
BodyStatus
Enumeration of possible tracking status of a orbbec::bodytracking::Body.
Definition: Body.hpp:289
astra::JointType::LeftHip
_astra_plane::b
float b
B coefficient.
Definition: body_types.h:376
astra::SkeletonOptimization::MinimizeMemory
astra::Joint::world_position
const Vector3f & world_position() const
Gets the real world position of the Joint.
Definition: Body.hpp:246
astra::BitmapMask::height
int32_t height() const
Gets the height of the mask.
Definition: Body.hpp:65
astra::BodyStream::get_default_body_features
BodyTrackingFeatureFlags get_default_body_features()
get default body features
Definition: Body.hpp:665
astra::BodyFrame::is_valid
bool is_valid() const
get body frame is vaild
Definition: Body.hpp:544
astra::JointStatus::NotTracked
astra::Body::center_of_mass
const Vector3f & center_of_mass() const
Gets the real world center of mass estimate.
Definition: Body.hpp:346
astra::JointType::LeftHand
astra::Plane::b
float b() const
Gets the B coefficient.
Definition: Body.hpp:416
astra::HandPose
HandPose
Hand pose enum. Enumeration of the hand poses that can be detected.
Definition: Body.hpp:265
astra::Plane::d
float d() const
Gets the D coefficent (signed distance)
Definition: Body.hpp:424
astra::Plane::a
float a() const
Gets the A coefficient.
Definition: Body.hpp:412
astra::JointType::RightKnee


Astra SDK: body_capi.h Source File

  • include
  • astra
  • capi
  • streams
body_capi.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef BODY_CAPI_H
18 #define BODY_CAPI_H
19
20 #include <astra_core/capi/astra_defines.h>
21 #include <astra_core/capi/astra_types.h>
22 #include "body_types.h"
23 #include <stdbool.h>
24
25 ASTRA_BEGIN_DECLS
26
32 ASTRA_API_EX astra_status_t astra_reader_get_bodystream(astra_reader_t reader,
33 astra_bodystream_t* bodyStream);
34
35 ASTRA_API_EX astra_status_t astra_bodystream_is_available(astra_bodystream_t bodyStream,
36 bool* isAvailable);
37
38 ASTRA_API_EX astra_status_t astra_bodystream_get_body_features(astra_bodystream_t bodyStream,
39 astra_body_id_t id,
40 astra_body_tracking_feature_flags_t* features);
41
42 ASTRA_API_EX astra_status_t astra_bodystream_set_body_features(astra_bodystream_t bodyStream,
43 astra_body_id_t id,
44 astra_body_tracking_feature_flags_t features);
45
46 ASTRA_API_EX astra_status_t astra_bodystream_get_default_body_features(astra_bodystream_t bodyStream,
47 astra_body_tracking_feature_flags_t* features);
48
49 ASTRA_API_EX astra_status_t astra_bodystream_set_default_body_features(astra_bodystream_t bodyStream,
50 astra_body_tracking_feature_flags_t features);
51
52 ASTRA_API_EX astra_status_t astra_bodystream_get_skeleton_profile(astra_bodystream_t bodyStream,
53 astra_skeleton_profile_t* skeletonProfile);
54
55 ASTRA_API_EX astra_status_t astra_bodystream_set_skeleton_profile(astra_bodystream_t bodyStream,
56 astra_skeleton_profile_t skeletonProfile);
57
58 ASTRA_API_EX astra_status_t astra_bodystream_get_skeleton_optimization(astra_bodystream_t bodyStream,
59 astra_skeleton_optimization_t* skeletonOptimization);
60
61 ASTRA_API_EX astra_status_t astra_bodystream_set_skeleton_optimization(astra_bodystream_t bodyStream,
62 astra_skeleton_optimization_t skeletonOptimization);
63
64 ASTRA_API_EX astra_status_t astra_frame_get_bodyframe(astra_reader_frame_t readerFrame,
65 astra_bodyframe_t* bodyFrame);
66
67 ASTRA_API_EX astra_status_t astra_bodyframe_get_frameindex(astra_bodyframe_t bodyFrame,
68 astra_frame_index_t* index);
69
70 ASTRA_API_EX astra_status_t astra_bodyframe_info(astra_bodyframe_t bodyFrame,
71 astra_bodyframe_info_t* info);
72
73 ASTRA_API_EX astra_status_t astra_bodyframe_bodymask(astra_bodyframe_t bodyFrame,
74 astra_bodymask_t* bodyMask);
75
76 // Internal use only
77 ASTRA_API_EX astra_status_t astra_bodyframe_bodymask_ptr(astra_bodyframe_t bodyFrame,
78 uint32_t* width,
79 uint32_t* height,
80 void** dataPtr);
81
82 ASTRA_API_EX astra_status_t astra_bodyframe_copy_bodymask_data(astra_bodyframe_t bodyFrame,
83 void* data);
84
85 ASTRA_API_EX astra_status_t astra_bodyframe_floor_info(astra_bodyframe_t bodyFrame,
86 astra_floor_info_t* floorInfo);
87
88 ASTRA_API_EX astra_status_t astra_bodyframe_floormask_ptr(astra_bodyframe_t bodyFrame,
89 uint32_t* width,
90 uint32_t* height,
91 void** dataPtr);
92
93 ASTRA_API_EX astra_status_t astra_bodyframe_copy_floormask_data(astra_bodyframe_t bodyFrame,
94 void* data);
95
96 // Internal use only
97 ASTRA_API_EX astra_status_t astra_bodyframe_floor_info_ptr(astra_bodyframe_t bodyFrame,
98 astra_floor_info_t** floorInfo);
99
100 ASTRA_API_EX astra_status_t astra_bodyframe_body_list(astra_bodyframe_t bodyFrame,
101 astra_body_list_t* bodyList);
107 ASTRA_API_EX astra_status_t orbbec_body_tracking_set_license(const char* licenseString);
110 ASTRA_END_DECLS
111
112 #endif // BODY_CAPI_H
_astra_body_list
Struct containing a variable-sized array of astra_body_t structs.
Definition: body_types.h:315
_astra_streamconnection
Definition: astra_plugin.h:24
orbbec_body_tracking_set_license
ASTRA_API_EX astra_status_t orbbec_body_tracking_set_license(const char *licenseString)
_astra_bodyframe
Definition: stream_types.h:62
_astra_floor_info
Struct containing floor information about the scene.
Definition: body_types.h:400
_astra_bitmapmask
Struct representing a 2-dimensional bitmask.
Definition: body_types.h:330
_astra_bodyframe_info
Struct containing general body frame information.
Definition: body_types.h:387


Astra SDK: body_parameters.h Source File

  • include
  • astra
  • capi
  • streams
body_parameters.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef BODY_PARAMETERS_H
18 #define BODY_PARAMETERS_H
19
20 enum {
21 ASTRA_PARAMETER_BODY_DEFAULT_BODY_FEATURES = 1,
22 ASTRA_PARAMETER_BODY_SKELETON_PROFILE = 2,
23 ASTRA_PARAMETER_BODY_SKELETON_OPTIMIZATION = 3,
24 };
25
26 enum {
27 ASTRA_COMMAND_GET_BODY_FEATURES = 1001,
28 ASTRA_COMMAND_SET_BODY_FEATURES = 1002,
29 };
30
31 enum {
32 ORBBEC_BODY_TRACKING_EVENT_SET_LICENSE = 1001
33 };
34
35 #endif /* BODY_PARAMETERS_H */


Astra SDK: body_types.h Source File

  • include
  • astra
  • capi
  • streams
body_types.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef BODY_TYPES_H
18 #define BODY_TYPES_H
19
20 #include <astra_core/capi/astra_types.h>
21 #include <astra/capi/astra_ctypes.h>
22
27 #define ASTRA_MAX_JOINTS 19
28
29 #define ASTRA_INVALID_BODY_ID 0
30 #define ASTRA_MIN_BODY_ID 1
31 #define ASTRA_MAX_BODY_ID 255
32 #define ASTRA_MAX_BODIES 6
33
34 #define ASTRA_TEMP_IMAGE_WIDTH 640
35 #define ASTRA_TEMP_IMAGE_HEIGHT 480
36 #define ASTRA_TEMP_IMAGE_LENGTH ASTRA_TEMP_IMAGE_WIDTH*ASTRA_TEMP_IMAGE_HEIGHT
37
42 typedef enum _astra_joint_type {
44 ASTRA_JOINT_HEAD = 0,
46 ASTRA_JOINT_SHOULDER_SPINE = 1,
48 ASTRA_JOINT_LEFT_SHOULDER = 2,
50 ASTRA_JOINT_LEFT_ELBOW = 3,
52 ASTRA_JOINT_LEFT_HAND = 4,
54 ASTRA_JOINT_RIGHT_SHOULDER = 5,
56 ASTRA_JOINT_RIGHT_ELBOW = 6,
58 ASTRA_JOINT_RIGHT_HAND = 7,
60 ASTRA_JOINT_MID_SPINE = 8,
62 ASTRA_JOINT_BASE_SPINE = 9,
64 ASTRA_JOINT_LEFT_HIP = 10,
66 ASTRA_JOINT_LEFT_KNEE = 11,
68 ASTRA_JOINT_LEFT_FOOT = 12,
70 ASTRA_JOINT_RIGHT_HIP = 13,
72 ASTRA_JOINT_RIGHT_KNEE = 14,
74 ASTRA_JOINT_RIGHT_FOOT = 15,
76 ASTRA_JOINT_LEFT_WRIST = 16,
78 ASTRA_JOINT_RIGHT_WRIST = 17,
80 ASTRA_JOINT_NECK = 18,
82 ASTRA_JOINT_UNKNOWN = 255,
83 } astra_joint_type_v;
84
92 typedef uint8_t astra_joint_type_t;
93
98 typedef enum _astra_joint_status {
100 ASTRA_JOINT_STATUS_NOT_TRACKED = 0,
105 ASTRA_JOINT_STATUS_LOW_CONFIDENCE = 1,
107 ASTRA_JOINT_STATUS_TRACKED = 2,
108 } astra_joint_status_v;
109
117 typedef uint8_t astra_joint_status_t;
118
123 typedef struct _astra_joint {
128 astra_joint_type_t type;
133 astra_joint_status_t status;
135 astra_vector2f_t depthPosition;
137 astra_vector3f_t worldPosition;
139 // TODO: is this rotation relative to the parent? is Y up?
140 astra_matrix3x3_t orientation;
141 } astra_joint_t;
142
147 typedef enum _astra_body_status {
149 ASTRA_BODY_STATUS_NOT_TRACKING = 0,
151 ASTRA_BODY_STATUS_LOST = 1,
153 ASTRA_BODY_STATUS_TRACKING_STARTED = 2,
155 ASTRA_BODY_STATUS_TRACKING = 3,
156 } astra_body_status_v;
157
165 typedef uint8_t astra_body_status_t;
166
172 typedef enum _astra_handpose {
174 ASTRA_HANDPOSE_UNKNOWN = 0,
176 ASTRA_HANDPOSE_GRIP = 1
177 } astra_handpose_v;
178
185 typedef uint8_t astra_handpose_t;
186
187 typedef struct _astra_handpose_info {
188 astra_handpose_t leftHand;
189 astra_handpose_t rightHand;
190 } astra_handpose_info_t;
191
198 typedef enum _astra_body_features {
200 ASTRA_BODY_TRACKING_SEGMENTATION = 0,
202 ASTRA_BODY_TRACKING_JOINTS = 1,
204 ASTRA_BODY_TRACKING_HAND_POSES = 3
205 } astra_body_tracking_feature_flags_v;
206
213 typedef uint32_t astra_body_tracking_feature_flags_t;
214
219 typedef enum _astra_skeleton_profile {
221 ASTRA_SKELETON_PROFILE_FULL = 0,
223 ASTRA_SKELETON_PROFILE_UPPER_BODY = 1,
225 ASTRA_SKELETON_PROFILE_BASIC = 2
226 } astra_skeleton_profile_v;
227
234 typedef uint32_t astra_skeleton_profile_t;
235
241 typedef enum _astra_skeleton_optimization {
242 ASTRA_SKELETON_OPTIMIZATION_1 = 1,
244 ASTRA_SKELETON_OPTIMIZATION_MINIMIZE_MEMORY = 2,
245 ASTRA_SKELETON_OPTIMIZATION_2 = 2,
246 ASTRA_SKELETON_OPTIMIZATION_3 = 3,
247 ASTRA_SKELETON_OPTIMIZATION_4 = 4,
249 ASTRA_SKELETON_OPTIMIZATION_BALANCED = 5,
250 ASTRA_SKELETON_OPTIMIZATION_5 = 5,
251 ASTRA_SKELETON_OPTIMIZATION_6 = 6,
252 ASTRA_SKELETON_OPTIMIZATION_7 = 7,
253 ASTRA_SKELETON_OPTIMIZATION_8 = 8,
254 ASTRA_SKELETON_OPTIMIZATION_9 = 9,
256 ASTRA_SKELETON_OPTIMIZATION_BEST_ACCURACY = 9,
257 } astra_skeleton_optimization_v;
258
259
267 typedef uint32_t astra_skeleton_optimization_t;
268
273 typedef uint8_t astra_body_id_t;
274
279 typedef struct _astra_body {
284 astra_body_tracking_feature_flags_t features;
290 astra_vector3f_t centerOfMass;
292 astra_joint_t joints[ASTRA_MAX_JOINTS];
294 astra_handpose_info_t handPoses;
301 astra_body_id_t id;
307 astra_body_status_t status;
308 } astra_body_t;
309
315 typedef struct _astra_body_list {
317 // astra_body_t* bodies;
318 astra_body_t bodies[ASTRA_MAX_BODIES];
320 int32_t count;
321 } astra_body_list_t;
322
330 typedef struct _astra_bitmapmask {
332 // uint8_t* data;
333 uint8_t data[ASTRA_TEMP_IMAGE_LENGTH];
335 int32_t width;
337 int32_t height;
338 } astra_bitmapmask_t;
339
348 typedef astra_bitmapmask_t astra_bodymask_t;
356 typedef astra_bitmapmask_t astra_floormask_t;
357
372 typedef struct _astra_plane {
374 float a;
376 float b;
378 float c;
380 float d;
381 } astra_plane_t;
382
387 typedef struct _astra_bodyframe_info {
389 int32_t width;
391 int32_t height;
393 int8_t isEstimated;
394 } astra_bodyframe_info_t;
395
400 typedef struct _astra_floor_info {
402 astra_floormask_t floorMask;
404 astra_plane_t floorPlane;
410 astra_bool_t floorDetected;
411 } astra_floor_info_t;
412
413 typedef struct _astra_bodyframe* astra_bodyframe_t;
414 typedef astra_streamconnection_t astra_bodystream_t;
415
416 typedef struct {
417 astra_body_id_t bodyId;
418 astra_body_tracking_feature_flags_t feature;
419 } astra_body_feature_command_t;
420
421 #endif /* BODY_TYPES_H */
_astra_body_list::count
int32_t count
Number of astra_body_t in bodies.
Definition: body_types.h:320
_astra_bodyframe_info::isEstimated
int8_t isEstimated
If the frame was estimated due to a slow CPU.
Definition: body_types.h:393
_astra_body_list
Struct containing a variable-sized array of astra_body_t structs.
Definition: body_types.h:315
_astra_body::features
astra_body_tracking_feature_flags_t features
Bitmask of features that are enabled.
Definition: body_types.h:284
_astra_matrix3x3
Represents a 3x3 rotation matrix.
Definition: astra_ctypes.h:51
_astra_joint::depthPosition
astra_vector2f_t depthPosition
Depth ("projective") position of joint.
Definition: body_types.h:135
_astra_bodyframe_info::width
int32_t width
Frame width.
Definition: body_types.h:389
_astra_body::handPoses
astra_handpose_info_t handPoses
Hand poses.
Definition: body_types.h:294
_astra_bitmapmask::height
int32_t height
height in pixels
Definition: body_types.h:337
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_body::centerOfMass
astra_vector3f_t centerOfMass
Single point describing the center of mass of a body.
Definition: body_types.h:290
_astra_bodyframe
Definition: stream_types.h:62
_astra_joint::worldPosition
astra_vector3f_t worldPosition
Real world position of joint.
Definition: body_types.h:137
astra_body_feature_command_t
Definition: body_types.h:416
_astra_plane::d
float d
D coefficient.
Definition: body_types.h:380
_astra_joint::status
astra_joint_status_t status
Joint status.
Definition: body_types.h:133
_astra_joint
Joint information.
Definition: body_types.h:123
_astra_floor_info::floorMask
astra_floormask_t floorMask
Floor mask.
Definition: body_types.h:402
_astra_bodyframe_info::height
int32_t height
Frame height.
Definition: body_types.h:391
_astra_joint::type
astra_joint_type_t type
Joint type.
Definition: body_types.h:128
astra_vector3f_t
Definition: astra_ctypes.h:33
_astra_plane::a
float a
A coefficient.
Definition: body_types.h:374
_astra_floor_info
Struct containing floor information about the scene.
Definition: body_types.h:400
_astra_body::id
astra_body_id_t id
Persistent Id.
Definition: body_types.h:301
_astra_plane
Struct representing a geometric 3-dimensional plane.
Definition: body_types.h:372
_astra_body::status
astra_body_status_t status
Tracking status.
Definition: body_types.h:307
_astra_handpose_info
Definition: body_types.h:187
_astra_bitmapmask
Struct representing a 2-dimensional bitmask.
Definition: body_types.h:330
_astra_floor_info::floorDetected
astra_bool_t floorDetected
If the floor is detected, ASTRA_TRUE. Otherwise, ASTRA_FALSE.
Definition: body_types.h:410
_astra_plane::c
float c
C coefficient.
Definition: body_types.h:378
_astra_floor_info::floorPlane
astra_plane_t floorPlane
Floor plane.
Definition: body_types.h:404
_astra_body
Struct containing body tracking information.
Definition: body_types.h:279
_astra_joint::orientation
astra_matrix3x3_t orientation
3x3 Rotation matrix representing the rotation of this joint.
Definition: body_types.h:140
_astra_bitmapmask::width
int32_t width
width in pixels
Definition: body_types.h:335
_astra_bodyframe_info
Struct containing general body frame information.
Definition: body_types.h:387
_astra_plane::b
float b
B coefficient.
Definition: body_types.h:376
astra_vector2f_t
Definition: astra_ctypes.h:28


Astra SDK: Color.hpp Source File

  • include
  • astra
  • streams
Color.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_COLOR_HPP
18 #define ASTRA_COLOR_HPP
19
20 #include <astra_core/astra_core.hpp>
21 #include <astra/capi/astra_ctypes.h>
22 #include <astra/capi/streams/color_capi.h>
23 #include <astra/streams/Image.hpp>
24
25 namespace astra {
26
33 class ColorStream : public ImageStream
34 {
35 public:
36 explicit ColorStream(astra_streamconnection_t connection)
37 : ImageStream(connection)
38 {
39 colorStream_ = reinterpret_cast< astra_colorstream_t >(connection);
40 }
41
42 static const astra_stream_type_t id = ASTRA_STREAM_COLOR;
43
44
45 private:
46 astra_colorstream_t colorStream_;
47 };
48
55 class ColorFrame : public ImageFrame<RgbPixel, ASTRA_STREAM_COLOR>
56 {
57 public:
58 ColorFrame(astra_imageframe_t frame)
59 : ImageFrame(frame, ASTRA_PIXEL_FORMAT_RGB888)
60 {}
61 };
62
69 class RawColorFrame : public ImageFrame<uint8_t, ASTRA_STREAM_COLOR>
70 {
71 public:
72 RawColorFrame(astra_imageframe_t frame)
73 : ImageFrame(frame, ASTRA_PIXEL_FORMAT_RGB888)
74 {}
75 };
76 }
77
78 #endif // ASTRA_COLOR_HPP
astra::RawColorFrame
color frame of raw format
Definition: Color.hpp:69
astra::ImageFrame
Basic Image Frame.
Definition: Image.hpp:392
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra
Definition: Array.hpp:20
astra::ImageStream
basic Image Stream
Definition: Image.hpp:267
astra::ColorFrame
color frame of rgb format
Definition: Color.hpp:55
astra::ColorStream
A color stream.
Definition: Color.hpp:33


Astra SDK: color_capi.h Source File

  • include
  • astra
  • capi
  • streams
color_capi.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef COLOR_CAPI_H
18 #define COLOR_CAPI_H
19
20 #include <astra_core/capi/astra_types.h>
21 #include "color_types.h"
22 #include <stdbool.h>
23
24 ASTRA_BEGIN_DECLS
25
31 ASTRA_API_EX astra_status_t astra_reader_get_colorstream(astra_reader_t reader,
32 astra_colorstream_t* colorStream);
33
34 ASTRA_API_EX astra_status_t astra_colorstream_is_available(astra_colorstream_t colorStream,
35 bool* isAvailable);
36
37 ASTRA_API_EX astra_status_t astra_colorstream_get_usb_info(astra_colorstream_t colorStream,
38 astra_usb_info_t* usbInfo);
39
40 ASTRA_API_EX astra_status_t astra_frame_get_colorframe(astra_reader_frame_t readerFrame,
41 astra_colorframe_t* colorFrame);
42
43 ASTRA_API_EX astra_status_t astra_frame_get_colorframe_with_subtype(astra_reader_frame_t readerFrame,
44 astra_stream_subtype_t subtype,
45 astra_colorframe_t* colorFrame);
46
47 ASTRA_API_EX astra_status_t astra_colorframe_get_data_byte_length(astra_colorframe_t colorFrame,
48 uint32_t* byteLength);
49
50 ASTRA_API_EX astra_status_t astra_colorframe_get_data_ptr(astra_colorframe_t colorFrame,
51 uint8_t** data,
52 uint32_t* byteLength);
53
54 ASTRA_API_EX astra_status_t astra_colorframe_get_data_rgb_ptr(astra_colorframe_t colorFrame,
55 astra_rgb_pixel_t** data,
56 uint32_t* byteLength);
57
58 ASTRA_API_EX astra_status_t astra_colorframe_copy_data(astra_colorframe_t colorFrame,
59 uint8_t* data);
60
61 ASTRA_API_EX astra_status_t astra_colorframe_get_metadata(astra_colorframe_t colorFrame,
62 astra_image_metadata_t* metadata);
63
64 ASTRA_API_EX astra_status_t astra_colorframe_get_frameindex(astra_colorframe_t colorFrame,
65 astra_frame_index_t* index);
67 ASTRA_END_DECLS
68
69 #endif /* COLOR_CAPI_H */
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra_usb_info_t
Definition: astra_ctypes.h:45
astra_image_metadata_t
Definition: image_types.h:55
astra_rgb_pixel_t
Definition: image_types.h:41


Astra SDK: color_types.h Source File

  • include
  • astra
  • capi
  • streams
color_types.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef COLOR_TYPES_H
18 #define COLOR_TYPES_H
19
20 #include "image_types.h"
21
22 typedef astra_streamconnection_t astra_colorstream_t;
23
24 typedef struct _astra_imageframe* astra_colorframe_t;
25
26 #endif // COLOR_TYPES_H
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37


Astra SDK: colorized_body_capi.h Source File

  • include
  • astra
  • capi
  • streams
colorized_body_capi.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef COLORIZED_BODY_CAPI_H
18 #define COLORIZED_BODY_CAPI_H
19
20 #include <astra_core/capi/astra_types.h>
21 #include "colorized_body_types.h"
22
23 ASTRA_BEGIN_DECLS
24
30 ASTRA_API_EX astra_status_t astra_reader_get_colorizedbodystream(astra_reader_t reader,
31 astra_colorizedbodystream_t* colorizedbodyStream);
32
33 ASTRA_API_EX astra_status_t astra_colorizedbodystream_is_available(astra_colorizedbodystream_t colorizedbodyStream,
34 bool* isAvailable);
35
36 ASTRA_API_EX astra_status_t astra_frame_get_colorizedbodyframe(astra_reader_frame_t readerFrame,
37 astra_colorizedbodyframe_t* colorizedbodyFrame);
38
39 ASTRA_API_EX astra_status_t astra_frame_get_colorizedbodyframe_with_subtype(astra_reader_frame_t readerFrame,
40 astra_stream_subtype_t subtype,
41 astra_colorizedbodyframe_t* colorizedbodyFrame);
42
43 ASTRA_API_EX astra_status_t astra_colorizedbodyframe_get_data_byte_length(astra_colorizedbodyframe_t colorizedbodyFrame,
44 uint32_t* byteLength);
45
46 ASTRA_API_EX astra_status_t astra_colorizedbodyframe_get_data_ptr(astra_colorizedbodyframe_t colorizedbodyFrame,
47 astra_rgba_pixel_t** data,
48 uint32_t* byteLength);
49
50 ASTRA_API_EX astra_status_t astra_colorizedbodyframe_copy_data(astra_colorizedbodyframe_t colorizedbodyFrame,
51 astra_rgba_pixel_t* data);
52
53 ASTRA_API_EX astra_status_t astra_colorizedbodyframe_get_metadata(astra_colorizedbodyframe_t colorizedbodyFrame,
54 astra_image_metadata_t* metadata);
55
56 ASTRA_API_EX astra_status_t astra_colorizedbodyframe_get_frameindex(astra_colorizedbodyframe_t colorizedbodyFrame,
57 astra_frame_index_t* index);
59 ASTRA_END_DECLS
60
61 #endif /* COLORIZED_BODY_CAPI_H */
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra_image_metadata_t
Definition: image_types.h:55
astra_rgba_pixel_t
Definition: image_types.h:47


Astra SDK: colorized_body_types.h Source File

  • include
  • astra
  • capi
  • streams
colorized_body_types.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef COLORIZED_BODY_TYPES_H
18 #define COLORIZED_BODY_TYPES_H
19
20 #include <astra_core/capi/astra_types.h>
21 #include <astra/capi/streams/image_types.h>
22
23 typedef astra_streamconnection_t astra_colorizedbodystream_t;
24 typedef struct _astra_imageframe* astra_colorizedbodyframe_t;
25
26 #endif // MASKED_COLOR_TYPES_H
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37


Astra SDK: ColorizedBody.hpp Source File

  • include
  • astra
  • streams
ColorizedBody.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_COLORIZEDBODY_HPP
18 #define ASTRA_COLORIZEDBODY_HPP
19
20 #include <astra_core/astra_core.hpp>
21 #include <astra/capi/astra_ctypes.h>
22 #include <astra/capi/streams/colorized_body_capi.h>
23 #include <astra/streams/Image.hpp>
24
25 namespace astra {
26
33 class ColorizedBodyStream : public DataStream
34 {
35 public:
36 ColorizedBodyStream()
37 {}
38
39 explicit ColorizedBodyStream(astra_streamconnection_t connection)
40 : DataStream(connection)
41 {
42 colorizedbodyStream_ = reinterpret_cast< astra_colorizedbodystream_t >(connection);
43 }
44
45 static const astra_stream_type_t id = ASTRA_STREAM_COLORIZED_BODY;
46
47 private:
48 astra_colorizedbodystream_t colorizedbodyStream_;
49 };
50
57 class ColorizedBodyFrame : public ImageFrame<RgbaPixel, ASTRA_STREAM_COLORIZED_BODY>
58 {
59 public:
60 ColorizedBodyFrame(astra_imageframe_t frame)
61 : ImageFrame(frame, ASTRA_PIXEL_FORMAT_RGBA)
62 {}
63 };
64 }
65
66 #endif // ASTRA_COLORIZEDBODY_HPP
astra::ImageFrame
Basic Image Frame.
Definition: Image.hpp:392
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra::ColorizedBodyStream
A Colorized Body Stream.
Definition: ColorizedBody.hpp:33
astra
Definition: Array.hpp:20
astra::DataStream
Data Stream.
Definition: DataStream.hpp:32
astra::ColorizedBodyFrame
A Colorized Body Frame.
Definition: ColorizedBody.hpp:57


Astra SDK: DataStream.hpp Source File

  • include
  • astra_core
DataStream.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_DATASTREAM_HPP
18 #define ASTRA_DATASTREAM_HPP
19
20 #include "capi/astra_core.h"
21 #include <astra_core/StreamDescription.hpp>
22 #include <stdexcept>
23
24 namespace astra {
25
32 class DataStream
33 {
34 public:
35 DataStream()
36 {}
37
43 DataStream(astra_streamconnection_t connection)
44 : connection_(connection)
45 {
46 if(connection_ != nullptr)
47 {
48 astra_stream_get_description(connection,&description_);
49 }
50 }
51
57 bool is_available()
58 {
59 bool isAvailable = false;
60 if (connection_ == nullptr)
61 {
62 return isAvailable;
63 }
64 astra_stream_is_available(connection_, &isAvailable);
65 return isAvailable;
66 }
67
71 void start()
72 {
73 if(connection_ == nullptr)
74 {
75 throw std::logic_error("Cannot start a stream that is not available");
76 }
77 astra_stream_start(connection_);
78 }
79
83 void stop()
84 {
85 if(connection_ == nullptr)
86 {
87 throw std::logic_error("Cannot stop a stream that is not available");
88 }
89 astra_stream_stop(connection_);
90 }
91
92 private:
93 astra_streamconnection_t connection_{nullptr};
94 astra_stream_desc_t description_;
95 };
96 }
97
98 #endif // ASTRA_DATASTREAM_HPP
astra::DataStream::start
void start()
start stream
Definition: DataStream.hpp:71
_astra_streamconnection
Definition: astra_plugin.h:24
astra::DataStream::DataStream
DataStream(astra_streamconnection_t connection)
default constructs
Definition: DataStream.hpp:43
astra
Definition: Array.hpp:20
astra_stream_get_description
ASTRA_API astra_status_t astra_stream_get_description(astra_streamconnection_t stream, astra_stream_desc_t *description)
Get description of Stream.
astra_stream_desc_t
Definition: astra_types.h:38
astra_stream_is_available
ASTRA_API astra_status_t astra_stream_is_available(astra_streamconnection_t stream, bool *isAvailable)
Test whether the handle to Stream is valid.
astra_stream_start
ASTRA_API astra_status_t astra_stream_start(astra_streamconnection_t stream)
Start the Stream.
astra::DataStream
Data Stream.
Definition: DataStream.hpp:32
astra_stream_stop
ASTRA_API astra_status_t astra_stream_stop(astra_streamconnection_t stream)
Stop the Stream.
astra::DataStream::stop
void stop()
stop stream
Definition: DataStream.hpp:83
astra::DataStream::is_available
bool is_available()
start stream
Definition: DataStream.hpp:57


Astra SDK: DebugHand.hpp Source File

  • include
  • astra
  • streams
DebugHand.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_HAND_DEBUG_HPP
18 #define ASTRA_HAND_DEBUG_HPP
19
20 #include <astra_core/astra_core.hpp>
21 #include <astra/capi/astra_ctypes.h>
22 #include <astra/capi/streams/hand_capi.h>
23
24 namespace astra {
25
26 using DebugHandViewType = astra_debug_hand_view_type_t;
27
34 class DebugHandStream : public DataStream
35 {
36 public:
42 explicit DebugHandStream(astra_streamconnection_t connection)
43 : DataStream(connection),
44 debugHandStream_(connection)
45 { }
46
47 static const astra_stream_type_t id = ASTRA_STREAM_DEBUG_HAND;
48
54 void set_view_type(DebugHandViewType view)
55 {
56 astra_debug_handstream_set_view_type(debugHandStream_, view);
57 }
58
64 void set_use_mouse_probe(bool useMouseProbe)
65 {
66 astra_debug_handstream_set_use_mouse_probe(debugHandStream_, useMouseProbe);
67 }
68
74 void set_mouse_position(Vector2f position)
75 {
76 astra_debug_handstream_set_mouse_position(debugHandStream_, position);
77 }
78
84 void set_pause_input(bool pauseInput)
85 {
86 astra_debug_handstream_set_pause_input(debugHandStream_, pauseInput);
87 }
88
94 void set_lock_spawn_point(bool lockSpawnPoint)
95 {
96 astra_debug_handstream_set_lock_spawn_point(debugHandStream_, lockSpawnPoint);
97 }
98
104 DebugHandViewType get_view_type() const
105 {
106 DebugHandViewType view;
107 astra_debug_handstream_get_view_type(debugHandStream_, &view);
108 return view;
109 }
110
111 private:
112 astra_debug_handstream_t debugHandStream_;
113 };
114
121 class DebugHandFrame : public ImageFrame<RgbPixel, ASTRA_STREAM_DEBUG_HAND>
122 {
123 public:
129 DebugHandFrame(astra_imageframe_t frame)
130 : ImageFrame(frame, ASTRA_PIXEL_FORMAT_RGB888)
131 {}
132 };
133 }
134
135 #endif /* ASTRA_HAND_DEBUG_HPP */
astra::DebugHandFrame
A Debug Hand Frame.
Definition: DebugHand.hpp:121
astra::ImageFrame
Basic Image Frame.
Definition: Image.hpp:392
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra::DebugHandStream::get_view_type
DebugHandViewType get_view_type() const
get view type
Definition: DebugHand.hpp:104
astra::DebugHandStream::DebugHandStream
DebugHandStream(astra_streamconnection_t connection)
default constructs
Definition: DebugHand.hpp:42
astra::DebugHandStream::set_pause_input
void set_pause_input(bool pauseInput)
set pause input
Definition: DebugHand.hpp:84
astra
Definition: Array.hpp:20
astra::Vector2f
Represents a float 2d vector.
Definition: Vector2f.hpp:29
astra::DebugHandStream::set_lock_spawn_point
void set_lock_spawn_point(bool lockSpawnPoint)
set lock spawn point
Definition: DebugHand.hpp:94
astra::DebugHandFrame::DebugHandFrame
DebugHandFrame(astra_imageframe_t frame)
default constructs
Definition: DebugHand.hpp:129
astra::DebugHandStream::set_mouse_position
void set_mouse_position(Vector2f position)
set mouse position
Definition: DebugHand.hpp:74
astra::DebugHandStream::set_use_mouse_probe
void set_use_mouse_probe(bool useMouseProbe)
set is use mouse probe
Definition: DebugHand.hpp:64
astra::DataStream
Data Stream.
Definition: DataStream.hpp:32
astra::DebugHandStream::set_view_type
void set_view_type(DebugHandViewType view)
set view type
Definition: DebugHand.hpp:54
astra::DebugHandStream
A Debug Hand Stream.
Definition: DebugHand.hpp:34


Astra SDK: Depth.hpp Source File

  • include
  • astra
  • streams
Depth.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_DEPTH_HPP
18 #define ASTRA_DEPTH_HPP
19
20 #include <astra_core/astra_core.hpp>
21 #include <astra/capi/astra_ctypes.h>
22 #include <astra/capi/streams/depth_capi.h>
23 #include <astra/streams/Image.hpp>
24 #include <astra/Vector.hpp>
25
26 namespace astra {
27
34 class CoordinateMapper
35 {
36 public:
40 CoordinateMapper(astra_depthstream_t depthStream)
41 : depthStream_(depthStream)
42 { }
43
47 CoordinateMapper(const CoordinateMapper& rhs)
48 {
49 this->depthStream_ = rhs.depthStream_;
50 }
51
55 CoordinateMapper operator=(const CoordinateMapper& rhs)
56 {
57 this->depthStream_ = rhs.depthStream_;
58 return *this;
59 }
60
67 astra::Vector3f convert_depth_to_world(astra::Vector3f depthPosition) const
68 {
69 float worldX, worldY, worldZ;
70 astra_convert_depth_to_world(depthStream_,
71 depthPosition.x,
72 depthPosition.y,
73 depthPosition.z,
74 &worldX, &worldY, &worldZ);
75
76 return Vector3f(worldX, worldY, worldZ);
77 }
78
85 Vector3f convert_world_to_depth(Vector3f worldPosition) const
86 {
87 float depthX, depthY, depthZ;
88 astra_convert_world_to_depth(depthStream_,
89 worldPosition.x,
90 worldPosition.y,
91 worldPosition.z,
92 &depthX, &depthY, &depthZ);
93
94 return Vector3f(depthX, depthY, depthZ);
95 }
96
107 void convert_depth_to_world(float depthX, float depthY, float depthZ,
108 float& worldX, float& worldY, float& worldZ) const
109 {
110 astra_convert_depth_to_world(depthStream_, depthX, depthY, depthZ,
111 &worldX, &worldY, &worldZ);
112 }
113
124 void convert_world_to_depth(float worldX, float worldY, float worldZ,
125 float& depthX, float& depthY, float& depthZ) const
126 {
127 astra_convert_world_to_depth(depthStream_,
128 worldX, worldY, worldZ,
129 &depthX, &depthY, &depthZ);
130 }
131
132 private:
133 astra_depthstream_t depthStream_;
134 };
135
142 class DepthStream : public ImageStream
143 {
144 public:
145 explicit DepthStream(astra_streamconnection_t connection)
146 : ImageStream(connection),
147 depthStream_(reinterpret_cast<astra_depthstream_t>(connection)),
148 coordinateMapper_(reinterpret_cast<astra_depthstream_t>(connection))
149 { }
150
151 static const astra_stream_type_t id = ASTRA_STREAM_DEPTH;
152
158 astra_conversion_cache_t depth_to_world_data() const
159 {
160 astra_conversion_cache_t data;
161 astra_depthstream_get_depth_to_world_data(depthStream_, &data);
162
163 return data;
164 }
165
171 bool registration_enabled() const
172 {
173 bool enabled = false;
174 astra_depthstream_get_registration(depthStream_, &enabled);
175
176 return enabled;
177 }
178
184 void enable_registration(bool enable)
185 {
186 astra_depthstream_set_registration(depthStream_, enable);
187 }
188
195 void serial_number(char* serialnumber, uint32_t length) const
196 {
197 astra_depthstream_get_serialnumber(depthStream_, serialnumber, length);
198 }
199
205 std::string serial_number() const
206 {
207 char serialNumber[ASTRA_SERIAL_NUMBER_MAX];
208 astra_depthstream_get_serialnumber(depthStream_, serialNumber, sizeof(serialNumber) / sizeof(char));
209 return std::string(serialNumber);
210 }
211
217 std::uint32_t chip_id() const
218 {
219 uint32_t chip_id;
220 astra_depthstream_get_chip_id(depthStream_, &chip_id);
221 return chip_id;
222 }
223
229 const CoordinateMapper& coordinateMapper() const { return coordinateMapper_; };
230
231 private:
232 astra_depthstream_t depthStream_;
233 CoordinateMapper coordinateMapper_;
234 };
235
236
243 class DepthFrame : public ImageFrame<int16_t, ASTRA_STREAM_DEPTH>
244 {
245 public:
246 DepthFrame(astra_imageframe_t frame)
247 : ImageFrame(frame, ASTRA_PIXEL_FORMAT_DEPTH_MM)
248 {}
249
250 };
251 }
252
253 #endif /* ASTRA_DEPTH_HPP */
astra::DepthStream
A Depth Stream.
Definition: Depth.hpp:142
astra::DepthStream::serial_number
std::string serial_number() const
get serial number
Definition: Depth.hpp:205
astra::ImageFrame
Basic Image Frame.
Definition: Image.hpp:392
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra
Definition: Array.hpp:20
astra::DepthStream::enable_registration
void enable_registration(bool enable)
enable registration
Definition: Depth.hpp:184
astra::DepthFrame
A Depth Frame.
Definition: Depth.hpp:243
astra::CoordinateMapper
CoordinateMapper.
Definition: Depth.hpp:34
astra::CoordinateMapper::CoordinateMapper
CoordinateMapper(const CoordinateMapper &rhs)
copy Constructs
Definition: Depth.hpp:47
astra::CoordinateMapper::convert_world_to_depth
void convert_world_to_depth(float worldX, float worldY, float worldZ, float &depthX, float &depthY, float &depthZ) const
convert world coor to depth coor
Definition: Depth.hpp:124
astra::DepthStream::serial_number
void serial_number(char *serialnumber, uint32_t length) const
get serial number
Definition: Depth.hpp:195
astra::DepthStream::registration_enabled
bool registration_enabled() const
return is registration enabled
Definition: Depth.hpp:171
astra::ImageStream
basic Image Stream
Definition: Image.hpp:267
astra::CoordinateMapper::convert_depth_to_world
astra::Vector3f convert_depth_to_world(astra::Vector3f depthPosition) const
convert depth coor to world coor
Definition: Depth.hpp:67
astra::CoordinateMapper::convert_world_to_depth
Vector3f convert_world_to_depth(Vector3f worldPosition) const
convert depth coor to world coor
Definition: Depth.hpp:85
astra::CoordinateMapper::convert_depth_to_world
void convert_depth_to_world(float depthX, float depthY, float depthZ, float &worldX, float &worldY, float &worldZ) const
convert depth coor to world coor
Definition: Depth.hpp:107
astra::CoordinateMapper::CoordinateMapper
CoordinateMapper(astra_depthstream_t depthStream)
Constructs.
Definition: Depth.hpp:40
astra::CoordinateMapper::operator=
CoordinateMapper operator=(const CoordinateMapper &rhs)
copy Constructs
Definition: Depth.hpp:55
astra::Vector3f
Represents a float 3d vector.
Definition: Vector3f.hpp:29
astra::DepthStream::coordinateMapper
const CoordinateMapper & coordinateMapper() const
get Coordinate Mapper
Definition: Depth.hpp:229
astra::DepthStream::chip_id
std::uint32_t chip_id() const
get chip id
Definition: Depth.hpp:217
astra::DepthStream::depth_to_world_data
astra_conversion_cache_t depth_to_world_data() const
get world conversion
Definition: Depth.hpp:158
astra_conversion_cache_t
Definition: depth_types.h:23


Astra SDK: depth_capi.h Source File

  • include
  • astra
  • capi
  • streams
depth_capi.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef DEPTH_CAPI_H
18 #define DEPTH_CAPI_H
19
20 #include <astra_core/capi/astra_defines.h>
21 #include <astra_core/capi/astra_types.h>
22 #include <astra/capi/streams/depth_types.h>
23 #include <stdbool.h>
24
25 #define ASTRA_SERIAL_NUMBER_MAX 256
26
27 ASTRA_BEGIN_DECLS
28
38 ASTRA_API_EX astra_status_t astra_convert_depth_to_world(astra_depthstream_t depthStream,
39 float depthX, float depthY, float depthZ,
40 float* pWorldX, float* pWorldY, float* pWorldZ);
41
45 ASTRA_API_EX astra_status_t astra_convert_world_to_depth(astra_depthstream_t depthStream,
46 float worldX, float worldY, float worldZ,
47 float* pDepthX, float* pDepthY, float* pDepthZ);
48
52 ASTRA_API_EX astra_status_t astra_reader_get_depthstream(astra_reader_t reader,
53 astra_depthstream_t* depthStream);
54
58 ASTRA_API_EX astra_status_t astra_depthstream_is_available(astra_depthstream_t depthStream,
59 bool* isAvailable);
60
64 ASTRA_API_EX astra_status_t astra_depthstream_get_depth_to_world_data(astra_depthstream_t depthStream,
65 astra_conversion_cache_t* conversionData);
66
70 ASTRA_API_EX astra_status_t astra_depthstream_get_hfov(astra_depthstream_t depthStream,
71 float* hFov);
72
76 ASTRA_API_EX astra_status_t astra_depthstream_get_vfov(astra_depthstream_t depthStream,
77 float* vFov);
78
82 ASTRA_API_EX astra_status_t astra_depthstream_get_registration(astra_depthstream_t depthStream,
83 bool* enabled);
84
88 ASTRA_API_EX astra_status_t astra_depthstream_set_registration(astra_depthstream_t depthStream,
89 bool enabled);
90
94 ASTRA_API_EX astra_status_t astra_depthstream_get_serialnumber(astra_depthstream_t depthStream,
95 char* serialnumber,
96 uint32_t length);
97
101 ASTRA_API_EX astra_status_t astra_depthstream_get_chip_id(astra_depthstream_t depthStream,
102 uint32_t* chipId);
103
107 ASTRA_API_EX astra_status_t astra_depthstream_get_usb_info(astra_depthstream_t depthStream,
108 astra_usb_info_t* usbInfo);
109
113 ASTRA_API_EX astra_status_t astra_frame_get_depthframe(astra_reader_frame_t readerFrame,
114 astra_depthframe_t* depthFrame);
115
119 ASTRA_API_EX astra_status_t astra_frame_get_depthframe_with_subtype(astra_reader_frame_t readerFrame,
120 astra_stream_subtype_t subtype,
121 astra_depthframe_t* colorFrame);
122
126 ASTRA_API_EX astra_status_t astra_depthframe_get_data_byte_length(astra_depthframe_t depthFrame,
127 uint32_t* byteLength);
128
132 ASTRA_API_EX astra_status_t astra_depthframe_get_data_ptr(astra_depthframe_t depthFrame,
133 int16_t** data,
134 uint32_t* byteLength);
135
139 ASTRA_API_EX astra_status_t astra_depthframe_copy_data(astra_depthframe_t depthFrame,
140 int16_t* data);
141
145 ASTRA_API_EX astra_status_t astra_depthframe_get_metadata(astra_depthframe_t depthFrame,
146 astra_image_metadata_t* metadata );
147
151 ASTRA_API_EX astra_status_t astra_depthframe_get_frameindex(astra_depthframe_t depthFrame,
152 astra_frame_index_t* index);
153
155 ASTRA_END_DECLS
156
157 #endif // DEPTH_CAPI_H
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra_usb_info_t
Definition: astra_ctypes.h:45
astra_image_metadata_t
Definition: image_types.h:55
astra_conversion_cache_t
Definition: depth_types.h:23


Astra SDK: depth_parameters.h Source File

  • include
  • astra
  • capi
  • streams
depth_parameters.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef DEPTH_PARAMETERS_H
18 #define DEPTH_PARAMETERS_H
19
20 enum
21 {
22 ASTRA_PARAMETER_DEPTH_CONVERSION_CACHE = 100,
23 ASTRA_PARAMETER_DEPTH_REGISTRATION = 101,
24 ASTRA_PARAMETER_DEPTH_SERIAL_NUMBER = 102,
25 ASTRA_PARAMETER_DEPTH_CHIP_ID = 103
26 };
27
28 #endif /* DEPTH_PARAMETERS_H */


Astra SDK: depth_types.h Source File

  • include
  • astra
  • capi
  • streams
depth_types.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef DEPTH_TYPES_H
18 #define DEPTH_TYPES_H
19
20 #include <astra_core/capi/astra_types.h>
21 #include <astra/capi/streams/image_types.h>
22
23 typedef struct {
24 float xzFactor;
25 float yzFactor;
26 float coeffX;
27 float coeffY;
28 int resolutionX;
29 int resolutionY;
30 int halfResX;
31 int halfResY;
32 } astra_conversion_cache_t;
33
34 typedef astra_streamconnection_t astra_depthstream_t;
35 typedef struct _astra_imageframe* astra_depthframe_t;
36
37 #endif // DEPTH_TYPES_H
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra_conversion_cache_t
Definition: depth_types.h:23


Astra SDK: Frame.hpp Source File

  • include
  • astra_core
Frame.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_FRAME_HPP
18 #define ASTRA_FRAME_HPP
19
20 #include <memory>
21 #include "capi/astra_core.h"
22
23 namespace astra {
24
31 class Frame
32 {
33 public:
40 Frame(astra_reader_frame_t readerFrame, const bool autoCloseFrame)
41 : frameRef_(std::make_shared<FrameRef>(readerFrame, autoCloseFrame))
42 { }
43
49 Frame(astra_reader_frame_t readerFrame)
50 : Frame(readerFrame, true)
51 { }
52
58 template<typename T>
59 T get()
60 {
61 return get<T>(DEFAULT_SUBTYPE);
62 }
63
70 template<typename T>
71 T get(astra_stream_subtype_t subtype)
72 {
73 return T::template acquire<T>(frameRef_->get_frame(), subtype);
74 }
75
81 bool is_valid()
82 {
83 return frameRef_->get_frame() != nullptr;
84 }
85
91 operator bool()
92 {
93 return is_valid();
94 }
95
96 private:
97 class FrameRef
98 {
99 public:
100 FrameRef(astra_reader_frame_t readerFrame, const bool autoCloseFrame)
101 : frame_(readerFrame),
102 autoCloseFrame_(autoCloseFrame)
103 { }
104
105 ~FrameRef()
106 {
107 if (frame_ != nullptr && autoCloseFrame_)
108 {
109 astra_reader_close_frame(&frame_);
110 }
111 }
112
113 astra_reader_frame_t get_frame() const { return frame_; }
114
115 private:
116 astra_reader_frame_t frame_;
117 const bool autoCloseFrame_;
118 };
119
120 std::shared_ptr<FrameRef> frameRef_;
121 };
122 }
123
124 #endif // ASTRA_FRAME_HPP
astra::Frame
Frame class.
Definition: Frame.hpp:31
astra::Frame::Frame
Frame(astra_reader_frame_t readerFrame)
constructs
Definition: Frame.hpp:49
astra
Definition: Array.hpp:20
astra::Frame::is_valid
bool is_valid()
get frame is valid
Definition: Frame.hpp:81
astra::Frame::Frame
Frame(astra_reader_frame_t readerFrame, const bool autoCloseFrame)
constructs
Definition: Frame.hpp:40
astra_reader_close_frame
ASTRA_API astra_status_t astra_reader_close_frame(astra_reader_frame_t *frame)
Close.


Astra SDK: FrameListener.hpp Source File

  • include
  • astra_core
FrameListener.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_FRAMELISTENER_HPP
18 #define ASTRA_FRAMELISTENER_HPP
19
20 namespace astra {
21
22 class StreamReader;
23 class Frame;
24
30 class FrameListener
31 {
32 public:
33 virtual ~FrameListener() = default;
34 virtual void on_frame_ready(StreamReader& reader, Frame& frame) = 0;
35 };
36
37 inline bool operator==(const FrameListener& l, const FrameListener& r)
38 {
39 return &l == &r;
40 }
41 }
42
43 #endif // ASTRA_FRAMELISTENER_HPP
astra::Frame
Frame class.
Definition: Frame.hpp:31
astra
Definition: Array.hpp:20
astra::operator==
bool operator==(const StreamDescription &lhs, const StreamDescription &rhs)
compare StreamDescription is equal
Definition: StreamDescription.hpp:94
astra::FrameListener
Frame Listener class.
Definition: FrameListener.hpp:30
astra::StreamReader
Stream Reader class.
Definition: StreamReader.hpp:37


Astra SDK: Hand.hpp Source File

  • include
  • astra
  • streams
Hand.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_HAND_HPP
18 #define ASTRA_HAND_HPP
19
20 #include <stdexcept>
21 #include <cstdint>
22 #include <astra_core/astra_core.hpp>
23 #include <astra/capi/astra_ctypes.h>
24 #include <astra/capi/streams/hand_capi.h>
25 #include <astra/Vector.hpp>
26
27 namespace astra {
28
35 class HandPoint : public astra_handpoint_t
36 {
37 public:
47 HandPoint(std::int32_t trackingId,
48 astra_handstatus_t status,
49 Vector2i depthPosition,
50 Vector3f worldPosition,
51 Vector3f worldDeltaPosition)
52 {
53 astra_handpoint_t::trackingId = trackingId;
54 astra_handpoint_t::status = status;
55 astra_handpoint_t::depthPosition = depthPosition;
56 astra_handpoint_t::worldPosition = worldPosition;
57 astra_handpoint_t::worldDeltaPosition = worldDeltaPosition;
58 }
59
65 HandPoint(const astra_handpoint_t& handPoint)
66 {
67 *this = handPoint;
68 }
69
75 HandPoint& operator=(const ::astra_handpoint_t& handPoint)
76 {
77 astra_handpoint_t::trackingId = handPoint.trackingId;
78 astra_handpoint_t::status = handPoint.status;
79 astra_handpoint_t::depthPosition = handPoint.depthPosition;
80 astra_handpoint_t::worldPosition = handPoint.worldPosition;
81 astra_handpoint_t::worldDeltaPosition = handPoint.worldDeltaPosition;
82
83 return *this;
84 }
85
91 inline operator ::astra_handpoint_t*() { return this; }
92
98 inline operator const ::astra_handpoint_t*() const { return this; }
99
105 inline std::int32_t tracking_id() const { return astra_handpoint_t::trackingId; }
106
112 inline astra_handstatus_t status() const { return astra_handpoint_t::status; }
113
119 inline Vector2i depth_position() const { return astra_handpoint_t::depthPosition; }
120
126 inline Vector3f world_position() const { return astra_handpoint_t::worldPosition; }
127
133 inline Vector3f world_delta_position() const { return astra_handpoint_t::worldDeltaPosition; }
134
135 private:
136 astra_handpoint_t handPoint_;
137 Vector2i depthPosition_;
138 Vector3f worldPosition_;
139 Vector3f worldDeltaPosition_;
140 };
141
148 class HandStream : public DataStream
149 {
150 public:
156 explicit HandStream(astra_streamconnection_t connection)
157 : DataStream(connection),
158 handStream_(connection)
159 { }
160
161 static const astra_stream_type_t id = ASTRA_STREAM_HAND;
162
168 bool get_include_candidate_points() const
169 {
170 bool includeCandidatePoints;
171 astra_handstream_get_include_candidate_points(handStream_, &includeCandidatePoints);
172 return includeCandidatePoints;
173 }
174
180 void set_include_candidate_points(bool includeCandidatePoints)
181 {
182 astra_handstream_set_include_candidate_points(handStream_, includeCandidatePoints);
183 }
184 private:
185 astra_handstream_t handStream_;
186 };
187
194 class HandFrame
195 {
196 public:
197 using HandPointList = std::vector<HandPoint>;
198
204 template<typename TFrameType>
205 static TFrameType acquire(astra_reader_frame_t readerFrame,
206 astra_stream_subtype_t subtype)
207 {
208 if (readerFrame != nullptr)
209 {
210 astra_handframe_t handFrame;
211 astra_frame_get_handframe_with_subtype(readerFrame, subtype, &handFrame);
212 return TFrameType(handFrame);
213 }
214
215 return TFrameType(nullptr);
216 }
217
223 HandFrame(astra_handframe_t handFrame)
224 {
225 handFrame_ = handFrame;
226 if (handFrame_)
227 {
228 astra_handframe_get_frameindex(handFrame_, &frameIndex_);
229
230 std::uint32_t maxHandCount;
231 astra_handframe_get_hand_count(handFrame_, &maxHandCount);
232
233 handPoints_.reserve(maxHandCount);
234 }
235 }
236
242 bool is_valid() const { return handFrame_ != nullptr; }
243
249 astra_handframe_t handle() const { return handFrame_; }
250
256 size_t handpoint_count() const
257 {
258 throw_if_invalid_frame();
259 verify_handpoints();
260
261 return handPoints_.size();
262 }
263
269 const HandPointList& handpoints() const
270 {
271 throw_if_invalid_frame();
272 verify_handpoints();
273 return handPoints_;
274 }
275
281 astra_frame_index_t frame_index() const
282 {
283 throw_if_invalid_frame();
284 return frameIndex_;
285 }
286
287 private:
288 void throw_if_invalid_frame() const
289 {
290 if (!handFrame_) { throw std::logic_error("Cannot operate on an invalid frame"); }
291 }
292
293 void verify_handpoints() const
294 {
295 if (handPointsInitialized_) { return; }
296 handPointsInitialized_ = true;
297
298 astra_handpoint_t* handPtr;
299 std::uint32_t maxHandCount;
300
301 astra_handframe_get_shared_hand_array(handFrame_, &handPtr, &maxHandCount);
302
303 for (size_t i = 0; i < maxHandCount; ++i, ++handPtr)
304 {
305 astra_handpoint_t& p = *handPtr;
306 if (p.status != astra_handstatus_t::HAND_STATUS_NOTTRACKING)
307 {
308 handPoints_.emplace_back(HandPoint(p));
309 }
310 }
311 }
312
313 // mutable for purposes of lazy computation
314 mutable bool handPointsInitialized_{false};
315 mutable HandPointList handPoints_;
316
317 astra_handframe_t handFrame_{nullptr};
318 astra_frame_index_t frameIndex_;
319 };
320 }
321
322 #endif /* ASTRA_HAND_HPP */
astra::HandPoint::tracking_id
std::int32_t tracking_id() const
get tracking id
Definition: Hand.hpp:105
astra::HandPoint::HandPoint
HandPoint(const astra_handpoint_t &handPoint)
constructs
Definition: Hand.hpp:65
astra::HandFrame
A Hand Data Frame.
Definition: Hand.hpp:194
_astra_streamconnection
Definition: astra_plugin.h:24
astra::HandPoint
Hand Point struct.
Definition: Hand.hpp:35
astra
Definition: Array.hpp:20
astra::HandStream::set_include_candidate_points
void set_include_candidate_points(bool includeCandidatePoints)
set is include candidate points
Definition: Hand.hpp:180
astra::HandFrame::handle
astra_handframe_t handle() const
get handle
Definition: Hand.hpp:249
astra::Vector2i
Represents a float 2d vector.
Definition: Vector2i.hpp:30
astra::HandPoint::depth_position
Vector2i depth_position() const
get depth position
Definition: Hand.hpp:119
astra::HandPoint::HandPoint
HandPoint(std::int32_t trackingId, astra_handstatus_t status, Vector2i depthPosition, Vector3f worldPosition, Vector3f worldDeltaPosition)
constructs
Definition: Hand.hpp:47
astra::HandPoint::world_delta_position
Vector3f world_delta_position() const
get world delta position
Definition: Hand.hpp:133
astra::HandPoint::operator=
HandPoint & operator=(const ::astra_handpoint_t &handPoint)
copy constructs
Definition: Hand.hpp:75
astra::HandFrame::handpoint_count
size_t handpoint_count() const
get hand Points count
Definition: Hand.hpp:256
astra::HandFrame::handpoints
const HandPointList & handpoints() const
get hand Points
Definition: Hand.hpp:269
_astra_handframe
Definition: stream_types.h:50
astra::HandStream::HandStream
HandStream(astra_streamconnection_t connection)
constructs
Definition: Hand.hpp:156
astra::HandPoint::status
astra_handstatus_t status() const
get status
Definition: Hand.hpp:112
astra::HandFrame::HandFrame
HandFrame(astra_handframe_t handFrame)
constructs
Definition: Hand.hpp:223
astra_handpoint_t
Definition: hand_types.h:48
astra::Vector3f
Represents a float 3d vector.
Definition: Vector3f.hpp:29
astra::HandFrame::frame_index
astra_frame_index_t frame_index() const
get frame index
Definition: Hand.hpp:281
astra::HandFrame::is_valid
bool is_valid() const
get is valid
Definition: Hand.hpp:242
astra::HandPoint::world_position
Vector3f world_position() const
get world position
Definition: Hand.hpp:126
astra::DataStream
Data Stream.
Definition: DataStream.hpp:32
astra::HandStream
A Hand Stream.
Definition: Hand.hpp:148
astra::HandFrame::acquire
static TFrameType acquire(astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype)
set is include candidate points
Definition: Hand.hpp:205
astra::HandStream::get_include_candidate_points
bool get_include_candidate_points() const
get is include candidate points
Definition: Hand.hpp:168


Astra SDK: hand_capi.h Source File

  • include
  • astra
  • capi
  • streams
hand_capi.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef HAND_CAPI_H
18 #define HAND_CAPI_H
19
20 #include <astra_core/capi/astra_defines.h>
21 #include <astra_core/capi/astra_types.h>
22 #include "hand_types.h"
23 #include <stdbool.h>
24
25 ASTRA_BEGIN_DECLS
26
32 ASTRA_API_EX astra_status_t astra_reader_get_handstream(astra_reader_t reader,
33 astra_handstream_t* handStream);
34
35 ASTRA_API_EX astra_status_t astra_handstream_is_available(astra_handstream_t handStream,
36 bool* isAvailable);
37
38 ASTRA_API_EX astra_status_t astra_frame_get_handframe(astra_reader_frame_t readerFrame,
39 astra_handframe_t* handFrame);
40
41 ASTRA_API_EX astra_status_t astra_frame_get_handframe_with_subtype(astra_reader_frame_t readerFrame,
42 astra_stream_subtype_t subtype,
43 astra_handframe_t* handFrame);
44 ASTRA_API_EX astra_status_t astra_handframe_get_frameindex(astra_handframe_t handFrame,
45 astra_frame_index_t* index);
46
47 ASTRA_API_EX astra_status_t astra_handframe_get_hand_count(astra_handframe_t handFrame,
48 uint32_t* handCount);
49
50 ASTRA_API_EX astra_status_t astra_handframe_copy_hands(astra_handframe_t handFrame,
51 astra_handpoint_t* handPointsDestination);
52
53 ASTRA_API_EX astra_status_t astra_handframe_get_shared_hand_array(astra_handframe_t handFrame,
54 astra_handpoint_t** handpoints,
55 uint32_t* handCount);
56
57 ASTRA_API_EX astra_status_t astra_handstream_get_include_candidate_points(astra_handstream_t handStream,
58 bool* includeCandidatePoints);
59
60 ASTRA_API_EX astra_status_t astra_handstream_set_include_candidate_points(astra_handstream_t handStream,
61 bool includeCandidatePoints);
62
63 ASTRA_API_EX astra_status_t astra_reader_get_debug_handstream(astra_reader_t reader,
64 astra_debug_handstream_t* debugHandStream);
65
66 ASTRA_API_EX astra_status_t astra_frame_get_debug_handframe(astra_reader_frame_t readerFrame,
67 astra_debug_handframe_t* debugHandFrame);
68
69 ASTRA_API_EX astra_status_t astra_debug_handstream_get_view_type(astra_debug_handstream_t debugHandStream,
70 astra_debug_hand_view_type_t* viewType);
71
72 ASTRA_API_EX astra_status_t astra_debug_handstream_set_view_type(astra_debug_handstream_t debugHandStream,
73 astra_debug_hand_view_type_t viewType);
74
75 ASTRA_API_EX astra_status_t astra_debug_handstream_set_mouse_position(astra_debug_handstream_t debugHandStream,
76 astra_vector2f_t normPosition);
77
78 ASTRA_API_EX astra_status_t astra_debug_handstream_set_use_mouse_probe(astra_debug_handstream_t debugHandStream,
79 bool useMouseProbe);
80
81 ASTRA_API_EX astra_status_t astra_debug_handstream_set_pause_input(astra_debug_handstream_t debugHandStream,
82 bool pauseInput);
83
84 ASTRA_API_EX astra_status_t astra_debug_handstream_set_lock_spawn_point(astra_debug_handstream_t debugHandStream,
85 bool lockSpawnPoint);
86
88 ASTRA_END_DECLS
89
90 #endif // HAND_CAPI_H
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
_astra_handframe
Definition: stream_types.h:50
astra_handpoint_t
Definition: hand_types.h:48
astra_vector2f_t
Definition: astra_ctypes.h:28


Astra SDK: hand_parameters.h Source File

  • include
  • astra
  • capi
  • streams
hand_parameters.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef HAND_PARAMETERS_H
18 #define HAND_PARAMETERS_H
19
20 enum
21 {
22 ASTRA_PARAMETER_DEBUG_HAND_VIEW_TYPE = 0,
23 ASTRA_PARAMETER_DEBUG_HAND_USE_MOUSE_PROBE = 1,
24 ASTRA_PARAMETER_DEBUG_HAND_MOUSE_NORM_POSITION = 2,
25 ASTRA_PARAMETER_HAND_INCLUDE_CANDIDATE_POINTS = 3,
26 ASTRA_PARAMETER_DEBUG_HAND_PAUSE_INPUT = 4,
27 ASTRA_PARAMETER_DEBUG_HAND_LOCK_SPAWN_POINT = 5,
28 };
29
30 #endif /* HAND_PARAMETERS_H */


Astra SDK: hand_types.h Source File

  • include
  • astra
  • capi
  • streams
hand_types.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef HAND_TYPES_H
18 #define HAND_TYPES_H
19
20 #include <astra_core/capi/astra_types.h>
21 #include <astra/capi/astra_ctypes.h>
22
23 #define ASTRA_HANDS_MAX_HAND_COUNT 10
24
25 typedef enum {
26 DEBUG_HAND_VIEW_DEPTH,
27 DEBUG_HAND_VIEW_VELOCITY,
28 DEBUG_HAND_VIEW_FILTEREDVELOCITY,
29 DEBUG_HAND_VIEW_UPDATE_SEGMENTATION,
30 DEBUG_HAND_VIEW_CREATE_SEGMENTATION,
31 DEBUG_HAND_VIEW_UPDATE_SEARCHED,
32 DEBUG_HAND_VIEW_CREATE_SEARCHED,
33 DEBUG_HAND_VIEW_CREATE_SCORE,
34 DEBUG_HAND_VIEW_UPDATE_SCORE,
35 DEBUG_HAND_VIEW_HANDWINDOW,
36 DEBUG_HAND_VIEW_DEPTH_MOD,
37 DEBUG_HAND_VIEW_DEPTH_AVG,
38 DEBUG_HAND_VIEW_TEST_PASS_MAP,
39 } astra_debug_hand_view_type_t;
40
41 typedef enum {
42 HAND_STATUS_NOTTRACKING,
43 HAND_STATUS_CANDIDATE,
44 HAND_STATUS_TRACKING,
45 HAND_STATUS_LOST
46 } astra_handstatus_t;
47
48 typedef struct {
49 int32_t trackingId;
50 astra_handstatus_t status;
51 astra_vector2i_t depthPosition;
52 astra_vector3f_t worldPosition;
53 astra_vector3f_t worldDeltaPosition;
54 } astra_handpoint_t;
55
56 typedef struct _astra_handframe* astra_handframe_t;
57 typedef astra_streamconnection_t astra_handstream_t;
58
59 typedef struct _astra_imageframe* astra_debug_handframe_t;
60 typedef astra_streamconnection_t astra_debug_handstream_t;
61
62 #endif // HAND_TYPES_H
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra_vector3f_t
Definition: astra_ctypes.h:33
_astra_handframe
Definition: stream_types.h:50
astra_handpoint_t
Definition: hand_types.h:48
astra_vector2i_t
Definition: astra_ctypes.h:23


Astra SDK: Image.hpp Source File

  • include
  • astra
  • streams
Image.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_IMAGE_HPP
18 #define ASTRA_IMAGE_HPP
19
20 #include <stdexcept>
21 #include <iostream>
22 #include <cstdint>
23 #include <astra_core/astra_core.hpp>
24 #include <astra/capi/astra_ctypes.h>
25 #include <astra/capi/streams/image_capi.h>
26
27 namespace astra {
28
33 struct RgbPixel : public astra_rgb_pixel_t
34 {
38 RgbPixel()
39 : RgbPixel(0, 0, 0)
40 {}
41
49 RgbPixel(std::uint8_t r, std::uint8_t g, std::uint8_t b)
50 {
51 ::astra_rgb_pixel_t::r = r;
52 ::astra_rgb_pixel_t::g = g;
53 ::astra_rgb_pixel_t::b = b;
54 }
55 };
56
61 struct RgbaPixel : public astra_rgba_pixel_t
62 {
66 RgbaPixel()
67 : RgbaPixel(0, 0,0,0)
68 {}
69
78 RgbaPixel(std::uint8_t r, std::uint8_t g, std::uint8_t b, std::uint8_t alpha)
79 {
80 ::astra_rgba_pixel_t::r = r;
81 ::astra_rgba_pixel_t::g = g;
82 ::astra_rgba_pixel_t::b = b;
83 ::astra_rgba_pixel_t::alpha = alpha;
84 }
85 };
86
87 // DEPRECATED
88 typedef RgbaPixel RGBAPixel;
89
94 class ImageStreamMode : private ::astra_imagestream_mode_t
95 {
96 public:
100 ImageStreamMode()
101 : ImageStreamMode(0, 0, 0, ASTRA_PIXEL_FORMAT_UNKNOWN)
102 {}
103
112 ImageStreamMode(std::uint32_t width, std::uint32_t height, std::uint8_t fps, astra_pixel_format_t format)
113 {
114 set_width(width);
115 set_height(height);
116 set_fps(fps);
117 set_pixel_format(format);
118 }
119
125 ImageStreamMode(const ::astra_imagestream_mode_t& mode)
126 {
127 *this = mode;
128 }
129
135 ImageStreamMode& operator=(const ::astra_imagestream_mode_t& mode)
136 {
137 set_width(mode.width);
138 set_height(mode.height);
139 set_fps(mode.fps);
140 set_pixel_format(mode.pixelFormat);
141
142 return *this;
143 }
144
145 operator ::astra_imagestream_mode_t*() { return this; }
146 operator const ::astra_imagestream_mode_t*() const { return this; }
147
153 std::uint8_t fps() const { return astra_imagestream_mode_t::fps; }
154
160 void set_fps(std::uint8_t fps) { astra_imagestream_mode_t::fps = fps; }
161
167 const std::uint8_t bytes_per_pixel() const
168 {
169 std::uint8_t bpp;
170 astra_pixelformat_get_bytes_per_pixel(pixel_format(), &bpp);
171 return bpp;
172 }
173
179 std::uint32_t width() const { return astra_imagestream_mode_t::width; }
180
186 void set_width(std::uint32_t width) { astra_imagestream_mode_t::width = width; }
187
193 std::uint32_t height() const { return astra_imagestream_mode_t::height; }
194
200 void set_height(std::uint32_t height) { astra_imagestream_mode_t::height = height; }
201
207 astra_pixel_format_t pixel_format() const { return astra_imagestream_mode_t::pixelFormat; }
208
214 void set_pixel_format(astra_pixel_format_t format) { astra_imagestream_mode_t::pixelFormat = format; }
215
216 friend std::ostream& operator<<(std::ostream& os, const ImageStreamMode& ism);
217 };
218
226 inline bool operator==(const ImageStreamMode& lhs, const ImageStreamMode& rhs)
227 {
228 return
229 lhs.width() == rhs.width() &&
230 lhs.height() == rhs.height() &&
231 lhs.pixel_format() == rhs.pixel_format() &&
232 lhs.fps() == rhs.fps() &&
233 lhs.bytes_per_pixel() && rhs.bytes_per_pixel();
234 }
235
243 inline bool operator!=(const ImageStreamMode& lhs, const ImageStreamMode& rhs)
244 {
245 return !(lhs == rhs);
246 }
247
248 inline std::ostream& operator<<(std::ostream& os, const ImageStreamMode& ism)
249 {
250 os << ism.width()
251 << "x"
252 << ism.height()
253 << "x"
254 << static_cast<int>(ism.bytes_per_pixel())
255 << "@"
256 << static_cast<int>(ism.fps())
257 << " pf:"
258 << ism.pixel_format();
259
260 return os;
261 }
262
267 class ImageStream : public DataStream
268 {
269 public:
270 explicit ImageStream(astra_streamconnection_t connection)
271 : DataStream(connection),
272 imageStream_(reinterpret_cast<astra_imagestream_t>(connection))
273 {}
274
280 float hFov() const
281 {
282 float hFov = 0.0f;
283 astra_imagestream_get_hfov(imageStream_, &hFov);
284
285 return hFov;
286 }
287
293 float vFov() const
294 {
295 float vFov = 0.0f;
296 astra_imagestream_get_vfov(imageStream_, &vFov);
297
298 return vFov;
299 }
300
306 astra_usb_info_t usb_info()const
307 {
308 astra_usb_info_t usbInfo;
309 astra_imagestream_get_usb_info(imageStream_, &usbInfo);
310 return usbInfo;
311 }
312
318 bool mirroring_enabled() const
319 {
320 bool mirroring = false;
321 astra_imagestream_get_mirroring(imageStream_, &mirroring);
322
323 return mirroring;
324 }
325
331 void enable_mirroring(bool mirroring)
332 {
333 astra_imagestream_set_mirroring(imageStream_, mirroring);
334 }
335
341 std::vector<ImageStreamMode> available_modes() const
342 {
343 astra_result_token_t token;
344 std::uint32_t count = 0;
345 astra_imagestream_request_modes(imageStream_, &token, &count);
346
347 std::vector<ImageStreamMode> result;
348 result.resize(count);
349
350 astra_imagestream_get_modes_result(imageStream_,
351 token,
352 reinterpret_cast<astra_imagestream_mode_t*>(&result[0]),
353 count);
354
355 return result;
356 }
357
363 ImageStreamMode mode() const
364 {
365 ImageStreamMode mode;
366 astra_imagestream_mode_t* cMode = mode;
367 astra_imagestream_get_mode(imageStream_, cMode);
368 return mode;
369 }
370
376 void set_mode(const ImageStreamMode& mode)
377 {
378 const astra_imagestream_mode_t* cMode = mode;
379 astra_imagestream_set_mode(imageStream_, cMode);
380 }
381
382 private:
383 astra_imagestream_t imageStream_;
384 };
385
386
391 template<typename TDataType, astra_stream_type_t TStreamType>
392 class ImageFrame
393 {
394 public:
401 ImageFrame(astra_imageframe_t frame, astra_pixel_format_t expected_format)
402 {
403 imageFrame_ = frame;
404 if (imageFrame_)
405 {
406 astra_imageframe_get_metadata(imageFrame_, &metadata_);
407 if (metadata_.pixelFormat != expected_format)
408 {
409 //wrong format -- this must be an invalid frame
410 imageFrame_ = nullptr;
411 return;
412 }
413
414 astra_imageframe_get_frameindex(imageFrame_, &frameIndex_);
415
416 void* voidData = nullptr;
417 astra_imageframe_get_data_ptr(imageFrame_, &voidData, &byteLength_);
418 dataPtr_ = static_cast<TDataType*>(voidData);
419 }
420 }
421
427 const bool is_valid() const { return imageFrame_ != nullptr; }
428
434 const int width() const { throw_if_invalid_frame(); return metadata_.width; }
435
441 const int height() const { throw_if_invalid_frame(); return metadata_.height; }
442
448 const std::uint8_t bytes_per_pixel() const
449 {
450 throw_if_invalid_frame();
451
452 std::uint8_t bpp;
453 astra_pixelformat_get_bytes_per_pixel(metadata_.pixelFormat, &bpp);
454 return bpp;
455 }
456
462 const astra_frame_index_t frame_index() const { throw_if_invalid_frame(); return frameIndex_; }
463
469 const astra_imageframe_t handle() const { return imageFrame_; }
470
476 static astra_stream_type_t stream_type() { return TStreamType; }
477
483 const TDataType* data() const { throw_if_invalid_frame(); return dataPtr_; }
484
490 const size_t byte_length() const { throw_if_invalid_frame(); return byteLength_; }
491
497 const size_t length() const { throw_if_invalid_frame(); return metadata_.width * metadata_.height; }
498
504 void copy_to(TDataType* buffer) const
505 {
506 throw_if_invalid_frame();
507 astra_imageframe_copy_data(imageFrame_, buffer);
508 }
509
515 template<typename TFrameType>
516 static TFrameType acquire(astra_reader_frame_t readerFrame,
517 astra_stream_subtype_t subtype)
518 {
519 if (readerFrame != nullptr)
520 {
521 astra_imageframe_t imageFrame;
522 astra_reader_get_imageframe(readerFrame, TStreamType, subtype, &imageFrame);
523
524 return TFrameType(imageFrame);
525 }
526
527 return TFrameType(nullptr);
528 }
529
530 private:
531 void throw_if_invalid_frame() const
532 {
533 if (!imageFrame_) { throw std::logic_error("Cannot operate on an invalid frame"); }
534 }
535
536 astra_imageframe_t imageFrame_{nullptr};
537 astra_image_metadata_t metadata_;
538 astra_frame_index_t frameIndex_;
539
540 TDataType* dataPtr_;
541 std::uint32_t byteLength_;
542 };
543 }
544
545 #endif // ASTRA_IMAGE_HPP
astra::ImageFrame::stream_type
static astra_stream_type_t stream_type()
get stream type
Definition: Image.hpp:476
astra::ImageFrame::bytes_per_pixel
const std::uint8_t bytes_per_pixel() const
get bytes per pixel
Definition: Image.hpp:448
astra::ImageFrame::width
const int width() const
get width
Definition: Image.hpp:434
astra::RgbaPixel::RgbaPixel
RgbaPixel()
Default constructs all zero.
Definition: Image.hpp:66
astra::ImageFrame::length
const size_t length() const
get length
Definition: Image.hpp:497
astra::ImageFrame::acquire
static TFrameType acquire(astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype)
acquire frame
Definition: Image.hpp:516
astra::ImageFrame
Basic Image Frame.
Definition: Image.hpp:392
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra::ImageFrame::data
const TDataType * data() const
get data pointer
Definition: Image.hpp:483
astra
Definition: Array.hpp:20
astra::ImageStream::hFov
float hFov() const
get horizontal fov
Definition: Image.hpp:280
astra::operator==
bool operator==(const StreamDescription &lhs, const StreamDescription &rhs)
compare StreamDescription is equal
Definition: StreamDescription.hpp:94
astra::ImageStream::set_mode
void set_mode(const ImageStreamMode &mode)
set current image mode
Definition: Image.hpp:376
astra::RgbaPixel
rgba pixel struct
Definition: Image.hpp:61
astra_usb_info_t
Definition: astra_ctypes.h:45
astra::ImageStreamMode::set_pixel_format
void set_pixel_format(astra_pixel_format_t format)
set fps
Definition: Image.hpp:214
astra::ImageFrame::copy_to
void copy_to(TDataType *buffer) const
copy to buffer
Definition: Image.hpp:504
astra::ImageFrame::height
const int height() const
get height
Definition: Image.hpp:441
astra::ImageFrame::byte_length
const size_t byte_length() const
get byte length
Definition: Image.hpp:490
astra::ImageStream::mode
ImageStreamMode mode() const
get current image mode
Definition: Image.hpp:363
astra::ImageStreamMode::fps
std::uint8_t fps() const
get fps
Definition: Image.hpp:153
astra::ImageStreamMode::height
std::uint32_t height() const
get height
Definition: Image.hpp:193
astra::ImageStreamMode
Image Stream Mode.
Definition: Image.hpp:94
astra::ImageStreamMode::ImageStreamMode
ImageStreamMode(std::uint32_t width, std::uint32_t height, std::uint8_t fps, astra_pixel_format_t format)
constructs
Definition: Image.hpp:112
astra::ImageStream
basic Image Stream
Definition: Image.hpp:267
astra::ImageFrame::frame_index
const astra_frame_index_t frame_index() const
get frame index
Definition: Image.hpp:462
astra::ImageStreamMode::ImageStreamMode
ImageStreamMode(const ::astra_imagestream_mode_t &mode)
copy constructs
Definition: Image.hpp:125
astra::ImageStream::vFov
float vFov() const
get vertical fov
Definition: Image.hpp:293
astra_image_metadata_t
Definition: image_types.h:55
astra::operator!=
bool operator!=(const StreamDescription &lhs, const StreamDescription &rhs)
compare StreamDescription is not equal
Definition: StreamDescription.hpp:105
astra::RgbaPixel::RgbaPixel
RgbaPixel(std::uint8_t r, std::uint8_t g, std::uint8_t b, std::uint8_t alpha)
constructs
Definition: Image.hpp:78
astra::ImageStreamMode::operator=
ImageStreamMode & operator=(const ::astra_imagestream_mode_t &mode)
copy constructs
Definition: Image.hpp:135
astra::ImageStreamMode::set_width
void set_width(std::uint32_t width)
set width
Definition: Image.hpp:186
astra::RgbPixel::RgbPixel
RgbPixel()
Default constructs all zero.
Definition: Image.hpp:38
astra::ImageStreamMode::bytes_per_pixel
const std::uint8_t bytes_per_pixel() const
get bytes per pixel
Definition: Image.hpp:167
astra::RgbPixel
rgb pixel struct
Definition: Image.hpp:33
astra::ImageFrame::handle
const astra_imageframe_t handle() const
get handle
Definition: Image.hpp:469
astra::ImageStream::usb_info
astra_usb_info_t usb_info() const
get usb_info
Definition: Image.hpp:306
astra::RgbPixel::RgbPixel
RgbPixel(std::uint8_t r, std::uint8_t g, std::uint8_t b)
constructs
Definition: Image.hpp:49
astra::ImageStreamMode::set_height
void set_height(std::uint32_t height)
set height
Definition: Image.hpp:200
astra::DataStream
Data Stream.
Definition: DataStream.hpp:32
astra_rgba_pixel_t
Definition: image_types.h:47
astra::ImageStreamMode::pixel_format
astra_pixel_format_t pixel_format() const
get height
Definition: Image.hpp:207
astra::ImageStreamMode::ImageStreamMode
ImageStreamMode()
Default constructs.
Definition: Image.hpp:100
astra::ImageStreamMode::width
std::uint32_t width() const
get width
Definition: Image.hpp:179
astra_rgb_pixel_t
Definition: image_types.h:41
astra::ImageStream::mirroring_enabled
bool mirroring_enabled() const
get is mirroring
Definition: Image.hpp:318
astra::ImageStream::available_modes
std::vector< ImageStreamMode > available_modes() const
get available_modes
Definition: Image.hpp:341
astra::ImageFrame::ImageFrame
ImageFrame(astra_imageframe_t frame, astra_pixel_format_t expected_format)
Default constructs.
Definition: Image.hpp:401
astra::ImageStream::enable_mirroring
void enable_mirroring(bool mirroring)
enable mirroring
Definition: Image.hpp:331
astra::ImageStreamMode::set_fps
void set_fps(std::uint8_t fps)
set fps
Definition: Image.hpp:160
astra::ImageFrame::is_valid
const bool is_valid() const
get is vaild
Definition: Image.hpp:427
astra_imagestream_mode_t
Definition: image_types.h:61


Astra SDK: image_capi.h Source File

  • include
  • astra
  • capi
  • streams
image_capi.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef IMAGE_CAPI_H
18 #define IMAGE_CAPI_H
19
20 #include <astra_core/capi/astra_defines.h>
21 #include <astra_core/capi/astra_types.h>
22 #include <astra/capi/streams/image_types.h>
23 #include <astra/capi/astra_ctypes.h>
24 #include <stdbool.h>
25
26 ASTRA_BEGIN_DECLS
27
33 ASTRA_API_EX astra_status_t astra_imagestream_get_mirroring(astra_imagestream_t imageStream,
34 bool* mirroring);
35
36 ASTRA_API_EX astra_status_t astra_imagestream_set_mirroring(astra_imagestream_t imageStream,
37 bool mirroring);
38
39 ASTRA_API_EX astra_status_t astra_imagestream_get_hfov(astra_imagestream_t imageStream,
40 float* hFov);
41
42 ASTRA_API_EX astra_status_t astra_imagestream_get_vfov(astra_imagestream_t imageStream,
43 float* vFov);
44
45
46 ASTRA_API_EX astra_status_t astra_imagestream_get_usb_info(astra_imagestream_t imageStream,
47 astra_usb_info_t* usbInfo);
48
49 ASTRA_API_EX astra_status_t astra_imagestream_request_modes(astra_imagestream_t imageStream,
50 astra_result_token_t* token,
51 uint32_t* count);
52
53 ASTRA_API_EX astra_status_t astra_imagestream_get_modes_result(astra_imagestream_t imageStream,
54 astra_result_token_t token,
55 astra_imagestream_mode_t* modes,
56 uint32_t count);
57
58 ASTRA_API_EX astra_status_t astra_imagestream_get_mode(astra_imagestream_t imageStream,
59 astra_imagestream_mode_t* mode);
60
61 ASTRA_API_EX astra_status_t astra_imagestream_set_mode(astra_imagestream_t imageStream,
62 const astra_imagestream_mode_t* mode);
63
64 ASTRA_API_EX astra_status_t astra_reader_get_imageframe(astra_reader_frame_t readerFrame,
65 astra_stream_type_t type,
66 astra_stream_subtype_t subtype,
67 astra_imageframe_t* imageFrame);
68
69 ASTRA_API_EX astra_status_t astra_imageframe_get_stream(astra_imageframe_t imageFrame,
70 astra_streamconnection_t* stream);
71
72 ASTRA_API_EX astra_status_t astra_imageframe_get_frameindex(astra_imageframe_t imageFrame,
73 astra_frame_index_t* index);
74
75 ASTRA_API_EX astra_status_t astra_imageframe_get_data_byte_length(astra_imageframe_t imageFrame,
76 uint32_t* byteLength);
77
78 ASTRA_API_EX astra_status_t astra_imageframe_get_data_ptr(astra_imageframe_t imageFrame,
79 void** data,
80 uint32_t* byteLength);
81
82 ASTRA_API_EX astra_status_t astra_imageframe_copy_data(astra_imageframe_t imageFrame,
83 void* data);
84
85 ASTRA_API_EX astra_status_t astra_imageframe_get_metadata(astra_imageframe_t imageFrame,
86 astra_image_metadata_t* metadata);
87
88 ASTRA_API_EX void astra_pixelformat_get_bytes_per_pixel(astra_pixel_format_t format,
89 uint8_t* bpp);
92 ASTRA_END_DECLS
93
94 #endif // IMAGE_CAPI_H
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra_usb_info_t
Definition: astra_ctypes.h:45
astra_image_metadata_t
Definition: image_types.h:55
astra_imagestream_mode_t
Definition: image_types.h:61


Astra SDK: image_parameters.h Source File

  • include
  • astra
  • capi
  • streams
image_parameters.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef IMAGE_PARAMETERS_H
18 #define IMAGE_PARAMETERS_H
19
20 enum {
21 ASTRA_PARAMETER_IMAGE_HFOV = 0,
22 ASTRA_PARAMETER_IMAGE_VFOV = 1,
23 ASTRA_PARAMETER_IMAGE_MIRRORING = 2,
24 ASTRA_PARAMETER_IMAGE_AVAILABLE_MODES = 3,
25 ASTRA_PARAMETER_IMAGE_MODE = 4,
26 ASTRA_PARAMETER_IMAGE_USB_INFO = 5
27 };
28
29 #endif /* IMAGE_PARAMETERS_H */


Astra SDK: image_types.h Source File

  • include
  • astra
  • capi
  • streams
image_types.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef IMAGE_TYPES_H
18 #define IMAGE_TYPES_H
19
20 #include <stdint.h>
21 #include <astra_core/capi/astra_types.h>
22
23 typedef uint32_t astra_pixel_format_t;
24
25 typedef enum {
26 ASTRA_PIXEL_FORMAT_UNKNOWN = 0,
27 ASTRA_PIXEL_FORMAT_DEPTH_MM = 100,
28
29 // color layouts
30 ASTRA_PIXEL_FORMAT_RGB888 = 200,
31 ASTRA_PIXEL_FORMAT_YUV422 = 201,
32 ASTRA_PIXEL_FORMAT_YUYV = 202,
33 ASTRA_PIXEL_FORMAT_RGBA = 203,
34 ASTRA_PIXEL_FORMAT_GRAY8 = 300,
35 ASTRA_PIXEL_FORMAT_GRAY16 = 301,
36
37 ASTRA_PIXEL_FORMAT_POINT = 400,
38
39 } astra_pixel_formats;
40
41 typedef struct {
42 uint8_t r;
43 uint8_t g;
44 uint8_t b;
45 } astra_rgb_pixel_t;
46
47 typedef struct {
48 uint8_t r;
49 uint8_t g;
50 uint8_t b;
51 uint8_t alpha;
52 } astra_rgba_pixel_t;
53
54
55 typedef struct {
56 uint32_t width;
57 uint32_t height;
58 astra_pixel_format_t pixelFormat;
59 } astra_image_metadata_t;
60
61 typedef struct {
62 uint32_t id;
63 uint32_t width;
64 uint32_t height;
65 astra_pixel_format_t pixelFormat;
66 uint8_t fps;
67 } astra_imagestream_mode_t;
68
69 typedef struct _astra_imageframe* astra_imageframe_t;
70 typedef astra_streamconnection_t astra_imagestream_t;
71
72 #endif // IMAGE_TYPES_H
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra_image_metadata_t
Definition: image_types.h:55
astra_rgba_pixel_t
Definition: image_types.h:47
astra_rgb_pixel_t
Definition: image_types.h:41
astra_imagestream_mode_t
Definition: image_types.h:61


Astra SDK: Infrared.hpp Source File

  • include
  • astra
  • streams
Infrared.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_INFRARED_HPP
18 #define ASTRA_INFRARED_HPP
19
20 #include <astra_core/astra_core.hpp>
21 #include <astra/capi/astra_ctypes.h>
22 #include <astra/capi/streams/infrared_capi.h>
23 #include <astra/streams/Image.hpp>
24 #include <astra/Vector.hpp>
25
26 namespace astra {
27
34 class InfraredStream : public ImageStream
35 {
36 public:
37 explicit InfraredStream(astra_streamconnection_t connection)
38 : ImageStream(connection)
39 { }
40
41 static const astra_stream_type_t id = ASTRA_STREAM_INFRARED;
42 };
43
50 class InfraredFrame16 : public ImageFrame<uint16_t, ASTRA_STREAM_INFRARED>
51 {
52 public:
53 InfraredFrame16(astra_imageframe_t frame)
54 : ImageFrame(frame, ASTRA_PIXEL_FORMAT_GRAY16)
55 {}
56 };
57
64 class InfraredFrameRgb : public ImageFrame<RgbPixel, ASTRA_STREAM_INFRARED>
65 {
66 public:
67 InfraredFrameRgb(astra_imageframe_t frame)
68 : ImageFrame(frame, ASTRA_PIXEL_FORMAT_RGB888)
69 {}
70 };
71
72 }
73
74 #endif /* ASTRA_INFRARED_HPP */
astra::ImageFrame
Basic Image Frame.
Definition: Image.hpp:392
astra::InfraredFrame16
A Infrared Frame use 16bit unsigned short format.
Definition: Infrared.hpp:50
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra
Definition: Array.hpp:20
astra::ImageStream
basic Image Stream
Definition: Image.hpp:267
astra::InfraredFrameRgb
A Infrared Frame use rgb format.
Definition: Infrared.hpp:64
astra::InfraredStream
A Infrared Stream.
Definition: Infrared.hpp:34


Astra SDK: infrared_capi.h Source File

  • include
  • astra
  • capi
  • streams
infrared_capi.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef INFRARED_CAPI_H
18 #define INFRARED_CAPI_H
19
20 #include <astra_core/capi/astra_defines.h>
21 #include <astra_core/capi/astra_types.h>
22 #include <astra/capi/streams/infrared_types.h>
23 #include <stdbool.h>
24
25 ASTRA_BEGIN_DECLS
26
32 ASTRA_API_EX astra_status_t astra_reader_get_infraredstream(astra_reader_t reader,
33 astra_infraredstream_t* infraredstream);
34
35 ASTRA_API_EX astra_status_t astra_infraredstream_is_available(astra_infraredstream_t infraredStream,
36 bool* isAvailable);
37
38 ASTRA_API_EX astra_status_t astra_infraredstream_get_hfov(astra_infraredstream_t infraredstream,
39 float* hFov);
40
41 ASTRA_API_EX astra_status_t astra_infraredstream_get_vfov(astra_infraredstream_t infraredstream,
42 float* vFov);
43
44 ASTRA_API_EX astra_status_t astra_infraredstream_get_usb_info(astra_infraredstream_t infraredStream,
45 astra_usb_info_t* usbInfo);
46
47 ASTRA_API_EX astra_status_t astra_frame_get_infraredframe(astra_reader_frame_t readerFrame,
48 astra_infraredframe_t* infraredframe);
49
50 ASTRA_API_EX astra_status_t astra_frame_get_infraredframe_with_subtype(astra_reader_frame_t readerFrame,
51 astra_stream_subtype_t subtype,
52 astra_infraredframe_t* colorFrame);
53
54 ASTRA_API_EX astra_status_t astra_infraredframe_get_data_byte_length(astra_infraredframe_t infraredframe,
55 uint32_t* byteLength);
56
57 ASTRA_API_EX astra_status_t astra_infraredframe_get_data_ptr(astra_infraredframe_t infraredframe,
58 uint8_t** data,
59 uint32_t* byteLength);
60
61 ASTRA_API_EX astra_status_t astra_infraredframe_copy_data(astra_infraredframe_t infraredframe,
62 uint8_t* data);
63
64 ASTRA_API_EX astra_status_t astra_infraredframe_get_metadata(astra_infraredframe_t infraredframe,
65 astra_image_metadata_t* metadata );
66
67 ASTRA_API_EX astra_status_t astra_infraredframe_get_frameindex(astra_infraredframe_t infraredframe,
68 astra_frame_index_t* index);
71 ASTRA_END_DECLS
72
73
74 #endif /* INFRARED_CAPI_H */
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra_usb_info_t
Definition: astra_ctypes.h:45
astra_image_metadata_t
Definition: image_types.h:55


Astra SDK: infrared_types.h Source File

  • include
  • astra
  • capi
  • streams
infrared_types.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef INFRARED_TYPES_H
18 #define INFRARED_TYPES_H
19
20 #include <astra_core/capi/astra_types.h>
21 #include <astra/capi/streams/image_types.h>
22
23 typedef astra_streamconnection_t astra_infraredstream_t;
24 typedef struct _astra_imageframe* astra_infraredframe_t;
25
26 #endif /* INFRARED_TYPES_H */
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37


Astra SDK: masked_color_capi.h Source File

  • include
  • astra
  • capi
  • streams
masked_color_capi.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef MASKED_COLOR_CAPI_H
18 #define MASKED_COLOR_CAPI_H
19
20 #include <astra_core/capi/astra_types.h>
21 #include "masked_color_types.h"
22
23 ASTRA_BEGIN_DECLS
24
30 ASTRA_API_EX astra_status_t astra_reader_get_maskedcolorstream(astra_reader_t reader,
31 astra_maskedcolorstream_t* maskedcolorStream);
32
33 ASTRA_API_EX astra_status_t astra_maskedcolorstream_is_available(astra_maskedcolorstream_t maskedcolorStream,
34 bool* isAvailable);
35
36 ASTRA_API_EX astra_status_t astra_frame_get_maskedcolorframe(astra_reader_frame_t readerFrame,
37 astra_maskedcolorframe_t* maskedcolorFrame);
38
39 ASTRA_API_EX astra_status_t astra_frame_get_maskedcolorframe_with_subtype(astra_reader_frame_t readerFrame,
40 astra_stream_subtype_t subtype,
41 astra_maskedcolorframe_t* maskedcolorFrame);
42
43 ASTRA_API_EX astra_status_t astra_maskedcolorframe_get_data_byte_length(astra_maskedcolorframe_t maskedcolorFrame,
44 uint32_t* byteLength);
45
46 ASTRA_API_EX astra_status_t astra_maskedcolorframe_get_data_ptr(astra_maskedcolorframe_t maskedcolorFrame,
47 astra_rgba_pixel_t** data,
48 uint32_t* byteLength);
49
50 ASTRA_API_EX astra_status_t astra_maskedcolorframe_copy_data(astra_maskedcolorframe_t maskedcolorFrame,
51 astra_rgba_pixel_t* data);
52
53 ASTRA_API_EX astra_status_t astra_maskedcolorframe_get_metadata(astra_maskedcolorframe_t maskedcolorFrame,
54 astra_image_metadata_t* metadata);
55
56 ASTRA_API_EX astra_status_t astra_maskedcolorframe_get_frameindex(astra_maskedcolorframe_t maskedcolorFrame,
57 astra_frame_index_t* index);
59 ASTRA_END_DECLS
60
61 #endif /* MASKED_COLOR_CAPI_H */
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra_image_metadata_t
Definition: image_types.h:55
astra_rgba_pixel_t
Definition: image_types.h:47


Astra SDK: masked_color_types.h Source File

  • include
  • astra
  • capi
  • streams
masked_color_types.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef MASKED_COLOR_TYPES_H
18 #define MASKED_COLOR_TYPES_H
19
20 #include <astra_core/capi/astra_types.h>
21 #include <astra/capi/streams/image_types.h>
22
23 typedef astra_streamconnection_t astra_maskedcolorstream_t;
24 typedef struct _astra_imageframe* astra_maskedcolorframe_t;
25
26 #endif // MASKED_COLOR_TYPES_H
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37


Astra SDK: MaskedColor.hpp Source File

  • include
  • astra
  • streams
MaskedColor.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_MASKEDCOLOR_HPP
18 #define ASTRA_MASKEDCOLOR_HPP
19
20 #include <astra_core/astra_core.hpp>
21 #include <astra/capi/astra_ctypes.h>
22 #include <astra/capi/streams/masked_color_capi.h>
23 #include <astra/streams/Image.hpp>
24
25 namespace astra {
26
33 class MaskedColorStream : public DataStream
34 {
35 public:
36 MaskedColorStream()
37 {}
38
39 explicit MaskedColorStream(astra_streamconnection_t connection)
40 : DataStream(connection)
41 {
42 maskedcolorStream_ = reinterpret_cast< astra_maskedcolorstream_t >(connection);
43 }
44
45 static const astra_stream_type_t id = ASTRA_STREAM_MASKED_COLOR;
46
47 private:
48 astra_maskedcolorstream_t maskedcolorStream_;
49 };
50
57 class MaskedColorFrame : public ImageFrame<RgbaPixel, ASTRA_STREAM_MASKED_COLOR>
58 {
59 public:
60 MaskedColorFrame(astra_imageframe_t frame)
61 : ImageFrame(frame, ASTRA_PIXEL_FORMAT_RGBA)
62 {}
63 };
64 }
65
66 #endif // ASTRA_MASKEDCOLOR_HPP
astra::ImageFrame
Basic Image Frame.
Definition: Image.hpp:392
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra::MaskedColorFrame
A Masked Color Frame of Masked Color Stream.
Definition: MaskedColor.hpp:57
astra
Definition: Array.hpp:20
astra::MaskedColorStream
A Masked Color Stream.
Definition: MaskedColor.hpp:33
astra::DataStream
Data Stream.
Definition: DataStream.hpp:32


Astra SDK: Matrix3x3.hpp Source File

  • include
  • astra
Matrix3x3.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_MATRIX3X3_HPP
18 #define ASTRA_MATRIX3X3_HPP
19
20 #include <cmath>
21 #include "Vector3f.hpp"
22 #include "capi/astra_ctypes.h"
23
24 namespace astra {
25
30 struct Matrix3x3 : private ::astra_matrix3x3_t
31 {
35 Matrix3x3()
36 {
37 ::astra_matrix3x3_t::m00 = 0.f;
38 ::astra_matrix3x3_t::m10 = 0.f;
39 ::astra_matrix3x3_t::m20 = 0.f;
40
41 ::astra_matrix3x3_t::m01 = 0.f;
42 ::astra_matrix3x3_t::m11 = 0.f;
43 ::astra_matrix3x3_t::m21 = 0.f;
44
45 ::astra_matrix3x3_t::m02 = 0.f;
46 ::astra_matrix3x3_t::m12 = 0.f;
47 ::astra_matrix3x3_t::m22 = 0.f;
48 }
49
54 const Vector3f& x_axis() const
55 {
56 return *static_cast<const Vector3f*>(&(::astra_matrix3x3_t::xAxis));
57 }
62 const Vector3f& y_axis() const
63 {
64 return *static_cast<const Vector3f*>(&(::astra_matrix3x3_t::yAxis));
65 }
70 const Vector3f& z_axis() const
71 {
72 return *static_cast<const Vector3f*>(&(::astra_matrix3x3_t::zAxis));
73 }
74
79 float m00() const { return ::astra_matrix3x3_t::m00; }
80
85 float m10() const { return ::astra_matrix3x3_t::m10; }
86
91 float m20() const { return ::astra_matrix3x3_t::m20; }
92
97 float m01() const { return ::astra_matrix3x3_t::m01; }
98
103 float m11() const { return ::astra_matrix3x3_t::m11; }
104
109 float m21() const { return ::astra_matrix3x3_t::m21; }
110
115 float m02() const { return ::astra_matrix3x3_t::m02; }
116
121 float m12() const { return ::astra_matrix3x3_t::m12; }
122
127 float m22() const { return ::astra_matrix3x3_t::m22; }
128
129 friend class Joint;
130 };
131 }
132
133 #endif /* ASTRA_MATRIX3X3_HPP */
astra::Matrix3x3::m00
float m00() const
the m00 coef
Definition: Matrix3x3.hpp:79
_astra_matrix3x3
Represents a 3x3 rotation matrix.
Definition: astra_ctypes.h:51
astra
Definition: Array.hpp:20
astra::Matrix3x3
Represents a 3x3 rotation matrix.
Definition: Matrix3x3.hpp:30
astra::Joint
Body joint
Definition: Body.hpp:218
astra::Matrix3x3::m10
float m10() const
the m10 coef
Definition: Matrix3x3.hpp:85
astra::Matrix3x3::x_axis
const Vector3f & x_axis() const
X axis basis vector, or the first column vector.
Definition: Matrix3x3.hpp:54
astra::Matrix3x3::m20
float m20() const
the m20 coef
Definition: Matrix3x3.hpp:91
astra::Matrix3x3::z_axis
const Vector3f & z_axis() const
Z axis basis vector, or the third column vector.
Definition: Matrix3x3.hpp:70
astra::Matrix3x3::m12
float m12() const
the m12 coef
Definition: Matrix3x3.hpp:121
astra::Vector3f
Represents a float 3d vector.
Definition: Vector3f.hpp:29
astra::Matrix3x3::y_axis
const Vector3f & y_axis() const
Y axis basis vector, or the second column vector.
Definition: Matrix3x3.hpp:62
astra::Matrix3x3::m02
float m02() const
the m02 coef
Definition: Matrix3x3.hpp:115
astra::Matrix3x3::Matrix3x3
Matrix3x3()
Default constructs zero Matrix.
Definition: Matrix3x3.hpp:35
astra::Matrix3x3::m22
float m22() const
the m22 coef
Definition: Matrix3x3.hpp:127
astra::Matrix3x3::m11
float m11() const
the m11 coef
Definition: Matrix3x3.hpp:103
astra::Matrix3x3::m01
float m01() const
the m01 coef
Definition: Matrix3x3.hpp:97
astra::Matrix3x3::m21
float m21() const
the m21 coef
Definition: Matrix3x3.hpp:109


Astra SDK: Point.hpp Source File

  • include
  • astra
  • streams
Point.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_POINT_HPP
18 #define ASTRA_POINT_HPP
19
20 #include <astra_core/astra_core.hpp>
21 #include <astra/capi/astra_ctypes.h>
22 #include <astra/capi/streams/point_capi.h>
23 #include <astra/streams/Image.hpp>
24
25 namespace astra {
26
33 class PointStream : public DataStream
34 {
35 public:
36 PointStream()
37 {}
38
44 explicit PointStream(astra_streamconnection_t connection)
45 : DataStream(connection)
46 {
47 pointStream_ = reinterpret_cast< astra_pointstream_t >(connection);
48 }
49
50 static const astra_stream_type_t id = ASTRA_STREAM_POINT;
51
52 private:
53 astra_pointstream_t pointStream_;
54 };
55
62 class PointFrame : public ImageFrame<Vector3f, ASTRA_STREAM_POINT>
63 {
64 public:
70 PointFrame(astra_imageframe_t frame)
71 : ImageFrame(frame, ASTRA_PIXEL_FORMAT_POINT)
72 {}
73 };
74 }
75
76 #endif // ASTRA_POINT_HPP
astra::ImageFrame
Basic Image Frame.
Definition: Image.hpp:392
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra
Definition: Array.hpp:20
astra::PointStream::PointStream
PointStream(astra_streamconnection_t connection)
default constructs
Definition: Point.hpp:44
astra::PointFrame::PointFrame
PointFrame(astra_imageframe_t frame)
default constructs
Definition: Point.hpp:70
astra::DataStream
Data Stream.
Definition: DataStream.hpp:32
astra::PointFrame
A Point Data Frame.
Definition: Point.hpp:62
astra::PointStream
A Point Data Stream.
Definition: Point.hpp:33


Astra SDK: point_capi.h Source File

  • include
  • astra
  • capi
  • streams
point_capi.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef POINT_CAPI_H
18 #define POINT_CAPI_H
19
20 #include <astra_core/capi/astra_types.h>
21 #include "point_types.h"
22
23 ASTRA_BEGIN_DECLS
24
30 ASTRA_API_EX astra_status_t astra_reader_get_pointstream(astra_reader_t reader,
31 astra_pointstream_t* pointStream);
32
33 ASTRA_API_EX astra_status_t astra_pointstream_is_available(astra_pointstream_t pointStream,
34 bool* isAvailable);
35
36 ASTRA_API_EX astra_status_t astra_frame_get_pointframe(astra_reader_frame_t readerFrame,
37 astra_pointframe_t* pointFrame);
38
39 ASTRA_API_EX astra_status_t astra_frame_get_pointframe_with_subtype(astra_reader_frame_t readerFrame,
40 astra_stream_subtype_t subtype,
41 astra_pointframe_t* pointFrame);
42
43 ASTRA_API_EX astra_status_t astra_pointframe_get_data_byte_length(astra_pointframe_t pointFrame,
44 uint32_t* byteLength);
45
46 ASTRA_API_EX astra_status_t astra_pointframe_get_data_ptr(astra_pointframe_t pointFrame,
47 astra_vector3f_t** data,
48 uint32_t* byteLength);
49
50 ASTRA_API_EX astra_status_t astra_pointframe_copy_data(astra_pointframe_t pointFrame,
51 astra_vector3f_t* data);
52
53 ASTRA_API_EX astra_status_t astra_pointframe_get_metadata(astra_pointframe_t pointFrame,
54 astra_image_metadata_t* metadata);
55
56 ASTRA_API_EX astra_status_t astra_pointframe_get_frameindex(astra_pointframe_t pointFrame,
57 astra_frame_index_t* index);
59 ASTRA_END_DECLS
60
61 #endif /* POINT_CAPI_H */
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37
astra_vector3f_t
Definition: astra_ctypes.h:33
astra_image_metadata_t
Definition: image_types.h:55


Astra SDK: point_types.h Source File

  • include
  • astra
  • capi
  • streams
point_types.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef POINT_TYPES_H
18 #define POINT_TYPES_H
19
20 #include <astra_core/capi/astra_types.h>
21 #include <astra/capi/streams/image_types.h>
22
23 typedef astra_streamconnection_t astra_pointstream_t;
24 typedef struct _astra_imageframe* astra_pointframe_t;
25
26 #endif // POINT_TYPES_H
_astra_streamconnection
Definition: astra_plugin.h:24
_astra_imageframe
Definition: stream_types.h:37


Astra SDK: stream_types.h Source File

  • include
  • astra
  • capi
  • streams
stream_types.h
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef STREAM_TYPES_H
18 #define STREAM_TYPES_H
19
20 #include "body_types.h"
21 #include "depth_types.h"
22 #include "color_types.h"
23 #include "hand_types.h"
24 #include "image_types.h"
25
26 #if __GNUC__
27 #define ASTRA_ALIGN(X) __attribute__((__aligned__(X)))
28 #elif _MSC_VER
29 #define ASTRA_ALIGN(X) __declspec(align(X))
30 #else
31 #error "Unsupported compiler"
32 #endif
33
34 // https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html
35 // http://stackoverflow.com/questions/3350852/how-to-correctly-fix-zero-sized-array-in-struct-union-warning-c4200-without
36
37 struct _astra_imageframe {
38 union {
39 astra_frame_t* frame;
40 uint64_t pad0;
41 };
42
43 astra_image_metadata_t metadata;
44 union {
45 void* data;
46 uint64_t pad1;
47 };
48 };
49
50 struct _astra_handframe {
51 union {
52 astra_frame_t* frame;
53 uint64_t pad0;
54 };
55 size_t handCount;
56 union {
57 astra_handpoint_t* handpoints;
58 uint64_t pad1;
59 };
60 };
61
62 struct _astra_bodyframe {
63 union {
64 astra_frame_t* frame;
65 uint64_t pad0;
66 };
67 astra_bodyframe_info_t info;
68 ASTRA_ALIGN(32) astra_bodymask_t bodyMask;
69 astra_floor_info_t floorInfo;
70 astra_body_list_t bodyList;
71 };
72
73 #if defined(_MSC_VER)
74 #pragma warning( push )
75 #pragma warning( disable : 4200 )
76 #elif defined(__clang__)
77 #pragma clang diagnostic push
78 #pragma clang diagnostic ignored "-Wc99-extensions"
79 #endif
80
81 typedef struct _astra_imageframe_wrapper {
82 _astra_imageframe frame;
83 ASTRA_ALIGN(32) char frame_data[];
84 } astra_imageframe_wrapper_t;
85
86 typedef struct _astra_handframe_wrapper {
87 _astra_handframe frame;
88 char frame_data[];
89 } astra_handframe_wrapper_t;
90
91 typedef struct _astra_bodyframe_wrapper {
92 _astra_bodyframe frame;
93 char frame_data[];
94 } astra_bodyframe_wrapper_t;
95
96 #if defined(_MSC_VER)
97 #pragma warning( pop )
98 #elif defined(__clang__)
99 #pragma clang diagnostic pop
100 #endif
101
102 #endif /* STREAM_TYPES_H */
_astra_body_list
Struct containing a variable-sized array of astra_body_t structs.
Definition: body_types.h:315
_astra_imageframe_wrapper
Definition: stream_types.h:81
_astra_imageframe
Definition: stream_types.h:37
_astra_bodyframe
Definition: stream_types.h:62
_astra_bodyframe_wrapper
Definition: stream_types.h:91
_astra_frame
Definition: astra_plugin.h:34
_astra_floor_info
Struct containing floor information about the scene.
Definition: body_types.h:400
_astra_bitmapmask
Struct representing a 2-dimensional bitmask.
Definition: body_types.h:330
astra_image_metadata_t
Definition: image_types.h:55
_astra_handframe
Definition: stream_types.h:50
astra_handpoint_t
Definition: hand_types.h:48
_astra_bodyframe_info
Struct containing general body frame information.
Definition: body_types.h:387
_astra_handframe_wrapper
Definition: stream_types.h:86


Astra SDK: StreamDescription.hpp Source File

  • include
  • astra_core
StreamDescription.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_STREAMDESCRIPTION_HPP
18 #define ASTRA_STREAMDESCRIPTION_HPP
19
20 #include "capi/astra_core.h"
21 #include <cassert>
22
23 namespace astra {
24
31 class StreamDescription : private ::astra_stream_desc_t
32 {
33 public:
40 StreamDescription(::astra_stream_type_t type,
41 ::astra_stream_subtype_t subtype = DEFAULT_SUBTYPE)
42 {
43 ::astra_stream_desc_t::type = type;
44 ::astra_stream_desc_t::subtype = subtype;
45 }
46
52 StreamDescription(const ::astra_stream_desc_t& desc)
53 {
54 *this = desc;
55 }
56
62 StreamDescription& operator=(const ::astra_stream_desc_t& desc)
63 {
64 ::astra_stream_desc_t::type = desc.type;
65 ::astra_stream_desc_t::subtype = desc.subtype;
66
67 return *this;
68 }
69
70 operator ::astra_stream_desc_t*() { return this; }
71 operator const ::astra_stream_desc_t*() const { return this; }
72
78 astra_stream_type_t type() const { return ::astra_stream_desc_t::type; }
79
85 astra_stream_subtype_t subtype() const { return ::astra_stream_desc_t::subtype; }
86 };
87
94 inline bool operator==(const StreamDescription& lhs, const StreamDescription& rhs)
95 {
96 return lhs.type() == rhs.type() && lhs.subtype() == rhs.subtype();
97 }
98
105 inline bool operator!=(const StreamDescription& lhs, const StreamDescription& rhs)
106 {
107 return !(lhs == rhs);
108 }
109 }
110
111 #endif // ASTRA_STREAMDESCRIPTION_HPP
astra
Definition: Array.hpp:20
astra::operator==
bool operator==(const StreamDescription &lhs, const StreamDescription &rhs)
compare StreamDescription is equal
Definition: StreamDescription.hpp:94
astra_stream_desc_t
Definition: astra_types.h:38
astra::StreamDescription::StreamDescription
StreamDescription(::astra_stream_type_t type, ::astra_stream_subtype_t subtype=DEFAULT_SUBTYPE)
default constructs
Definition: StreamDescription.hpp:40
astra::StreamDescription
Stream Description class.
Definition: StreamDescription.hpp:31
astra::StreamDescription::type
astra_stream_type_t type() const
get type
Definition: StreamDescription.hpp:78
astra::StreamDescription::subtype
astra_stream_subtype_t subtype() const
get sub type
Definition: StreamDescription.hpp:85
astra::StreamDescription::operator=
StreamDescription & operator=(const ::astra_stream_desc_t &desc)
copy constructs
Definition: StreamDescription.hpp:62
astra::operator!=
bool operator!=(const StreamDescription &lhs, const StreamDescription &rhs)
compare StreamDescription is not equal
Definition: StreamDescription.hpp:105
astra::StreamDescription::StreamDescription
StreamDescription(const ::astra_stream_desc_t &desc)
copy constructs
Definition: StreamDescription.hpp:52


Astra SDK: StreamReader.hpp Source File

  • include
  • astra_core
StreamReader.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_STREAMREADER_HPP
18 #define ASTRA_STREAMREADER_HPP
19
20 #include "capi/astra_core.h"
21 #include <astra_core/FrameListener.hpp>
22 #include <astra_core/Frame.hpp>
23 #include <memory>
24 #include <vector>
25 #include <algorithm>
26 #include <functional>
27 #include <iterator>
28
29 namespace astra {
30
37 class StreamReader
38 {
39 public:
44 StreamReader()
45 : readerRef_(nullptr)
46 {}
47
53 StreamReader(astra_reader_t reader)
54 : readerRef_(std::make_shared<ReaderRef>(reader))
55 {}
56
62 StreamReader(const StreamReader& reader)
63 : readerRef_(reader.readerRef_)
64 {}
65
71 StreamReader& operator=(const StreamReader& reader)
72 {
73 this->readerRef_ = reader.readerRef_;
74 return *this;
75 }
76
82 template<typename T>
83 T stream()
84 {
85 return stream<T>(DEFAULT_SUBTYPE);
86 }
87
94 template<typename T>
95 T stream(astra_stream_subtype_t subtype)
96 {
97 if (!is_valid())
98 throw std::logic_error("StreamReader is not associated with a streamset.");
99
100 astra_streamconnection_t connection;
101 astra_reader_get_stream(readerRef_->get_reader(),
102 T::id,
103 subtype,
104 &connection);
105
106 return T(connection);
107 }
108
109
116 void add_listener(FrameListener& listener)
117 {
118 if (!is_valid())
119 throw std::logic_error("StreamReader is not associated with a streamset.");
120
121 readerRef_.get()->add_listener(listener);
122 }
123
130 void remove_listener(FrameListener& listener)
131 {
132 if (!is_valid())
133 throw std::logic_error("StreamReader is not associated with a streamset.");
134
135 readerRef_.get()->remove_listener(listener);
136 }
137
143 bool is_valid() { return readerRef_ != nullptr; }
144
150 bool has_new_frame()
151 {
152 if (!is_valid())
153 throw std::logic_error("StreamReader is not associated with a streamset.");
154
155 bool hasNewFrame = false;
156 astra_reader_has_new_frame(readerRef_->get_reader(), &hasNewFrame);
157 return hasNewFrame;
158 }
159
165 Frame get_latest_frame(int timeoutMillis = ASTRA_TIMEOUT_FOREVER)
166 {
167 if (!is_valid())
168 throw std::logic_error("StreamReader is not associated with a streamset.");
169
170 astra_reader_frame_t frame;
171 astra_reader_open_frame(readerRef_->get_reader(), timeoutMillis, &frame);
172
173 return astra::Frame(frame);
174 }
175
176 private:
177 class ReaderRef;
178 using ReaderRefPtr = std::shared_ptr<ReaderRef>;
179
180 StreamReader(ReaderRefPtr readerRef)
181 : readerRef_(readerRef)
182 { }
183
184 class ReaderRef :
185 public std::enable_shared_from_this<ReaderRef>
186 {
187 public:
188 ReaderRef(astra_reader_t reader)
189 : reader_(reader)
190 { }
191
192 ~ReaderRef()
193 {
194 listeners_.clear();
195 ensure_callback_removed();
196 astra_reader_destroy(&reader_);
197 }
198
199 static void ASTRA_CALLBACK frame_ready_thunk(void* clientTag,
200 astra_reader_t reader,
201 astra_reader_frame_t frame)
202 {
203 ReaderRef* self = static_cast<ReaderRef*>(clientTag);
204 self->notify_listeners(frame);
205 }
206
207 void add_listener(FrameListener& listener)
208 {
209 ensure_callback_added();
210
211 auto it = std::find(listeners_.begin(),
212 listeners_.end(),
213 listener);
214
215 if (it != listeners_.end())
216 return;
217
218 if (isNotifying_)
219 {
220 addedListeners_.push_back(listener);
221 }
222 else
223 {
224 listeners_.push_back(listener);
225 }
226 }
227
228 void remove_listener(FrameListener& listener)
229 {
230 auto it = std::find(listeners_.begin(),
231 listeners_.end(),
232 listener);
233
234 if (it == listeners_.end())
235 return;
236
237 if (isNotifying_)
238 {
239 removedListeners_.push_back(listener);
240 }
241 else
242 {
243 listeners_.erase(it);
244 }
245
246 if (listeners_.size() == 0)
247 {
248 ensure_callback_removed();
249 }
250 }
251
252 void notify_listeners(astra_reader_frame_t readerFrame)
253 {
254 if (removedListeners_.size() > 0)
255 {
256 for(FrameListener& listener : removedListeners_)
257 {
258 auto it = std::find(listeners_.begin(),
259 listeners_.end(),
260 listener);
261
262 listeners_.erase(it);
263 }
264 removedListeners_.clear();
265 }
266
267 std::move(addedListeners_.begin(),
268 addedListeners_.end(),
269 std::back_inserter(listeners_));
270
271 if (listeners_.size() == 0)
272 {
273 ensure_callback_removed();
274 return;
275 }
276
277 //we didn't open the frame, so don't auto close it.
278 //the StreamReader internals will close it automatically
279 const bool autoCloseFrame = false;
280 astra::Frame frameWrapper(readerFrame, autoCloseFrame);
281
282 isNotifying_ = true;
283 StreamReader reader(shared_from_this());
284 for(FrameListener& listener : listeners_)
285 {
286 listener.on_frame_ready(reader, frameWrapper);
287 }
288
289 isNotifying_ = false;
290 }
291
292 astra_reader_t get_reader() { return reader_; }
293
294 private:
295 void ensure_callback_added()
296 {
297 if (!callbackRegistered_)
298 {
299 astra_reader_register_frame_ready_callback(reader_,
300 &ReaderRef::frame_ready_thunk,
301 this,
302 &callbackId_);
303
304 callbackRegistered_ = true;
305 }
306 }
307
308 void ensure_callback_removed()
309 {
310 if (callbackRegistered_)
311 {
312 astra_reader_unregister_frame_ready_callback(&callbackId_);
313 callbackRegistered_ = false;
314 }
315 }
316
317 astra_reader_t reader_;
318
319 bool isNotifying_{false};
320 bool callbackRegistered_{false};
321
322 using ListenerList = std::vector<std::reference_wrapper<FrameListener>>;
323
324 ListenerList listeners_;
325 ListenerList addedListeners_;
326 ListenerList removedListeners_;
327
328 astra_reader_callback_id_t callbackId_;
329 };
330
331 ReaderRefPtr readerRef_;
332
333 friend bool operator==(const StreamReader& lhs, const StreamReader& rhs);
334 };
335
336 inline bool operator==(const StreamReader& lhs, const StreamReader& rhs)
337 {
338 return lhs.readerRef_ == rhs.readerRef_;
339 }
340
341 inline bool operator!=(const StreamReader& lhs, const StreamReader& rhs)
342 {
343 return !(lhs == rhs);
344 }
345 }
346
347 #endif // ASTRA_STREAMREADER_HPP
astra::StreamReader::has_new_frame
bool has_new_frame()
get is new frame ready
Definition: StreamReader.hpp:150
astra_reader_register_frame_ready_callback
ASTRA_API astra_status_t astra_reader_register_frame_ready_callback(astra_reader_t reader, astra_frame_ready_callback_t callback, void *clientTag, astra_reader_callback_id_t *callbackId)
Registers a callback function to StreamReader.
astra::Frame
Frame class.
Definition: Frame.hpp:31
_astra_streamconnection
Definition: astra_plugin.h:24
astra
Definition: Array.hpp:20
astra::StreamReader::is_valid
bool is_valid()
get is reader available
Definition: StreamReader.hpp:143
astra_reader_destroy
ASTRA_API astra_status_t astra_reader_destroy(astra_reader_t *reader)
Destroy the handle to StreamReader.
astra_reader_open_frame
ASTRA_API astra_status_t astra_reader_open_frame(astra_reader_t reader, int timeoutMillis, astra_reader_frame_t *frame)
Open.
astra::StreamReader::add_listener
void add_listener(FrameListener &listener)
add listener
Definition: StreamReader.hpp:116
_astra_reader_callback_id
Definition: astra_plugin.h:29
astra::FrameListener
Frame Listener class.
Definition: FrameListener.hpp:30
astra::StreamReader::stream
T stream()
get stream template
Definition: StreamReader.hpp:83
astra::StreamReader::StreamReader
StreamReader(astra_reader_t reader)
constructs
Definition: StreamReader.hpp:53
astra_reader_has_new_frame
ASTRA_API astra_status_t astra_reader_has_new_frame(astra_reader_t reader, bool *hasNewFrame)
Test whether there is a new frame.
astra::operator!=
bool operator!=(const StreamDescription &lhs, const StreamDescription &rhs)
compare StreamDescription is not equal
Definition: StreamDescription.hpp:105
astra::StreamReader::stream
T stream(astra_stream_subtype_t subtype)
get stream template
Definition: StreamReader.hpp:95
astra::StreamReader::StreamReader
StreamReader()
default constructs
Definition: StreamReader.hpp:44
astra::StreamReader::StreamReader
StreamReader(const StreamReader &reader)
constructs
Definition: StreamReader.hpp:62
astra::StreamReader
Stream Reader class.
Definition: StreamReader.hpp:37
astra_reader_unregister_frame_ready_callback
ASTRA_API astra_status_t astra_reader_unregister_frame_ready_callback(astra_reader_callback_id_t *callbackId)
Unregisters the callback function.
astra::StreamReader::remove_listener
void remove_listener(FrameListener &listener)
remove listener
Definition: StreamReader.hpp:130
astra::StreamReader::get_latest_frame
Frame get_latest_frame(int timeoutMillis=ASTRA_TIMEOUT_FOREVER)
get is latest frame
Definition: StreamReader.hpp:165
astra_reader_get_stream
ASTRA_API astra_status_t astra_reader_get_stream(astra_reader_t reader, astra_stream_type_t type, astra_stream_subtype_t subtype, astra_streamconnection_t *stream)
Get specified stream from StreamReader reader.
astra::StreamReader::operator=
StreamReader & operator=(const StreamReader &reader)
copy constructs
Definition: StreamReader.hpp:71


Astra SDK: StreamServiceProxy.hpp Source File

  • include
  • astra_core
StreamServiceProxy.hpp
1 /* THIS FILE AUTO-GENERATED FROM StreamServiceProxy.hpp.lpp. DO NOT EDIT. */
2 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
3 // Copyright (c) 2015-2017 Orbbec 3D
4 //
5 // Licensed under the Apache License, Version 2.0 (the "License");
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 // http://www.apache.org/licenses/LICENSE-2.0
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 //
17 // Be excellent to each other.
18 #ifndef ASTRA_STREAMSERVICEPROXY_HPP
19 #define ASTRA_STREAMSERVICEPROXY_HPP
20
21 #include <astra_core/capi/astra_streamservice_proxy.h>
22
23 namespace astra {
24
31 class StreamServiceProxy : public astra_streamservice_proxy_t
32 {
33 public:
34
42 astra_status_t notify_plugin_event(astra_event_id id,
43 const void* data,
44 uint32_t dataSize)
45 {
46 return astra_streamservice_proxy_t::notify_plugin_event(streamService, id, data, dataSize);
47 }
48
55 astra_status_t streamset_is_available(astra_streamsetconnection_t connection,
56 bool* isAvailable)
57 {
58 return astra_streamservice_proxy_t::streamset_is_available(streamService, connection, isAvailable);
59 }
60
67 astra_status_t streamset_open(const char* connectionString,
68 astra_streamsetconnection_t* streamSet)
69 {
70 return astra_streamservice_proxy_t::streamset_open(streamService, connectionString, streamSet);
71 }
72
78 astra_status_t streamset_close(astra_streamsetconnection_t* streamSet)
79 {
80 return astra_streamservice_proxy_t::streamset_close(streamService, streamSet);
81 }
82
90 astra_status_t streamset_get_uri(astra_streamsetconnection_t connection,
91 char* uri,
92 int32_t size)
93 {
94 return astra_streamservice_proxy_t::streamset_get_uri(streamService, connection, uri, size);
95 }
96
103 astra_status_t reader_create(astra_streamsetconnection_t streamSet,
104 astra_reader_t* reader)
105 {
106 return astra_streamservice_proxy_t::reader_create(streamService, streamSet, reader);
107 }
108
114 astra_status_t reader_destroy(astra_reader_t* reader)
115 {
116 return astra_streamservice_proxy_t::reader_destroy(streamService, reader);
117 }
118
127 astra_status_t reader_get_stream(astra_reader_t reader,
128 astra_stream_type_t type,
129 astra_stream_subtype_t subtype,
130 astra_streamconnection_t* connection)
131 {
132 return astra_streamservice_proxy_t::reader_get_stream(streamService, reader, type, subtype, connection);
133 }
134
141 astra_status_t stream_get_description(astra_streamconnection_t connection,
142 astra_stream_desc_t* description)
143 {
144 return astra_streamservice_proxy_t::stream_get_description(streamService, connection, description);
145 }
146
153 astra_status_t stream_is_available(astra_streamconnection_t connection,
154 bool* isAvailable)
155 {
156 return astra_streamservice_proxy_t::stream_is_available(streamService, connection, isAvailable);
157 }
158
164 astra_status_t stream_start(astra_streamconnection_t connection)
165 {
166 return astra_streamservice_proxy_t::stream_start(streamService, connection);
167 }
168
174 astra_status_t stream_stop(astra_streamconnection_t connection)
175 {
176 return astra_streamservice_proxy_t::stream_stop(streamService, connection);
177 }
178
185 astra_status_t reader_has_new_frame(astra_reader_t reader,
186 bool* hasNewFrame)
187 {
188 return astra_streamservice_proxy_t::reader_has_new_frame(streamService, reader, hasNewFrame);
189 }
190
198 astra_status_t reader_open_frame(astra_reader_t reader,
199 int timeoutMillis,
200 astra_reader_frame_t* frame)
201 {
202 return astra_streamservice_proxy_t::reader_open_frame(streamService, reader, timeoutMillis, frame);
203 }
204
210 astra_status_t reader_close_frame(astra_reader_frame_t* frame)
211 {
212 return astra_streamservice_proxy_t::reader_close_frame(streamService, frame);
213 }
214
223 astra_status_t reader_register_frame_ready_callback(astra_reader_t reader,
224 astra_frame_ready_callback_t callback,
225 void* clientTag,
226 astra_reader_callback_id_t* callbackId)
227 {
228 return astra_streamservice_proxy_t::reader_register_frame_ready_callback(streamService, reader, callback, clientTag, callbackId);
229 }
230
236 astra_status_t reader_unregister_frame_ready_callback(astra_reader_callback_id_t* callbackId)
237 {
238 return astra_streamservice_proxy_t::reader_unregister_frame_ready_callback(streamService, callbackId);
239 }
240
249 astra_status_t reader_get_frame(astra_reader_frame_t frame,
250 astra_stream_type_t type,
251 astra_stream_subtype_t subtype,
252 astra_frame_t** subFrame)
253 {
254 return astra_streamservice_proxy_t::reader_get_frame(streamService, frame, type, subtype, subFrame);
255 }
256
265 astra_status_t stream_set_parameter(astra_streamconnection_t connection,
266 astra_parameter_id parameterId,
267 uint32_t inByteLength,
268 astra_parameter_data_t inData)
269 {
270 return astra_streamservice_proxy_t::stream_set_parameter(streamService, connection, parameterId, inByteLength, inData);
271 }
272
281 astra_status_t stream_get_parameter(astra_streamconnection_t connection,
282 astra_parameter_id parameterId,
283 uint32_t* resultByteLength,
284 astra_result_token_t* token)
285 {
286 return astra_streamservice_proxy_t::stream_get_parameter(streamService, connection, parameterId, resultByteLength, token);
287 }
288
297 astra_status_t stream_get_result(astra_streamconnection_t connection,
298 astra_result_token_t token,
299 uint32_t dataByteLength,
300 astra_parameter_data_t dataDestination)
301 {
302 return astra_streamservice_proxy_t::stream_get_result(streamService, connection, token, dataByteLength, dataDestination);
303 }
304
315 astra_status_t stream_invoke(astra_streamconnection_t connection,
316 astra_command_id commandId,
317 uint32_t inByteLength,
318 astra_parameter_data_t inData,
319 uint32_t* resultByteLength,
320 astra_result_token_t* token)
321 {
322 return astra_streamservice_proxy_t::stream_invoke(streamService, connection, commandId, inByteLength, inData, resultByteLength, token);
323 }
324
328 astra_status_t update()
329 {
330 return astra_streamservice_proxy_t::update(streamService);
331 }
332 };
333 }
334
335 #endif // ASTRA_STREAMSERVICEPROXY_HPP
astra::StreamServiceProxy
Stream Service Proxy Class.
Definition: StreamServiceProxy.hpp:31
astra::StreamServiceProxy::streamset_open
astra_status_t streamset_open(const char *connectionString, astra_streamsetconnection_t *streamSet)
open streamset
Definition: StreamServiceProxy.hpp:67
astra::StreamServiceProxy::stream_get_result
astra_status_t stream_get_result(astra_streamconnection_t connection, astra_result_token_t token, uint32_t dataByteLength, astra_parameter_data_t dataDestination)
get stream result
Definition: StreamServiceProxy.hpp:297
_astra_streamconnection
Definition: astra_plugin.h:24
astra::StreamServiceProxy::notify_plugin_event
astra_status_t notify_plugin_event(astra_event_id id, const void *data, uint32_t dataSize)
notify plugin event
Definition: StreamServiceProxy.hpp:42
astra::StreamServiceProxy::stream_stop
astra_status_t stream_stop(astra_streamconnection_t connection)
stop stream
Definition: StreamServiceProxy.hpp:174
astra
Definition: Array.hpp:20
astra::StreamServiceProxy::reader_has_new_frame
astra_status_t reader_has_new_frame(astra_reader_t reader, bool *hasNewFrame)
get is reader has new frame
Definition: StreamServiceProxy.hpp:185
astra_stream_desc_t
Definition: astra_types.h:38
_astra_frame
Definition: astra_plugin.h:34
astra::StreamServiceProxy::stream_invoke
astra_status_t stream_invoke(astra_streamconnection_t connection, astra_command_id commandId, uint32_t inByteLength, astra_parameter_data_t inData, uint32_t *resultByteLength, astra_result_token_t *token)
call stream command by id
Definition: StreamServiceProxy.hpp:315
_astra_reader_callback_id
Definition: astra_plugin.h:29
astra::StreamServiceProxy::stream_is_available
astra_status_t stream_is_available(astra_streamconnection_t connection, bool *isAvailable)
get stream is description
Definition: StreamServiceProxy.hpp:153
astra::StreamServiceProxy::reader_close_frame
astra_status_t reader_close_frame(astra_reader_frame_t *frame)
close frame
Definition: StreamServiceProxy.hpp:210
astra::StreamServiceProxy::reader_register_frame_ready_callback
astra_status_t reader_register_frame_ready_callback(astra_reader_t reader, astra_frame_ready_callback_t callback, void *clientTag, astra_reader_callback_id_t *callbackId)
register reader frame ready callback
Definition: StreamServiceProxy.hpp:223
astra::StreamServiceProxy::reader_get_stream
astra_status_t reader_get_stream(astra_reader_t reader, astra_stream_type_t type, astra_stream_subtype_t subtype, astra_streamconnection_t *connection)
get stream
Definition: StreamServiceProxy.hpp:127
astra_streamservice_proxy_t
Definition: astra_streamservice_proxy.h:23
astra::StreamServiceProxy::reader_create
astra_status_t reader_create(astra_streamsetconnection_t streamSet, astra_reader_t *reader)
create reader
Definition: StreamServiceProxy.hpp:103
astra::StreamServiceProxy::streamset_is_available
astra_status_t streamset_is_available(astra_streamsetconnection_t connection, bool *isAvailable)
get streamset is available
Definition: StreamServiceProxy.hpp:55
astra::StreamServiceProxy::reader_open_frame
astra_status_t reader_open_frame(astra_reader_t reader, int timeoutMillis, astra_reader_frame_t *frame)
open a frame in timeout ms
Definition: StreamServiceProxy.hpp:198
astra::StreamServiceProxy::streamset_close
astra_status_t streamset_close(astra_streamsetconnection_t *streamSet)
close streamset
Definition: StreamServiceProxy.hpp:78
astra::StreamServiceProxy::stream_get_description
astra_status_t stream_get_description(astra_streamconnection_t connection, astra_stream_desc_t *description)
get stream description
Definition: StreamServiceProxy.hpp:141
astra::StreamServiceProxy::reader_destroy
astra_status_t reader_destroy(astra_reader_t *reader)
destroy reader
Definition: StreamServiceProxy.hpp:114
astra::StreamServiceProxy::update
astra_status_t update()
update
Definition: StreamServiceProxy.hpp:328
astra::StreamServiceProxy::stream_start
astra_status_t stream_start(astra_streamconnection_t connection)
start stream
Definition: StreamServiceProxy.hpp:164
astra::StreamServiceProxy::streamset_get_uri
astra_status_t streamset_get_uri(astra_streamsetconnection_t connection, char *uri, int32_t size)
get streamset uri
Definition: StreamServiceProxy.hpp:90
astra::StreamServiceProxy::reader_unregister_frame_ready_callback
astra_status_t reader_unregister_frame_ready_callback(astra_reader_callback_id_t *callbackId)
unregister reader frame ready callback
Definition: StreamServiceProxy.hpp:236
astra::StreamServiceProxy::stream_set_parameter
astra_status_t stream_set_parameter(astra_streamconnection_t connection, astra_parameter_id parameterId, uint32_t inByteLength, astra_parameter_data_t inData)
set connection param
Definition: StreamServiceProxy.hpp:265
astra::StreamServiceProxy::reader_get_frame
astra_status_t reader_get_frame(astra_reader_frame_t frame, astra_stream_type_t type, astra_stream_subtype_t subtype, astra_frame_t **subFrame)
get sub frame int frame
Definition: StreamServiceProxy.hpp:249
astra::StreamServiceProxy::stream_get_parameter
astra_status_t stream_get_parameter(astra_streamconnection_t connection, astra_parameter_id parameterId, uint32_t *resultByteLength, astra_result_token_t *token)
get connection param
Definition: StreamServiceProxy.hpp:281


Astra SDK: StreamSet.hpp Source File

  • include
  • astra_core
StreamSet.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_STREAMSET_HPP
18 #define ASTRA_STREAMSET_HPP
19
20 #include <string>
21 #include "capi/astra_core.h"
22 #include "StreamReader.hpp"
23 #include <stdexcept>
24
25 namespace astra {
26
27 static const char* ASTRA_DEFAULT_DEVICE_URI = "device/default";
28
35 class StreamSet
36 {
37 public:
42 StreamSet()
43 : StreamSet(ASTRA_DEFAULT_DEVICE_URI)
44 {}
45
51 StreamSet(const char* uri)
52 {
53 setRef_ = std::make_shared<StreamSetRef>(uri);
54 }
55
61 StreamSet(const StreamSet& other)
62 : setRef_(other.setRef_)
63 {}
64
70 StreamSet& operator=(const StreamSet& rhs)
71 {
72 this->setRef_ = rhs.setRef_;
73 return *this;
74 }
75
81 std::string uri()
82 {
83 char uri[ASTRA_STREAMSET_URI_MAX_LENGTH];
84 astra_streamset_get_uri(setRef_->connection_handle(), uri, ASTRA_STREAMSET_URI_MAX_LENGTH);
85 return std::string(uri);
86 }
87
93 bool is_valid() { return setRef_ != nullptr; }
94
100 bool is_available()
101 {
102 bool isAvailable = false;
103 if (setRef_ == nullptr || setRef_->connection_handle() == nullptr)
104 {
105 return isAvailable;
106 }
107 astra_streamset_is_available(setRef_->connection_handle(), &isAvailable);
108 return isAvailable;
109 }
110
116 inline StreamReader create_reader();
117
123 astra_streamsetconnection_t get_handle() const { return setRef_->connection_handle(); }
124
125 private:
126 class StreamSetRef;
127 using StreamSetRefPtr = std::shared_ptr<StreamSetRef>;
128
129 class StreamSetRef :
130 public std::enable_shared_from_this<StreamSetRef>
131 {
132 public:
133 StreamSetRef(std::string uri)
134 : uri_(uri)
135 { }
136
137 void connect()
138 {
139 if (!is_connected())
140 astra_streamset_open(uri_.c_str(), &connection_);
141 }
142
143 bool is_connected() { return connection_ != nullptr; }
144
145 ~StreamSetRef()
146 {
147 if (is_connected())
148 astra_streamset_close(&connection_);
149 }
150
151 astra_streamsetconnection_t connection_handle() const { return connection_; }
152
153 private:
154 astra_streamsetconnection_t connection_{nullptr};
155 std::string uri_;
156 };
157
158 StreamSetRefPtr setRef_;
159
160 friend bool operator==(const StreamSet& lhs, const StreamSet& rhs);
161 friend bool operator!=(const StreamSet& lhs, const StreamSet& rhs);
162 };
163
164 inline bool operator==(const StreamSet& lhs, const StreamSet& rhs)
165 {
166 return lhs.setRef_ == rhs.setRef_;
167 }
168
169 inline bool operator!=(const StreamSet& lhs, const StreamSet& rhs)
170 {
171 return !(lhs == rhs);
172 }
173
174 StreamReader StreamSet::create_reader()
175 {
176 if (!setRef_->is_connected())
177 setRef_->connect();
178
179 astra_reader_t reader;
180 astra_reader_create(get_handle(), &reader);
181
182 return StreamReader(reader);
183 }
184 }
185
186 #endif // ASTRA_STREAMSET_HPP
astra
Definition: Array.hpp:20
astra::StreamSet
Stream Set Class.
Definition: StreamSet.hpp:35
astra_streamset_is_available
ASTRA_API astra_status_t astra_streamset_is_available(astra_streamsetconnection_t streamSet, bool *isAvailable)
Test whether the StreamSet is valid.
astra::StreamSet::StreamSet
StreamSet()
default constructs
Definition: StreamSet.hpp:42
astra_streamset_close
ASTRA_API astra_status_t astra_streamset_close(astra_streamsetconnection_t *streamSet)
Close the handle to StreamSet.
astra::StreamSet::create_reader
StreamReader create_reader()
create and return reader
Definition: StreamSet.hpp:174
astra::StreamSet::is_available
bool is_available()
get is available
Definition: StreamSet.hpp:100
astra_reader_create
ASTRA_API astra_status_t astra_reader_create(astra_streamsetconnection_t streamSet, astra_reader_t *reader)
Create a StreamReader in StreamSet.
astra_streamset_open
ASTRA_API astra_status_t astra_streamset_open(const char *uri, astra_streamsetconnection_t *streamSet)
Open a StreamSet.
astra::StreamSet::get_handle
astra_streamsetconnection_t get_handle() const
get handle
Definition: StreamSet.hpp:123
astra::StreamSet::StreamSet
StreamSet(const char *uri)
constructs
Definition: StreamSet.hpp:51
astra::StreamReader
Stream Reader class.
Definition: StreamReader.hpp:37
astra::StreamSet::operator=
StreamSet & operator=(const StreamSet &rhs)
copy constructs
Definition: StreamSet.hpp:70
astra::StreamSet::StreamSet
StreamSet(const StreamSet &other)
copy constructs
Definition: StreamSet.hpp:61
astra_streamset_get_uri
ASTRA_API astra_status_t astra_streamset_get_uri(astra_streamsetconnection_t streamSet, char *uri, int32_t size)
Get the URI of StreamSet.
astra::StreamSet::is_valid
bool is_valid()
get is valid
Definition: StreamSet.hpp:93
astra::StreamSet::uri
std::string uri()
get device uri
Definition: StreamSet.hpp:81


Astra SDK: Vector.hpp Source File

  • include
  • astra
Vector.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_VECTOR_HPP
18 #define ASTRA_VECTOR_HPP
19
20 #include "Vector2i.hpp"
21 #include "Vector2f.hpp"
22 #include "Vector3i.hpp"
23 #include "Vector3f.hpp"
24
25 #endif // ASTRA_VECTOR_HPP


Astra SDK: Vector2f.hpp Source File

  • include
  • astra
Vector2f.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_VECTOR2F_HPP
18 #define ASTRA_VECTOR2F_HPP
19
20 #include <cmath>
21 #include "capi/astra_ctypes.h"
22
23 namespace astra
24 {
29 struct Vector2f : public astra_vector2f_t
30 {
34 Vector2f()
35 {
36 this->x = 0.0f;
37 this->y = 0.0f;
38 }
39
43 Vector2f(const astra_vector2f_t& v)
44 {
45 *this = v;
46 }
47
51 Vector2f& operator=(const astra_vector2f_t& rhs)
52 {
53 ::astra_vector2f_t::x = rhs.x;
54 ::astra_vector2f_t::y = rhs.y;
55
56 return *this;
57 }
58
62 Vector2f(float x, float y)
63 {
64 this->x = x;
65 this->y = y;
66 }
67
68 inline operator ::astra_vector2f_t*() { return this; }
69 inline operator const ::astra_vector2f_t*() const { return this; }
70
75 float length() const;
80 float length_squared() const;
86 float dot(const Vector2f& v) const;
92 static Vector2f normalize(Vector2f v);
93
97 static inline Vector2f zero();
98
103 inline bool is_zero() const;
104
105 friend bool operator==(const Vector2f& lhs, const Vector2f& rhs);
106 friend Vector2f operator+(const Vector2f& lhs, const Vector2f& rhs);
107 friend Vector2f operator-(const Vector2f& lhs, const Vector2f& rhs);
108 friend Vector2f operator*(const Vector2f& lhs, const float& rhs);
109 friend Vector2f operator*(const float& lhs, const Vector2f& rhs);
110 friend Vector2f operator/(const Vector2f& lhs, const float& rhs);
111
112 Vector2f operator-();
113 Vector2f& operator+=(const Vector2f& rhs);
114 Vector2f& operator-=(const Vector2f& rhs);
115 Vector2f& operator*=(const float& rhs);
116 Vector2f& operator/=(const float& rhs);
117 };
118
119 inline Vector2f Vector2f::normalize(Vector2f v)
120 {
121 double length = std::sqrt(v.x*v.x + v.y*v.y);
122
123 if (length < 1e-9)
124 {
125 return Vector2f(0.0f, 0.0f);
126 }
127 else
128 {
129 return Vector2f(
130 static_cast<float>(v.x / length),
131 static_cast<float>(v.y / length));
132 }
133 }
134
135 inline float Vector2f::length() const
136 {
137 return std::sqrt(x * x + y * y);
138 }
139
140 inline float Vector2f::length_squared() const
141 {
142 return x * x + y * y;
143 }
144
145 inline float Vector2f::dot(const Vector2f& v) const
146 {
147 return x * v.x + y * v.y;
148 }
149
150 inline Vector2f& Vector2f::operator+=(const Vector2f& rhs)
151 {
152 this->x = this->x + rhs.x;
153 this->y = this->y + rhs.y;
154 return *this;
155 }
156
157 inline Vector2f& Vector2f::operator-=(const Vector2f& rhs)
158 {
159 this->x = this->x - rhs.x;
160 this->y = this->y - rhs.y;
161 return *this;
162 }
163
164 inline Vector2f& Vector2f::operator*=(const float& rhs)
165 {
166 this->x = this->x * rhs;
167 this->y = this->y * rhs;
168 return *this;
169 }
170
171 inline Vector2f& Vector2f::operator/=(const float& rhs)
172 {
173 this->x = this->x / rhs;
174 this->y = this->y / rhs;
175 return *this;
176 }
177
178 inline Vector2f Vector2f::operator-()
179 {
180 return Vector2f(-this->x, -this->y);
181 }
182
183 inline bool operator==(const Vector2f& lhs, const Vector2f& rhs)
184 {
185 return lhs.x == rhs.x && lhs.y == rhs.y;
186 }
187
188 inline bool operator!=(const Vector2f& lhs, const Vector2f& rhs)
189 {
190 return !(lhs == rhs);
191 }
192
193 inline Vector2f operator+(const Vector2f& lhs, const Vector2f& rhs)
194 {
195 return Vector2f(lhs.x + rhs.x, lhs.y + rhs.y);
196 }
197
198 inline Vector2f operator-(const Vector2f& lhs, const Vector2f& rhs)
199 {
200 return Vector2f(lhs.x - rhs.x, lhs.y - rhs.y);
201 }
202
203 inline Vector2f operator*(const Vector2f& lhs, const float& rhs)
204 {
205 return Vector2f(lhs.x * rhs, lhs.y * rhs);
206 }
207
208 inline Vector2f operator*(const float& lhs, const Vector2f& rhs)
209 {
210 return rhs * lhs;
211 }
212
213 inline Vector2f operator/(const Vector2f& lhs, const float& rhs)
214 {
215 return Vector2f(lhs.x / rhs, lhs.y / rhs);
216 }
217
218 inline Vector2f Vector2f::zero()
219 {
220 Vector2f zero;
221 return zero;
222 }
223
224 inline bool Vector2f::is_zero() const
225 {
226 return *this == zero();
227 }
228
229 }
230
231 #endif // ASTRA_VECTOR2F_HPP
astra::Vector2f::dot
float dot(const Vector2f &v) const
dot cross width v.
Definition: Vector2f.hpp:145
astra
Definition: Array.hpp:20
astra::Vector2f::Vector2f
Vector2f()
constructs zero vector.
Definition: Vector2f.hpp:34
astra::Vector2f
Represents a float 2d vector.
Definition: Vector2f.hpp:29
astra::Vector2f::Vector2f
Vector2f(const astra_vector2f_t &v)
constructs for astra_vector2f_t
Definition: Vector2f.hpp:43
astra::Vector2f::length
float length() const
calc length
Definition: Vector2f.hpp:135
astra::Vector2f::is_zero
bool is_zero() const
adjust vector is zero.
Definition: Vector2f.hpp:224
astra::operator!=
bool operator!=(const StreamDescription &lhs, const StreamDescription &rhs)
compare StreamDescription is not equal
Definition: StreamDescription.hpp:105
astra::Vector2f::operator=
Vector2f & operator=(const astra_vector2f_t &rhs)
copy constructs for astra_vector2f_t
Definition: Vector2f.hpp:51
astra::Vector2f::Vector2f
Vector2f(float x, float y)
constructs
Definition: Vector2f.hpp:62
astra::Vector2f::length_squared
float length_squared() const
calc length squared
Definition: Vector2f.hpp:140
astra::Vector2f::normalize
static Vector2f normalize(Vector2f v)
normalize vector.
Definition: Vector2f.hpp:119
astra::Vector2f::zero
static Vector2f zero()
make vector all zero.
Definition: Vector2f.hpp:218
astra_vector2f_t
Definition: astra_ctypes.h:28


Astra SDK: Vector2i.hpp Source File

  • include
  • astra
Vector2i.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_VECTOR2I_HPP
18 #define ASTRA_VECTOR2I_HPP
19
20 #include <cmath>
21 #include <cstdint>
22 #include "capi/astra_ctypes.h"
23
24 namespace astra
25 {
30 struct Vector2i : public astra_vector2i_t
31 {
35 Vector2i()
36 {
37 this->x = 0;
38 this->y = 0;
39 }
40
44 Vector2i(const astra_vector2i_t& v)
45 {
46 *this = v;
47 }
48
52 Vector2i& operator=(const astra_vector2i_t& rhs)
53 {
54 ::astra_vector2i_t::x = rhs.x;
55 ::astra_vector2i_t::y = rhs.y;
56
57 return *this;
58 }
59
63 Vector2i(int x, int y)
64 {
65 this->x = x;
66 this->y = y;
67 }
68
69 inline operator ::astra_vector2i_t*() { return this; }
70 inline operator const ::astra_vector2i_t*() const { return this; }
71
76 float length() const;
81 std::int32_t length_squared() const;
87 std::int32_t dot(const Vector2i& v) const;
93 static Vector2i normalize(const Vector2i& v);
94
98 static inline const Vector2i& zero();
99
104 inline bool is_zero() const;
105
106 friend bool operator==(const Vector2i& lhs, const Vector2i& rhs);
107 friend Vector2i operator+(const Vector2i& lhs, const Vector2i& rhs);
108 friend Vector2i operator-(const Vector2i& lhs, const Vector2i& rhs);
109 friend Vector2i operator*(const Vector2i& lhs, const std::int32_t rhs);
110 friend Vector2i operator*(const std::int32_t lhs, const Vector2i& rhs);
111 friend Vector2i operator/(const Vector2i& lhs, const std::int32_t rhs);
112
113 Vector2i operator-();
114 Vector2i& operator+=(const Vector2i& rhs);
115 Vector2i& operator-=(const Vector2i& rhs);
116 Vector2i& operator*=(const std::int32_t rhs);
117 Vector2i& operator/=(const std::int32_t rhs);
118 };
119
120 inline Vector2i Vector2i::normalize(const Vector2i& v)
121 {
122 double length = std::sqrt(
123 static_cast<float>(v.x*v.x + v.y*v.y));
124
125 if (length < 1e-9)
126 {
127 return Vector2i(0, 0);
128 }
129 else
130 {
131 return Vector2i(
132 static_cast<std::int32_t>(v.x / length),
133 static_cast<std::int32_t>(v.y / length));
134 }
135 }
136
137 inline float Vector2i::length() const
138 {
139 return std::sqrt(
140 static_cast<float>(x * x + y * y));
141 }
142
143 inline std::int32_t Vector2i::length_squared() const
144 {
145 return x * x + y * y;
146 }
147
148
149 inline std::int32_t Vector2i::dot(const Vector2i& v) const
150 {
151 return x * v.x + y * v.y;
152 }
153
154 inline Vector2i& Vector2i::operator+=(const Vector2i& rhs)
155 {
156 this->x = this->x + rhs.x;
157 this->y = this->y + rhs.y;
158 return *this;
159 }
160
161 inline Vector2i& Vector2i::operator-=(const Vector2i& rhs)
162 {
163 this->x = this->x - rhs.x;
164 this->y = this->y - rhs.y;
165 return *this;
166 }
167
168 inline Vector2i& Vector2i::operator*=(const std::int32_t rhs)
169 {
170 this->x = static_cast<std::int32_t>(this->x * rhs);
171 this->y = static_cast<std::int32_t>(this->y * rhs);
172 return *this;
173 }
174
175 inline Vector2i& Vector2i::operator/=(const std::int32_t rhs)
176 {
177 this->x = static_cast<std::int32_t>(this->x / rhs);
178 this->y = static_cast<std::int32_t>(this->y / rhs);
179
180 return *this;
181 }
182
183 inline Vector2i Vector2i::operator-()
184 {
185 return Vector2i(-this->x, -this->y);
186 }
187
188 inline bool operator==(const Vector2i& lhs, const Vector2i& rhs)
189 {
190 return lhs.x == rhs.x && lhs.y == rhs.y;
191 }
192
193 inline bool operator!=(const Vector2i& lhs, const Vector2i& rhs)
194 {
195 return !(lhs == rhs);
196 }
197
198 inline Vector2i operator+(const Vector2i& lhs, const Vector2i& rhs)
199 {
200 return Vector2i(lhs.x + rhs.x, lhs.y + rhs.y);
201 }
202
203 inline Vector2i operator-(const Vector2i& lhs, const Vector2i& rhs)
204 {
205 return Vector2i(lhs.x - rhs.x, lhs.y - rhs.y);
206 }
207
208 inline Vector2i operator*(const Vector2i& lhs, const std::int32_t rhs)
209 {
210 return Vector2i(
211 static_cast<std::int32_t>(lhs.x * rhs),
212 static_cast<std::int32_t>(lhs.y * rhs));
213 }
214
215 inline Vector2i operator*(const std::int32_t lhs, const Vector2i& rhs)
216 {
217 return rhs * lhs;
218 }
219
220 inline Vector2i operator/(const Vector2i& lhs, const std::int32_t rhs)
221 {
222 return Vector2i(
223 static_cast<std::int32_t>(lhs.x / rhs),
224 static_cast<std::int32_t>(lhs.y / rhs));
225 }
226
227 inline const Vector2i& Vector2i::zero()
228 {
229 static Vector2i zero;
230 return zero;
231 }
232
233 inline bool Vector2i::is_zero() const
234 {
235 return *this == zero();
236 }
237 }
238
239 #endif // ASTRA_VECTOR2I_HPP
astra::Vector2i::Vector2i
Vector2i(const astra_vector2i_t &v)
constructs for astra_vector2i_t
Definition: Vector2i.hpp:44
astra::Vector2i::operator=
Vector2i & operator=(const astra_vector2i_t &rhs)
copy constructs for astra_vector2i_t
Definition: Vector2i.hpp:52
astra::Vector2i::length_squared
std::int32_t length_squared() const
calc length squared
Definition: Vector2i.hpp:143
astra::Vector2i::zero
static const Vector2i & zero()
make vector all zero.
Definition: Vector2i.hpp:227
astra
Definition: Array.hpp:20
astra::Vector2i
Represents a float 2d vector.
Definition: Vector2i.hpp:30
astra::Vector2i::Vector2i
Vector2i()
constructs zero vector.
Definition: Vector2i.hpp:35
astra::Vector2i::Vector2i
Vector2i(int x, int y)
constructs
Definition: Vector2i.hpp:63
astra::Vector2i::normalize
static Vector2i normalize(const Vector2i &v)
normalize vector.
Definition: Vector2i.hpp:120
astra::operator!=
bool operator!=(const StreamDescription &lhs, const StreamDescription &rhs)
compare StreamDescription is not equal
Definition: StreamDescription.hpp:105
astra::Vector2i::dot
std::int32_t dot(const Vector2i &v) const
dot cross width v.
Definition: Vector2i.hpp:149
astra::Vector2i::length
float length() const
calc length
Definition: Vector2i.hpp:137
astra_vector2i_t
Definition: astra_ctypes.h:23
astra::Vector2i::is_zero
bool is_zero() const
adjust vector is zero.
Definition: Vector2i.hpp:233


Astra SDK: Vector3f.hpp Source File

  • include
  • astra
Vector3f.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_VECTOR3F_HPP
18 #define ASTRA_VECTOR3F_HPP
19
20 #include <cmath>
21 #include "capi/astra_ctypes.h"
22
23 namespace astra {
24
29 struct Vector3f : public astra_vector3f_t
30 {
34 Vector3f()
35 {
36 this->x = 0.0;
37 this->y = 0.0;
38 this->z = 0.0;
39 }
40
44 Vector3f(const astra_vector3f_t& v)
45 {
46 *this = v;
47 }
48
52 Vector3f& operator=(const astra_vector3f_t& rhs)
53 {
54 ::astra_vector3f_t::x = rhs.x;
55 ::astra_vector3f_t::y = rhs.y;
56 ::astra_vector3f_t::z = rhs.z;
57
58 return *this;
59 }
60
64 Vector3f(float x, float y, float z)
65 {
66 this->x = x;
67 this->y = y;
68 this->z = z;
69 }
70
71 inline operator ::astra_vector3f_t*() { return this; }
72 inline operator const ::astra_vector3f_t*() const { return this; }
73
78 float length() const;
79
84 float length_squared() const;
85
91 float dot(const Vector3f& v) const;
92
98 Vector3f cross(const Vector3f& v) const;
99
103 static inline Vector3f zero();
104
110 static Vector3f normalize(Vector3f v);
111
112 friend bool operator==(const Vector3f& lhs, const Vector3f& rhs);
113 friend bool operator!=(const Vector3f& lhs, const Vector3f& rhs);
114
119 bool is_zero() const;
120
121 Vector3f& operator+=(const Vector3f& rhs);
122 Vector3f& operator-=(const Vector3f& rhs);
123 Vector3f& operator*=(const float& rhs);
124 Vector3f& operator/=(const float& rhs);
125
126 friend Vector3f operator+(const Vector3f& lhs, const Vector3f& rhs);
127 friend Vector3f operator-(const Vector3f& lhs, const Vector3f& rhs);
128 friend Vector3f operator*(const Vector3f& lhs, const float& rhs);
129 friend Vector3f operator*(const float& lhs, const Vector3f& rhs);
130 friend Vector3f operator/(const Vector3f& lhs, const float& rhs);
131
132 Vector3f operator-();
133 };
134
135 inline float Vector3f::length() const
136 {
137 return std::sqrt(x * x + y * y + z * z);
138 }
139
140 inline float Vector3f::length_squared() const
141 {
142 return x * x + y * y + z * z;
143 }
144
145 inline float Vector3f::dot(const Vector3f& v) const
146 {
147 return x * v.x + y * v.y + z * v.z;
148 }
149
150 inline Vector3f Vector3f::cross(const Vector3f& v) const
151 {
152 return Vector3f(y*v.z - z*v.y, z*v.x - x*v.z, x*v.y - y*v.x);
153 }
154
155 inline Vector3f Vector3f::normalize(Vector3f v)
156 {
157 double length = std::sqrt(v.x*v.x + v.y*v.y + v.z*v.z);
158 if (length < 1e-9)
159 {
160 return Vector3f(0.0f, 0.0f, 0.0f);
161 }
162 else
163 {
164 return Vector3f(
165 static_cast<float>(v.x / length),
166 static_cast<float>(v.y / length),
167 static_cast<float>(v.z / length));
168 }
169 }
170
171 inline Vector3f Vector3f::zero()
172 {
173 static Vector3f zero;
174 return zero;
175 }
176
177 inline bool Vector3f::is_zero() const
178 {
179 return *this == zero();
180 }
181
182 inline Vector3f& Vector3f::operator+=(const Vector3f& rhs)
183 {
184 this->x = this->x + rhs.x;
185 this->y = this->y + rhs.y;
186 this->z = this->z + rhs.z;
187 return *this;
188 }
189
190 inline Vector3f& Vector3f::operator-=(const Vector3f& rhs)
191 {
192 this->x = this->x - rhs.x;
193 this->y = this->y - rhs.y;
194 this->z = this->z - rhs.z;
195 return *this;
196 }
197
198 inline Vector3f& Vector3f::operator*=(const float& rhs)
199 {
200 this->x = this->x * rhs;
201 this->y = this->y * rhs;
202 this->z = this->z * rhs;
203 return *this;
204 }
205
206 inline Vector3f& Vector3f::operator/=(const float& rhs)
207 {
208 this->x = this->x / rhs;
209 this->y = this->y / rhs;
210 this->z = this->z / rhs;
211 return *this;
212 }
213
214 inline Vector3f Vector3f::operator-()
215 {
216 return Vector3f(-this->x, -this->y, -this->z);
217 }
218
219 inline bool operator==(const Vector3f& lhs, const Vector3f& rhs)
220 {
221 return lhs.x == rhs.x && lhs.y == rhs.y && lhs.z == rhs.z;
222 }
223
224 inline bool operator!=(const Vector3f& lhs, const Vector3f& rhs)
225 {
226 return !(lhs == rhs);
227 }
228
229 inline Vector3f operator+(const Vector3f& lhs, const Vector3f& rhs)
230 {
231 return Vector3f(lhs.x + rhs.x, lhs.y + rhs.y, lhs.z + rhs.z);
232 }
233
234 inline Vector3f operator-(const Vector3f& lhs, const Vector3f& rhs)
235 {
236 return Vector3f(lhs.x - rhs.x, lhs.y - rhs.y, lhs.z - rhs.z);
237 }
238
239 inline Vector3f operator*(const Vector3f& lhs, const float& rhs)
240 {
241 return Vector3f(lhs.x * rhs, lhs.y * rhs, lhs.z * rhs);
242 }
243
244 inline Vector3f operator*(const float& lhs, const Vector3f& rhs)
245 {
246 return rhs * lhs;
247 }
248
249 inline Vector3f operator/(const Vector3f& lhs, const float& rhs)
250 {
251 return Vector3f(lhs.x / rhs, lhs.y / rhs, lhs.z / rhs);
252 }
253 }
254
255 #endif /* ASTRA_VECTOR3F_HPP */
astra::Vector3f::operator=
Vector3f & operator=(const astra_vector3f_t &rhs)
copy constructs for astra_vector3f_t
Definition: Vector3f.hpp:52
astra::Vector3f::normalize
static Vector3f normalize(Vector3f v)
normalize vector.
Definition: Vector3f.hpp:155
astra::Vector3f::cross
Vector3f cross(const Vector3f &v) const
cross width v.
Definition: Vector3f.hpp:150
astra::Vector3f::is_zero
bool is_zero() const
adjust vector is zero.
Definition: Vector3f.hpp:177
astra::Vector3f::Vector3f
Vector3f(const astra_vector3f_t &v)
constructs for astra_vector3f_t
Definition: Vector3f.hpp:44
astra::Vector3f::Vector3f
Vector3f()
constructs zero vector.
Definition: Vector3f.hpp:34
astra
Definition: Array.hpp:20
astra_vector3f_t
Definition: astra_ctypes.h:33
astra::Vector3f::Vector3f
Vector3f(float x, float y, float z)
constructs
Definition: Vector3f.hpp:64
astra::Vector3f::length
float length() const
calc length
Definition: Vector3f.hpp:135
astra::Vector3f
Represents a float 3d vector.
Definition: Vector3f.hpp:29
astra::Vector3f::dot
float dot(const Vector3f &v) const
dot cross width v.
Definition: Vector3f.hpp:145
astra::Vector3f::zero
static Vector3f zero()
make vector all zero.
Definition: Vector3f.hpp:171
astra::Vector3f::length_squared
float length_squared() const
calc length
Definition: Vector3f.hpp:140


Astra SDK: Vector3i.hpp Source File

  • include
  • astra
Vector3i.hpp
1 // This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
2 // Copyright (c) 2015-2017 Orbbec 3D
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 // Be excellent to each other.
17 #ifndef ASTRA_VECTOR3I_HPP
18 #define ASTRA_VECTOR3I_HPP
19
20 #include <cmath>
21 #include <cstdint>
22 #include "capi/astra_ctypes.h"
23
24 namespace astra {
25
30 struct Vector3i : public astra_vector3i_t
31 {
35 Vector3i()
36 {
37 this->x = 0;
38 this->y = 0;
39 this->z = 0;
40 }
41
45 Vector3i(const astra_vector3i_t& v)
46 {
47 *this = v;
48 }
49
53 Vector3i& operator=(const astra_vector3i_t& rhs)
54 {
55 ::astra_vector3i_t::x = rhs.x;
56 ::astra_vector3i_t::y = rhs.y;
57 ::astra_vector3i_t::z = rhs.z;
58
59 return *this;
60 }
61
65 Vector3i(int x, int y, int z)
66 {
67 this->x = x;
68 this->y = y;
69 this->z = z;
70 }
71
72 inline operator ::astra_vector3i_t*() { return this; }
73 inline operator const ::astra_vector3i_t*() const { return this; }
74
79 float length() const;
84 std::int32_t length_squared() const;
90 std::int32_t dot(const Vector3i& v) const;
91
97 Vector3i cross(const Vector3i& v) const;
98
102 static Vector3i normalize(const Vector3i& v);
103
109 static inline const Vector3i& zero();
110
111 friend bool operator==(const Vector3i& lhs, const Vector3i& rhs);
112 friend bool operator!=(const Vector3i& lhs, const Vector3i& rhs);
113
118 bool is_zero() const;
119
120 Vector3i& operator+=(const Vector3i& rhs);
121 Vector3i& operator-=(const Vector3i& rhs);
122 Vector3i& operator*=(const std::int32_t rhs);
123 Vector3i& operator/=(const std::int32_t rhs);
124
125 friend Vector3i operator+(const Vector3i& lhs, const Vector3i& rhs);
126 friend Vector3i operator-(const Vector3i& lhs, const Vector3i& rhs);
127 friend Vector3i operator*(const Vector3i& lhs, const std::int32_t rhs);
128 friend Vector3i operator*(const float lhs, const Vector3i& rhs);
129 friend Vector3i operator/(const Vector3i& lhs, const std::int32_t rhs);
130
131 Vector3i operator-();
132 };
133
134 inline float Vector3i::length() const
135 {
136 return std::sqrt(static_cast<float>(x * x + y * y + z * z));
137 }
138
139 inline std::int32_t Vector3i::length_squared() const
140 {
141 return x * x + y * y + z * z;
142 }
143
144 inline std::int32_t Vector3i::dot(const Vector3i& v) const
145 {
146 return x * v.x + y * v.y + z * v.z;
147 }
148
149 inline Vector3i Vector3i::cross(const Vector3i& v) const
150 {
151 return Vector3i(
152 static_cast<std::int32_t>(y*v.z - z*v.y),
153 static_cast<std::int32_t>(z*v.x - x*v.z),
154 static_cast<std::int32_t>(x*v.y - y*v.x));
155 }
156
157 inline Vector3i Vector3i::normalize(const Vector3i& v)
158 {
159 double length = sqrt(
160 static_cast<float>(v.x*v.x + v.y*v.y + v.z*v.z));
161
162 if (length < 1e-9)
163 {
164 return Vector3i(0, 0, 0);
165 }
166 else
167 {
168 return Vector3i(
169 static_cast<std::int32_t>(v.x / length),
170 static_cast<std::int32_t>(v.y / length),
171 static_cast<std::int32_t>(v.z / length));
172 }
173 }
174
175 inline bool Vector3i::is_zero() const
176 {
177 Vector3i zero;
178 return *this == zero;
179 }
180
181 inline Vector3i& Vector3i::operator+=(const Vector3i& rhs)
182 {
183 this->x = this->x + rhs.x;
184 this->y = this->y + rhs.y;
185 this->z = this->z + rhs.z;
186 return *this;
187 }
188
189 inline Vector3i& Vector3i::operator-=(const Vector3i& rhs)
190 {
191 this->x = this->x - rhs.x;
192 this->y = this->y - rhs.y;
193 this->z = this->z - rhs.z;
194 return *this;
195 }
196
197 inline Vector3i& Vector3i::operator*=(const std::int32_t rhs)
198 {
199 this->x = this->x * rhs;
200 this->y = this->y * rhs;
201 this->z = this->z * rhs;
202 return *this;
203 }
204
205 inline Vector3i& Vector3i::operator/=(const std::int32_t rhs)
206 {
207 this->x = static_cast<std::int32_t>(this->x / rhs);
208 this->y = static_cast<std::int32_t>(this->y / rhs);
209 this->z = static_cast<std::int32_t>(this->z / rhs);
210 return *this;
211 }
212
213 inline Vector3i Vector3i::operator-()
214 {
215 return Vector3i(-this->x, -this->y, -this->z);
216 }
217
218 inline bool operator==(const Vector3i& lhs, const Vector3i& rhs)
219 {
220 return lhs.x == rhs.x && lhs.y == rhs.y && lhs.z == rhs.z;
221 }
222
223 inline bool operator!=(const Vector3i& lhs, const Vector3i& rhs)
224 {
225 return !(lhs == rhs);
226 }
227
228 inline Vector3i operator+(const Vector3i& lhs, const Vector3i& rhs)
229 {
230 return Vector3i(lhs.x + rhs.x, lhs.y + rhs.y, lhs.z + rhs.z);
231 }
232
233 inline Vector3i operator-(const Vector3i& lhs, const Vector3i& rhs)
234 {
235 return Vector3i(lhs.x - rhs.x, lhs.y - rhs.y, lhs.z - rhs.z);
236 }
237
238 inline Vector3i operator*(const Vector3i& lhs, const std::int32_t rhs)
239 {
240 return Vector3i(lhs.x * rhs, lhs.y * rhs, lhs.z * rhs);
241 }
242
243 inline Vector3i operator*(const std::int32_t lhs, const Vector3i& rhs)
244 {
245 return rhs * lhs;
246 }
247
248 inline Vector3i operator/(const Vector3i& lhs, const std::int32_t rhs)
249 {
250 return Vector3i(
251 static_cast<std::int32_t>(lhs.x / rhs),
252 static_cast<std::int32_t>(lhs.y / rhs),
253 static_cast<std::int32_t>(lhs.z / rhs));
254 }
255
256 inline const Vector3i& Vector3i::zero()
257 {
258 static Vector3i zero;
259 return zero;
260 }
261 }
262
263 #endif /* ASTRA_VECTOR3I_HPP */
astra::Vector3i::zero
static const Vector3i & zero()
normalize vector.
Definition: Vector3i.hpp:256
astra_vector3i_t
Definition: astra_ctypes.h:39
astra::Vector3i::is_zero
bool is_zero() const
adjust vector is zero.
Definition: Vector3i.hpp:175
astra::Vector3i::Vector3i
Vector3i()
constructs zero vector.
Definition: Vector3i.hpp:35
astra
Definition: Array.hpp:20
astra::Vector3i::dot
std::int32_t dot(const Vector3i &v) const
dot cross width v.
Definition: Vector3i.hpp:144
astra::Vector3i::length
float length() const
calc length
Definition: Vector3i.hpp:134
astra::Vector3i::length_squared
std::int32_t length_squared() const
calc length
Definition: Vector3i.hpp:139
astra::Vector3i::Vector3i
Vector3i(const astra_vector3i_t &v)
constructs for astra_vector3i_t
Definition: Vector3i.hpp:45
astra::Vector3i::Vector3i
Vector3i(int x, int y, int z)
constructs
Definition: Vector3i.hpp:65
astra::Vector3i::cross
Vector3i cross(const Vector3i &v) const
cross width v.
Definition: Vector3i.hpp:149
astra::Vector3i
Represents a float 3d vector.
Definition: Vector3i.hpp:30
astra::Vector3i::operator=
Vector3i & operator=(const astra_vector3i_t &rhs)
copy constructs for astra_vector3i_t
Definition: Vector3i.hpp:53
astra::Vector3i::normalize
static Vector3i normalize(const Vector3i &v)
make vector all zero.
Definition: Vector3i.hpp:157


Astra SDK: Examples

Examples
Here is a list of all examples:
  • BodyReaderPoll\main.c
  • ColorizedBodyViewer-SFML\main.cpp
  • ColorReaderEvent\main.c
  • ColorReaderEventCPP\main.cpp
  • ColorReaderPoll\main.c
  • DepthReaderEvent\main.c
  • DepthReaderEventCPP\main.cpp
  • DepthReaderPoll\main.c
  • HandReader\main.c
  • InfraredColorReaderEvent\main.c
  • InfraredReaderEvent\main.c
  • InfraredReaderPoll\main.c
  • MaskedColorViewer-SFML\main.cpp
  • MultiSensorViewer-SFML\main.cpp
  • SimpleBodyViewer-SFML\main.cpp
  • SimpleColorViewer-SFML\main.cpp
  • SimpleDepthViewer-SFML\main.cpp
  • SimpleHandViewer-SFML\main.cpp
  • SimpleStreamViewer-SFML\main.cpp


Astra SDK: BodyReaderPoll\main.c

BodyReaderPoll\main.c
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <astra/capi/astra.h>
#include <stdio.h>
#include <stdint.h>
#include <stdbool.h>
#include <key_handler.h>
void output_floor(astra_bodyframe_t bodyFrame)
{
astra_floor_info_t floorInfo;
astra_status_t rc = astra_bodyframe_floor_info(bodyFrame, &floorInfo);
if (rc != ASTRA_STATUS_SUCCESS)
{
printf("Error %d in astra_bodyframe_floor_info()\n", rc);
return;
}
const astra_bool_t floorDetected = floorInfo.floorDetected;
const astra_plane_t* floorPlane = &floorInfo.floorPlane;
const astra_floormask_t* floorMask = &floorInfo.floorMask;
if (floorDetected != ASTRA_FALSE)
{
printf("Floor plane: [%f, %f, %f, %f]\n",
floorPlane->a,
floorPlane->b,
floorPlane->c,
floorPlane->d);
const int32_t bottomCenterIndex = floorMask->width / 2 + floorMask->width * (floorMask->height - 1);
printf("Floor mask: width: %d height: %d bottom center value: %d\n",
floorMask->width,
floorMask->height,
floorMask->data[bottomCenterIndex]);
}
}
void output_body_mask(astra_bodyframe_t bodyFrame)
{
astra_bodymask_t bodyMask;
const astra_status_t rc = astra_bodyframe_bodymask(bodyFrame, &bodyMask);
if (rc != ASTRA_STATUS_SUCCESS)
{
printf("Error %d in astra_bodyframe_bodymask()\n", rc);
return;
}
const int32_t centerIndex = bodyMask.width / 2 + bodyMask.width * bodyMask.height / 2;
printf("Body mask: width: %d height: %d center value: %d\n",
bodyMask.width,
bodyMask.height,
bodyMask.data[centerIndex]);
}
void output_bodyframe_info(astra_bodyframe_t bodyFrame)
{
astra_bodyframe_info_t info;
const astra_status_t rc = astra_bodyframe_info(bodyFrame, &info);
if (rc != ASTRA_STATUS_SUCCESS)
{
printf("Error %d in astra_bodyframe_info()\n", rc);
return;
}
// width and height of floor mask, body mask, and the size of depth image
// that joint depth position is relative to.
const int32_t width = info.width;
const int32_t height = info.height;
printf("BodyFrame info: Width: %d Height: %d\n",
width,
height);
}
void output_joint(const int32_t bodyId, const astra_joint_t* joint)
{
// jointType is one of ASTRA_JOINT_* which exists for each joint type
const astra_joint_type_t jointType = joint->type;
// jointStatus is one of:
// ASTRA_JOINT_STATUS_NOT_TRACKED = 0,
// ASTRA_JOINT_STATUS_LOW_CONFIDENCE = 1,
// ASTRA_JOINT_STATUS_TRACKED = 2,
const astra_joint_status_t jointStatus = joint->status;
const astra_vector3f_t* worldPos = &joint->worldPosition;
// depthPosition is in pixels from 0 to width and 0 to height
// where width and height are member of astra_bodyframe_info_t
// which is obtained from astra_bodyframe_info().
const astra_vector2f_t* depthPos = &joint->depthPosition;
printf("Body %u Joint %d status %d @ world (%.1f, %.1f, %.1f) depth (%.1f, %.1f)\n",
bodyId,
jointType,
jointStatus,
worldPos->x,
worldPos->y,
worldPos->z,
depthPos->x,
depthPos->y);
// orientation is a 3x3 rotation matrix where the column vectors also
// represent the orthogonal basis vectors for the x, y, and z axes.
const astra_matrix3x3_t* orientation = &joint->orientation;
const astra_vector3f_t* xAxis = &orientation->xAxis; // same as orientation->m00, m10, m20
const astra_vector3f_t* yAxis = &orientation->yAxis; // same as orientation->m01, m11, m21
const astra_vector3f_t* zAxis = &orientation->zAxis; // same as orientation->m02, m12, m22
printf("Head orientation x: [%f %f %f]\n", xAxis->x, xAxis->y, xAxis->z);
printf("Head orientation y: [%f %f %f]\n", yAxis->x, yAxis->y, yAxis->z);
printf("Head orientation z: [%f %f %f]\n", zAxis->x, zAxis->y, zAxis->z);
}
void output_hand_poses(const astra_body_t* body)
{
const astra_handpose_info_t* handPoses = &body->handPoses;
// astra_handpose_t is one of:
// ASTRA_HANDPOSE_UNKNOWN = 0
// ASTRA_HANDPOSE_GRIP = 1
const astra_handpose_t leftHandPose = handPoses->leftHand;
const astra_handpose_t rightHandPose = handPoses->rightHand;
printf("Body %d Left hand pose: %d Right hand pose: %d\n",
body->id,
leftHandPose,
rightHandPose);
}
void output_bodies(astra_bodyframe_t bodyFrame)
{
int i;
astra_body_list_t bodyList;
const astra_status_t rc = astra_bodyframe_body_list(bodyFrame, &bodyList);
if (rc != ASTRA_STATUS_SUCCESS)
{
printf("Error %d in astra_bodyframe_body_list()\n", rc);
return;
}
for(i = 0; i < bodyList.count; ++i)
{
astra_body_t* body = &bodyList.bodies[i];
// Pixels in the body mask with the same value as bodyId are
// from the same body.
astra_body_id_t bodyId = body->id;
// bodyStatus is one of:
// ASTRA_BODY_STATUS_NOT_TRACKING = 0,
// ASTRA_BODY_STATUS_LOST = 1,
// ASTRA_BODY_STATUS_TRACKING_STARTED = 2,
// ASTRA_BODY_STATUS_TRACKING = 3,
astra_body_status_t bodyStatus = body->status;
if (bodyStatus == ASTRA_BODY_STATUS_TRACKING_STARTED)
{
printf("Body Id: %d Status: Tracking started\n", bodyId);
}
if (bodyStatus == ASTRA_BODY_STATUS_TRACKING)
{
printf("Body Id: %d Status: Tracking\n", bodyId);
}
if (bodyStatus == ASTRA_BODY_STATUS_TRACKING_STARTED ||
bodyStatus == ASTRA_BODY_STATUS_TRACKING)
{
const astra_vector3f_t* centerOfMass = &body->centerOfMass;
const astra_body_tracking_feature_flags_t features = body->features;
const bool jointTrackingEnabled = (features & ASTRA_BODY_TRACKING_JOINTS) == ASTRA_BODY_TRACKING_JOINTS;
const bool handPoseRecognitionEnabled = (features & ASTRA_BODY_TRACKING_HAND_POSES) == ASTRA_BODY_TRACKING_HAND_POSES;
printf("Body %d CenterOfMass (%f, %f, %f) Joint Tracking Enabled: %s Hand Pose Recognition Enabled: %s\n",
bodyId,
centerOfMass->x, centerOfMass->y, centerOfMass->z,
jointTrackingEnabled ? "True" : "False",
handPoseRecognitionEnabled ? "True" : "False");
const astra_joint_t* joint = &body->joints[ASTRA_JOINT_HEAD];
output_joint(bodyId, joint);
output_hand_poses(body);
}
else if (bodyStatus == ASTRA_BODY_STATUS_LOST)
{
printf("Body %u Status: Tracking lost.\n", bodyId);
}
else // bodyStatus == ASTRA_BODY_STATUS_NOT_TRACKING
{
printf("Body Id: %d Status: Not Tracking\n", bodyId);
}
}
}
void output_bodyframe(astra_bodyframe_t bodyFrame)
{
output_floor(bodyFrame);
output_body_mask(bodyFrame);
output_bodyframe_info(bodyFrame);
output_bodies(bodyFrame);
}
int main(int argc, char* argv[])
{
set_key_handler();
astra_initialize();
const char* licenseString = "<INSERT LICENSE KEY HERE>";
orbbec_body_tracking_set_license(licenseString);
astra_streamsetconnection_t sensor;
astra_streamset_open("device/default", &sensor);
astra_reader_t reader;
astra_reader_create(sensor, &reader);
astra_bodystream_t bodyStream;
astra_reader_get_bodystream(reader, &bodyStream);
astra_stream_start(bodyStream);
do
{
astra_update();
astra_reader_frame_t frame;
astra_status_t rc = astra_reader_open_frame(reader, 0, &frame);
if (rc == ASTRA_STATUS_SUCCESS)
{
astra_bodyframe_t bodyFrame;
astra_frame_get_bodyframe(frame, &bodyFrame);
astra_frame_index_t frameIndex;
astra_bodyframe_get_frameindex(bodyFrame, &frameIndex);
printf("Frame index: %d\n", frameIndex);
output_bodyframe(bodyFrame);
printf("----------------------------\n");
astra_reader_close_frame(&frame);
}
} while (shouldContinue);
astra_reader_destroy(&reader);
astra_streamset_close(&sensor);
astra_terminate();
}


Astra SDK: ColorizedBodyViewer-SFML\main.cpp

ColorizedBodyViewer-SFML\main.cpp
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <SFML/Graphics.hpp>
#include <astra/astra.hpp>
#include "LitDepthVisualizer.hpp"
#include <chrono>
#include <iostream>
#include <iomanip>
#include <key_handler.h>
#include <sstream>
class MaskedColorFrameListener : public astra::FrameListener
{
public:
MaskedColorFrameListener(const astra::CoordinateMapper& coordinateMapper)
: coordinateMapper_(coordinateMapper)
{
prev_ = ClockType::now();
font_.loadFromFile("Inconsolata.otf");
}
void ensure_texture(int width, int height)
{
if (!displayBuffer_ ||
width != displayWidth_ ||
height != displayHeight_)
{
displayWidth_ = width;
displayHeight_ = height;
// texture is RGBA
const int byteLength = displayWidth_ * displayHeight_ * 4;
displayBuffer_ = BufferPtr(new uint8_t[byteLength]);
std::fill(&displayBuffer_[0], &displayBuffer_[0] + byteLength, 0);
texture_.create(displayWidth_, displayHeight_);
sprite_.setTexture(texture_, true);
sprite_.setPosition(0, 0);
}
}
void check_fps()
{
const float frameWeight = .2f;
const ClockType::time_point now = ClockType::now();
const float elapsedMillis = std::chrono::duration_cast<DurationType>(now - prev_).count();
elapsedMillis_ = elapsedMillis * frameWeight + elapsedMillis_ * (1.f - frameWeight);
prev_ = now;
const float fps = 1000.f / elapsedMillis;
const auto precision = std::cout.precision();
std::cout << std::fixed
<< std::setprecision(1)
<< fps << " fps ("
<< std::setprecision(1)
<< elapsedMillis_ << " ms)"
<< std::setprecision(precision)
<< std::endl;
}
void on_frame_ready(astra::StreamReader& reader,
astra::Frame& frame) override
{
const astra::ColorizedBodyFrame MaskedColorFrame = frame.get<astra::ColorizedBodyFrame>();
const int width = MaskedColorFrame.width();
const int height = MaskedColorFrame.height();
ensure_texture(width, height);
check_fps();
if (isPaused_) { return; }
copy_depth_data(frame);
const float x_scale = float(width) / depthWidth_;
const float y_scale = float(height) / depthHeight_;
const astra::RgbaPixel* vizBuffer = MaskedColorFrame.data();
for (int y = 0; y < height; ++y)
{
for (int x = 0; x < width; ++x)
{
const int index_color = y * width + x;
const int rgbaOffset = index_color * 4;
if (vizBuffer[index_color].alpha != 0)
{
displayBuffer_[rgbaOffset] = vizBuffer[index_color].r;
displayBuffer_[rgbaOffset + 1] = vizBuffer[index_color].g;
displayBuffer_[rgbaOffset + 2] = vizBuffer[index_color].b;
displayBuffer_[rgbaOffset + 3] = vizBuffer[index_color].alpha;
}
else
{
const int index_depth = int(y / y_scale + 0.5) * depthWidth_ +
int(x / x_scale + 0.5);
displayBuffer_[rgbaOffset] = uint8_t(depthData_[index_depth]);
displayBuffer_[rgbaOffset + 1] = uint8_t(depthData_[index_depth]);
displayBuffer_[rgbaOffset + 2] = uint8_t(depthData_[index_depth]);
displayBuffer_[rgbaOffset + 3] = 255;
}
}
}
texture_.update(displayBuffer_.get());
}
void copy_depth_data(astra::Frame& frame)
{
const astra::DepthFrame depthFrame = frame.get<astra::DepthFrame>();
if (depthFrame.is_valid())
{
const int width = depthFrame.width();
const int height = depthFrame.height();
if (!depthData_ || width != depthWidth_ || height != depthHeight_)
{
depthWidth_ = width;
depthHeight_ = height;
// texture is RGBA
const int byteLength = depthWidth_ * depthHeight_ * sizeof(uint16_t);
depthData_ = DepthPtr(new int16_t[byteLength]);
}
depthFrame.copy_to(&depthData_[0]);
}
}
void update_mouse_position(sf::RenderWindow& window)
{
const sf::Vector2i position = sf::Mouse::getPosition(window);
const sf::Vector2u windowSize = window.getSize();
mouseNormX_ = position.x / float(windowSize.x);
mouseNormY_ = position.y / float(windowSize.y);
}
void draw_text(sf::RenderWindow& window,
sf::Text& text,
sf::Color color,
const int x,
const int y) const
{
text.setColor(sf::Color::Black);
text.setPosition(x + 5, y + 5);
window.draw(text);
text.setColor(color);
text.setPosition(x, y);
window.draw(text);
}
void draw_mouse_overlay(sf::RenderWindow& window,
const float depthWScale,
const float depthHScale) const
{
if (!isMouseOverlayEnabled_ || !depthData_) { return; }
const int mouseX = depthWidth_ * mouseNormX_;
const int mouseY = depthHeight_ * mouseNormY_;
if (mouseX >= depthWidth_ ||
mouseY >= depthHeight_ ||
mouseX < 0 ||
mouseY < 0) { return; }
const size_t index = (depthWidth_ * mouseY + mouseX);
const short z = depthData_[index];
float worldX, worldY, worldZ;
coordinateMapper_.convert_depth_to_world(float(mouseX),
float(mouseY),
float(z),
worldX,
worldY,
worldZ);
std::stringstream str;
str << std::fixed
<< std::setprecision(0)
<< "(" << mouseX << ", " << mouseY << ") "
<< "X: " << worldX << " Y: " << worldY << " Z: " << worldZ;
const int characterSize = 40;
sf::Text text(str.str(), font_);
text.setCharacterSize(characterSize);
text.setStyle(sf::Text::Bold);
const float displayX = 10.f;
const float margin = 10.f;
const float displayY = window.getView().getSize().y - (margin + characterSize);
draw_text(window, text, sf::Color::White, displayX, displayY);
}
void draw_to(sf::RenderWindow& window)
{
if (displayBuffer_ != nullptr)
{
const float depthWScale = window.getView().getSize().x / displayWidth_;
const float depthHScale = window.getView().getSize().y / displayHeight_;
sprite_.setScale(depthWScale, depthHScale);
window.draw(sprite_);
draw_mouse_overlay(window, depthWScale, depthHScale);
}
}
void toggle_paused()
{
isPaused_ = !isPaused_;
}
bool is_paused() const
{
return isPaused_;
}
void toggle_overlay()
{
isMouseOverlayEnabled_ = !isMouseOverlayEnabled_;
}
bool overlay_enabled() const
{
return isMouseOverlayEnabled_;
}
private:
samples::common::LitDepthVisualizer visualizer_;
using DurationType = std::chrono::milliseconds;
using ClockType = std::chrono::high_resolution_clock;
ClockType::time_point prev_;
float elapsedMillis_{.0f};
sf::Texture texture_;
sf::Sprite sprite_;
sf::Font font_;
const astra::CoordinateMapper& coordinateMapper_;
int displayWidth_{0};
int displayHeight_{0};
using BufferPtr = std::unique_ptr<uint8_t[]>;
BufferPtr displayBuffer_{nullptr};
int depthWidth_{0};
int depthHeight_{0};
using DepthPtr = std::unique_ptr<int16_t[]>;
DepthPtr depthData_{nullptr};
float mouseNormX_{0};
float mouseNormY_{0};
bool isPaused_{false};
bool isMouseOverlayEnabled_{true};
};
astra::DepthStream configure_depth(astra::StreamReader& reader)
{
auto depthStream = reader.stream<astra::DepthStream>();
//We don't have to set the mode to start the stream, but if you want to here is how:
astra::ImageStreamMode depthMode;
depthMode.set_width(320);
depthMode.set_height(240);
depthMode.set_pixel_format(astra_pixel_formats::ASTRA_PIXEL_FORMAT_DEPTH_MM);
depthMode.set_fps(30);
depthStream.set_mode(depthMode);
return depthStream;
}
int main(int argc, char** argv)
{
astra::initialize();
const char* licenseString = "<INSERT LICENSE KEY HERE>";
orbbec_body_tracking_set_license(licenseString);
set_key_handler();
const char* windowTitle = "Colorized Body Viewer";
sf::RenderWindow window(sf::VideoMode(1280, 960), windowTitle);
#ifdef _WIN32
auto fullscreenStyle = sf::Style::None;
#else
auto fullscreenStyle = sf::Style::Fullscreen;
#endif
const sf::VideoMode fullScreenMode = sf::VideoMode::getFullscreenModes()[0];
const sf::VideoMode windowedMode(1280, 1024);
bool isFullScreen = false;
astra::StreamSet streamSet;
astra::StreamReader reader = streamSet.create_reader();
auto depthStream = configure_depth(reader);
depthStream.start();
reader.stream<astra::BodyStream>().start();
reader.stream<astra::ColorStream>().start();
//reader.stream<astra::MaskedColorStream>().start();
reader.stream<astra::ColorizedBodyStream>().start();
auto coordinateMapper = depthStream.coordinateMapper();
MaskedColorFrameListener listener(coordinateMapper);
reader.add_listener(listener);
while (window.isOpen())
{
astra_update();
sf::Event event;
while (window.pollEvent(event))
{
switch (event.type)
{
case sf::Event::Closed:
window.close();
break;
case sf::Event::KeyPressed:
{
if (event.key.code == sf::Keyboard::C && event.key.control)
{
window.close();
}
switch (event.key.code)
{
case sf::Keyboard::Escape:
window.close();
break;
case sf::Keyboard::F:
if (isFullScreen)
{
window.create(windowedMode, windowTitle, sf::Style::Default);
}
else
{
window.create(fullScreenMode, windowTitle, fullscreenStyle);
}
isFullScreen = !isFullScreen;
break;
case sf::Keyboard::R:
depthStream.enable_registration(!depthStream.registration_enabled());
break;
case sf::Keyboard::M:
depthStream.enable_mirroring(!depthStream.mirroring_enabled());
break;
case sf::Keyboard::P:
listener.toggle_paused();
break;
case sf::Keyboard::Space:
listener.toggle_overlay();
break;
default:
break;
}
break;
}
case sf::Event::MouseMoved:
{
listener.update_mouse_position(window);
break;
}
default:
break;
}
}
// clear the window with black color
window.clear(sf::Color::Black);
listener.draw_to(window);
window.display();
if (!shouldContinue)
{
window.close();
}
}
astra::terminate();
return 0;
}


Astra SDK: ColorReaderEvent\main.c

ColorReaderEvent\main.c
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <astra/capi/astra.h>
#include <stdio.h>
#include <key_handler.h>
void print_color(astra_colorframe_t colorFrame)
{
astra_image_metadata_t metadata;
astra_rgb_pixel_t* colorData_rgb;
uint32_t colorByteLength;
astra_colorframe_get_data_rgb_ptr(colorFrame, &colorData_rgb, &colorByteLength);
astra_colorframe_get_metadata(colorFrame, &metadata);
int width = metadata.width;
int height = metadata.height;
size_t index = ((width * (height / 2)) + (width / 2));
astra_frame_index_t frameIndex;
astra_colorframe_get_frameindex(colorFrame, &frameIndex);
astra_rgb_pixel_t middle = colorData_rgb[index];
printf("color frameIndex: %d r: %d g: %d b: %d \n", frameIndex, (int)(middle.r), (int)(middle.g), (int)(middle.b));
}
void frame_ready(void* clientTag, astra_reader_t reader, astra_reader_frame_t frame)
{
astra_colorframe_t colorFrame;
astra_frame_get_colorframe(frame, &colorFrame);
print_color(colorFrame);
}
int main(int argc, char* argv[])
{
set_key_handler();
astra_initialize();
astra_streamsetconnection_t sensor;
astra_streamset_open("device/default", &sensor);
astra_reader_t reader;
astra_reader_create(sensor, &reader);
astra_colorstream_t colorStream;
astra_reader_get_colorstream(reader, &colorStream);
astra_stream_start(colorStream);
astra_reader_callback_id_t callbackId;
astra_reader_register_frame_ready_callback(reader, &frame_ready, NULL, &callbackId);
do
{
astra_update();
} while (shouldContinue);
astra_reader_unregister_frame_ready_callback(&callbackId);
astra_reader_destroy(&reader);
astra_streamset_close(&sensor);
astra_terminate();
}


Astra SDK: ColorReaderEventCPP\main.cpp

ColorReaderEventCPP\main.cpp
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <astra/astra.hpp>
#include <cstdio>
#include <iostream>
#include <key_handler.h>
class SampleFrameListener : public astra::FrameListener
{
private:
using buffer_ptr = std::unique_ptr<astra::RgbPixel []>;
buffer_ptr buffer_;
unsigned int lastWidth_;
unsigned int lastHeight_;
public:
virtual void on_frame_ready(astra::StreamReader& reader,
astra::Frame& frame) override
{
const astra::ColorFrame colorFrame = frame.get<astra::ColorFrame>();
if (colorFrame.is_valid())
{
print_color(colorFrame);
}
}
void print_color(const astra::ColorFrame& colorFrame)
{
if (colorFrame.is_valid())
{
int width = colorFrame.width();
int height = colorFrame.height();
int frameIndex = colorFrame.frame_index();
if (width != lastWidth_ || height != lastHeight_){
buffer_ = buffer_ptr(new astra::RgbPixel[colorFrame.length()]);
lastWidth_ = width;
lastHeight_ = height;
}
colorFrame.copy_to(buffer_.get());
size_t index = ((width * (height / 2.0f)) + (width / 2.0f));
astra::RgbPixel middle = buffer_[index];
std::cout << "color frameIndex: " << frameIndex
<< " r: " << static_cast<int>(middle.r)
<< " g: " << static_cast<int>(middle.g)
<< " b: " << static_cast<int>(middle.b)
<< std::endl;
}
}
};
int main(int argc, char** argv)
{
astra::initialize();
set_key_handler();
astra::StreamSet streamSet;
astra::StreamReader reader = streamSet.create_reader();
SampleFrameListener listener;
reader.stream<astra::ColorStream>().start();
std::cout << "colorStream -- hFov: "
<< reader.stream<astra::ColorStream>().hFov()
<< " vFov: "
<< reader.stream<astra::ColorStream>().vFov()
<< std::endl;
reader.add_listener(listener);
do
{
astra_update();
} while (shouldContinue);
reader.remove_listener(listener);
astra::terminate();
}


Astra SDK: ColorReaderPoll\main.c

ColorReaderPoll\main.c
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <astra/capi/astra.h>
#include <stdio.h>
#include <key_handler.h>
void print_color(astra_colorframe_t colorFrame)
{
astra_image_metadata_t metadata;
astra_rgb_pixel_t* colorData_rgb;
uint32_t colorByteLength;
astra_colorframe_get_data_rgb_ptr(colorFrame, &colorData_rgb, &colorByteLength);
astra_colorframe_get_metadata(colorFrame, &metadata);
int width = metadata.width;
int height = metadata.height;
size_t index = ((width * (height / 2)) + (width / 2));
astra_frame_index_t frameIndex;
astra_colorframe_get_frameindex(colorFrame, &frameIndex);
astra_rgb_pixel_t middle = colorData_rgb[index];
printf("color frameIndex: %d r: %d g: %d b: %d \n", frameIndex, (int)(middle.r), (int)(middle.g), (int)(middle.b));
}
int main(int argc, char* argv[])
{
set_key_handler();
astra_initialize();
astra_streamsetconnection_t sensor;
astra_streamset_open("device/default", &sensor);
astra_reader_t reader;
astra_reader_create(sensor, &reader);
astra_depthstream_t colorStream;
astra_reader_get_colorstream(reader, &colorStream);
astra_stream_start(colorStream);
astra_frame_index_t lastFrameIndex = -1;
do
{
astra_update();
astra_reader_frame_t frame;
astra_status_t rc = astra_reader_open_frame(reader, 0, &frame);
if (rc == ASTRA_STATUS_SUCCESS)
{
astra_colorframe_t colorFrame;
astra_frame_get_colorframe(frame, &colorFrame);
astra_frame_index_t newFrameIndex;
astra_colorframe_get_frameindex(colorFrame, &newFrameIndex);
if (lastFrameIndex == newFrameIndex)
{
printf("duplicate frame index: %d\n", lastFrameIndex);
}
lastFrameIndex = newFrameIndex;
print_color(colorFrame);
astra_reader_close_frame(&frame);
}
} while (shouldContinue);
astra_reader_destroy(&reader);
astra_streamset_close(&sensor);
astra_terminate();
}


Astra SDK: DepthReaderEvent\main.c

DepthReaderEvent\main.c
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <astra/capi/astra.h>
#include <stdio.h>
#include <key_handler.h>
void print_depth(astra_depthframe_t depthFrame)
{
astra_image_metadata_t metadata;
int16_t* depthData;
uint32_t depthLength;
astra_depthframe_get_data_ptr(depthFrame, &depthData, &depthLength);
astra_depthframe_get_metadata(depthFrame, &metadata);
int width = metadata.width;
int height = metadata.height;
size_t index = ((width * (height / 2)) + (width / 2));
short middle = depthData[index];
astra_frame_index_t frameIndex;
astra_depthframe_get_frameindex(depthFrame, &frameIndex);
printf("depth frameIndex: %d value: %d \n", frameIndex, middle);
}
void frame_ready(void* clientTag, astra_reader_t reader, astra_reader_frame_t frame)
{
astra_depthframe_t depthFrame;
astra_frame_get_depthframe(frame, &depthFrame);
print_depth(depthFrame);
}
int main(int argc, char* argv[])
{
set_key_handler();
astra_initialize();
astra_streamsetconnection_t sensor;
astra_streamset_open("device/default", &sensor);
astra_reader_t reader;
astra_reader_create(sensor, &reader);
astra_depthstream_t depthStream;
astra_reader_get_depthstream(reader, &depthStream);
astra_stream_start(depthStream);
astra_reader_callback_id_t callbackId;
astra_reader_register_frame_ready_callback(reader, &frame_ready, NULL, &callbackId);
do
{
astra_update();
} while (shouldContinue);
astra_reader_unregister_frame_ready_callback(&callbackId);
astra_reader_destroy(&reader);
astra_streamset_close(&sensor);
astra_terminate();
}


Astra SDK: DepthReaderEventCPP\main.cpp

DepthReaderEventCPP\main.cpp
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <astra/astra.hpp>
#include <cstdio>
#include <chrono>
#include <iostream>
#include <iomanip>
#include <key_handler.h>
class SampleFrameListener : public astra::FrameListener
{
private:
using buffer_ptr = std::unique_ptr<int16_t []>;
buffer_ptr buffer_;
unsigned int lastWidth_;
unsigned int lastHeight_;
public:
virtual void on_frame_ready(astra::StreamReader& reader,
astra::Frame& frame) override
{
const astra::DepthFrame depthFrame = frame.get<astra::DepthFrame>();
if (depthFrame.is_valid())
{
auto depthStream = reader.stream<astra::DepthStream>();
print_depth(depthFrame, depthStream.coordinateMapper());
check_fps();
}
}
void print_depth(const astra::DepthFrame& depthFrame,
const astra::CoordinateMapper& mapper)
{
if (depthFrame.is_valid())
{
int width = depthFrame.width();
int height = depthFrame.height();
int frameIndex = depthFrame.frame_index();
//determine if buffer needs to be reallocated
if (width != lastWidth_ || height != lastHeight_)
{
buffer_ = buffer_ptr(new int16_t[depthFrame.length()]);
lastWidth_ = width;
lastHeight_ = height;
}
depthFrame.copy_to(buffer_.get());
size_t index = ((width * (height / 2.0f)) + (width / 2.0f));
short middle = buffer_[index];
float worldX, worldY, worldZ;
float depthX, depthY, depthZ;
mapper.convert_depth_to_world(width / 2.0f, height / 2.0f, middle, worldX, worldY, worldZ);
mapper.convert_world_to_depth(worldX, worldY, worldZ, depthX, depthY, depthZ);
std::cout << "depth frameIndex: " << frameIndex
<< " value: " << middle
<< " wX: " << worldX
<< " wY: " << worldY
<< " wZ: " << worldZ
<< " dX: " << depthX
<< " dY: " << depthY
<< " dZ: " << depthZ
<< std::endl;
}
}
void check_fps()
{
const float frameWeight = 0.5;
auto newTimepoint = clock_type::now();
float frameDuration = std::chrono::duration_cast<duration_type>(newTimepoint - lastTimepoint_).count();
frameDuration_ = frameDuration * frameWeight + frameDuration_ * (1 - frameWeight);
lastTimepoint_ = newTimepoint;
double fps = 1.0 / frameDuration_;
auto precision = std::cout.precision();
std::cout << std::fixed
<< std::setprecision(1)
<< fps << " fps ("
<< std::setprecision(2)
<< frameDuration_ * 1000.0 << " ms)"
<< std::setprecision(precision)
<< std::endl;
}
private:
using duration_type = std::chrono::duration<float>;
float frameDuration_{ 0.0 };
using clock_type = std::chrono::system_clock;
std::chrono::time_point<clock_type> lastTimepoint_{clock_type::now()};
};
int main(int argc, char** argv)
{
astra::initialize();
set_key_handler();
astra::StreamSet streamSet;
astra::StreamReader reader = streamSet.create_reader();
SampleFrameListener listener;
auto depthStream = reader.stream<astra::DepthStream>();
depthStream.start();
char serialnumber[256];
depthStream.serial_number(serialnumber, 256);
std::cout << "depthStream -- hFov: "
<< reader.stream<astra::DepthStream>().hFov()
<< " vFov: "
<< reader.stream<astra::DepthStream>().vFov()
<< " serial number: "
<< serialnumber
<< std::endl;
const uint32_t chipId = depthStream.chip_id();
switch (chipId)
{
case ASTRA_CHIP_ID_MX400:
std::cout << "Chip ID: MX400" << std::endl;
break;
case ASTRA_CHIP_ID_MX6000:
std::cout << "Chip ID: MX6000" << std::endl;
break;
case ASTRA_CHIP_ID_UNKNOWN:
default:
std::cout << "Chip ID: Unknown" << std::endl;
break;
}
const astra_usb_info_t usbinfo = depthStream.usb_info();
std::cout << "usbInfo ---pid:" << usbinfo.pid<<" vid: "<< usbinfo.vid<< std::endl;
reader.add_listener(listener);
do
{
astra_update();
} while (shouldContinue);
reader.remove_listener(listener);
astra::terminate();
}


Astra SDK: DepthReaderPoll\main.c

DepthReaderPoll\main.c
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <astra/capi/astra.h>
#include <stdio.h>
#include <key_handler.h>
#include <astra_core/capi/astra_types.h>
void print_depth(astra_depthframe_t depthFrame)
{
astra_image_metadata_t metadata;
int16_t* depthData;
uint32_t depthLength;
astra_depthframe_get_data_byte_length(depthFrame, &depthLength);
astra_depthframe_get_metadata(depthFrame, &metadata);
depthData = (int16_t*)malloc(depthLength);
astra_depthframe_copy_data(depthFrame, depthData);
int width = metadata.width;
int height = metadata.height;
size_t index = ((width * (height / 2)) + (width / 2));
short middle = depthData[index];
free(depthData);
astra_frame_index_t frameIndex;
astra_depthframe_get_frameindex(depthFrame, &frameIndex);
printf("depth frameIndex %d value %d\n", frameIndex, middle);
}
int main(int argc, char* argv[])
{
set_key_handler();
astra_initialize();
astra_streamsetconnection_t sensor;
astra_streamset_open("device/default", &sensor);
astra_reader_t reader;
astra_reader_create(sensor, &reader);
astra_depthstream_t depthStream;
astra_reader_get_depthstream(reader, &depthStream);
float hFov, vFov;
astra_depthstream_get_hfov(depthStream, &hFov);
astra_depthstream_get_vfov(depthStream, &vFov);
printf("depth sensor -- hFov: %f radians vFov: %f radians\n", hFov, vFov);
char serialnumber[128];
astra_depthstream_get_serialnumber(depthStream,serialnumber,128);
printf("depth sensor -- serial number: %s\n", serialnumber);
const uint32_t chipId;
astra_depthstream_get_chip_id(depthStream, &chipId);
switch (chipId)
{
case ASTRA_CHIP_ID_MX400:
printf("Chip ID: MX400\n");
break;
case ASTRA_CHIP_ID_MX6000:
printf("Chip ID: MX6000\n");
break;
case ASTRA_CHIP_ID_UNKNOWN:
default:
printf("Chip ID: Unknown\n");
break;
}
astra_stream_start(depthStream);
astra_frame_index_t lastFrameIndex = -1;
do
{
astra_update();
astra_reader_frame_t frame;
astra_status_t rc = astra_reader_open_frame(reader, 0, &frame);
if (rc == ASTRA_STATUS_SUCCESS)
{
astra_depthframe_t depthFrame;
astra_frame_get_depthframe(frame, &depthFrame);
astra_frame_index_t newFrameIndex;
astra_depthframe_get_frameindex(depthFrame, &newFrameIndex);
if (lastFrameIndex == newFrameIndex)
{
printf("duplicate frame index: %d\n", lastFrameIndex);
}
lastFrameIndex = newFrameIndex;
print_depth(depthFrame);
astra_reader_close_frame(&frame);
}
} while (shouldContinue);
astra_reader_destroy(&reader);
astra_streamset_close(&sensor);
astra_terminate();
}


Astra SDK: HandReader\main.c

HandReader\main.c
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <astra/capi/astra.h>
#include <stdio.h>
#include <key_handler.h>
void print_hand_frame(astra_handframe_t handFrame)
{
astra_handpoint_t* handPoints;
uint32_t handCount;
astra_handframe_get_hand_count(handFrame, &handCount);
handPoints = (astra_handpoint_t*)malloc(handCount * sizeof(astra_handpoint_t));
astra_handframe_copy_hands(handFrame, handPoints);
astra_frame_index_t frameIndex;
astra_handframe_get_frameindex(handFrame, &frameIndex);
int activeHandCount = 0;
astra_handpoint_t* point = handPoints;
int i;
for (i = 0; i < handCount; i++)
{
if (point->status == HAND_STATUS_TRACKING)
{
++activeHandCount;
}
++point;
}
free(handPoints);
printf("index %d active hand count %d\n", frameIndex, activeHandCount);
}
void runHandStream(astra_reader_t reader)
{
do
{
astra_update();
astra_reader_frame_t frame;
astra_status_t rc = astra_reader_open_frame(reader, 0, &frame);
if (rc == ASTRA_STATUS_SUCCESS)
{
astra_handframe_t handFrame;
astra_frame_get_handframe(frame, &handFrame);
print_hand_frame(handFrame);
astra_colorframe_t handDebugimageframe;
astra_frame_get_debug_handframe(frame, &handDebugimageframe);
astra_image_metadata_t metadata;
astra_colorframe_get_metadata(handDebugimageframe, &metadata);
astra_reader_close_frame(&frame);
}
} while (shouldContinue);
}
int main(int argc, char* argv[])
{
set_key_handler();
astra_initialize();
astra_streamsetconnection_t sensor;
astra_streamset_open("device/default", &sensor);
astra_reader_t reader;
astra_reader_create(sensor, &reader);
astra_handstream_t handStream;
astra_reader_get_handstream(reader, &handStream);
astra_stream_start(handStream);
astra_colorstream_t handDebugimagestream;
astra_reader_get_debug_handstream(reader, &handDebugimagestream);
astra_stream_start(handDebugimagestream);
runHandStream(reader);
astra_reader_destroy(&reader);
astra_streamset_close(&sensor);
astra_terminate();
}


Astra SDK: InfraredColorReaderEvent\main.c

InfraredColorReaderEvent\main.c
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <astra/capi/astra.h>
#include <astra/capi/streams/infrared_capi.h>
#include <stdio.h>
#include <key_handler.h>
int count = 0;
void print_infrared(astra_infraredframe_t infraredFrame)
{
astra_image_metadata_t metadata;
uint32_t irLength;
uint8_t* dataBytes = NULL;
astra_infraredframe_get_data_ptr(infraredFrame, &dataBytes, &irLength);
astra_infraredframe_get_metadata(infraredFrame, &metadata);
uint16_t* irData = (uint16_t*)dataBytes;
int width = metadata.width;
int height = metadata.height;
size_t index = ((width * (height / 2)) + (width / 2));
uint16_t middle = irData[index];
astra_frame_index_t frameIndex;
astra_infraredframe_get_frameindex(infraredFrame, &frameIndex);
printf("infrared frameIndex: %d value: %d \n", frameIndex, middle);
}
void print_color(astra_colorframe_t colorFrame)
{
astra_image_metadata_t metadata;
astra_rgb_pixel_t* colorData_rgb;
uint32_t colorByteLength;
astra_colorframe_get_data_rgb_ptr(colorFrame, &colorData_rgb, &colorByteLength);
astra_colorframe_get_metadata(colorFrame, &metadata);
int width = metadata.width;
int height = metadata.height;
size_t index = ((width * (height / 2)) + (width / 2));
astra_frame_index_t frameIndex;
astra_colorframe_get_frameindex(colorFrame, &frameIndex);
astra_rgb_pixel_t middle = colorData_rgb[index];
printf("color frameIndex: %d r: %d g: %d b: %d \n", frameIndex, (int)(middle.r), (int)(middle.g), (int)(middle.b));
}
void frame_ready(void* clientTag, astra_reader_t reader, astra_reader_frame_t frame)
{
astra_infraredframe_t infraredFrame;
astra_frame_get_infraredframe(frame, &infraredFrame);
//Check for NULL because we reuse this method for both infrared and color events
if (infraredFrame != NULL)
{
print_infrared(infraredFrame);
}
astra_colorframe_t colorFrame;
astra_frame_get_colorframe(frame, &colorFrame);
if (colorFrame != NULL)
{
print_color(colorFrame);
}
if (infraredFrame != NULL || colorFrame != NULL)
{
//clientTag is pointer to frameCount, pass to astra_reader_register_frame_ready_callback()
int* frameCount = (int*)clientTag;
//Increment frameCount only when we have a succesful frame
(*frameCount)++;
}
}
astra_infraredstream_t setup_infrared(astra_reader_t reader)
{
astra_infraredstream_t infraredStream;
astra_reader_get_infraredstream(reader, &infraredStream);
astra_imagestream_mode_t mode;
//640x480@30 or 1280x1024@30
//(Infrared 1280x1024 will only produce at ~5fps)
mode.width = 640;
mode.height = 480;
//IR supports ASTRA_PIXEL_FORMAT_RGB888 and ASTRA_PIXEL_FORMAT_GRAY16.
//If you change here, make sure to change the code in print_infrared to handle
//the proper format:
//ASTRA_PIXEL_FORMAT_RGB888 data = uint8t[], length = width*height*3 (RGB per pixel)
//ASTRA_PIXEL_FORMAT_GRAY16 data = int16_t[], length = width*height*2 (IR intensity)
mode.pixelFormat = ASTRA_PIXEL_FORMAT_GRAY16;
mode.fps = 30;
astra_imagestream_set_mode(infraredStream, &mode);
return infraredStream;
}
astra_colorstream_t setup_color(astra_reader_t reader)
{
astra_colorstream_t colorStream;
astra_reader_get_colorstream(reader, &colorStream);
astra_imagestream_mode_t mode;
//640x480@30 or 1280x1024@30
//(Color 1280x1024 will only produce at ~5fps)
mode.width = 640;
mode.height = 480;
mode.pixelFormat = ASTRA_PIXEL_FORMAT_RGB888;
mode.fps = 30;
astra_imagestream_set_mode(colorStream, &mode);
return colorStream;
}
int main(int argc, char* argv[])
{
set_key_handler();
astra_initialize();
astra_streamsetconnection_t sensor;
astra_streamset_open("device/default", &sensor);
astra_reader_t reader;
astra_reader_create(sensor, &reader);
astra_infraredstream_t infraredStream = setup_infrared(reader);
astra_colorstream_t colorStream = setup_color(reader);
bool infraredOn = true;
astra_stream_start(infraredStream);
int frameCount = 0;
astra_reader_callback_id_t callbackId;
astra_reader_register_frame_ready_callback(reader, &frame_ready, &frameCount, &callbackId);
do
{
astra_update();
if (frameCount >= 30)
{
frameCount = 0;
if (infraredOn)
{
infraredOn = false;
printf("Switching to color stream...\n");
//Must first stop infrared then we can start color
astra_stream_stop(infraredStream);
astra_stream_start(colorStream);
}
else
{
infraredOn = true;
printf("Switching to infrared stream...\n");
//Must first stop color then we can start infrared
astra_stream_stop(colorStream);
astra_stream_start(infraredStream);
}
}
} while (shouldContinue);
astra_reader_unregister_frame_ready_callback(&callbackId);
astra_reader_destroy(&reader);
astra_streamset_close(&sensor);
astra_terminate();
}


Astra SDK: InfraredReaderEvent\main.c

InfraredReaderEvent\main.c
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <astra/capi/astra.h>
#include <astra/capi/streams/infrared_capi.h>
#include <stdio.h>
#include <key_handler.h>
void print_infrared(astra_infraredframe_t infraredFrame)
{
astra_image_metadata_t metadata;
uint32_t irLength;
uint8_t* dataBytes = NULL;
astra_infraredframe_get_data_ptr(infraredFrame, &dataBytes, &irLength);
astra_infraredframe_get_metadata(infraredFrame, &metadata);
uint16_t* irData = (uint16_t*)dataBytes;
int width = metadata.width;
int height = metadata.height;
size_t index = ((width * (height / 2)) + (width / 2));
uint16_t middle = irData[index];
astra_frame_index_t frameIndex;
astra_infraredframe_get_frameindex(infraredFrame, &frameIndex);
printf("infrared frameIndex: %d value: %d \n", frameIndex, middle);
}
void frame_ready(void* clientTag, astra_reader_t reader, astra_reader_frame_t frame)
{
astra_infraredframe_t infraredFrame;
astra_frame_get_infraredframe(frame, &infraredFrame);
print_infrared(infraredFrame);
}
int main(int argc, char* argv[])
{
set_key_handler();
astra_initialize();
astra_streamsetconnection_t sensor;
astra_streamset_open("device/default", &sensor);
astra_reader_t reader;
astra_reader_create(sensor, &reader);
astra_infraredstream_t infraredStream;
astra_reader_get_infraredstream(reader, &infraredStream);
astra_imagestream_mode_t mode;
mode.width = 640;
mode.height = 480;
mode.pixelFormat = ASTRA_PIXEL_FORMAT_GRAY16;
mode.fps = 30;
astra_imagestream_set_mode(infraredStream, &mode);
astra_stream_start(infraredStream);
astra_reader_callback_id_t callbackId;
astra_reader_register_frame_ready_callback(reader, &frame_ready, NULL, &callbackId);
do
{
astra_update();
} while (shouldContinue);
astra_reader_unregister_frame_ready_callback(&callbackId);
astra_reader_destroy(&reader);
astra_streamset_close(&sensor);
astra_terminate();
}


Astra SDK: InfraredReaderPoll\main.c

InfraredReaderPoll\main.c
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <astra/capi/astra.h>
#include <astra/capi/streams/infrared_capi.h>
#include <stdio.h>
#include <key_handler.h>
void print_infrared(astra_infraredframe_t infraredFrame)
{
astra_image_metadata_t metadata;
uint32_t irLength;
uint8_t* dataBytes = NULL;
astra_infraredframe_get_data_ptr(infraredFrame, &dataBytes, &irLength);
astra_infraredframe_get_metadata(infraredFrame, &metadata);
uint16_t* irData = (uint16_t*)dataBytes;
int width = metadata.width;
int height = metadata.height;
size_t index = ((width * (height / 2)) + (width / 2));
uint16_t middle = irData[index];
astra_frame_index_t frameIndex;
astra_infraredframe_get_frameindex(infraredFrame, &frameIndex);
printf("infrared frameIndex: %d value: %d \n", frameIndex, middle);
}
int main(int argc, char* argv[])
{
set_key_handler();
astra_initialize();
astra_streamsetconnection_t sensor;
astra_streamset_open("device/default", &sensor);
astra_reader_t reader;
astra_reader_create(sensor, &reader);
astra_infraredstream_t infraredStream;
astra_reader_get_infraredstream(reader, &infraredStream);
astra_imagestream_mode_t mode;
mode.width = 640;
mode.height = 480;
mode.pixelFormat = ASTRA_PIXEL_FORMAT_GRAY16;
mode.fps = 30;
astra_imagestream_set_mode(infraredStream, &mode);
astra_stream_start(infraredStream);
do
{
astra_update();
astra_reader_frame_t frame;
astra_status_t rc = astra_reader_open_frame(reader, 0, &frame);
if (rc == ASTRA_STATUS_SUCCESS)
{
astra_infraredframe_t infraredFrame;
astra_frame_get_infraredframe(frame, &infraredFrame);
print_infrared(infraredFrame);
astra_reader_close_frame(&frame);
}
} while (shouldContinue);
astra_reader_destroy(&reader);
astra_streamset_close(&sensor);
astra_terminate();
}


Astra SDK: MaskedColorViewer-SFML\main.cpp

MaskedColorViewer-SFML\main.cpp
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <SFML/Graphics.hpp>
#include <astra/astra.hpp>
#include "LitDepthVisualizer.hpp"
#include <chrono>
#include <iostream>
#include <iomanip>
#include <key_handler.h>
#include <sstream>
class MaskedColorFrameListener : public astra::FrameListener
{
public:
MaskedColorFrameListener(const astra::CoordinateMapper& coordinateMapper)
: coordinateMapper_(coordinateMapper)
{
prev_ = ClockType::now();
font_.loadFromFile("Inconsolata.otf");
}
void ensure_texture(int width, int height)
{
if (!displayBuffer_ ||
width != displayWidth_ ||
height != displayHeight_)
{
displayWidth_ = width;
displayHeight_ = height;
textureBytesPerPixel_ = 4; // RGBA
const int byteLength = displayWidth_ * displayHeight_ * textureBytesPerPixel_;
displayBuffer_ = BufferPtr(new uint8_t[byteLength]);
std::fill(&displayBuffer_[0], &displayBuffer_[0] + byteLength, 0);
texture_.create(displayWidth_, displayHeight_);
sprite_.setTexture(texture_, true);
sprite_.setPosition(0, 0);
}
}
void check_fps()
{
const float frameWeight = .2f;
const ClockType::time_point now = ClockType::now();
const float elapsedMillis = std::chrono::duration_cast<DurationType>(now - prev_).count();
elapsedMillis_ = elapsedMillis * frameWeight + elapsedMillis_ * (1.f - frameWeight);
prev_ = now;
const float fps = 1000.f / elapsedMillis;
const auto precision = std::cout.precision();
std::cout << std::fixed
<< std::setprecision(1)
<< fps << " fps ("
<< std::setprecision(1)
<< elapsedMillis_ << " ms)"
<< std::setprecision(precision)
<< std::endl;
}
void on_frame_ready(astra::StreamReader& reader,
astra::Frame& frame) override
{
const astra::MaskedColorFrame MaskedColorFrame = frame.get<astra::MaskedColorFrame>();
const int maskedColorWidth = MaskedColorFrame.width();
const int maskedColorHeight = MaskedColorFrame.height();
if (maskedColorWidth <= 0 || maskedColorHeight <= 0) { return; }
ensure_texture(maskedColorWidth, maskedColorHeight);
check_fps();
if (isPaused_) { return; }
copy_depth_data(frame);
const float invScaleY = depthHeight_ / float(maskedColorHeight);
const float invScaleX = depthWidth_ / float(maskedColorWidth);
const astra::RgbaPixel* srcData = MaskedColorFrame.data();
for (int y = 0; y < maskedColorHeight; y++)
{
const int depthY = static_cast<int>(y * invScaleY);
for (int x = 0; x < maskedColorWidth; x++)
{
const int srcIndex = y * maskedColorWidth + x;
const int destIndex = srcIndex * textureBytesPerPixel_;
if (srcData[srcIndex].alpha != 0)
{
displayBuffer_[destIndex] = srcData[srcIndex].r;
displayBuffer_[destIndex + 1] = srcData[srcIndex].g;
displayBuffer_[destIndex + 2] = srcData[srcIndex].b;
displayBuffer_[destIndex + 3] = srcData[srcIndex].alpha;
}
else
{
const int depthX = static_cast<int>(x * invScaleX);
const int depthIndex = depthY * depthWidth_ + depthX;
displayBuffer_[destIndex] = uint8_t(depthData_[depthIndex]);
displayBuffer_[destIndex + 1] = uint8_t(depthData_[depthIndex]);
displayBuffer_[destIndex + 2] = uint8_t(depthData_[depthIndex]);
displayBuffer_[destIndex + 3] = 255; // Fully opaque
}
}
}
texture_.update(displayBuffer_.get());
}
void copy_depth_data(astra::Frame& frame)
{
const astra::DepthFrame depthFrame = frame.get<astra::DepthFrame>();
if (depthFrame.is_valid())
{
const int width = depthFrame.width();
const int height = depthFrame.height();
if (!depthData_ || width != depthWidth_ || height != depthHeight_)
{
depthWidth_ = width;
depthHeight_ = height;
// texture is RGBA
const int byteLength = depthWidth_ * depthHeight_ * sizeof(uint16_t);
depthData_ = DepthPtr(new int16_t[byteLength]);
}
depthFrame.copy_to(&depthData_[0]);
}
}
void update_mouse_position(sf::RenderWindow& window)
{
const sf::Vector2i position = sf::Mouse::getPosition(window);
const sf::Vector2u windowSize = window.getSize();
mouseNormX_ = position.x / float(windowSize.x);
mouseNormY_ = position.y / float(windowSize.y);
}
void draw_text(sf::RenderWindow& window,
sf::Text& text,
sf::Color color,
const int x,
const int y) const
{
text.setColor(sf::Color::Black);
text.setPosition(x + 5, y + 5);
window.draw(text);
text.setColor(color);
text.setPosition(x, y);
window.draw(text);
}
void draw_mouse_overlay(sf::RenderWindow& window,
const float depthWScale,
const float depthHScale) const
{
if (!isMouseOverlayEnabled_ || !depthData_) { return; }
const int mouseX = depthWidth_ * mouseNormX_;
const int mouseY = depthHeight_ * mouseNormY_;
if (mouseX >= depthWidth_ ||
mouseY >= depthHeight_ ||
mouseX < 0 ||
mouseY < 0) { return; }
const size_t index = (depthWidth_ * mouseY + mouseX);
const short z = depthData_[index];
float worldX, worldY, worldZ;
coordinateMapper_.convert_depth_to_world(float(mouseX),
float(mouseY),
float(z),
worldX,
worldY,
worldZ);
std::stringstream str;
str << std::fixed
<< std::setprecision(0)
<< "(" << mouseX << ", " << mouseY << ") "
<< "X: " << worldX << " Y: " << worldY << " Z: " << worldZ;
const int characterSize = 40;
sf::Text text(str.str(), font_);
text.setCharacterSize(characterSize);
text.setStyle(sf::Text::Bold);
const float displayX = 10.f;
const float margin = 10.f;
const float displayY = window.getView().getSize().y - (margin + characterSize);
draw_text(window, text, sf::Color::White, displayX, displayY);
}
void draw_to(sf::RenderWindow& window)
{
if (displayBuffer_ != nullptr)
{
const float depthWScale = window.getView().getSize().x / displayWidth_;
const float depthHScale = window.getView().getSize().y / displayHeight_;
sprite_.setScale(depthWScale, depthHScale);
window.draw(sprite_);
draw_mouse_overlay(window, depthWScale, depthHScale);
}
}
void toggle_paused()
{
isPaused_ = !isPaused_;
}
bool is_paused() const
{
return isPaused_;
}
void toggle_overlay()
{
isMouseOverlayEnabled_ = !isMouseOverlayEnabled_;
}
bool overlay_enabled() const
{
return isMouseOverlayEnabled_;
}
private:
samples::common::LitDepthVisualizer visualizer_;
using DurationType = std::chrono::milliseconds;
using ClockType = std::chrono::high_resolution_clock;
ClockType::time_point prev_;
float elapsedMillis_{.0f};
int textureBytesPerPixel_{0};
sf::Texture texture_;
sf::Sprite sprite_;
sf::Font font_;
const astra::CoordinateMapper& coordinateMapper_;
int displayWidth_{0};
int displayHeight_{0};
using BufferPtr = std::unique_ptr<uint8_t[]>;
BufferPtr displayBuffer_{nullptr};
int depthWidth_{0};
int depthHeight_{0};
using DepthPtr = std::unique_ptr<int16_t[]>;
DepthPtr depthData_{nullptr};
float mouseNormX_{0};
float mouseNormY_{0};
bool isPaused_{false};
bool isMouseOverlayEnabled_{true};
};
astra::DepthStream configure_depth(astra::StreamReader& reader)
{
auto depthStream = reader.stream<astra::DepthStream>();
//We don't have to set the mode to start the stream, but if you want to here is how:
astra::ImageStreamMode depthMode;
depthMode.set_width(640);
depthMode.set_height(480);
depthMode.set_pixel_format(astra_pixel_formats::ASTRA_PIXEL_FORMAT_DEPTH_MM);
depthMode.set_fps(30);
depthStream.set_mode(depthMode);
return depthStream;
}
astra::ColorStream configure_color(astra::StreamReader& reader)
{
auto colorStream = reader.stream<astra::ColorStream>();
//We don't have to set the mode to start the stream, but if you want to here is how:
astra::ImageStreamMode colorMode;
colorMode.set_width(640);
colorMode.set_height(480);
colorMode.set_pixel_format(astra_pixel_formats::ASTRA_PIXEL_FORMAT_RGB888);
colorMode.set_fps(30);
colorStream.set_mode(colorMode);
return colorStream;
}
int main(int argc, char** argv)
{
astra::initialize();
const char* licenseString = "<INSERT LICENSE KEY HERE>";
orbbec_body_tracking_set_license(licenseString);
set_key_handler();
const char* windowTitle = "Masked Color Viewer";
sf::RenderWindow window(sf::VideoMode(1280, 960), windowTitle);
#ifdef _WIN32
auto fullscreenStyle = sf::Style::None;
#else
auto fullscreenStyle = sf::Style::Fullscreen;
#endif
const sf::VideoMode fullScreenMode = sf::VideoMode::getFullscreenModes()[0];
const sf::VideoMode windowedMode(1280, 1024);
bool isFullScreen = false;
astra::StreamSet streamSet;
astra::StreamReader reader = streamSet.create_reader();
auto depthStream = configure_depth(reader);
depthStream.start();
reader.stream<astra::BodyStream>().start();
configure_color(reader).start();
reader.stream<astra::MaskedColorStream>().start();
auto coordinateMapper = depthStream.coordinateMapper();
MaskedColorFrameListener listener(coordinateMapper);
reader.add_listener(listener);
while (window.isOpen())
{
astra_update();
sf::Event event;
while (window.pollEvent(event))
{
switch (event.type)
{
case sf::Event::Closed:
window.close();
break;
case sf::Event::KeyPressed:
{
if (event.key.code == sf::Keyboard::C && event.key.control)
{
window.close();
}
switch (event.key.code)
{
case sf::Keyboard::Escape:
window.close();
break;
case sf::Keyboard::F:
if (isFullScreen)
{
window.create(windowedMode, windowTitle, sf::Style::Default);
}
else
{
window.create(fullScreenMode, windowTitle, fullscreenStyle);
}
isFullScreen = !isFullScreen;
break;
case sf::Keyboard::R:
depthStream.enable_registration(!depthStream.registration_enabled());
break;
case sf::Keyboard::M:
depthStream.enable_mirroring(!depthStream.mirroring_enabled());
break;
case sf::Keyboard::P:
listener.toggle_paused();
break;
case sf::Keyboard::Space:
listener.toggle_overlay();
break;
default:
break;
}
break;
}
case sf::Event::MouseMoved:
{
listener.update_mouse_position(window);
break;
}
default:
break;
}
}
// clear the window with black color
window.clear(sf::Color::Black);
listener.draw_to(window);
window.display();
if (!shouldContinue)
{
window.close();
}
}
astra::terminate();
return 0;
}


Astra SDK: MultiSensorViewer-SFML\main.cpp

MultiSensorViewer-SFML\main.cpp
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <SFML/Graphics.hpp>
#include <astra_core/astra_core.hpp>
#include <astra/astra.hpp>
#include "LitDepthVisualizer.hpp"
#include <chrono>
#include <iostream>
#include <iomanip>
#include <key_handler.h>
enum ColorMode
{
MODE_COLOR,
MODE_IR_16,
MODE_IR_RGB,
};
class MultiFrameListener : public astra::FrameListener
{
public:
using BufferPtr = std::unique_ptr<uint8_t[]>;
struct StreamView
{
sf::Sprite sprite_;
sf::Texture texture_;
BufferPtr buffer_;
int width_{0};
int height_{0};
};
MultiFrameListener()
{
prev_ = ClockType::now();
}
void init_texture(int width, int height, StreamView& view)
{
if (view.buffer_ == nullptr || width != view.width_ || height != view.height_)
{
view.width_ = width;
view.height_ = height;
// texture is RGBA
const int byteLength = width * height * 4;
view.buffer_ = BufferPtr(new uint8_t[byteLength]);
clear_view(view);
view.texture_.create(width, height);
view.sprite_.setTexture(view.texture_, true);
view.sprite_.setPosition(0, 0);
}
}
void clear_view(StreamView& view)
{
const int byteLength = view.width_ * view.height_ * 4;
std::fill(&view.buffer_[0], &view.buffer_[0] + byteLength, 0);
}
void check_fps()
{
const float frameWeight = .2f;
const ClockType::time_point now = ClockType::now();
const float elapsedMillis = std::chrono::duration_cast<DurationType>(now - prev_).count();
elapsedMillis_ = elapsedMillis * frameWeight + elapsedMillis_ * (1.f - frameWeight);
prev_ = now;
const float fps = 1000.f / elapsedMillis;
const auto precision = std::cout.precision();
std::cout << std::fixed
<< std::setprecision(1)
<< fps << " fps ("
<< std::setprecision(1)
<< elapsedMillis_ << " ms)"
<< std::setprecision(precision)
<< std::endl;
}
void update_depth(astra::Frame& frame)
{
const astra::PointFrame pointFrame = frame.get<astra::PointFrame>();
if (!pointFrame.is_valid())
{
clear_view(depthView_);
depthView_.texture_.update(&depthView_.buffer_[0]);
return;
}
const int depthWidth = pointFrame.width();
const int depthHeight = pointFrame.height();
init_texture(depthWidth, depthHeight, depthView_);
if (isPaused_) { return; }
visualizer_.update(pointFrame);
astra::RgbPixel* vizBuffer = visualizer_.get_output();
uint8_t* buffer = &depthView_.buffer_[0];
for (int i = 0; i < depthWidth * depthHeight; i++)
{
const int rgbaOffset = i * 4;
buffer[rgbaOffset] = vizBuffer[i].r;
buffer[rgbaOffset + 1] = vizBuffer[i].g;
buffer[rgbaOffset + 2] = vizBuffer[i].b;
buffer[rgbaOffset + 3] = 255;
}
depthView_.texture_.update(&depthView_.buffer_[0]);
}
void update_color(astra::Frame& frame)
{
const astra::ColorFrame colorFrame = frame.get<astra::ColorFrame>();
if (!colorFrame.is_valid())
{
clear_view(colorView_);
colorView_.texture_.update(&colorView_.buffer_[0]);
return;
}
const int colorWidth = colorFrame.width();
const int colorHeight = colorFrame.height();
init_texture(colorWidth, colorHeight, colorView_);
if (isPaused_) { return; }
const astra::RgbPixel* color = colorFrame.data();
uint8_t* buffer = &colorView_.buffer_[0];
for(int i = 0; i < colorWidth * colorHeight; i++)
{
const int rgbaOffset = i * 4;
buffer[rgbaOffset] = color[i].r;
buffer[rgbaOffset + 1] = color[i].g;
buffer[rgbaOffset + 2] = color[i].b;
buffer[rgbaOffset + 3] = 255;
}
colorView_.texture_.update(&colorView_.buffer_[0]);
}
void update_ir_16(astra::Frame& frame)
{
const astra::InfraredFrame16 irFrame = frame.get<astra::InfraredFrame16>();
if (!irFrame.is_valid())
{
clear_view(colorView_);
colorView_.texture_.update(&colorView_.buffer_[0]);
return;
}
const int irWidth = irFrame.width();
const int irHeight = irFrame.height();
init_texture(irWidth, irHeight, colorView_);
if (isPaused_) { return; }
const uint16_t* ir_values = irFrame.data();
uint8_t* buffer = &colorView_.buffer_[0];
for (int i = 0; i < irWidth * irHeight; i++)
{
const int rgbaOffset = i * 4;
const uint16_t value = ir_values[i];
const uint8_t red = static_cast<uint8_t>(value >> 2);
const uint8_t blue = 0x66 - red / 2;
buffer[rgbaOffset] = red;
buffer[rgbaOffset + 1] = 0;
buffer[rgbaOffset + 2] = blue;
buffer[rgbaOffset + 3] = 255;
}
colorView_.texture_.update(&colorView_.buffer_[0]);
}
void update_ir_rgb(astra::Frame& frame)
{
const astra::InfraredFrameRgb irFrame = frame.get<astra::InfraredFrameRgb>();
if (!irFrame.is_valid())
{
clear_view(colorView_);
colorView_.texture_.update(&colorView_.buffer_[0]);
return;
}
int irWidth = irFrame.width();
int irHeight = irFrame.height();
init_texture(irWidth, irHeight, colorView_);
if (isPaused_) { return; }
const astra::RgbPixel* irRGB = irFrame.data();
uint8_t* buffer = &colorView_.buffer_[0];
for (int i = 0; i < irWidth * irHeight; i++)
{
const int rgbaOffset = i * 4;
buffer[rgbaOffset] = irRGB[i].r;
buffer[rgbaOffset + 1] = irRGB[i].g;
buffer[rgbaOffset + 2] = irRGB[i].b;
buffer[rgbaOffset + 3] = 255;
}
colorView_.texture_.update(&colorView_.buffer_[0]);
}
virtual void on_frame_ready(astra::StreamReader& reader,
astra::Frame& frame) override
{
update_depth(frame);
switch (colorMode_)
{
case MODE_COLOR:
update_color(frame);
break;
case MODE_IR_16:
update_ir_16(frame);
break;
case MODE_IR_RGB:
update_ir_rgb(frame);
break;
}
check_fps();
}
void draw_to(sf::RenderWindow& window, sf::Vector2f origin, sf::Vector2f size)
{
const int viewSize = (int)(size.x / 2.0f);
const sf::Vector2f windowSize = window.getView().getSize();
if (depthView_.buffer_ != nullptr)
{
const float depthScale = viewSize / (float)depthView_.width_;
const int horzCenter = origin.y * windowSize.y;
depthView_.sprite_.setScale(depthScale, depthScale);
depthView_.sprite_.setPosition(origin.x * windowSize.x, horzCenter);
window.draw(depthView_.sprite_);
}
if (colorView_.buffer_ != nullptr)
{
const float colorScale = viewSize / (float)colorView_.width_;
const int horzCenter = origin.y * windowSize.y;
colorView_.sprite_.setScale(colorScale, colorScale);
if (overlayDepth_)
{
colorView_.sprite_.setPosition(origin.x * windowSize.x, horzCenter);
colorView_.sprite_.setColor(sf::Color(255, 255, 255, 128));
}
else
{
colorView_.sprite_.setPosition(origin.x * windowSize.x + viewSize, horzCenter);
colorView_.sprite_.setColor(sf::Color(255, 255, 255, 255));
}
window.draw(colorView_.sprite_);
}
}
void toggle_depth_overlay()
{
overlayDepth_ = !overlayDepth_;
}
bool get_overlay_depth() const
{
return overlayDepth_;
}
void toggle_paused()
{
isPaused_ = !isPaused_;
}
bool is_paused() const
{
return isPaused_;
}
ColorMode get_mode() const { return colorMode_; }
void set_mode(ColorMode mode) { colorMode_ = mode; }
private:
samples::common::LitDepthVisualizer visualizer_;
using DurationType = std::chrono::milliseconds;
using ClockType = std::chrono::high_resolution_clock;
ClockType::time_point prev_;
float elapsedMillis_{.0f};
StreamView depthView_;
StreamView colorView_;
ColorMode colorMode_;
bool overlayDepth_{ false };
bool isPaused_{ false };
};
astra::DepthStream configure_depth(astra::StreamReader& reader)
{
auto depthStream = reader.stream<astra::DepthStream>();
//We don't have to set the mode to start the stream, but if you want to here is how:
astra::ImageStreamMode depthMode;
depthMode.set_width(640);
depthMode.set_height(480);
depthMode.set_pixel_format(astra_pixel_formats::ASTRA_PIXEL_FORMAT_DEPTH_MM);
depthMode.set_fps(30);
depthStream.set_mode(depthMode);
return depthStream;
}
astra::InfraredStream configure_ir(astra::StreamReader& reader, bool useRGB)
{
auto irStream = reader.stream<astra::InfraredStream>();
astra::ImageStreamMode irMode;
irMode.set_width(640);
irMode.set_height(480);
if (useRGB)
{
irMode.set_pixel_format(astra_pixel_formats::ASTRA_PIXEL_FORMAT_RGB888);
}
else
{
irMode.set_pixel_format(astra_pixel_formats::ASTRA_PIXEL_FORMAT_GRAY16);
}
irMode.set_fps(30);
irStream.set_mode(irMode);
return irStream;
}
astra::ColorStream configure_color(astra::StreamReader& reader)
{
auto colorStream = reader.stream<astra::ColorStream>();
astra::ImageStreamMode colorMode;
colorMode.set_width(640);
colorMode.set_height(480);
colorMode.set_pixel_format(astra_pixel_formats::ASTRA_PIXEL_FORMAT_RGB888);
colorMode.set_fps(30);
colorStream.set_mode(colorMode);
return colorStream;
}
int main(int argc, char** argv)
{
astra::initialize();
set_key_handler();
#ifdef _WIN32
auto fullscreenStyle = sf::Style::None;
#else
auto fullscreenStyle = sf::Style::Fullscreen;
#endif
const sf::VideoMode fullScreenMode = sf::VideoMode::getFullscreenModes()[0];
const sf::VideoMode windowedMode(1800, 1350);
bool isFullScreen = false;
sf::RenderWindow window(windowedMode, "Multi Sensor Viewer");
astra::StreamSet streamSet1("device/sensor0");
astra::StreamSet streamSet2("device/sensor1");
astra::StreamReader reader1 = streamSet1.create_reader();
astra::StreamReader reader2 = streamSet2.create_reader();
reader1.stream<astra::PointStream>().start();
reader2.stream<astra::PointStream>().start();
auto depthStream1 = configure_depth(reader1);
depthStream1.start();
auto colorStream1 = configure_color(reader1);
colorStream1.start();
auto irStream1 = configure_ir(reader1, false);
auto depthStream2 = configure_depth(reader2);
depthStream2.start();
auto colorStream2 = configure_color(reader2);
colorStream2.start();
auto irStream2 = configure_ir(reader2, false);
MultiFrameListener listener1;
listener1.set_mode(MODE_COLOR);
MultiFrameListener listener2;
listener2.set_mode(MODE_COLOR);
reader1.add_listener(listener1);
reader2.add_listener(listener2);
while (window.isOpen())
{
astra_update();
sf::Event event;
while (window.pollEvent(event))
{
switch (event.type)
{
case sf::Event::Closed:
window.close();
break;
case sf::Event::KeyPressed:
{
switch (event.key.code)
{
case sf::Keyboard::Escape:
window.close();
break;
case sf::Keyboard::F:
if (isFullScreen)
{
isFullScreen = false;
window.create(windowedMode, "Multi Sensor Viewer", sf::Style::Default);
}
else
{
isFullScreen = true;
window.create(fullScreenMode, "Multi Sensor Viewer", fullscreenStyle);
}
break;
case sf::Keyboard::R:
depthStream1.enable_registration(!depthStream1.registration_enabled());
depthStream2.enable_registration(!depthStream2.registration_enabled());
break;
case sf::Keyboard::M:
{
const bool newMirroring1 = !depthStream1.mirroring_enabled();
depthStream1.enable_mirroring(newMirroring1);
colorStream1.enable_mirroring(newMirroring1);
irStream1.enable_mirroring(newMirroring1);
const bool newMirroring2 = !depthStream2.mirroring_enabled();
depthStream2.enable_mirroring(newMirroring2);
colorStream2.enable_mirroring(newMirroring2);
irStream2.enable_mirroring(newMirroring2);
}
break;
case sf::Keyboard::G:
colorStream1.stop();
configure_ir(reader1, false);
listener1.set_mode(MODE_IR_16);
irStream1.start();
colorStream2.stop();
configure_ir(reader2, false);
listener2.set_mode(MODE_IR_16);
irStream2.start();
break;
case sf::Keyboard::I:
colorStream1.stop();
configure_ir(reader1, true);
listener1.set_mode(MODE_IR_RGB);
irStream1.start();
colorStream2.stop();
configure_ir(reader2, true);
listener2.set_mode(MODE_IR_RGB);
irStream2.start();
break;
case sf::Keyboard::O:
listener1.toggle_depth_overlay();
if (listener1.get_overlay_depth())
{
depthStream1.enable_registration(true);
}
listener2.toggle_depth_overlay();
if (listener2.get_overlay_depth())
{
depthStream2.enable_registration(true);
}
break;
case sf::Keyboard::P:
listener1.toggle_paused();
listener2.toggle_paused();
break;
case sf::Keyboard::C:
if (event.key.control)
{
window.close();
}
else
{
irStream1.stop();
listener1.set_mode(MODE_COLOR);
colorStream1.start();
irStream2.stop();
listener2.set_mode(MODE_COLOR);
colorStream2.start();
}
break;
default:
break;
}
break;
}
default:
break;
}
}
// clear the window with black color
window.clear(sf::Color::Black);
listener1.draw_to(window, sf::Vector2f(0.0f, 0.0f), sf::Vector2f(window.getSize().x, window.getSize().y / 2.0f));
listener2.draw_to(window, sf::Vector2f(0.0f, 0.5f), sf::Vector2f(window.getSize().x, window.getSize().y / 2.0f));
window.display();
if (!shouldContinue)
{
window.close();
}
}
astra::terminate();
return 0;
}


Astra SDK: SimpleBodyViewer-SFML\main.cpp

SimpleBodyViewer-SFML\main.cpp
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <SFML/Graphics.hpp>
#include <astra/astra.hpp>
#include <iostream>
#include <cstring>
class sfLine : public sf::Drawable
{
public:
sfLine(const sf::Vector2f& point1, const sf::Vector2f& point2, sf::Color color, float thickness)
: color_(color)
{
const sf::Vector2f direction = point2 - point1;
const sf::Vector2f unitDirection = direction / std::sqrt(direction.x*direction.x + direction.y*direction.y);
const sf::Vector2f normal(-unitDirection.y, unitDirection.x);
const sf::Vector2f offset = (thickness / 2.f) * normal;
vertices_[0].position = point1 + offset;
vertices_[1].position = point2 + offset;
vertices_[2].position = point2 - offset;
vertices_[3].position = point1 - offset;
for (int i = 0; i<4; ++i)
vertices_[i].color = color;
}
void draw(sf::RenderTarget &target, sf::RenderStates states) const
{
target.draw(vertices_, 4, sf::Quads, states);
}
private:
sf::Vertex vertices_[4];
sf::Color color_;
};
class BodyVisualizer : public astra::FrameListener
{
public:
static sf::Color get_body_color(std::uint8_t bodyId)
{
if (bodyId == 0)
{
// Handle no body separately - transparent
return sf::Color(0x00, 0x00, 0x00, 0x00);
}
// Case 0 below could mean bodyId == 25 or
// above due to the "% 24".
switch (bodyId % 24) {
case 0:
return sf::Color(0x00, 0x88, 0x00, 0xFF);
case 1:
return sf::Color(0x00, 0x00, 0xFF, 0xFF);
case 2:
return sf::Color(0x88, 0x00, 0x00, 0xFF);
case 3:
return sf::Color(0x00, 0xFF, 0x00, 0xFF);
case 4:
return sf::Color(0x00, 0x00, 0x88, 0xFF);
case 5:
return sf::Color(0xFF, 0x00, 0x00, 0xFF);
case 6:
return sf::Color(0xFF, 0x88, 0x00, 0xFF);
case 7:
return sf::Color(0xFF, 0x00, 0xFF, 0xFF);
case 8:
return sf::Color(0x88, 0x00, 0xFF, 0xFF);
case 9:
return sf::Color(0x00, 0xFF, 0xFF, 0xFF);
case 10:
return sf::Color(0x00, 0xFF, 0x88, 0xFF);
case 11:
return sf::Color(0xFF, 0xFF, 0x00, 0xFF);
case 12:
return sf::Color(0x00, 0x88, 0x88, 0xFF);
case 13:
return sf::Color(0x00, 0x88, 0xFF, 0xFF);
case 14:
return sf::Color(0x88, 0x88, 0x00, 0xFF);
case 15:
return sf::Color(0x88, 0xFF, 0x00, 0xFF);
case 16:
return sf::Color(0x88, 0x00, 0x88, 0xFF);
case 17:
return sf::Color(0xFF, 0x00, 0x88, 0xFF);
case 18:
return sf::Color(0xFF, 0x88, 0x88, 0xFF);
case 19:
return sf::Color(0xFF, 0x88, 0xFF, 0xFF);
case 20:
return sf::Color(0x88, 0x88, 0xFF, 0xFF);
case 21:
return sf::Color(0x88, 0xFF, 0xFF, 0xFF);
case 22:
return sf::Color(0x88, 0xFF, 0x88, 0xFF);
case 23:
return sf::Color(0xFF, 0xFF, 0x88, 0xFF);
default:
return sf::Color(0xAA, 0xAA, 0xAA, 0xFF);
}
}
void init_depth_texture(int width, int height)
{
if (displayBuffer_ == nullptr || width != depthWidth_ || height != depthHeight_)
{
depthWidth_ = width;
depthHeight_ = height;
int byteLength = depthWidth_ * depthHeight_ * 4;
displayBuffer_ = BufferPtr(new uint8_t[byteLength]);
std::memset(displayBuffer_.get(), 0, byteLength);
texture_.create(depthWidth_, depthHeight_);
sprite_.setTexture(texture_, true);
sprite_.setPosition(0, 0);
}
}
void init_overlay_texture(int width, int height)
{
if (overlayBuffer_ == nullptr || width != overlayWidth_ || height != overlayHeight_)
{
overlayWidth_ = width;
overlayHeight_ = height;
int byteLength = overlayWidth_ * overlayHeight_ * 4;
overlayBuffer_ = BufferPtr(new uint8_t[byteLength]);
std::fill(&overlayBuffer_[0], &overlayBuffer_[0] + byteLength, 0);
overlayTexture_.create(overlayWidth_, overlayHeight_);
overlaySprite_.setTexture(overlayTexture_, true);
overlaySprite_.setPosition(0, 0);
}
}
void check_fps()
{
double fpsFactor = 0.02;
std::clock_t newTimepoint= std::clock();
long double frameDuration = (newTimepoint - lastTimepoint_) / static_cast<long double>(CLOCKS_PER_SEC);
frameDuration_ = frameDuration * fpsFactor + frameDuration_ * (1 - fpsFactor);
lastTimepoint_ = newTimepoint;
double fps = 1.0 / frameDuration_;
printf("FPS: %3.1f (%3.4Lf ms)\n", fps, frameDuration_ * 1000);
}
void processDepth(astra::Frame& frame)
{
const astra::DepthFrame depthFrame = frame.get<astra::DepthFrame>();
if (!depthFrame.is_valid()) { return; }
int width = depthFrame.width();
int height = depthFrame.height();
init_depth_texture(width, height);
const int16_t* depthPtr = depthFrame.data();
for(int y = 0; y < height; y++)
{
for(int x = 0; x < width; x++)
{
int index = (x + y * width);
int index4 = index * 4;
int16_t depth = depthPtr[index];
uint8_t value = depth % 255;
displayBuffer_[index4] = value;
displayBuffer_[index4 + 1] = value;
displayBuffer_[index4 + 2] = value;
displayBuffer_[index4 + 3] = 255;
}
}
texture_.update(displayBuffer_.get());
}
void processBodies(astra::Frame& frame)
{
astra::BodyFrame bodyFrame = frame.get<astra::BodyFrame>();
jointPositions_.clear();
circles_.clear();
circleShadows_.clear();
boneLines_.clear();
boneShadows_.clear();
if (!bodyFrame.is_valid() || bodyFrame.info().width() == 0 || bodyFrame.info().height() == 0)
{
clear_overlay();
return;
}
const float jointScale = bodyFrame.info().width() / 120.f;
const auto& bodies = bodyFrame.bodies();
for (auto& body : bodies)
{
printf("Processing frame #%d body %d left hand: %u\n",
bodyFrame.frame_index(), body.id(), unsigned(body.hand_poses().left_hand()));
for(auto& joint : body.joints())
{
jointPositions_.push_back(joint.depth_position());
}
update_body(body, jointScale);
}
const auto& floor = bodyFrame.floor_info(); //floor
if (floor.floor_detected())
{
const auto& p = floor.floor_plane();
std::cout << "Floor plane: ["
<< p.a() << ", " << p.b() << ", " << p.c() << ", " << p.d()
<< "]" << std::endl;
}
const auto& bodyMask = bodyFrame.body_mask();
const auto& floorMask = floor.floor_mask();
update_overlay(bodyMask, floorMask);
}
void update_body(astra::Body body,
const float jointScale)
{
const auto& joints = body.joints();
if (joints.empty())
{
return;
}
for (const auto& joint : joints)
{
astra::JointType type = joint.type();
const auto& pos = joint.depth_position();
if (joint.status() == astra::JointStatus::NotTracked)
{
continue;
}
auto radius = jointRadius_ * jointScale; // pixels
sf::Color circleShadowColor(0, 0, 0, 255);
auto color = sf::Color(0x00, 0xFF, 0x00, 0xFF);
if ((type == astra::JointType::LeftHand && astra::HandPose::Grip==body.hand_poses().left_hand()) ||
(type == astra::JointType::RightHand && astra::HandPose::Grip==body.hand_poses().right_hand()))
{
radius *= 1.5f;
circleShadowColor = sf::Color(255, 255, 255, 255);
color = sf::Color(0x00, 0xAA, 0xFF, 0xFF);
}
const auto shadowRadius = radius + shadowRadius_ * jointScale;
const auto radiusDelta = shadowRadius - radius;
sf::CircleShape circle(radius);
circle.setFillColor(sf::Color(color.r, color.g, color.b, 255));
circle.setPosition(pos.x - radius, pos.y - radius);
circles_.push_back(circle);
sf::CircleShape shadow(shadowRadius);
shadow.setFillColor(circleShadowColor);
shadow.setPosition(circle.getPosition() - sf::Vector2f(radiusDelta, radiusDelta));
circleShadows_.push_back(shadow);
}
update_bone(joints, jointScale, astra::JointType::Head, astra::JointType::Neck);
update_bone(joints, jointScale, astra::JointType::Neck, astra::JointType::ShoulderSpine);
update_bone(joints, jointScale, astra::JointType::ShoulderSpine, astra::JointType::LeftShoulder);
update_bone(joints, jointScale, astra::JointType::LeftShoulder, astra::JointType::LeftElbow);
update_bone(joints, jointScale, astra::JointType::LeftElbow, astra::JointType::LeftWrist);
update_bone(joints, jointScale, astra::JointType::LeftWrist, astra::JointType::LeftHand);
update_bone(joints, jointScale, astra::JointType::ShoulderSpine, astra::JointType::RightShoulder);
update_bone(joints, jointScale, astra::JointType::RightShoulder, astra::JointType::RightElbow);
update_bone(joints, jointScale, astra::JointType::RightElbow, astra::JointType::RightWrist);
update_bone(joints, jointScale, astra::JointType::RightWrist, astra::JointType::RightHand);
update_bone(joints, jointScale, astra::JointType::ShoulderSpine, astra::JointType::MidSpine);
update_bone(joints, jointScale, astra::JointType::MidSpine, astra::JointType::BaseSpine);
update_bone(joints, jointScale, astra::JointType::BaseSpine, astra::JointType::LeftHip);
update_bone(joints, jointScale, astra::JointType::LeftHip, astra::JointType::LeftKnee);
update_bone(joints, jointScale, astra::JointType::LeftKnee, astra::JointType::LeftFoot);
update_bone(joints, jointScale, astra::JointType::BaseSpine, astra::JointType::RightHip);
update_bone(joints, jointScale, astra::JointType::RightHip, astra::JointType::RightKnee);
update_bone(joints, jointScale, astra::JointType::RightKnee, astra::JointType::RightFoot);
}
void update_bone(const astra::JointList& joints,
const float jointScale,astra::JointType j1,
astra::JointType j2)
{
const auto& joint1 = joints[int(j1)];
const auto& joint2 = joints[int(j2)];
if (joint1.status() == astra::JointStatus::NotTracked ||
joint2.status() == astra::JointStatus::NotTracked)
{
//don't render bones between untracked joints
return;
}
//actually depth position, not world position
const auto& jp1 = joint1.depth_position();
const auto& jp2 = joint2.depth_position();
auto p1 = sf::Vector2f(jp1.x, jp1.y);
auto p2 = sf::Vector2f(jp2.x, jp2.y);
sf::Color color(255, 255, 255, 255);
float thickness = lineThickness_ * jointScale;
if (joint1.status() == astra::JointStatus::LowConfidence ||
joint2.status() == astra::JointStatus::LowConfidence)
{
color = sf::Color(128, 128, 128, 255);
thickness *= 0.5f;
}
boneLines_.push_back(sfLine(p1,
p2,
color,
thickness));
const float shadowLineThickness = thickness + shadowRadius_ * jointScale * 2.f;
boneShadows_.push_back(sfLine(p1,
p2,
sf::Color(0, 0, 0, 255),
shadowLineThickness));
}
void update_overlay(const astra::BodyMask& bodyMask,
const astra::FloorMask& floorMask)
{
const auto* bodyData = bodyMask.data();
const auto* floorData = floorMask.data();
const int width = bodyMask.width();
const int height = bodyMask.height();
init_overlay_texture(width, height);
const int length = width * height;
for (int i = 0; i < length; i++)
{
const auto bodyId = bodyData[i];
const auto isFloor = floorData[i];
sf::Color color(0x0, 0x0, 0x0, 0x0);
if (bodyId != 0)
{
color = get_body_color(bodyId);
}
else if (isFloor != 0)
{
color = sf::Color(0x0, 0x0, 0xFF, 0x88);
}
const int rgbaOffset = i * 4;
overlayBuffer_[rgbaOffset] = color.r;
overlayBuffer_[rgbaOffset + 1] = color.g;
overlayBuffer_[rgbaOffset + 2] = color.b;
overlayBuffer_[rgbaOffset + 3] = color.a;
}
overlayTexture_.update(overlayBuffer_.get());
}
void clear_overlay()
{
int byteLength = overlayWidth_ * overlayHeight_ * 4;
std::fill(&overlayBuffer_[0], &overlayBuffer_[0] + byteLength, 0);
overlayTexture_.update(overlayBuffer_.get());
}
virtual void on_frame_ready(astra::StreamReader& reader,
astra::Frame& frame) override
{
processDepth(frame);
processBodies(frame);
check_fps();
}
void draw_bodies(sf::RenderWindow& window)
{
const float scaleX = window.getView().getSize().x / overlayWidth_;
const float scaleY = window.getView().getSize().y / overlayHeight_;
sf::RenderStates states;
sf::Transform transform;
transform.scale(scaleX, scaleY);
states.transform *= transform;
for (const auto& bone : boneShadows_)
window.draw(bone, states);
for (const auto& c : circleShadows_)
window.draw(c, states);
for (const auto& bone : boneLines_)
window.draw(bone, states);
for (auto& c : circles_)
window.draw(c, states);
}
void draw_to(sf::RenderWindow& window)
{
if (displayBuffer_ != nullptr)
{
const float scaleX = window.getView().getSize().x / depthWidth_;
const float scaleY = window.getView().getSize().y / depthHeight_;
sprite_.setScale(scaleX, scaleY);
window.draw(sprite_); // depth
}
if (overlayBuffer_ != nullptr)
{
const float scaleX = window.getView().getSize().x / overlayWidth_;
const float scaleY = window.getView().getSize().y / overlayHeight_;
overlaySprite_.setScale(scaleX, scaleY);
window.draw(overlaySprite_); //bodymask and floormask
}
draw_bodies(window);
}
private:
long double frameDuration_{ 0 };
std::clock_t lastTimepoint_ { 0 };
sf::Texture texture_;
sf::Sprite sprite_;
using BufferPtr = std::unique_ptr < uint8_t[] >;
BufferPtr displayBuffer_{ nullptr };
std::vector<astra::Vector2f> jointPositions_;
int depthWidth_{0};
int depthHeight_{0};
int overlayWidth_{0};
int overlayHeight_{0};
std::vector<sfLine> boneLines_;
std::vector<sfLine> boneShadows_;
std::vector<sf::CircleShape> circles_;
std::vector<sf::CircleShape> circleShadows_;
float lineThickness_{ 0.5f }; // pixels
float jointRadius_{ 1.0f }; // pixels
float shadowRadius_{ 0.5f }; // pixels
BufferPtr overlayBuffer_{ nullptr };
sf::Texture overlayTexture_;
sf::Sprite overlaySprite_;
};
astra::DepthStream configure_depth(astra::StreamReader& reader)
{
auto depthStream = reader.stream<astra::DepthStream>();
//We don't have to set the mode to start the stream, but if you want to here is how:
astra::ImageStreamMode depthMode;
depthMode.set_width(640);
depthMode.set_height(480);
depthMode.set_pixel_format(astra_pixel_formats::ASTRA_PIXEL_FORMAT_DEPTH_MM);
depthMode.set_fps(30);
depthStream.set_mode(depthMode);
return depthStream;
}
int main(int argc, char** argv)
{
astra::initialize();
const char* licenseString = "<INSERT LICENSE KEY HERE>";
orbbec_body_tracking_set_license(licenseString);
sf::RenderWindow window(sf::VideoMode(1280, 960), "Simple Body Viewer");
#ifdef _WIN32
auto fullscreenStyle = sf::Style::None;
#else
auto fullscreenStyle = sf::Style::Fullscreen;
#endif
const sf::VideoMode fullScreenMode = sf::VideoMode::getFullscreenModes()[0];
const sf::VideoMode windowedMode(1280, 960);
bool isFullScreen = false;
astra::StreamSet sensor;
astra::StreamReader reader = sensor.create_reader();
BodyVisualizer listener;
auto depthStream = configure_depth(reader);
depthStream.start();
auto bodyStream = reader.stream<astra::BodyStream>();
bodyStream.start();
reader.add_listener(listener);
astra::SkeletonProfile profile = bodyStream.get_skeleton_profile();
// HandPoses includes Joints and Segmentation
astra::BodyTrackingFeatureFlags features = astra::BodyTrackingFeatureFlags::HandPoses;
while (window.isOpen())
{
astra_update();
sf::Event event;
while (window.pollEvent(event))
{
switch (event.type)
{
case sf::Event::Closed:
window.close();
break;
case sf::Event::KeyPressed:
{
if (event.key.code == sf::Keyboard::C && event.key.control)
{
window.close();
}
switch (event.key.code)
{
case sf::Keyboard::Escape:
window.close();
break;
case sf::Keyboard::F:
if (isFullScreen)
{
window.create(windowedMode, "Simple Body Viewer", sf::Style::Default);
}
else
{
window.create(fullScreenMode, "Simple Body Viewer", fullscreenStyle);
}
isFullScreen = !isFullScreen;
break;
case sf::Keyboard::R:
depthStream.enable_registration(!depthStream.registration_enabled());
break;
case sf::Keyboard::M:
depthStream.enable_mirroring(!depthStream.mirroring_enabled());
break;
case sf::Keyboard::P:
if (profile == astra::SkeletonProfile::Full)
{
profile = astra::SkeletonProfile::Basic;
printf("Skeleton Profile: basic\n");
}
else
{
profile = astra::SkeletonProfile::Full;
printf("Skeleton Profile: full\n");
}
bodyStream.set_skeleton_profile(profile);
break;
case sf::Keyboard::T:
if (features == astra::BodyTrackingFeatureFlags::Segmentation)
{
// Joints includes Segmentation
features = astra::BodyTrackingFeatureFlags::Joints;
printf("Default Body Features: Seg+Body\n");
}
else if (features == astra::BodyTrackingFeatureFlags::Joints)
{
// HandPoses includes Joints and Segmentation
features = astra::BodyTrackingFeatureFlags::HandPoses;
printf("Default Body Features: Seg+Body+Hand\n");
}
else
{
// HandPoses includes Joints and Segmentation
features = astra::BodyTrackingFeatureFlags::Segmentation;
printf("Default Body Features: Seg\n");
}
bodyStream.set_default_body_features(features);
break;
default:
break;
}
break;
}
default:
break;
}
}
// clear the window with black color
window.clear(sf::Color::Black);
listener.draw_to(window);
window.display();
}
astra::terminate();
return 0;
}


Astra SDK: SimpleColorViewer-SFML\main.cpp

SimpleColorViewer-SFML\main.cpp
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <SFML/Graphics.hpp>
#include <astra_core/astra_core.hpp>
#include <astra/astra.hpp>
#include <chrono>
#include <iostream>
#include <iomanip>
#include <cstring>
#include <key_handler.h>
class ColorFrameListener : public astra::FrameListener
{
public:
ColorFrameListener()
{
prev_ = ClockType::now();
}
void init_texture(int width, int height)
{
if (displayBuffer_ == nullptr || width != displayWidth_ || height != displayHeight_)
{
displayWidth_ = width;
displayHeight_ = height;
// texture is RGBA
int byteLength = displayWidth_ * displayHeight_ * 4;
displayBuffer_ = BufferPtr(new uint8_t[byteLength]);
std::memset(displayBuffer_.get(), 0, byteLength);
texture_.create(displayWidth_, displayHeight_);
sprite_.setTexture(texture_, true);
sprite_.setPosition(0, 0);
}
}
void check_fps()
{
const float frameWeight = .2f;
const ClockType::time_point now = ClockType::now();
const float elapsedMillis = std::chrono::duration_cast<DurationType>(now - prev_).count();
elapsedMillis_ = elapsedMillis * frameWeight + elapsedMillis_ * (1.f - frameWeight);
prev_ = now;
const float fps = 1000.f / elapsedMillis;
const auto precision = std::cout.precision();
std::cout << std::fixed
<< std::setprecision(1)
<< fps << " fps ("
<< std::setprecision(1)
<< elapsedMillis_ << " ms)"
<< std::setprecision(precision)
<< std::endl;
}
virtual void on_frame_ready(astra::StreamReader& reader, astra::Frame& frame) override
{
const astra::ColorFrame colorFrame = frame.get<astra::ColorFrame>();
int width = colorFrame.width();
int height = colorFrame.height();
init_texture(width, height);
const astra::RgbPixel* colorData = colorFrame.data();
for (int i = 0; i < width * height; i++)
{
int rgbaOffset = i * 4;
displayBuffer_[rgbaOffset] = colorData[i].r;
displayBuffer_[rgbaOffset + 1] = colorData[i].g;
displayBuffer_[rgbaOffset + 2] = colorData[i].b;
displayBuffer_[rgbaOffset + 3] = 255;
}
texture_.update(displayBuffer_.get());
check_fps();
}
void drawTo(sf::RenderWindow& window)
{
if (displayBuffer_ != nullptr)
{
float imageScale = window.getView().getSize().x / displayWidth_;
sprite_.setScale(imageScale, imageScale);
window.draw(sprite_);
}
}
private:
using DurationType = std::chrono::milliseconds;
using ClockType = std::chrono::high_resolution_clock;
ClockType::time_point prev_;
float elapsedMillis_{.0f};
sf::Texture texture_;
sf::Sprite sprite_;
using BufferPtr = std::unique_ptr<uint8_t[]>;
BufferPtr displayBuffer_{nullptr};
int displayWidth_{0};
int displayHeight_{0};
};
int main(int argc, char** argv)
{
astra::initialize();
set_key_handler();
sf::RenderWindow window(sf::VideoMode(1280, 960), "Color Viewer");
astra::StreamSet streamSet;
astra::StreamReader reader = streamSet.create_reader();
reader.stream<astra::ColorStream>().start();
ColorFrameListener listener;
reader.add_listener(listener);
while (window.isOpen())
{
astra_update();
sf::Event event;
while (window.pollEvent(event))
{
switch (event.type)
{
case sf::Event::Closed:
window.close();
break;
case sf::Event::KeyPressed:
{
if (event.key.code == sf::Keyboard::Escape ||
(event.key.code == sf::Keyboard::C && event.key.control))
{
window.close();
}
}
default:
break;
}
}
// clear the window with black color
window.clear(sf::Color::Black);
listener.drawTo(window);
window.display();
if (!shouldContinue)
{
window.close();
}
}
astra::terminate();
return 0;
}


Astra SDK: SimpleDepthViewer-SFML\main.cpp

SimpleDepthViewer-SFML\main.cpp
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <SFML/Graphics.hpp>
#include <astra/astra.hpp>
#include "LitDepthVisualizer.hpp"
#include <chrono>
#include <iostream>
#include <iomanip>
#include <key_handler.h>
#include <sstream>
class DepthFrameListener : public astra::FrameListener
{
public:
DepthFrameListener()
{
prev_ = ClockType::now();
font_.loadFromFile("Inconsolata.otf");
}
void init_texture(int width, int height)
{
if (!displayBuffer_ ||
width != displayWidth_ ||
height != displayHeight_)
{
displayWidth_ = width;
displayHeight_ = height;
// texture is RGBA
const int byteLength = displayWidth_ * displayHeight_ * 4;
displayBuffer_ = BufferPtr(new uint8_t[byteLength]);
std::fill(&displayBuffer_[0], &displayBuffer_[0] + byteLength, 0);
texture_.create(displayWidth_, displayHeight_);
sprite_.setTexture(texture_, true);
sprite_.setPosition(0, 0);
}
}
void check_fps()
{
const float frameWeight = .2f;
const ClockType::time_point now = ClockType::now();
const float elapsedMillis = std::chrono::duration_cast<DurationType>(now - prev_).count();
elapsedMillis_ = elapsedMillis * frameWeight + elapsedMillis_ * (1.f - frameWeight);
prev_ = now;
const float fps = 1000.f / elapsedMillis;
const auto precision = std::cout.precision();
std::cout << std::fixed
<< std::setprecision(1)
<< fps << " fps ("
<< std::setprecision(1)
<< elapsedMillis_ << " ms)"
<< std::setprecision(precision)
<< std::endl;
}
void on_frame_ready(astra::StreamReader& reader,
astra::Frame& frame) override
{
const astra::PointFrame pointFrame = frame.get<astra::PointFrame>();
const int width = pointFrame.width();
const int height = pointFrame.height();
init_texture(width, height);
check_fps();
if (isPaused_) { return; }
copy_depth_data(frame);
visualizer_.update(pointFrame);
const astra::RgbPixel* vizBuffer = visualizer_.get_output();
for (int i = 0; i < width * height; i++)
{
const int rgbaOffset = i * 4;
displayBuffer_[rgbaOffset] = vizBuffer[i].r;
displayBuffer_[rgbaOffset + 1] = vizBuffer[i].b;
displayBuffer_[rgbaOffset + 2] = vizBuffer[i].g;
displayBuffer_[rgbaOffset + 3] = 255;
}
texture_.update(displayBuffer_.get());
}
void copy_depth_data(astra::Frame& frame)
{
const astra::DepthFrame depthFrame = frame.get<astra::DepthFrame>();
if (depthFrame.is_valid())
{
const int width = depthFrame.width();
const int height = depthFrame.height();
if (!depthData_ || width != depthWidth_ || height != depthHeight_)
{
depthWidth_ = width;
depthHeight_ = height;
// texture is RGBA
const int byteLength = depthWidth_ * depthHeight_ * sizeof(uint16_t);
depthData_ = DepthPtr(new int16_t[byteLength]);
}
depthFrame.copy_to(&depthData_[0]);
}
}
void update_mouse_position(sf::RenderWindow& window,
const astra::CoordinateMapper& coordinateMapper)
{
const sf::Vector2i position = sf::Mouse::getPosition(window);
const sf::Vector2u windowSize = window.getSize();
float mouseNormX = position.x / float(windowSize.x);
float mouseNormY = position.y / float(windowSize.y);
mouseX_ = depthWidth_ * mouseNormX;
mouseY_ = depthHeight_ * mouseNormY;
if (mouseX_ >= depthWidth_ ||
mouseY_ >= depthHeight_ ||
mouseX_ < 0 ||
mouseY_ < 0) { return; }
const size_t index = (depthWidth_ * mouseY_ + mouseX_);
const short z = depthData_[index];
coordinateMapper.convert_depth_to_world(float(mouseX_),
float(mouseY_),
float(z),
mouseWorldX_,
mouseWorldY_,
mouseWorldZ_);
}
void draw_text(sf::RenderWindow& window,
sf::Text& text,
sf::Color color,
const int x,
const int y) const
{
text.setColor(sf::Color::Black);
text.setPosition(x + 5, y + 5);
window.draw(text);
text.setColor(color);
text.setPosition(x, y);
window.draw(text);
}
void draw_mouse_overlay(sf::RenderWindow& window,
const float depthWScale,
const float depthHScale) const
{
if (!isMouseOverlayEnabled_ || !depthData_) { return; }
std::stringstream str;
str << std::fixed
<< std::setprecision(0)
<< "(" << mouseX_ << ", " << mouseY_ << ") "
<< "X: " << mouseWorldX_ << " Y: " << mouseWorldY_ << " Z: " << mouseWorldZ_;
const int characterSize = 40;
sf::Text text(str.str(), font_);
text.setCharacterSize(characterSize);
text.setStyle(sf::Text::Bold);
const float displayX = 10.f;
const float margin = 10.f;
const float displayY = window.getView().getSize().y - (margin + characterSize);
draw_text(window, text, sf::Color::White, displayX, displayY);
}
void draw_to(sf::RenderWindow& window)
{
if (displayBuffer_ != nullptr)
{
const float depthWScale = window.getView().getSize().x / displayWidth_;
const float depthHScale = window.getView().getSize().y / displayHeight_;
sprite_.setScale(depthWScale, depthHScale);
window.draw(sprite_);
draw_mouse_overlay(window, depthWScale, depthHScale);
}
}
void toggle_paused()
{
isPaused_ = !isPaused_;
}
bool is_paused() const
{
return isPaused_;
}
void toggle_overlay()
{
isMouseOverlayEnabled_ = !isMouseOverlayEnabled_;
}
bool overlay_enabled() const
{
return isMouseOverlayEnabled_;
}
private:
samples::common::LitDepthVisualizer visualizer_;
using DurationType = std::chrono::milliseconds;
using ClockType = std::chrono::high_resolution_clock;
ClockType::time_point prev_;
float elapsedMillis_{.0f};
sf::Texture texture_;
sf::Sprite sprite_;
sf::Font font_;
int displayWidth_{0};
int displayHeight_{0};
using BufferPtr = std::unique_ptr<uint8_t[]>;
BufferPtr displayBuffer_{nullptr};
int depthWidth_{0};
int depthHeight_{0};
using DepthPtr = std::unique_ptr<int16_t[]>;
DepthPtr depthData_{nullptr};
int mouseX_{0};
int mouseY_{0};
float mouseWorldX_{0};
float mouseWorldY_{0};
float mouseWorldZ_{0};
bool isPaused_{false};
bool isMouseOverlayEnabled_{true};
};
astra::DepthStream configure_depth(astra::StreamReader& reader)
{
auto depthStream = reader.stream<astra::DepthStream>();
auto oldMode = depthStream.mode();
//We don't have to set the mode to start the stream, but if you want to here is how:
astra::ImageStreamMode depthMode;
depthMode.set_width(640);
depthMode.set_height(480);
depthMode.set_pixel_format(astra_pixel_formats::ASTRA_PIXEL_FORMAT_DEPTH_MM);
depthMode.set_fps(30);
depthStream.set_mode(depthMode);
auto newMode = depthStream.mode();
printf("Changed depth mode: %dx%d @ %d -> %dx%d @ %d\n",
oldMode.width(), oldMode.height(), oldMode.fps(),
newMode.width(), newMode.height(), newMode.fps());
return depthStream;
}
int main(int argc, char** argv)
{
astra::initialize();
set_key_handler();
sf::RenderWindow window(sf::VideoMode(1280, 960), "Depth Viewer");
#ifdef _WIN32
auto fullscreenStyle = sf::Style::None;
#else
auto fullscreenStyle = sf::Style::Fullscreen;
#endif
const sf::VideoMode fullScreenMode = sf::VideoMode::getFullscreenModes()[0];
const sf::VideoMode windowedMode(1280, 1024);
bool isFullScreen = false;
astra::StreamSet streamSet;
astra::StreamReader reader = streamSet.create_reader();
reader.stream<astra::PointStream>().start();
auto depthStream = configure_depth(reader);
depthStream.start();
DepthFrameListener listener;
reader.add_listener(listener);
while (window.isOpen())
{
astra_update();
sf::Event event;
while (window.pollEvent(event))
{
switch (event.type)
{
case sf::Event::Closed:
window.close();
break;
case sf::Event::KeyPressed:
{
if (event.key.code == sf::Keyboard::C && event.key.control)
{
window.close();
}
switch (event.key.code)
{
case sf::Keyboard::Escape:
window.close();
break;
case sf::Keyboard::F:
if (isFullScreen)
{
window.create(windowedMode, "Depth Viewer", sf::Style::Default);
}
else
{
window.create(fullScreenMode, "Depth Viewer", fullscreenStyle);
}
isFullScreen = !isFullScreen;
break;
case sf::Keyboard::R:
depthStream.enable_registration(!depthStream.registration_enabled());
break;
case sf::Keyboard::M:
depthStream.enable_mirroring(!depthStream.mirroring_enabled());
break;
case sf::Keyboard::P:
listener.toggle_paused();
break;
case sf::Keyboard::Space:
listener.toggle_overlay();
break;
default:
break;
}
break;
}
case sf::Event::MouseMoved:
{
auto coordinateMapper = depthStream.coordinateMapper();
listener.update_mouse_position(window, coordinateMapper);
break;
}
default:
break;
}
}
// clear the window with black color
window.clear(sf::Color::Black);
listener.draw_to(window);
window.display();
if (!shouldContinue)
{
window.close();
}
}
astra::terminate();
return 0;
}


Astra SDK: SimpleHandViewer-SFML\main.cpp

SimpleHandViewer-SFML\main.cpp
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <sstream>
#include <iomanip>
#include <deque>
#include <unordered_map>
#include <chrono>
#include <SFML/Graphics.hpp>
#include <astra_core/astra_core.hpp>
#include <astra/astra.hpp>
#include "LitDepthVisualizer.hpp"
#include <key_handler.h>
class sfLine : public sf::Drawable
{
public:
sfLine(const sf::Vector2f& point1, const sf::Vector2f& point2, sf::Color color, float thickness)
: color_(color)
{
const sf::Vector2f direction = point2 - point1;
const sf::Vector2f unitDirection = direction / std::sqrt(direction.x*direction.x + direction.y*direction.y);
const sf::Vector2f normal(-unitDirection.y, unitDirection.x);
const sf::Vector2f offset = (thickness / 2.f) * normal;
vertices_[0].position = point1 + offset;
vertices_[1].position = point2 + offset;
vertices_[2].position = point2 - offset;
vertices_[3].position = point1 - offset;
for (int i = 0; i<4; ++i)
vertices_[i].color = color;
}
void draw(sf::RenderTarget &target, sf::RenderStates states) const
{
target.draw(vertices_, 4, sf::Quads);
}
private:
sf::Vertex vertices_[4];
sf::Color color_;
};
class HandFrameListener : public astra::FrameListener
{
public:
using PointList = std::deque<astra::Vector2i>;
using PointMap = std::unordered_map<int, PointList>;
HandFrameListener()
{
font_.loadFromFile("Inconsolata.otf");
prev_ = ClockType::now();
}
HandFrameListener(const HandFrameListener&) = delete;
HandFrameListener& operator=(const HandFrameListener&) = delete;
void init_texture(int width, int height)
{
if (displayBuffer_ == nullptr || width != depthWidth_ || height != depthHeight_)
{
depthWidth_ = width;
depthHeight_ = height;
const int byteLength = depthWidth_ * depthHeight_ * 4;
displayBuffer_ = BufferPtr(new uint8_t[byteLength]);
std::fill(&displayBuffer_[0], &displayBuffer_[0] + byteLength, 0);
texture_.create(depthWidth_, depthHeight_);
sprite_.setTexture(texture_, true);
sprite_.setPosition(0, 0);
}
}
void check_fps()
{
const float frameWeight = .2f;
const ClockType::time_point now = ClockType::now();
const float elapsedMillis = std::chrono::duration_cast<DurationType>(now - prev_).count();
elapsedMillis_ = elapsedMillis * frameWeight + elapsedMillis_ * (1.f - frameWeight);
prev_ = now;
const float fps = 1000.f / elapsedMillis;
const auto precision = std::cout.precision();
std::cout << std::fixed
<< std::setprecision(1)
<< fps << " fps ("
<< std::setprecision(1)
<< elapsedMillis_ << " ms)"
<< std::setprecision(precision)
<< std::endl;
}
void process_depth(astra::Frame& frame)
{
const astra::PointFrame pointFrame = frame.get<astra::PointFrame>();
const int width = pointFrame.width();
const int height = pointFrame.height();
init_texture(width, height);
visualizer_.update(pointFrame);
const astra::RgbPixel* vizBuffer = visualizer_.get_output();
for (int i = 0; i < width * height; i++)
{
const int rgbaOffset = i * 4;
displayBuffer_[rgbaOffset] = vizBuffer[i].r;
displayBuffer_[rgbaOffset + 1] = vizBuffer[i].b;
displayBuffer_[rgbaOffset + 2] = vizBuffer[i].g;
displayBuffer_[rgbaOffset + 3] = 255;
}
texture_.update(displayBuffer_.get());
}
void update_hand_trace(int trackingId, const astra::Vector2i& position)
{
auto it = pointMap_.find(trackingId);
if (it == pointMap_.end())
{
PointList list;
for (int i = 0; i < maxTraceLength_; i++)
{
list.push_back(position);
}
pointMap_.insert({trackingId, list});
}
else
{
PointList& list = it->second;
while (list.size() < maxTraceLength_)
{
list.push_back(position);
}
}
}
void shorten_hand_traces()
{
auto it = pointMap_.begin();
while (it != pointMap_.end())
{
PointList& list = it->second;
if (list.size() > 1)
{
list.pop_front();
++it;
}
else
{
it = pointMap_.erase(it);
}
}
}
void process_hand_frame(astra::Frame& frame)
{
const astra::HandFrame handFrame = frame.get<astra::HandFrame>();
handPoints_ = handFrame.handpoints();
shorten_hand_traces();
for (const auto& handPoint : handPoints_)
{
if (handPoint.status() == HAND_STATUS_TRACKING)
{
update_hand_trace(handPoint.tracking_id(), handPoint.depth_position());
}
}
}
virtual void on_frame_ready(astra::StreamReader& reader,
astra::Frame& frame) override
{
process_depth(frame);
process_hand_frame(frame);
check_fps();
}
void draw_circle(sf::RenderWindow& window, float radius, float x, float y, sf::Color color)
{
sf::CircleShape shape(radius);
shape.setFillColor(color);
shape.setOrigin(radius, radius);
shape.setPosition(x, y);
window.draw(shape);
}
void draw_shadow_text(sf::RenderWindow& window, sf::Text& text, sf::Color color, int x, int y)
{
text.setColor(sf::Color::Black);
text.setPosition(x + 5, y + 5);
window.draw(text);
text.setColor(color);
text.setPosition(x, y);
window.draw(text);
}
void draw_hand_label(sf::RenderWindow& window,
const float radius,
const float x,
const float y,
const astra::HandPoint& handPoint)
{
const auto trackingId = handPoint.tracking_id();
std::stringstream str;
str << trackingId;
if (handPoint.status() == HAND_STATUS_LOST) { str << "Lost"; }
sf::Text label(str.str(), font_);
const int characterSize = 60;
label.setCharacterSize(characterSize);
const auto bounds = label.getLocalBounds();
label.setOrigin(bounds.left + bounds.width / 2.f, characterSize);
draw_shadow_text(window, label, sf::Color::White, x, y - radius - 10);
}
void draw_hand_position(sf::RenderWindow& window,
const float radius,
const float x,
const float y,
const astra::HandPoint& handPoint)
{
const auto worldPosition = handPoint.world_position();
std::stringstream str;
str << std::fixed
<< std::setprecision(0)
<< worldPosition.x << ", "
<< worldPosition.y << ", "
<< worldPosition.z;
sf::Text label(str.str(), font_);
const int characterSize = 60;
label.setCharacterSize(characterSize);
const auto bounds = label.getLocalBounds();
label.setOrigin(bounds.left + bounds.width / 2.f, 0);
draw_shadow_text(window, label, sf::Color::White, x, y + radius + 10);
}
void draw_hand_trace(sf::RenderWindow& window,
const PointList& pointList,
const sf::Color& color,
const float depthScale)
{
if (pointList.size() < 2) { return; }
const float thickness = 4;
auto it = pointList.begin();
astra::Vector2i previousPoint = *it;
while (it != pointList.end())
{
const astra::Vector2i currentPoint = *it;
++it;
const sf::Vector2f p1((previousPoint.x + .5f) * depthScale,
(previousPoint.y + .5f) * depthScale);
const sf::Vector2f p2((currentPoint.x + .5f) * depthScale,
(currentPoint.y + .5f) * depthScale);
previousPoint = currentPoint;
window.draw(sfLine(p1, p2, color, thickness));
}
}
void draw_hand_points(sf::RenderWindow& window, const float depthScale)
{
const float radius = 16;
const sf::Color candidateColor(255, 255, 0);
const sf::Color lostColor(255, 0, 0);
const sf::Color trackingColor(0, 139, 69);
for (const auto& handPoint : handPoints_)
{
sf::Color color;
switch(handPoint.status())
{
case HAND_STATUS_LOST:
color = lostColor;
case HAND_STATUS_CANDIDATE:
color = candidateColor;
default:
color = trackingColor;
}
const astra::Vector2i& p = handPoint.depth_position();
const float circleX = (p.x + .5f) * depthScale;
const float circleY = (p.y + .5f) * depthScale;
draw_circle(window, radius, circleX, circleY, color);
draw_hand_label(window, radius, circleX, circleY, handPoint);
if (handPoint.status() == HAND_STATUS_TRACKING)
{
draw_hand_position(window, radius, circleX, circleY, handPoint);
}
}
const sf::Color lineColor(0, 0, 255);
for (const auto& kvp : pointMap_)
{
const PointList& list = kvp.second;
draw_hand_trace(window, list, lineColor, depthScale);
}
}
void draw_to(sf::RenderWindow& window)
{
if (displayBuffer_)
{
const float depthScale = window.getView().getSize().x / depthWidth_;
sprite_.setScale(depthScale, depthScale);
window.draw(sprite_);
draw_hand_points(window, depthScale);
}
}
private:
samples::common::LitDepthVisualizer visualizer_;
using DurationType = std::chrono::milliseconds;
using ClockType = std::chrono::high_resolution_clock;
ClockType::time_point prev_;
float elapsedMillis_{.0f};
sf::Texture texture_;
sf::Sprite sprite_;
sf::Font font_;
using BufferPtr = std::unique_ptr<uint8_t[]>;
BufferPtr displayBuffer_{nullptr};
std::vector<astra::HandPoint> handPoints_;
PointMap pointMap_;
int depthWidth_{0};
int depthHeight_{0};
int maxTraceLength_{15};
};
int main(int argc, char** argv)
{
astra::initialize();
set_key_handler();
sf::RenderWindow window(sf::VideoMode(1280, 960), "Hand Viewer");
astra::StreamSet streamSet;
astra::StreamReader reader = streamSet.create_reader();
reader.stream<astra::PointStream>().start();
reader.stream<astra::HandStream>().start();
HandFrameListener listener;
reader.add_listener(listener);
while (window.isOpen())
{
astra_update();
sf::Event event;
while (window.pollEvent(event))
{
switch (event.type)
{
case sf::Event::Closed:
window.close();
break;
case sf::Event::KeyPressed:
{
if (event.key.code == sf::Keyboard::Escape ||
(event.key.code == sf::Keyboard::C && event.key.control))
{
window.close();
}
}
default:
break;
}
}
// clear the window with black color
window.clear(sf::Color::Black);
listener.draw_to(window);
window.display();
if (!shouldContinue)
{
window.close();
}
}
astra::terminate();
return 0;
}


Astra SDK: SimpleStreamViewer-SFML\main.cpp

SimpleStreamViewer-SFML\main.cpp
// This file is part of the Orbbec Astra SDK [https://orbbec3d.com]
// Copyright (c) 2015-2017 Orbbec 3D
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Be excellent to each other.
#include <SFML/Graphics.hpp>
#include <astra_core/astra_core.hpp>
#include <astra/astra.hpp>
#include "LitDepthVisualizer.hpp"
#include <chrono>
#include <iostream>
#include <iomanip>
#include <key_handler.h>
enum ColorMode
{
MODE_COLOR,
MODE_IR_16,
MODE_IR_RGB,
};
class MultiFrameListener : public astra::FrameListener
{
public:
using BufferPtr = std::unique_ptr<uint8_t[]>;
struct StreamView
{
sf::Sprite sprite_;
sf::Texture texture_;
BufferPtr buffer_;
int width_{0};
int height_{0};
};
MultiFrameListener()
{
prev_ = ClockType::now();
}
void init_texture(int width, int height, StreamView& view)
{
if (view.buffer_ == nullptr || width != view.width_ || height != view.height_)
{
view.width_ = width;
view.height_ = height;
// texture is RGBA
const int byteLength = width * height * 4;
view.buffer_ = BufferPtr(new uint8_t[byteLength]);
clear_view(view);
view.texture_.create(width, height);
view.sprite_.setTexture(view.texture_, true);
view.sprite_.setPosition(0, 0);
}
}
void clear_view(StreamView& view)
{
const int byteLength = view.width_ * view.height_ * 4;
std::fill(&view.buffer_[0], &view.buffer_[0] + byteLength, 0);
}
void check_fps()
{
const float frameWeight = .2f;
const ClockType::time_point now = ClockType::now();
const float elapsedMillis = std::chrono::duration_cast<DurationType>(now - prev_).count();
elapsedMillis_ = elapsedMillis * frameWeight + elapsedMillis_ * (1.f - frameWeight);
prev_ = now;
const float fps = 1000.f / elapsedMillis;
const auto precision = std::cout.precision();
std::cout << std::fixed
<< std::setprecision(1)
<< fps << " fps ("
<< std::setprecision(1)
<< elapsedMillis_ << " ms)"
<< std::setprecision(precision)
<< std::endl;
}
void update_depth(astra::Frame& frame)
{
const astra::PointFrame pointFrame = frame.get<astra::PointFrame>();
if (!pointFrame.is_valid())
{
clear_view(depthView_);
depthView_.texture_.update(&depthView_.buffer_[0]);
return;
}
const int depthWidth = pointFrame.width();
const int depthHeight = pointFrame.height();
init_texture(depthWidth, depthHeight, depthView_);
if (isPaused_) { return; }
visualizer_.update(pointFrame);
astra::RgbPixel* vizBuffer = visualizer_.get_output();
uint8_t* buffer = &depthView_.buffer_[0];
for (int i = 0; i < depthWidth * depthHeight; i++)
{
const int rgbaOffset = i * 4;
buffer[rgbaOffset] = vizBuffer[i].r;
buffer[rgbaOffset + 1] = vizBuffer[i].g;
buffer[rgbaOffset + 2] = vizBuffer[i].b;
buffer[rgbaOffset + 3] = 255;
}
depthView_.texture_.update(&depthView_.buffer_[0]);
}
void update_color(astra::Frame& frame)
{
const astra::ColorFrame colorFrame = frame.get<astra::ColorFrame>();
if (!colorFrame.is_valid())
{
clear_view(colorView_);
colorView_.texture_.update(&colorView_.buffer_[0]);
return;
}
const int colorWidth = colorFrame.width();
const int colorHeight = colorFrame.height();
init_texture(colorWidth, colorHeight, colorView_);
if (isPaused_) { return; }
const astra::RgbPixel* color = colorFrame.data();
uint8_t* buffer = &colorView_.buffer_[0];
for(int i = 0; i < colorWidth * colorHeight; i++)
{
const int rgbaOffset = i * 4;
buffer[rgbaOffset] = color[i].r;
buffer[rgbaOffset + 1] = color[i].g;
buffer[rgbaOffset + 2] = color[i].b;
buffer[rgbaOffset + 3] = 255;
}
colorView_.texture_.update(&colorView_.buffer_[0]);
}
void update_ir_16(astra::Frame& frame)
{
const astra::InfraredFrame16 irFrame = frame.get<astra::InfraredFrame16>();
if (!irFrame.is_valid())
{
clear_view(colorView_);
colorView_.texture_.update(&colorView_.buffer_[0]);
return;
}
const int irWidth = irFrame.width();
const int irHeight = irFrame.height();
init_texture(irWidth, irHeight, colorView_);
if (isPaused_) { return; }
const uint16_t* ir_values = irFrame.data();
uint8_t* buffer = &colorView_.buffer_[0];
for (int i = 0; i < irWidth * irHeight; i++)
{
const int rgbaOffset = i * 4;
const uint16_t value = ir_values[i];
const uint8_t red = static_cast<uint8_t>(value >> 2);
const uint8_t blue = 0x66 - red / 2;
buffer[rgbaOffset] = red;
buffer[rgbaOffset + 1] = 0;
buffer[rgbaOffset + 2] = blue;
buffer[rgbaOffset + 3] = 255;
}
colorView_.texture_.update(&colorView_.buffer_[0]);
}
void update_ir_rgb(astra::Frame& frame)
{
const astra::InfraredFrameRgb irFrame = frame.get<astra::InfraredFrameRgb>();
if (!irFrame.is_valid())
{
clear_view(colorView_);
colorView_.texture_.update(&colorView_.buffer_[0]);
return;
}
int irWidth = irFrame.width();
int irHeight = irFrame.height();
init_texture(irWidth, irHeight, colorView_);
if (isPaused_) { return; }
const astra::RgbPixel* irRGB = irFrame.data();
uint8_t* buffer = &colorView_.buffer_[0];
for (int i = 0; i < irWidth * irHeight; i++)
{
const int rgbaOffset = i * 4;
buffer[rgbaOffset] = irRGB[i].r;
buffer[rgbaOffset + 1] = irRGB[i].g;
buffer[rgbaOffset + 2] = irRGB[i].b;
buffer[rgbaOffset + 3] = 255;
}
colorView_.texture_.update(&colorView_.buffer_[0]);
}
virtual void on_frame_ready(astra::StreamReader& reader,
astra::Frame& frame) override
{
update_depth(frame);
switch (colorMode_)
{
case MODE_COLOR:
update_color(frame);
break;
case MODE_IR_16:
update_ir_16(frame);
break;
case MODE_IR_RGB:
update_ir_rgb(frame);
break;
}
check_fps();
}
void draw_to(sf::RenderWindow& window, sf::Vector2f origin, sf::Vector2f size)
{
const int viewSize = (int)(size.x / 2.0f);
const sf::Vector2f windowSize = window.getView().getSize();
if (depthView_.buffer_ != nullptr)
{
const float depthScale = viewSize / (float)depthView_.width_;
const int horzCenter = origin.y * windowSize.y;
depthView_.sprite_.setScale(depthScale, depthScale);
depthView_.sprite_.setPosition(origin.x * windowSize.x, horzCenter);
window.draw(depthView_.sprite_);
}
if (colorView_.buffer_ != nullptr)
{
const float colorScale = viewSize / (float)colorView_.width_;
const int horzCenter = origin.y * windowSize.y;
colorView_.sprite_.setScale(colorScale, colorScale);
if (overlayDepth_)
{
colorView_.sprite_.setPosition(origin.x * windowSize.x, horzCenter);
colorView_.sprite_.setColor(sf::Color(255, 255, 255, 128));
}
else
{
colorView_.sprite_.setPosition(origin.x * windowSize.x + viewSize, horzCenter);
colorView_.sprite_.setColor(sf::Color(255, 255, 255, 255));
}
window.draw(colorView_.sprite_);
}
}
void toggle_depth_overlay()
{
overlayDepth_ = !overlayDepth_;
}
bool get_overlay_depth() const
{
return overlayDepth_;
}
void toggle_paused()
{
isPaused_ = !isPaused_;
}
bool is_paused() const
{
return isPaused_;
}
ColorMode get_mode() const { return colorMode_; }
void set_mode(ColorMode mode) { colorMode_ = mode; }
private:
samples::common::LitDepthVisualizer visualizer_;
using DurationType = std::chrono::milliseconds;
using ClockType = std::chrono::high_resolution_clock;
ClockType::time_point prev_;
float elapsedMillis_{.0f};
StreamView depthView_;
StreamView colorView_;
ColorMode colorMode_;
bool overlayDepth_{ false };
bool isPaused_{ false };
};
astra::DepthStream configure_depth(astra::StreamReader& reader)
{
auto depthStream = reader.stream<astra::DepthStream>();
auto oldMode = depthStream.mode();
//We don't have to set the mode to start the stream, but if you want to here is how:
astra::ImageStreamMode depthMode;
depthMode.set_width(640);
depthMode.set_height(480);
depthMode.set_pixel_format(astra_pixel_formats::ASTRA_PIXEL_FORMAT_DEPTH_MM);
depthMode.set_fps(30);
depthStream.set_mode(depthMode);
auto newMode = depthStream.mode();
printf("Changed depth mode: %dx%d @ %d -> %dx%d @ %d\n",
oldMode.width(), oldMode.height(), oldMode.fps(),
newMode.width(), newMode.height(), newMode.fps());
return depthStream;
}
astra::InfraredStream configure_ir(astra::StreamReader& reader, bool useRGB)
{
auto irStream = reader.stream<astra::InfraredStream>();
auto oldMode = irStream.mode();
astra::ImageStreamMode irMode;
irMode.set_width(640);
irMode.set_height(480);
if (useRGB)
{
irMode.set_pixel_format(astra_pixel_formats::ASTRA_PIXEL_FORMAT_RGB888);
}
else
{
irMode.set_pixel_format(astra_pixel_formats::ASTRA_PIXEL_FORMAT_GRAY16);
}
irMode.set_fps(30);
irStream.set_mode(irMode);
auto newMode = irStream.mode();
printf("Changed IR mode: %dx%d @ %d -> %dx%d @ %d\n",
oldMode.width(), oldMode.height(), oldMode.fps(),
newMode.width(), newMode.height(), newMode.fps());
return irStream;
}
astra::ColorStream configure_color(astra::StreamReader& reader)
{
auto colorStream = reader.stream<astra::ColorStream>();
auto oldMode = colorStream.mode();
astra::ImageStreamMode colorMode;
colorMode.set_width(640);
colorMode.set_height(480);
colorMode.set_pixel_format(astra_pixel_formats::ASTRA_PIXEL_FORMAT_RGB888);
colorMode.set_fps(30);
colorStream.set_mode(colorMode);
auto newMode = colorStream.mode();
printf("Changed color mode: %dx%d @ %d -> %dx%d @ %d\n",
oldMode.width(), oldMode.height(), oldMode.fps(),
newMode.width(), newMode.height(), newMode.fps());
return colorStream;
}
int main(int argc, char** argv)
{
astra::initialize();
set_key_handler();
#ifdef _WIN32
auto fullscreenStyle = sf::Style::None;
#else
auto fullscreenStyle = sf::Style::Fullscreen;
#endif
const sf::VideoMode fullScreenMode = sf::VideoMode::getFullscreenModes()[0];
const sf::VideoMode windowedMode(1800, 675);
bool isFullScreen = false;
sf::RenderWindow window(windowedMode, "Stream Viewer");
astra::StreamSet streamSet;
astra::StreamReader reader = streamSet.create_reader();
reader.stream<astra::PointStream>().start();
auto depthStream = configure_depth(reader);
depthStream.start();
auto colorStream = configure_color(reader);
colorStream.start();
auto irStream = configure_ir(reader, false);
MultiFrameListener listener;
listener.set_mode(MODE_COLOR);
reader.add_listener(listener);
while (window.isOpen())
{
astra_update();
sf::Event event;
while (window.pollEvent(event))
{
switch (event.type)
{
case sf::Event::Closed:
window.close();
break;
case sf::Event::KeyPressed:
{
switch (event.key.code)
{
case sf::Keyboard::Escape:
window.close();
break;
case sf::Keyboard::F:
if (isFullScreen)
{
isFullScreen = false;
window.create(windowedMode, "Stream Viewer", sf::Style::Default);
}
else
{
isFullScreen = true;
window.create(fullScreenMode, "Stream Viewer", fullscreenStyle);
}
break;
case sf::Keyboard::R:
depthStream.enable_registration(!depthStream.registration_enabled());
break;
case sf::Keyboard::M:
{
const bool newMirroring = !depthStream.mirroring_enabled();
depthStream.enable_mirroring(newMirroring);
colorStream.enable_mirroring(newMirroring);
irStream.enable_mirroring(newMirroring);
}
break;
case sf::Keyboard::G:
colorStream.stop();
configure_ir(reader, false);
listener.set_mode(MODE_IR_16);
irStream.start();
break;
case sf::Keyboard::I:
colorStream.stop();
configure_ir(reader, true);
listener.set_mode(MODE_IR_RGB);
irStream.start();
break;
case sf::Keyboard::O:
listener.toggle_depth_overlay();
if (listener.get_overlay_depth())
{
depthStream.enable_registration(true);
}
break;
case sf::Keyboard::P:
listener.toggle_paused();
break;
case sf::Keyboard::C:
if (event.key.control)
{
window.close();
}
else
{
irStream.stop();
listener.set_mode(MODE_COLOR);
colorStream.start();
}
break;
default:
break;
}
break;
}
default:
break;
}
}
// clear the window with black color
window.clear(sf::Color::Black);
listener.draw_to(window, sf::Vector2f(0.f, 0.f), sf::Vector2f(window.getSize().x, window.getSize().y));
window.display();
if (!shouldContinue)
{
window.close();
}
}
astra::terminate();
return 0;
}


Astra SDK: astra_core.h File Reference

  • include
  • astra_core
  • capi
Classes | Functions
astra_core.h File Reference
The Third Group

this file in group 3 More...

#include "astra_defines.h"
#include "astra_types.h"
#include "astra_core_version.h"
#include <stdbool.h>

Go to the source code of this file.

Classes

class | C1
class C1 in group 1 More...
class | C2
class C2 in group 1 More...
class | C3
class C3 in group 2 More...
class | C4
class C4 in group 2 More...
class | C5
class C5 in the third group. More...

Functions

ASTRA_API astra_status_t | astra_initialize ()
Initializes the library. More...
ASTRA_API astra_status_t | astra_terminate ()
Terminate the library, destroying all its streams. More...
ASTRA_API astra_status_t | astra_notify_plugin_event (astra_event_id id, const void *data, uint32_t dataSize)
Notify plugins an event. More...
ASTRA_API astra_status_t | astra_streamset_is_available (astra_streamsetconnection_t streamSet, bool *isAvailable)
Test whether the StreamSet is valid. More...
ASTRA_API astra_status_t | astra_streamset_open (const char *uri, astra_streamsetconnection_t *streamSet)
Open a StreamSet. More...
ASTRA_API astra_status_t | astra_streamset_close (astra_streamsetconnection_t *streamSet)
Close the handle to StreamSet. More...
ASTRA_API astra_status_t | astra_streamset_get_uri (astra_streamsetconnection_t streamSet, char *uri, int32_t size)
Get the URI of StreamSet. More...
ASTRA_API astra_status_t | astra_reader_create (astra_streamsetconnection_t streamSet, astra_reader_t *reader)
Create a StreamReader in StreamSet. More...
ASTRA_API astra_status_t | astra_reader_destroy (astra_reader_t *reader)
Destroy the handle to StreamReader. More...
ASTRA_API astra_status_t | astra_reader_get_stream (astra_reader_t reader, astra_stream_type_t type, astra_stream_subtype_t subtype, astra_streamconnection_t *stream)
Get specified stream from StreamReader reader. More...
ASTRA_API astra_status_t | astra_stream_get_description (astra_streamconnection_t stream, astra_stream_desc_t *description)
Get description of Stream. More...
ASTRA_API astra_status_t | astra_stream_is_available (astra_streamconnection_t stream, bool *isAvailable)
Test whether the handle to Stream is valid. More...
ASTRA_API astra_status_t | astra_stream_start (astra_streamconnection_t stream)
Start the Stream. More...
ASTRA_API astra_status_t | astra_stream_stop (astra_streamconnection_t stream)
Stop the Stream. More...
ASTRA_API astra_status_t | astra_reader_has_new_frame (astra_reader_t reader, bool *hasNewFrame)
Test whether there is a new frame. More...
ASTRA_API astra_status_t | astra_reader_open_frame (astra_reader_t reader, int timeoutMillis, astra_reader_frame_t *frame)
Open. More...
ASTRA_API astra_status_t | astra_reader_close_frame (astra_reader_frame_t *frame)
Close. More...
ASTRA_API astra_status_t | astra_reader_register_frame_ready_callback (astra_reader_t reader, astra_frame_ready_callback_t callback, void *clientTag, astra_reader_callback_id_t *callbackId)
Registers a callback function to StreamReader. More...
ASTRA_API astra_status_t | astra_reader_unregister_frame_ready_callback (astra_reader_callback_id_t *callbackId)
Unregisters the callback function. More...
ASTRA_API astra_status_t | astra_reader_get_frame (astra_reader_frame_t frame, astra_stream_type_t type, astra_stream_subtype_t subtype, astra_frame_t **subFrame)
Read a frame. More...
ASTRA_API astra_status_t | astra_stream_set_parameter (astra_streamconnection_t connection, astra_parameter_id parameterId, uint32_t inByteLength, astra_parameter_data_t inData)
Set parameter to StreamSet. More...
ASTRA_API astra_status_t | astra_stream_get_parameter (astra_streamconnection_t connection, astra_parameter_id parameterId, uint32_t *resultByteLength, astra_result_token_t *token)
Get parameter from StreamSet. More...
ASTRA_API astra_status_t | astra_stream_get_result (astra_streamconnection_t connection, astra_result_token_t token, uint32_t dataByteLength, astra_parameter_data_t dataDestination)
ASTRA_API astra_status_t | astra_stream_invoke (astra_streamconnection_t connection, astra_command_id commandId, uint32_t inByteLength, astra_parameter_data_t inData, uint32_t *resultByteLength, astra_result_token_t *token)
ASTRA_API astra_status_t | astra_update ()
Drive the library to get a new frame of stream.
void | func ()
int | a ()
void | func2 ()
void | func3 ()

Detailed Description

this file in group 3


Astra SDK: Member List

  • Astra
  • AstraException
Astra.AstraException Member List

This is the complete list of members for Astra.AstraException, including all inherited members.

AstraException() (defined in Astra.AstraException) | Astra.AstraException | inline
AstraException(string message) (defined in Astra.AstraException) | Astra.AstraException | inline
AstraException(string message, Exception innerException) (defined in Astra.AstraException) | Astra.AstraException | inline
AstraException(SerializationInfo info, StreamingContext context) (defined in Astra.AstraException) | Astra.AstraException | inlineprotected


Astra SDK: Member List

  • Astra
  • Body
Astra.Body Member List

This is the complete list of members for Astra.Body, including all inherited members.

AreHandPosesEnabled | Astra.Body |
AreJointsEnabled | Astra.Body |
Body(byte id, BodyStatus status, BodyFeatures features, Vector3D centerOfMass, Joint[] joints, HandPoseInfo handPoseInfo) (defined in Astra.Body) | Astra.Body | inline
CenterOfMass (defined in Astra.Body) | Astra.Body |
HandPoseInfo (defined in Astra.Body) | Astra.Body |
Id (defined in Astra.Body) | Astra.Body |
Joints (defined in Astra.Body) | Astra.Body |
Status (defined in Astra.Body) | Astra.Body |
ToString() (defined in Astra.Body) | Astra.Body | inline


Astra SDK: Member List

  • Astra
  • BodyFrame
Astra.BodyFrame Member List

This is the complete list of members for Astra.BodyFrame, including all inherited members.

BodyCount (defined in Astra.BodyFrame) | Astra.BodyFrame |
BodyFrame(IntPtr handle) (defined in Astra.BodyFrame) | Astra.BodyFrame | inline
BodyFrame() (defined in Astra.BodyFrame) | Astra.BodyFrame | inline
BodyMask | Astra.BodyFrame |
CopyBodyData(ref Body[] bodies) (defined in Astra.BodyFrame) | Astra.BodyFrame | inline
DataFrame() (defined in Astra.DataFrame) | Astra.DataFrame | inlineprotected
DataFrame(IntPtr handle) (defined in Astra.DataFrame) | Astra.DataFrame | inlineprotected
FloorInfo | Astra.BodyFrame |
FrameIndex (defined in Astra.DataFrame) | Astra.DataFrame |
Handle (defined in Astra.DataFrame) | Astra.DataFrame | protected
Height | Astra.BodyFrame |
IsEstimated | Astra.BodyFrame |
MaxBodies (defined in Astra.BodyFrame) | Astra.BodyFrame |
StreamType (defined in Astra.BodyFrame) | Astra.BodyFrame |
Width | Astra.BodyFrame |


Astra SDK: Member List

  • Astra
  • BodyMask
Astra.BodyMask Member List

This is the complete list of members for Astra.BodyMask, including all inherited members.

BodyMask(IntPtr handle, int width, int height, IntPtr dataPtr) (defined in Astra.BodyMask) | Astra.BodyMask | inline
CopyData(ref byte[] data) (defined in Astra.BodyMask) | Astra.BodyMask | inlinevirtual
DataPtr (defined in Astra.BodyMask) | Astra.BodyMask |
Height (defined in Astra.BodyMask) | Astra.BodyMask |
Width (defined in Astra.BodyMask) | Astra.BodyMask |


Astra SDK: Member List

  • Astra
  • BodyStream
Astra.BodyStream Member List

This is the complete list of members for Astra.BodyStream, including all inherited members.

BodyStream(IntPtr handle) (defined in Astra.BodyStream) | Astra.BodyStream | inline
DataStream(IntPtr handle) (defined in Astra.DataStream) | Astra.DataStream | inlineprotected
Description (defined in Astra.DataStream) | Astra.DataStream |
GetBodyFeatures(byte bodyId) (defined in Astra.BodyStream) | Astra.BodyStream | inline
GetDefaultBodyFeatures() (defined in Astra.BodyStream) | Astra.BodyStream | inline
GetParameter< T >(int parameterId) (defined in Astra.DataStream) | Astra.DataStream | inline
GetSkeletonOptimization() (defined in Astra.BodyStream) | Astra.BodyStream | inline
GetSkeletonProfile() (defined in Astra.BodyStream) | Astra.BodyStream | inline
Handle (defined in Astra.DataStream) | Astra.DataStream | protected
IsAvailable (defined in Astra.DataStream) | Astra.DataStream |
SetBodyFeatures(byte bodyId, BodyTrackingFeatures features) (defined in Astra.BodyStream) | Astra.BodyStream | inline
SetDefaultBodyFeatures(BodyTrackingFeatures features) (defined in Astra.BodyStream) | Astra.BodyStream | inline
SetParameter< T >(int parameterId, T parameterValue) (defined in Astra.DataStream) | Astra.DataStream | inline
SetSkeletonOptimization(SkeletonOptimization skeletonOptimization) | Astra.BodyStream | inline
SetSkeletonProfile(SkeletonProfile skeletonProfile) | Astra.BodyStream | inline
Start() (defined in Astra.DataStream) | Astra.DataStream | inline
Stop() (defined in Astra.DataStream) | Astra.DataStream | inline


Astra SDK: Member List

  • Astra
  • BodyTracking
Astra.BodyTracking Member List

This is the complete list of members for Astra.BodyTracking, including all inherited members.

SetLicense(String licenseString) Astra.BodyTracking inlinestatic


Astra SDK: Member List

  • Astra
  • ColorFrame
Astra.ColorFrame Member List

This is the complete list of members for Astra.ColorFrame, including all inherited members.

ByteLength (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > |
CopyData(ref T[] data) (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > | inlinevirtual
DataPtr (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > |
Height (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > |
ImageFrame(IntPtr handle) (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > | inlineprotected
ImageFrame() (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > | inlineprotected
PixelFormat (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > |
StreamType (defined in Astra.ColorFrame) | Astra.ColorFrame |
Width (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > |


Astra SDK: Member List

  • Astra
  • ColorStream
Astra.ColorStream Member List

This is the complete list of members for Astra.ColorStream, including all inherited members.

AvailableModes (defined in Astra.ImageStream) | Astra.ImageStream |
DataStream(IntPtr handle) (defined in Astra.DataStream) | Astra.DataStream | inlineprotected
Description (defined in Astra.DataStream) | Astra.DataStream |
GetMode() (defined in Astra.ImageStream) | Astra.ImageStream | inline
GetParameter< T >(int parameterId) (defined in Astra.DataStream) | Astra.DataStream | inline
Handle (defined in Astra.DataStream) | Astra.DataStream | protected
HorizontalFieldOfView (defined in Astra.ImageStream) | Astra.ImageStream |
ImageStream(IntPtr handle) (defined in Astra.ImageStream) | Astra.ImageStream | inlineprotected
IsAvailable (defined in Astra.DataStream) | Astra.DataStream |
IsMirroring (defined in Astra.ImageStream) | Astra.ImageStream |
SetMode(ImageMode mode) (defined in Astra.ImageStream) | Astra.ImageStream | inline
SetParameter< T >(int parameterId, T parameterValue) (defined in Astra.DataStream) | Astra.DataStream | inline
Start() (defined in Astra.DataStream) | Astra.DataStream | inline
Stop() (defined in Astra.DataStream) | Astra.DataStream | inline
StreamType (defined in Astra.ColorStream) | Astra.ColorStream |
usbInfo (defined in Astra.ImageStream) | Astra.ImageStream |
VerticalFieldOfView (defined in Astra.ImageStream) | Astra.ImageStream |


Astra SDK: Member List

  • Astra
  • ColorizedBodyFrame
Astra.ColorizedBodyFrame Member List

This is the complete list of members for Astra.ColorizedBodyFrame, including all inherited members.

ByteLength (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > |
CopyData(ref T[] data) (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > | inlinevirtual
DataPtr (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > |
Height (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > |
ImageFrame(IntPtr handle) (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > | inlineprotected
ImageFrame() (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > | inlineprotected
PixelFormat (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > |
StreamType (defined in Astra.ColorizedBodyFrame) | Astra.ColorizedBodyFrame |
Width (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > |


Astra SDK: Member List

  • Astra
  • ColorizedBodyStream
Astra.ColorizedBodyStream Member List

This is the complete list of members for Astra.ColorizedBodyStream, including all inherited members.

AvailableModes (defined in Astra.ImageStream) | Astra.ImageStream |
DataStream(IntPtr handle) (defined in Astra.DataStream) | Astra.DataStream | inlineprotected
Description (defined in Astra.DataStream) | Astra.DataStream |
GetMode() (defined in Astra.ImageStream) | Astra.ImageStream | inline
GetParameter< T >(int parameterId) (defined in Astra.DataStream) | Astra.DataStream | inline
Handle (defined in Astra.DataStream) | Astra.DataStream | protected
HorizontalFieldOfView (defined in Astra.ImageStream) | Astra.ImageStream |
ImageStream(IntPtr handle) (defined in Astra.ImageStream) | Astra.ImageStream | inlineprotected
IsAvailable (defined in Astra.DataStream) | Astra.DataStream |
IsMirroring (defined in Astra.ImageStream) | Astra.ImageStream |
SetMode(ImageMode mode) (defined in Astra.ImageStream) | Astra.ImageStream | inline
SetParameter< T >(int parameterId, T parameterValue) (defined in Astra.DataStream) | Astra.DataStream | inline
Start() (defined in Astra.DataStream) | Astra.DataStream | inline
Stop() (defined in Astra.DataStream) | Astra.DataStream | inline
StreamType (defined in Astra.ColorizedBodyStream) | Astra.ColorizedBodyStream |
usbInfo (defined in Astra.ImageStream) | Astra.ImageStream |
VerticalFieldOfView (defined in Astra.ImageStream) | Astra.ImageStream |


Astra SDK: Member List

  • Astra
  • Context
Astra.Context Member List

This is the complete list of members for Astra.Context, including all inherited members.

Initialize() | Astra.Context | inlinestatic
Terminate() | Astra.Context | inlinestatic
Update() | Astra.Context | inlinestatic


Astra SDK: Member List

  • Astra
  • CoordinateMapper
Astra.CoordinateMapper Member List

This is the complete list of members for Astra.CoordinateMapper, including all inherited members.

CoordinateMapper(int resolutionX, int resolutionY, float hFov, float vFov) | Astra.CoordinateMapper | inline
MapDepthPointToWorldSpace(Vector3D depthPoint) | Astra.CoordinateMapper | inline
MapWorldPointToDepthSpace(Vector3D worldPoint) | Astra.CoordinateMapper | inline


Astra SDK: Member List

  • Astra
  • Core
  • GcHandleWrapper
Astra.Core.GcHandleWrapper Member List

This is the complete list of members for Astra.Core.GcHandleWrapper, including all inherited members.

AddrOfPinnedObject() (defined in Astra.Core.GcHandleWrapper) | Astra.Core.GcHandleWrapper | inline
Dispose() (defined in Astra.Core.GcHandleWrapper) | Astra.Core.GcHandleWrapper | inline
GcHandleWrapper(GCHandle handle) (defined in Astra.Core.GcHandleWrapper) | Astra.Core.GcHandleWrapper | inline
IsAllocated (defined in Astra.Core.GcHandleWrapper) | Astra.Core.GcHandleWrapper |
Target (defined in Astra.Core.GcHandleWrapper) | Astra.Core.GcHandleWrapper |


Astra SDK: Member List

  • Astra
  • DataFrame
Astra.DataFrame Member List

This is the complete list of members for Astra.DataFrame, including all inherited members.

DataFrame() (defined in Astra.DataFrame) | Astra.DataFrame | inlineprotected
DataFrame(IntPtr handle) (defined in Astra.DataFrame) | Astra.DataFrame | inlineprotected
FrameIndex (defined in Astra.DataFrame) | Astra.DataFrame |
Handle (defined in Astra.DataFrame) | Astra.DataFrame | protected
StreamType (defined in Astra.DataFrame) | Astra.DataFrame |


Astra SDK: Member List

  • Astra
  • DataStream
Astra.DataStream Member List

This is the complete list of members for Astra.DataStream, including all inherited members.

DataStream(IntPtr handle) (defined in Astra.DataStream) | Astra.DataStream | inlineprotected
Description (defined in Astra.DataStream) | Astra.DataStream |
GetParameter< T >(int parameterId) (defined in Astra.DataStream) | Astra.DataStream | inline
Handle (defined in Astra.DataStream) | Astra.DataStream | protected
IsAvailable (defined in Astra.DataStream) | Astra.DataStream |
SetParameter< T >(int parameterId, T parameterValue) (defined in Astra.DataStream) | Astra.DataStream | inline
Start() (defined in Astra.DataStream) | Astra.DataStream | inline
Stop() (defined in Astra.DataStream) | Astra.DataStream | inline


Astra SDK: Member List

  • Astra
  • DepthFrame
Astra.DepthFrame Member List

This is the complete list of members for Astra.DepthFrame, including all inherited members.

ByteLength (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > |
CopyData(ref T[] data) (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > | inlinevirtual
DataPtr (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > |
Height (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > |
ImageFrame(IntPtr handle) (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > | inlineprotected
ImageFrame() (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > | inlineprotected
PixelFormat (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > |
StreamType (defined in Astra.DepthFrame) | Astra.DepthFrame |
Width (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > |


Astra SDK: Member List

  • Astra
  • DepthStream
Astra.DepthStream Member List

This is the complete list of members for Astra.DepthStream, including all inherited members.

AvailableModes (defined in Astra.ImageStream) | Astra.ImageStream |
ChipId (defined in Astra.DepthStream) | Astra.DepthStream |
DataStream(IntPtr handle) (defined in Astra.DataStream) | Astra.DataStream | inlineprotected
Description (defined in Astra.DataStream) | Astra.DataStream |
GetMode() (defined in Astra.ImageStream) | Astra.ImageStream | inline
GetParameter< T >(int parameterId) (defined in Astra.DataStream) | Astra.DataStream | inline
Handle (defined in Astra.DataStream) | Astra.DataStream | protected
HorizontalFieldOfView (defined in Astra.ImageStream) | Astra.ImageStream |
ImageStream(IntPtr handle) (defined in Astra.ImageStream) | Astra.ImageStream | inlineprotected
IsAvailable (defined in Astra.DataStream) | Astra.DataStream |
IsMirroring (defined in Astra.ImageStream) | Astra.ImageStream |
SetMode(ImageMode mode) (defined in Astra.ImageStream) | Astra.ImageStream | inline
SetParameter< T >(int parameterId, T parameterValue) (defined in Astra.DataStream) | Astra.DataStream | inline
Start() (defined in Astra.DataStream) | Astra.DataStream | inline
Stop() (defined in Astra.DataStream) | Astra.DataStream | inline
StreamType (defined in Astra.DepthStream) | Astra.DepthStream |
usbInfo (defined in Astra.ImageStream) | Astra.ImageStream |
VerticalFieldOfView (defined in Astra.ImageStream) | Astra.ImageStream |


Astra SDK: Member List

  • Astra
  • Extensions
  • IntPtrExtensions
Astra.Extensions.IntPtrExtensions Member List

This is the complete list of members for Astra.Extensions.IntPtrExtensions, including all inherited members.

ThrowIfNull(this IntPtr ptr) (defined in Astra.Extensions.IntPtrExtensions) | Astra.Extensions.IntPtrExtensions | inlinestatic
ThrowIfNull(this IntPtr ptr, string message) (defined in Astra.Extensions.IntPtrExtensions) | Astra.Extensions.IntPtrExtensions | inlinestatic


Astra SDK: Member List

  • Astra
  • FloorInfo
Astra.FloorInfo Member List

This is the complete list of members for Astra.FloorInfo, including all inherited members.

FloorInfo(FloorMask floorMask, Plane floorPlane, bool isFloorDetected) (defined in Astra.FloorInfo) | Astra.FloorInfo | inline
FloorMask (defined in Astra.FloorInfo) | Astra.FloorInfo |
FloorPlane (defined in Astra.FloorInfo) | Astra.FloorInfo |
IsFloorDetected (defined in Astra.FloorInfo) | Astra.FloorInfo |
ToString() (defined in Astra.FloorInfo) | Astra.FloorInfo | inline


Astra SDK: Member List

  • Astra
  • FloorMask
Astra.FloorMask Member List

This is the complete list of members for Astra.FloorMask, including all inherited members.

CopyData(ref byte[] data) (defined in Astra.FloorMask) | Astra.FloorMask | inlinevirtual
DataPtr (defined in Astra.FloorMask) | Astra.FloorMask |
FloorMask(IntPtr handle, int width, int height, IntPtr dataPtr) (defined in Astra.FloorMask) | Astra.FloorMask | inline
Height (defined in Astra.FloorMask) | Astra.FloorMask |
Width (defined in Astra.FloorMask) | Astra.FloorMask |


Astra SDK: Member List

  • Astra
  • FrameReadyEventArgs
Astra.FrameReadyEventArgs Member List

This is the complete list of members for Astra.FrameReadyEventArgs, including all inherited members.

Frame (defined in Astra.FrameReadyEventArgs) | Astra.FrameReadyEventArgs |
FrameReadyEventArgs(ReaderFrame frame) (defined in Astra.FrameReadyEventArgs) | Astra.FrameReadyEventArgs | inline


Astra SDK: Member List

  • Astra
  • ImageFrame
Astra.ImageFrame< T > Member List

This is the complete list of members for Astra.ImageFrame< T >, including all inherited members.

ByteLength (defined in Astra.ImageFrame< T >) | Astra.ImageFrame< T > |
CopyData(ref T[] data) (defined in Astra.ImageFrame< T >) | Astra.ImageFrame< T > | inlinevirtual
DataFrame() (defined in Astra.DataFrame) | Astra.DataFrame | inlineprotected
DataFrame(IntPtr handle) (defined in Astra.DataFrame) | Astra.DataFrame | inlineprotected
DataPtr (defined in Astra.ImageFrame< T >) | Astra.ImageFrame< T > |
FrameIndex (defined in Astra.DataFrame) | Astra.DataFrame |
Handle (defined in Astra.DataFrame) | Astra.DataFrame | protected
Height (defined in Astra.ImageFrame< T >) | Astra.ImageFrame< T > |
ImageFrame(IntPtr handle) (defined in Astra.ImageFrame< T >) | Astra.ImageFrame< T > | inlineprotected
ImageFrame() (defined in Astra.ImageFrame< T >) | Astra.ImageFrame< T > | inlineprotected
PixelFormat (defined in Astra.ImageFrame< T >) | Astra.ImageFrame< T > |
StreamType (defined in Astra.DataFrame) | Astra.DataFrame |
Width (defined in Astra.ImageFrame< T >) | Astra.ImageFrame< T > |


Astra SDK: Member List

  • Astra
  • ImageMode
Astra.ImageMode Member List

This is the complete list of members for Astra.ImageMode, including all inherited members.

FramesPerSecond (defined in Astra.ImageMode) | Astra.ImageMode |
Height (defined in Astra.ImageMode) | Astra.ImageMode |
Id (defined in Astra.ImageMode) | Astra.ImageMode |
PixelFormat (defined in Astra.ImageMode) | Astra.ImageMode |
ToString() (defined in Astra.ImageMode) | Astra.ImageMode | inline
Width (defined in Astra.ImageMode) | Astra.ImageMode |


Astra SDK: Member List

  • Astra
  • ImageStream
Astra.ImageStream Member List

This is the complete list of members for Astra.ImageStream, including all inherited members.

AvailableModes (defined in Astra.ImageStream) | Astra.ImageStream |
DataStream(IntPtr handle) (defined in Astra.DataStream) | Astra.DataStream | inlineprotected
Description (defined in Astra.DataStream) | Astra.DataStream |
GetMode() (defined in Astra.ImageStream) | Astra.ImageStream | inline
GetParameter< T >(int parameterId) (defined in Astra.DataStream) | Astra.DataStream | inline
Handle (defined in Astra.DataStream) | Astra.DataStream | protected
HorizontalFieldOfView (defined in Astra.ImageStream) | Astra.ImageStream |
ImageStream(IntPtr handle) (defined in Astra.ImageStream) | Astra.ImageStream | inlineprotected
IsAvailable (defined in Astra.DataStream) | Astra.DataStream |
IsMirroring (defined in Astra.ImageStream) | Astra.ImageStream |
SetMode(ImageMode mode) (defined in Astra.ImageStream) | Astra.ImageStream | inline
SetParameter< T >(int parameterId, T parameterValue) (defined in Astra.DataStream) | Astra.DataStream | inline
Start() (defined in Astra.DataStream) | Astra.DataStream | inline
Stop() (defined in Astra.DataStream) | Astra.DataStream | inline
usbInfo (defined in Astra.ImageStream) | Astra.ImageStream |
VerticalFieldOfView (defined in Astra.ImageStream) | Astra.ImageStream |


Astra SDK: Member List

  • Astra
  • InfraredFrame
Astra.InfraredFrame Member List

This is the complete list of members for Astra.InfraredFrame, including all inherited members.

ByteLength (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > |
CopyData(ref T[] data) (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > | inlinevirtual
DataPtr (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > |
Height (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > |
ImageFrame(IntPtr handle) (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > | inlineprotected
ImageFrame() (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > | inlineprotected
PixelFormat (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > |
StreamType (defined in Astra.InfraredFrame) | Astra.InfraredFrame |
Width (defined in Astra.ImageFrame< short >) | Astra.ImageFrame< short > |


Astra SDK: Member List

  • Astra
  • InfraredStream
Astra.InfraredStream Member List

This is the complete list of members for Astra.InfraredStream, including all inherited members.

AvailableModes (defined in Astra.ImageStream) | Astra.ImageStream |
DataStream(IntPtr handle) (defined in Astra.DataStream) | Astra.DataStream | inlineprotected
Description (defined in Astra.DataStream) | Astra.DataStream |
GetMode() (defined in Astra.ImageStream) | Astra.ImageStream | inline
GetParameter< T >(int parameterId) (defined in Astra.DataStream) | Astra.DataStream | inline
Handle (defined in Astra.DataStream) | Astra.DataStream | protected
HorizontalFieldOfView (defined in Astra.ImageStream) | Astra.ImageStream |
ImageStream(IntPtr handle) (defined in Astra.ImageStream) | Astra.ImageStream | inlineprotected
IsAvailable (defined in Astra.DataStream) | Astra.DataStream |
IsMirroring (defined in Astra.ImageStream) | Astra.ImageStream |
SetMode(ImageMode mode) (defined in Astra.ImageStream) | Astra.ImageStream | inline
SetParameter< T >(int parameterId, T parameterValue) (defined in Astra.DataStream) | Astra.DataStream | inline
Start() (defined in Astra.DataStream) | Astra.DataStream | inline
Stop() (defined in Astra.DataStream) | Astra.DataStream | inline
StreamType (defined in Astra.InfraredStream) | Astra.InfraredStream |
usbInfo (defined in Astra.ImageStream) | Astra.ImageStream |
VerticalFieldOfView (defined in Astra.ImageStream) | Astra.ImageStream |


Astra SDK: Member List

  • Astra
  • Joint
Astra.Joint Member List

This is the complete list of members for Astra.Joint, including all inherited members.

DepthPosition (defined in Astra.Joint) | Astra.Joint |
Joint(JointType type, JointStatus status, Vector2D depthPosition, Vector3D worldPosition, Matrix3x3 orientation) (defined in Astra.Joint) | Astra.Joint | inline
Orientation (defined in Astra.Joint) | Astra.Joint |
Status (defined in Astra.Joint) | Astra.Joint |
ToString() (defined in Astra.Joint) | Astra.Joint | inline
Type (defined in Astra.Joint) | Astra.Joint |
WorldPosition (defined in Astra.Joint) | Astra.Joint |


Astra SDK: Member List

  • Astra
  • MaskedColorFrame
Astra.MaskedColorFrame Member List

This is the complete list of members for Astra.MaskedColorFrame, including all inherited members.

ByteLength (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > |
CopyData(ref T[] data) (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > | inlinevirtual
DataPtr (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > |
Height (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > |
ImageFrame(IntPtr handle) (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > | inlineprotected
ImageFrame() (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > | inlineprotected
PixelFormat (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > |
StreamType (defined in Astra.MaskedColorFrame) | Astra.MaskedColorFrame |
Width (defined in Astra.ImageFrame< byte >) | Astra.ImageFrame< byte > |


Astra SDK: Member List

  • Astra
  • MaskedColorStream
Astra.MaskedColorStream Member List

This is the complete list of members for Astra.MaskedColorStream, including all inherited members.

AvailableModes (defined in Astra.ImageStream) | Astra.ImageStream |
DataStream(IntPtr handle) (defined in Astra.DataStream) | Astra.DataStream | inlineprotected
Description (defined in Astra.DataStream) | Astra.DataStream |
GetMode() (defined in Astra.ImageStream) | Astra.ImageStream | inline
GetParameter< T >(int parameterId) (defined in Astra.DataStream) | Astra.DataStream | inline
Handle (defined in Astra.DataStream) | Astra.DataStream | protected
HorizontalFieldOfView (defined in Astra.ImageStream) | Astra.ImageStream |
ImageStream(IntPtr handle) (defined in Astra.ImageStream) | Astra.ImageStream | inlineprotected
IsAvailable (defined in Astra.DataStream) | Astra.DataStream |
IsMirroring (defined in Astra.ImageStream) | Astra.ImageStream |
SetMode(ImageMode mode) (defined in Astra.ImageStream) | Astra.ImageStream | inline
SetParameter< T >(int parameterId, T parameterValue) (defined in Astra.DataStream) | Astra.DataStream | inline
Start() (defined in Astra.DataStream) | Astra.DataStream | inline
Stop() (defined in Astra.DataStream) | Astra.DataStream | inline
StreamType (defined in Astra.MaskedColorStream) | Astra.MaskedColorStream |
usbInfo (defined in Astra.ImageStream) | Astra.ImageStream |
VerticalFieldOfView (defined in Astra.ImageStream) | Astra.ImageStream |


Astra SDK: Member List

  • Astra
  • Plane
Astra.Plane Member List

This is the complete list of members for Astra.Plane, including all inherited members.

A (defined in Astra.Plane) | Astra.Plane |
B (defined in Astra.Plane) | Astra.Plane |
C (defined in Astra.Plane) | Astra.Plane |
D (defined in Astra.Plane) | Astra.Plane |
Plane(float a, float b, float c, float d) (defined in Astra.Plane) | Astra.Plane | inline
ToString() (defined in Astra.Plane) | Astra.Plane | inline


Astra SDK: Member List

  • Astra
  • PointFrame
Astra.PointFrame Member List

This is the complete list of members for Astra.PointFrame, including all inherited members.

ByteLength (defined in Astra.ImageFrame< Vector3D >) | Astra.ImageFrame< Vector3D > |
CopyData(ref Vector3D[] data) (defined in Astra.PointFrame) | Astra.PointFrame | inline
CopyData(ref T[] data) (defined in Astra.ImageFrame< Vector3D >) | Astra.ImageFrame< Vector3D > | inlinevirtual
DataPtr (defined in Astra.ImageFrame< Vector3D >) | Astra.ImageFrame< Vector3D > |
Height (defined in Astra.ImageFrame< Vector3D >) | Astra.ImageFrame< Vector3D > |
ImageFrame(IntPtr handle) (defined in Astra.ImageFrame< Vector3D >) | Astra.ImageFrame< Vector3D > | inlineprotected
ImageFrame() (defined in Astra.ImageFrame< Vector3D >) | Astra.ImageFrame< Vector3D > | inlineprotected
PixelFormat (defined in Astra.ImageFrame< Vector3D >) | Astra.ImageFrame< Vector3D > |
StreamType (defined in Astra.PointFrame) | Astra.PointFrame |
Width (defined in Astra.ImageFrame< Vector3D >) | Astra.ImageFrame< Vector3D > |


Astra SDK: Member List

  • Astra
  • PointStream
Astra.PointStream Member List

This is the complete list of members for Astra.PointStream, including all inherited members.

DataStream(IntPtr handle) (defined in Astra.DataStream) | Astra.DataStream | inlineprotected
Description (defined in Astra.DataStream) | Astra.DataStream |
GetParameter< T >(int parameterId) (defined in Astra.DataStream) | Astra.DataStream | inline
Handle (defined in Astra.DataStream) | Astra.DataStream | protected
IsAvailable (defined in Astra.DataStream) | Astra.DataStream |
PointStream(IntPtr handle) (defined in Astra.PointStream) | Astra.PointStream | inline
SetParameter< T >(int parameterId, T parameterValue) (defined in Astra.DataStream) | Astra.DataStream | inline
Start() (defined in Astra.DataStream) | Astra.DataStream | inline
Stop() (defined in Astra.DataStream) | Astra.DataStream | inline
StreamType (defined in Astra.PointStream) | Astra.PointStream |


Astra SDK: Member List

  • Astra
  • ReaderFrame
Astra.ReaderFrame Member List

This is the complete list of members for Astra.ReaderFrame, including all inherited members.

Dispose() (defined in Astra.ReaderFrame) | Astra.ReaderFrame | inline
GetFrame< TFrame >() | Astra.ReaderFrame | inline
GetFrame< TFrame >(StreamSubType subType) | Astra.ReaderFrame | inline


Astra SDK: Member List

  • Astra
  • StreamDescription
Astra.StreamDescription Member List

This is the complete list of members for Astra.StreamDescription, including all inherited members.

StreamDescription(int type, int subType) (defined in Astra.StreamDescription) | Astra.StreamDescription | inline
SubType (defined in Astra.StreamDescription) | Astra.StreamDescription |
Type (defined in Astra.StreamDescription) | Astra.StreamDescription |


Astra SDK: Member List

  • Astra
  • StreamReader
Astra.StreamReader Member List

This is the complete list of members for Astra.StreamReader, including all inherited members.

Dispose() (defined in Astra.StreamReader) | Astra.StreamReader | inline
FrameReady (defined in Astra.StreamReader) | Astra.StreamReader |
GetStream< TStream >() | Astra.StreamReader | inline
GetStream< TStream >(StreamSubType subType) | Astra.StreamReader | inline
HasNewFrame() (defined in Astra.StreamReader) | Astra.StreamReader | inline
RaiseFrameReady(ReaderFrame frame) (defined in Astra.StreamReader) | Astra.StreamReader | inlineprotectedvirtual
TryOpenFrame(int timeoutMillis, out ReaderFrame frame) | Astra.StreamReader | inline


Astra SDK: Member List

  • Astra
  • StreamSet
Astra.StreamSet Member List

This is the complete list of members for Astra.StreamSet, including all inherited members.

CreateReader() | Astra.StreamSet | inline
Dispose() | Astra.StreamSet | inline
IsAvailable (defined in Astra.StreamSet) | Astra.StreamSet |
Open(string connectionString) | Astra.StreamSet | inlinestatic
Open() | Astra.StreamSet | inlinestatic
Uri (defined in Astra.StreamSet) | Astra.StreamSet |


Astra SDK: Member List

  • Astra
  • StreamTypeRegistry
Astra.StreamTypeRegistry Member List

This is the complete list of members for Astra.StreamTypeRegistry, including all inherited members.

Instance (defined in Astra.StreamTypeRegistry) | Astra.StreamTypeRegistry | static
Register< TStream >(int type, Func< IntPtr, DataStream > streamCreate) (defined in Astra.StreamTypeRegistry) | Astra.StreamTypeRegistry | inline


Astra SDK: Member List

  • Astra
  • USBInfo
Astra.USBInfo Member List

This is the complete list of members for Astra.USBInfo, including all inherited members.

Pid (defined in Astra.USBInfo) | Astra.USBInfo |
USBInfo(int pid, int vid) (defined in Astra.USBInfo) | Astra.USBInfo | inline
Vid (defined in Astra.USBInfo) | Astra.USBInfo |


Astra SDK: C1 Class Reference

C1 Class Reference
The First Group

class C1 in group 1 More...

#include <astra_core.h>

Detailed Description

class C1 in group 1

The documentation for this class was generated from the following file:
  • astra_core.h


Astra SDK: C2 Class Reference

C2 Class Reference
The First Group

class C2 in group 1 More...

#include <astra_core.h>

Detailed Description

class C2 in group 1

The documentation for this class was generated from the following file:
  • astra_core.h


Astra SDK: C3 Class Reference

C3 Class Reference
The Second Group

class C3 in group 2 More...

#include <astra_core.h>

Detailed Description

class C3 in group 2

The documentation for this class was generated from the following file:
  • astra_core.h


Astra SDK: C4 Class Reference

C4 Class Reference
The Second Group

class C4 in group 2 More...

#include <astra_core.h>

Detailed Description

class C4 in group 2

The documentation for this class was generated from the following file:
  • astra_core.h


Astra SDK: C5 Class Reference

C5 Class Reference
The Third Group

class C5 in the third group. More...

#include <astra_core.h>

Detailed Description

class C5 in the third group.

The documentation for this class was generated from the following file:
  • astra_core.h


Astra SDK: Member List

  • astra
  • Array
astra::Array< T > Member List

This is the complete list of members for astra::Array< T >, including all inherited members.

Array() | astra::Array< T > | inline
Array(decltype(nullptr)) | astra::Array< T > | inline
Array(T *ptr, size_t size) | astra::Array< T > | inline
Array(T *begin, T *end) | astra::Array< T > | inline
back() | astra::Array< T > | inline
back() const | astra::Array< T > | inline
begin() | astra::Array< T > | inline
begin() const | astra::Array< T > | inline
data() | astra::Array< T > | inline
data() const | astra::Array< T > | inline
empty() const | astra::Array< T > | inline
end() | astra::Array< T > | inline
end() const | astra::Array< T > | inline
front() | astra::Array< T > | inline
front() const | astra::Array< T > | inline
operator!=(const Array &other) const | astra::Array< T > | inline
operator==(const Array &other) const | astra::Array< T > | inline
operator[](size_t index) | astra::Array< T > | inline
operator[](size_t index) const | astra::Array< T > | inline
size() const | astra::Array< T > | inline
slice(size_t start, size_t end) | astra::Array< T > | inline
slice(size_t start, size_t end) const | astra::Array< T > | inline


Astra SDK: Member List

  • astra
  • BitmapMask
astra::BitmapMask Member List

This is the complete list of members for astra::BitmapMask, including all inherited members.

BitmapMask() | astra::BitmapMask | inline
BodyFrame (defined in astra::BitmapMask) | astra::BitmapMask | friend
bpp() const | astra::BitmapMask | inline
byte_length() const | astra::BitmapMask | inline
data() const | astra::BitmapMask | inline
_astra_bitmapmask::data | _astra_bitmapmask | private
FloorInfo (defined in astra::BitmapMask) | astra::BitmapMask | friend
height() const | astra::BitmapMask | inline
_astra_bitmapmask::height | _astra_bitmapmask | private
length() const | astra::BitmapMask | inline
width() const | astra::BitmapMask | inline
_astra_bitmapmask::width | _astra_bitmapmask | private


Astra SDK: Member List

  • astra
  • Body
astra::Body Member List

This is the complete list of members for astra::Body, including all inherited members.

BodyFrame (defined in astra::Body) | astra::Body | friend
center_of_mass() const | astra::Body | inline
centerOfMass | _astra_body | private
features | _astra_body | private
hand_poses() const (defined in astra::Body) | astra::Body | inline
hand_poses_enabled() const (defined in astra::Body) | astra::Body | inline
handPoses | _astra_body | private
id() const | astra::Body | inline
_astra_body::id | _astra_body | private
joints() const | astra::Body | inline
_astra_body::joints | _astra_body | private
joints_enabled() const (defined in astra::Body) | astra::Body | inline
status() const | astra::Body | inline
_astra_body::status | _astra_body | private


Astra SDK: Member List

  • astra
  • BodyFrame
astra::BodyFrame Member List

This is the complete list of members for astra::BodyFrame, including all inherited members.

acquire(astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype) (defined in astra::BodyFrame) | astra::BodyFrame | inlinestatic
bodies() const | astra::BodyFrame | inline
body_mask() const | astra::BodyFrame | inline
BodyFrame(const BodyFrame &)=delete | astra::BodyFrame |
BodyFrame(BodyFrame &&other) | astra::BodyFrame | inline
floor_info() const (defined in astra::BodyFrame) | astra::BodyFrame | inline
frame_index() const | astra::BodyFrame | inline
info() const | astra::BodyFrame | inline
is_valid() const | astra::BodyFrame | inline
operator=(const BodyFrame &)=delete | astra::BodyFrame |
operator=(BodyFrame &&other) | astra::BodyFrame | inline


Astra SDK: Member List

  • astra
  • BodyFrameInfo
astra::BodyFrameInfo Member List

This is the complete list of members for astra::BodyFrameInfo, including all inherited members.

BodyFrame (defined in astra::BodyFrameInfo) | astra::BodyFrameInfo | friend
height() const (defined in astra::BodyFrameInfo) | astra::BodyFrameInfo | inline
_astra_bodyframe_info::height | _astra_bodyframe_info | private
is_estimated() const (defined in astra::BodyFrameInfo) | astra::BodyFrameInfo | inline
isEstimated | _astra_bodyframe_info | private
width() const (defined in astra::BodyFrameInfo) | astra::BodyFrameInfo | inline
_astra_bodyframe_info::width | _astra_bodyframe_info | private


Astra SDK: Member List

  • astra
  • BodyStream
astra::BodyStream Member List

This is the complete list of members for astra::BodyStream, including all inherited members.

BodyStream(astra_streamconnection_t connection) | astra::BodyStream | inlineexplicit
DataStream() (defined in astra::DataStream) | astra::DataStream | inline
DataStream(astra_streamconnection_t connection) | astra::DataStream | inline
get_body_features(astra_body_id_t id) | astra::BodyStream | inline
get_default_body_features() | astra::BodyStream | inline
get_skeleton_optimization() | astra::BodyStream | inline
get_skeleton_profile() | astra::BodyStream | inline
id (defined in astra::BodyStream) | astra::BodyStream | static
is_available() | astra::DataStream | inline
set_body_features(astra_body_id_t id, BodyTrackingFeatureFlags features) | astra::BodyStream | inline
set_default_body_features(BodyTrackingFeatureFlags features) | astra::BodyStream | inline
set_skeleton_optimization(SkeletonOptimization skeletonOptimization) | astra::BodyStream | inline
set_skeleton_profile(SkeletonProfile skeletonProfile) | astra::BodyStream | inline
start() | astra::DataStream | inline
stop() | astra::DataStream | inline


Astra SDK: Member List

  • astra
  • ColorFrame
astra::ColorFrame Member List

This is the complete list of members for astra::ColorFrame, including all inherited members.

acquire(astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype) | astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR > | inlinestatic
byte_length() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR > | inline
bytes_per_pixel() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR > | inline
ColorFrame(astra_imageframe_t frame) (defined in astra::ColorFrame) | astra::ColorFrame | inline
copy_to(RgbPixel *buffer) const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR > | inline
data() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR > | inline
frame_index() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR > | inline
handle() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR > | inline
height() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR > | inline
ImageFrame(astra_imageframe_t frame, astra_pixel_format_t expected_format) | astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR > | inline
is_valid() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR > | inline
length() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR > | inline
stream_type() | astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR > | inlinestatic
width() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_COLOR > | inline


Astra SDK: Member List

  • astra
  • ColorStream
astra::ColorStream Member List

This is the complete list of members for astra::ColorStream, including all inherited members.

available_modes() const | astra::ImageStream | inline
ColorStream(astra_streamconnection_t connection) (defined in astra::ColorStream) | astra::ColorStream | inlineexplicit
DataStream() (defined in astra::DataStream) | astra::DataStream | inline
DataStream(astra_streamconnection_t connection) | astra::DataStream | inline
enable_mirroring(bool mirroring) | astra::ImageStream | inline
hFov() const | astra::ImageStream | inline
id (defined in astra::ColorStream) | astra::ColorStream | static
ImageStream(astra_streamconnection_t connection) (defined in astra::ImageStream) | astra::ImageStream | inlineexplicit
is_available() | astra::DataStream | inline
mirroring_enabled() const | astra::ImageStream | inline
mode() const | astra::ImageStream | inline
set_mode(const ImageStreamMode &mode) | astra::ImageStream | inline
start() | astra::DataStream | inline
stop() | astra::DataStream | inline
usb_info() const | astra::ImageStream | inline
vFov() const | astra::ImageStream | inline


Astra SDK: Member List

  • astra
  • ColorizedBodyFrame
astra::ColorizedBodyFrame Member List

This is the complete list of members for astra::ColorizedBodyFrame, including all inherited members.

acquire(astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype) | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY > | inlinestatic
byte_length() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY > | inline
bytes_per_pixel() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY > | inline
ColorizedBodyFrame(astra_imageframe_t frame) (defined in astra::ColorizedBodyFrame) | astra::ColorizedBodyFrame | inline
copy_to(RgbaPixel *buffer) const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY > | inline
data() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY > | inline
frame_index() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY > | inline
handle() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY > | inline
height() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY > | inline
ImageFrame(astra_imageframe_t frame, astra_pixel_format_t expected_format) | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY > | inline
is_valid() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY > | inline
length() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY > | inline
stream_type() | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY > | inlinestatic
width() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_COLORIZED_BODY > | inline


Astra SDK: Member List

  • astra
  • ColorizedBodyStream
astra::ColorizedBodyStream Member List

This is the complete list of members for astra::ColorizedBodyStream, including all inherited members.

ColorizedBodyStream() (defined in astra::ColorizedBodyStream) | astra::ColorizedBodyStream | inline
ColorizedBodyStream(astra_streamconnection_t connection) (defined in astra::ColorizedBodyStream) | astra::ColorizedBodyStream | inlineexplicit
DataStream() (defined in astra::DataStream) | astra::DataStream | inline
DataStream(astra_streamconnection_t connection) | astra::DataStream | inline
id (defined in astra::ColorizedBodyStream) | astra::ColorizedBodyStream | static
is_available() | astra::DataStream | inline
start() | astra::DataStream | inline
stop() | astra::DataStream | inline


Astra SDK: Member List

  • astra
  • CoordinateMapper
astra::CoordinateMapper Member List

This is the complete list of members for astra::CoordinateMapper, including all inherited members.

convert_depth_to_world(astra::Vector3f depthPosition) const | astra::CoordinateMapper | inline
convert_depth_to_world(float depthX, float depthY, float depthZ, float &worldX, float &worldY, float &worldZ) const | astra::CoordinateMapper | inline
convert_world_to_depth(Vector3f worldPosition) const | astra::CoordinateMapper | inline
convert_world_to_depth(float worldX, float worldY, float worldZ, float &depthX, float &depthY, float &depthZ) const | astra::CoordinateMapper | inline
CoordinateMapper(astra_depthstream_t depthStream) | astra::CoordinateMapper | inline
CoordinateMapper(const CoordinateMapper &rhs) | astra::CoordinateMapper | inline
operator=(const CoordinateMapper &rhs) | astra::CoordinateMapper | inline


Astra SDK: Member List

  • astra
  • DataStream
astra::DataStream Member List

This is the complete list of members for astra::DataStream, including all inherited members.

DataStream() (defined in astra::DataStream) | astra::DataStream | inline
DataStream(astra_streamconnection_t connection) | astra::DataStream | inline
is_available() | astra::DataStream | inline
start() | astra::DataStream | inline
stop() | astra::DataStream | inline


Astra SDK: Member List

  • astra
  • DebugHandFrame
astra::DebugHandFrame Member List

This is the complete list of members for astra::DebugHandFrame, including all inherited members.

acquire(astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype) | astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND > | inlinestatic
byte_length() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND > | inline
bytes_per_pixel() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND > | inline
copy_to(RgbPixel *buffer) const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND > | inline
data() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND > | inline
DebugHandFrame(astra_imageframe_t frame) | astra::DebugHandFrame | inline
frame_index() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND > | inline
handle() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND > | inline
height() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND > | inline
ImageFrame(astra_imageframe_t frame, astra_pixel_format_t expected_format) | astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND > | inline
is_valid() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND > | inline
length() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND > | inline
stream_type() | astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND > | inlinestatic
width() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_DEBUG_HAND > | inline


Astra SDK: Member List

  • astra
  • DebugHandStream
astra::DebugHandStream Member List

This is the complete list of members for astra::DebugHandStream, including all inherited members.

DataStream() (defined in astra::DataStream) | astra::DataStream | inline
DataStream(astra_streamconnection_t connection) | astra::DataStream | inline
DebugHandStream(astra_streamconnection_t connection) | astra::DebugHandStream | inlineexplicit
get_view_type() const | astra::DebugHandStream | inline
id (defined in astra::DebugHandStream) | astra::DebugHandStream | static
is_available() | astra::DataStream | inline
set_lock_spawn_point(bool lockSpawnPoint) | astra::DebugHandStream | inline
set_mouse_position(Vector2f position) | astra::DebugHandStream | inline
set_pause_input(bool pauseInput) | astra::DebugHandStream | inline
set_use_mouse_probe(bool useMouseProbe) | astra::DebugHandStream | inline
set_view_type(DebugHandViewType view) | astra::DebugHandStream | inline
start() | astra::DataStream | inline
stop() | astra::DataStream | inline


Astra SDK: Member List

  • astra
  • DepthFrame
astra::DepthFrame Member List

This is the complete list of members for astra::DepthFrame, including all inherited members.

acquire(astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype) | astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH > | inlinestatic
byte_length() const | astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH > | inline
bytes_per_pixel() const | astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH > | inline
copy_to(int16_t *buffer) const | astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH > | inline
data() const | astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH > | inline
DepthFrame(astra_imageframe_t frame) (defined in astra::DepthFrame) | astra::DepthFrame | inline
frame_index() const | astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH > | inline
handle() const | astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH > | inline
height() const | astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH > | inline
ImageFrame(astra_imageframe_t frame, astra_pixel_format_t expected_format) | astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH > | inline
is_valid() const | astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH > | inline
length() const | astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH > | inline
stream_type() | astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH > | inlinestatic
width() const | astra::ImageFrame< int16_t, ASTRA_STREAM_DEPTH > | inline


Astra SDK: Member List

  • astra
  • DepthStream
astra::DepthStream Member List

This is the complete list of members for astra::DepthStream, including all inherited members.

available_modes() const | astra::ImageStream | inline
chip_id() const | astra::DepthStream | inline
coordinateMapper() const | astra::DepthStream | inline
DataStream() (defined in astra::DataStream) | astra::DataStream | inline
DataStream(astra_streamconnection_t connection) | astra::DataStream | inline
depth_to_world_data() const | astra::DepthStream | inline
DepthStream(astra_streamconnection_t connection) (defined in astra::DepthStream) | astra::DepthStream | inlineexplicit
enable_mirroring(bool mirroring) | astra::ImageStream | inline
enable_registration(bool enable) | astra::DepthStream | inline
hFov() const | astra::ImageStream | inline
id (defined in astra::DepthStream) | astra::DepthStream | static
ImageStream(astra_streamconnection_t connection) (defined in astra::ImageStream) | astra::ImageStream | inlineexplicit
is_available() | astra::DataStream | inline
mirroring_enabled() const | astra::ImageStream | inline
mode() const | astra::ImageStream | inline
registration_enabled() const | astra::DepthStream | inline
serial_number(char *serialnumber, uint32_t length) const | astra::DepthStream | inline
serial_number() const | astra::DepthStream | inline
set_mode(const ImageStreamMode &mode) | astra::ImageStream | inline
start() | astra::DataStream | inline
stop() | astra::DataStream | inline
usb_info() const | astra::ImageStream | inline
vFov() const | astra::ImageStream | inline


Astra SDK: Member List

  • astra
  • FloorInfo
astra::FloorInfo Member List

This is the complete list of members for astra::FloorInfo, including all inherited members.

BodyFrame (defined in astra::FloorInfo) | astra::FloorInfo | friend
floor_detected() const (defined in astra::FloorInfo) | astra::FloorInfo | inline
floor_mask() const (defined in astra::FloorInfo) | astra::FloorInfo | inline
floor_plane() const (defined in astra::FloorInfo) | astra::FloorInfo | inline
floorDetected | _astra_floor_info | private
floorMask | _astra_floor_info | private
floorPlane | _astra_floor_info | private


Astra SDK: Member List

  • astra
  • Frame
astra::Frame Member List

This is the complete list of members for astra::Frame, including all inherited members.

Frame(astra_reader_frame_t readerFrame, const bool autoCloseFrame) | astra::Frame | inline
Frame(astra_reader_frame_t readerFrame) | astra::Frame | inline
get() | astra::Frame | inline
get(astra_stream_subtype_t subtype) | astra::Frame | inline
is_valid() | astra::Frame | inline
operator bool() | astra::Frame | inline


Astra SDK: Member List

  • astra
  • FrameListener
astra::FrameListener Member List

This is the complete list of members for astra::FrameListener, including all inherited members.

on_frame_ready(StreamReader &reader, Frame &frame)=0 (defined in astra::FrameListener) | astra::FrameListener | pure virtual
~FrameListener()=default (defined in astra::FrameListener) | astra::FrameListener | virtual


Astra SDK: Member List

  • astra
  • HandFrame
astra::HandFrame Member List

This is the complete list of members for astra::HandFrame, including all inherited members.

acquire(astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype) | astra::HandFrame | inlinestatic
frame_index() const | astra::HandFrame | inline
HandFrame(astra_handframe_t handFrame) | astra::HandFrame | inline
handle() const | astra::HandFrame | inline
handpoint_count() const | astra::HandFrame | inline
HandPointList typedef (defined in astra::HandFrame) | astra::HandFrame |
handpoints() const | astra::HandFrame | inline
is_valid() const | astra::HandFrame | inline


Astra SDK: Member List

  • astra
  • HandPoint
astra::HandPoint Member List

This is the complete list of members for astra::HandPoint, including all inherited members.

depth_position() const | astra::HandPoint | inline
depthPosition (defined in astra_handpoint_t) | astra_handpoint_t |
HandPoint(std::int32_t trackingId, astra_handstatus_t status, Vector2i depthPosition, Vector3f worldPosition, Vector3f worldDeltaPosition) | astra::HandPoint | inline
HandPoint(const astra_handpoint_t &handPoint) | astra::HandPoint | inline
operator const ::astra_handpoint_t *() const | astra::HandPoint | inline
operator::astra_handpoint_t *() | astra::HandPoint | inline
operator=(const ::astra_handpoint_t &handPoint) | astra::HandPoint | inline
status() const | astra::HandPoint | inline
status (defined in astra_handpoint_t) | astra_handpoint_t |
tracking_id() const | astra::HandPoint | inline
trackingId (defined in astra_handpoint_t) | astra_handpoint_t |
world_delta_position() const | astra::HandPoint | inline
world_position() const | astra::HandPoint | inline
worldDeltaPosition (defined in astra_handpoint_t) | astra_handpoint_t |
worldPosition (defined in astra_handpoint_t) | astra_handpoint_t |


Astra SDK: Member List

  • astra
  • HandPoseInfo
astra::HandPoseInfo Member List

This is the complete list of members for astra::HandPoseInfo, including all inherited members.

Body (defined in astra::HandPoseInfo) | astra::HandPoseInfo | friend
left_hand() const (defined in astra::HandPoseInfo) | astra::HandPoseInfo | inline
leftHand (defined in _astra_handpose_info) | _astra_handpose_info | private
right_hand() const (defined in astra::HandPoseInfo) | astra::HandPoseInfo | inline
rightHand (defined in _astra_handpose_info) | _astra_handpose_info | private


Astra SDK: Member List

  • astra
  • HandStream
astra::HandStream Member List

This is the complete list of members for astra::HandStream, including all inherited members.

DataStream() (defined in astra::DataStream) | astra::DataStream | inline
DataStream(astra_streamconnection_t connection) | astra::DataStream | inline
get_include_candidate_points() const | astra::HandStream | inline
HandStream(astra_streamconnection_t connection) | astra::HandStream | inlineexplicit
id (defined in astra::HandStream) | astra::HandStream | static
is_available() | astra::DataStream | inline
set_include_candidate_points(bool includeCandidatePoints) | astra::HandStream | inline
start() | astra::DataStream | inline
stop() | astra::DataStream | inline


Astra SDK: Member List

  • astra
  • ImageFrame
astra::ImageFrame< TDataType, TStreamType > Member List

This is the complete list of members for astra::ImageFrame< TDataType, TStreamType >, including all inherited members.

acquire(astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype) | astra::ImageFrame< TDataType, TStreamType > | inlinestatic
byte_length() const | astra::ImageFrame< TDataType, TStreamType > | inline
bytes_per_pixel() const | astra::ImageFrame< TDataType, TStreamType > | inline
copy_to(TDataType *buffer) const | astra::ImageFrame< TDataType, TStreamType > | inline
data() const | astra::ImageFrame< TDataType, TStreamType > | inline
frame_index() const | astra::ImageFrame< TDataType, TStreamType > | inline
handle() const | astra::ImageFrame< TDataType, TStreamType > | inline
height() const | astra::ImageFrame< TDataType, TStreamType > | inline
ImageFrame(astra_imageframe_t frame, astra_pixel_format_t expected_format) | astra::ImageFrame< TDataType, TStreamType > | inline
is_valid() const | astra::ImageFrame< TDataType, TStreamType > | inline
length() const | astra::ImageFrame< TDataType, TStreamType > | inline
stream_type() | astra::ImageFrame< TDataType, TStreamType > | inlinestatic
width() const | astra::ImageFrame< TDataType, TStreamType > | inline


Astra SDK: Member List

  • astra
  • ImageStream
astra::ImageStream Member List

This is the complete list of members for astra::ImageStream, including all inherited members.

available_modes() const | astra::ImageStream | inline
DataStream() (defined in astra::DataStream) | astra::DataStream | inline
DataStream(astra_streamconnection_t connection) | astra::DataStream | inline
enable_mirroring(bool mirroring) | astra::ImageStream | inline
hFov() const | astra::ImageStream | inline
ImageStream(astra_streamconnection_t connection) (defined in astra::ImageStream) | astra::ImageStream | inlineexplicit
is_available() | astra::DataStream | inline
mirroring_enabled() const | astra::ImageStream | inline
mode() const | astra::ImageStream | inline
set_mode(const ImageStreamMode &mode) | astra::ImageStream | inline
start() | astra::DataStream | inline
stop() | astra::DataStream | inline
usb_info() const | astra::ImageStream | inline
vFov() const | astra::ImageStream | inline


Astra SDK: Member List

  • astra
  • ImageStreamMode
astra::ImageStreamMode Member List

This is the complete list of members for astra::ImageStreamMode, including all inherited members.

bytes_per_pixel() const | astra::ImageStreamMode | inline
fps() const | astra::ImageStreamMode | inline
fps (defined in astra_imagestream_mode_t) | astra_imagestream_mode_t | private
height() const | astra::ImageStreamMode | inline
height (defined in astra_imagestream_mode_t) | astra_imagestream_mode_t | private
id (defined in astra_imagestream_mode_t) | astra_imagestream_mode_t | private
ImageStreamMode() | astra::ImageStreamMode | inline
ImageStreamMode(std::uint32_t width, std::uint32_t height, std::uint8_t fps, astra_pixel_format_t format) | astra::ImageStreamMode | inline
ImageStreamMode(const ::astra_imagestream_mode_t &mode) | astra::ImageStreamMode | inline
operator const ::astra_imagestream_mode_t *() const (defined in astra::ImageStreamMode) | astra::ImageStreamMode | inline
operator::astra_imagestream_mode_t *() (defined in astra::ImageStreamMode) | astra::ImageStreamMode | inline
operator<< (defined in astra::ImageStreamMode) | astra::ImageStreamMode | friend
operator=(const ::astra_imagestream_mode_t &mode) | astra::ImageStreamMode | inline
pixel_format() const | astra::ImageStreamMode | inline
pixelFormat (defined in astra_imagestream_mode_t) | astra_imagestream_mode_t | private
set_fps(std::uint8_t fps) | astra::ImageStreamMode | inline
set_height(std::uint32_t height) | astra::ImageStreamMode | inline
set_pixel_format(astra_pixel_format_t format) | astra::ImageStreamMode | inline
set_width(std::uint32_t width) | astra::ImageStreamMode | inline
width() const | astra::ImageStreamMode | inline
width (defined in astra_imagestream_mode_t) | astra_imagestream_mode_t | private


Astra SDK: Member List

  • astra
  • InfraredFrame16
astra::InfraredFrame16 Member List

This is the complete list of members for astra::InfraredFrame16, including all inherited members.

acquire(astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype) | astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED > | inlinestatic
byte_length() const | astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED > | inline
bytes_per_pixel() const | astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED > | inline
copy_to(uint16_t *buffer) const | astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED > | inline
data() const | astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED > | inline
frame_index() const | astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED > | inline
handle() const | astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED > | inline
height() const | astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED > | inline
ImageFrame(astra_imageframe_t frame, astra_pixel_format_t expected_format) | astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED > | inline
InfraredFrame16(astra_imageframe_t frame) (defined in astra::InfraredFrame16) | astra::InfraredFrame16 | inline
is_valid() const | astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED > | inline
length() const | astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED > | inline
stream_type() | astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED > | inlinestatic
width() const | astra::ImageFrame< uint16_t, ASTRA_STREAM_INFRARED > | inline


Astra SDK: Member List

  • astra
  • InfraredFrameRgb
astra::InfraredFrameRgb Member List

This is the complete list of members for astra::InfraredFrameRgb, including all inherited members.

acquire(astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype) | astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED > | inlinestatic
byte_length() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED > | inline
bytes_per_pixel() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED > | inline
copy_to(RgbPixel *buffer) const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED > | inline
data() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED > | inline
frame_index() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED > | inline
handle() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED > | inline
height() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED > | inline
ImageFrame(astra_imageframe_t frame, astra_pixel_format_t expected_format) | astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED > | inline
InfraredFrameRgb(astra_imageframe_t frame) (defined in astra::InfraredFrameRgb) | astra::InfraredFrameRgb | inline
is_valid() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED > | inline
length() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED > | inline
stream_type() | astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED > | inlinestatic
width() const | astra::ImageFrame< RgbPixel, ASTRA_STREAM_INFRARED > | inline


Astra SDK: Member List

  • astra
  • InfraredStream
astra::InfraredStream Member List

This is the complete list of members for astra::InfraredStream, including all inherited members.

available_modes() const | astra::ImageStream | inline
DataStream() (defined in astra::DataStream) | astra::DataStream | inline
DataStream(astra_streamconnection_t connection) | astra::DataStream | inline
enable_mirroring(bool mirroring) | astra::ImageStream | inline
hFov() const | astra::ImageStream | inline
id (defined in astra::InfraredStream) | astra::InfraredStream | static
ImageStream(astra_streamconnection_t connection) (defined in astra::ImageStream) | astra::ImageStream | inlineexplicit
InfraredStream(astra_streamconnection_t connection) (defined in astra::InfraredStream) | astra::InfraredStream | inlineexplicit
is_available() | astra::DataStream | inline
mirroring_enabled() const | astra::ImageStream | inline
mode() const | astra::ImageStream | inline
set_mode(const ImageStreamMode &mode) | astra::ImageStream | inline
start() | astra::DataStream | inline
stop() | astra::DataStream | inline
usb_info() const | astra::ImageStream | inline
vFov() const | astra::ImageStream | inline


Astra SDK: Member List

  • astra
  • Joint
astra::Joint Member List

This is the complete list of members for astra::Joint, including all inherited members.

Body (defined in astra::Joint) | astra::Joint | friend
depth_position() const | astra::Joint | inline
depthPosition | _astra_joint | private
orientation() const | astra::Joint | inline
_astra_joint::orientation | _astra_joint | private
status() const | astra::Joint | inline
_astra_joint::status | _astra_joint | private
type() const | astra::Joint | inline
_astra_joint::type | _astra_joint | private
world_position() const | astra::Joint | inline
worldPosition | _astra_joint | private


Astra SDK: Member List

  • astra
  • MaskedColorFrame
astra::MaskedColorFrame Member List

This is the complete list of members for astra::MaskedColorFrame, including all inherited members.

acquire(astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype) | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR > | inlinestatic
byte_length() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR > | inline
bytes_per_pixel() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR > | inline
copy_to(RgbaPixel *buffer) const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR > | inline
data() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR > | inline
frame_index() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR > | inline
handle() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR > | inline
height() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR > | inline
ImageFrame(astra_imageframe_t frame, astra_pixel_format_t expected_format) | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR > | inline
is_valid() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR > | inline
length() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR > | inline
MaskedColorFrame(astra_imageframe_t frame) (defined in astra::MaskedColorFrame) | astra::MaskedColorFrame | inline
stream_type() | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR > | inlinestatic
width() const | astra::ImageFrame< RgbaPixel, ASTRA_STREAM_MASKED_COLOR > | inline


Astra SDK: Member List

  • astra
  • MaskedColorStream
astra::MaskedColorStream Member List

This is the complete list of members for astra::MaskedColorStream, including all inherited members.

DataStream() (defined in astra::DataStream) | astra::DataStream | inline
DataStream(astra_streamconnection_t connection) | astra::DataStream | inline
id (defined in astra::MaskedColorStream) | astra::MaskedColorStream | static
is_available() | astra::DataStream | inline
MaskedColorStream() (defined in astra::MaskedColorStream) | astra::MaskedColorStream | inline
MaskedColorStream(astra_streamconnection_t connection) (defined in astra::MaskedColorStream) | astra::MaskedColorStream | inlineexplicit
start() | astra::DataStream | inline
stop() | astra::DataStream | inline


Astra SDK: Member List

  • astra
  • Plane
astra::Plane Member List

This is the complete list of members for astra::Plane, including all inherited members.

a() const | astra::Plane | inline
_astra_plane::a | _astra_plane | private
b() const | astra::Plane | inline
_astra_plane::b | _astra_plane | private
c() const | astra::Plane | inline
_astra_plane::c | _astra_plane | private
d() const | astra::Plane | inline
_astra_plane::d | _astra_plane | private
FloorInfo (defined in astra::Plane) | astra::Plane | friend
is_degenerate() const | astra::Plane | inline
normal() const | astra::Plane | inline
Plane() | astra::Plane | inline


Astra SDK: Member List

  • astra
  • PointFrame
astra::PointFrame Member List

This is the complete list of members for astra::PointFrame, including all inherited members.

acquire(astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype) | astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT > | inlinestatic
byte_length() const | astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT > | inline
bytes_per_pixel() const | astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT > | inline
copy_to(Vector3f *buffer) const | astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT > | inline
data() const | astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT > | inline
frame_index() const | astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT > | inline
handle() const | astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT > | inline
height() const | astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT > | inline
ImageFrame(astra_imageframe_t frame, astra_pixel_format_t expected_format) | astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT > | inline
is_valid() const | astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT > | inline
length() const | astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT > | inline
PointFrame(astra_imageframe_t frame) | astra::PointFrame | inline
stream_type() | astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT > | inlinestatic
width() const | astra::ImageFrame< Vector3f, ASTRA_STREAM_POINT > | inline


Astra SDK: Member List

  • astra
  • PointStream
astra::PointStream Member List

This is the complete list of members for astra::PointStream, including all inherited members.

DataStream() (defined in astra::DataStream) | astra::DataStream | inline
DataStream(astra_streamconnection_t connection) | astra::DataStream | inline
id (defined in astra::PointStream) | astra::PointStream | static
is_available() | astra::DataStream | inline
PointStream() (defined in astra::PointStream) | astra::PointStream | inline
PointStream(astra_streamconnection_t connection) | astra::PointStream | inlineexplicit
start() | astra::DataStream | inline
stop() | astra::DataStream | inline


Astra SDK: Member List

  • astra
  • RawColorFrame
astra::RawColorFrame Member List

This is the complete list of members for astra::RawColorFrame, including all inherited members.

acquire(astra_reader_frame_t readerFrame, astra_stream_subtype_t subtype) | astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR > | inlinestatic
byte_length() const | astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR > | inline
bytes_per_pixel() const | astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR > | inline
copy_to(uint8_t *buffer) const | astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR > | inline
data() const | astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR > | inline
frame_index() const | astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR > | inline
handle() const | astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR > | inline
height() const | astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR > | inline
ImageFrame(astra_imageframe_t frame, astra_pixel_format_t expected_format) | astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR > | inline
is_valid() const | astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR > | inline
length() const | astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR > | inline
RawColorFrame(astra_imageframe_t frame) (defined in astra::RawColorFrame) | astra::RawColorFrame | inline
stream_type() | astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR > | inlinestatic
width() const | astra::ImageFrame< uint8_t, ASTRA_STREAM_COLOR > | inline


Astra SDK: Member List

  • astra
  • StreamDescription
astra::StreamDescription Member List

This is the complete list of members for astra::StreamDescription, including all inherited members.

operator const ::astra_stream_desc_t *() const (defined in astra::StreamDescription) | astra::StreamDescription | inline
operator::astra_stream_desc_t *() (defined in astra::StreamDescription) | astra::StreamDescription | inline
operator=(const ::astra_stream_desc_t &desc) | astra::StreamDescription | inline
StreamDescription(::astra_stream_type_t type, ::astra_stream_subtype_t subtype=DEFAULT_SUBTYPE) | astra::StreamDescription | inline
StreamDescription(const ::astra_stream_desc_t &desc) | astra::StreamDescription | inline
subtype() const | astra::StreamDescription | inline
subtype (defined in astra_stream_desc_t) | astra_stream_desc_t | private
type() const | astra::StreamDescription | inline
type (defined in astra_stream_desc_t) | astra_stream_desc_t | private


Astra SDK: Member List

  • astra
  • StreamReader
astra::StreamReader Member List

This is the complete list of members for astra::StreamReader, including all inherited members.

add_listener(FrameListener &listener) | astra::StreamReader | inline
get_latest_frame(int timeoutMillis=ASTRA_TIMEOUT_FOREVER) | astra::StreamReader | inline
has_new_frame() | astra::StreamReader | inline
is_valid() | astra::StreamReader | inline
operator=(const StreamReader &reader) | astra::StreamReader | inline
operator== (defined in astra::StreamReader) | astra::StreamReader | friend
remove_listener(FrameListener &listener) | astra::StreamReader | inline
stream() | astra::StreamReader | inline
stream(astra_stream_subtype_t subtype) | astra::StreamReader | inline
StreamReader() | astra::StreamReader | inline
StreamReader(astra_reader_t reader) | astra::StreamReader | inline
StreamReader(const StreamReader &reader) | astra::StreamReader | inline


Astra SDK: Member List

  • astra
  • StreamServiceProxy
astra::StreamServiceProxy Member List

This is the complete list of members for astra::StreamServiceProxy, including all inherited members.

astra_command_id (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_event_id (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_frame_ready_callback_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_parameter_data_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_parameter_data_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_parameter_data_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_parameter_id (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_parameter_id (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_reader_frame_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_reader_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_reader_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_reader_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_reader_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_result_token_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *notify_plugin_event)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *streamset_is_available)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *streamset_open)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *streamset_close)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *streamset_get_uri)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *reader_create)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *reader_destroy)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *reader_get_stream)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *stream_get_description)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *stream_is_available)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *stream_start)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *stream_stop)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *reader_has_new_frame)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *reader_open_frame)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *reader_close_frame)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *reader_register_frame_ready_callback)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *reader_unregister_frame_ready_callback)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *reader_get_frame)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *stream_set_parameter)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *stream_get_parameter)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *stream_get_result)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *stream_invoke)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_status_t(ASTRA_CALLBACK *update)(void *) (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_stream_subtype_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_stream_subtype_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_stream_type_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_stream_type_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_streamconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_streamconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_streamconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_streamconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_streamconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_streamconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_streamsetconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
astra_streamsetconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
int (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
int32_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
notify_plugin_event(astra_event_id id, const void *data, uint32_t dataSize) | astra::StreamServiceProxy | inline
reader_close_frame(astra_reader_frame_t *frame) | astra::StreamServiceProxy | inline
reader_create(astra_streamsetconnection_t streamSet, astra_reader_t *reader) | astra::StreamServiceProxy | inline
reader_destroy(astra_reader_t *reader) | astra::StreamServiceProxy | inline
reader_get_frame(astra_reader_frame_t frame, astra_stream_type_t type, astra_stream_subtype_t subtype, astra_frame_t **subFrame) | astra::StreamServiceProxy | inline
reader_get_stream(astra_reader_t reader, astra_stream_type_t type, astra_stream_subtype_t subtype, astra_streamconnection_t *connection) | astra::StreamServiceProxy | inline
reader_has_new_frame(astra_reader_t reader, bool *hasNewFrame) | astra::StreamServiceProxy | inline
reader_open_frame(astra_reader_t reader, int timeoutMillis, astra_reader_frame_t *frame) | astra::StreamServiceProxy | inline
reader_register_frame_ready_callback(astra_reader_t reader, astra_frame_ready_callback_t callback, void *clientTag, astra_reader_callback_id_t *callbackId) | astra::StreamServiceProxy | inline
reader_unregister_frame_ready_callback(astra_reader_callback_id_t *callbackId) | astra::StreamServiceProxy | inline
stream_get_description(astra_streamconnection_t connection, astra_stream_desc_t *description) | astra::StreamServiceProxy | inline
stream_get_parameter(astra_streamconnection_t connection, astra_parameter_id parameterId, uint32_t *resultByteLength, astra_result_token_t *token) | astra::StreamServiceProxy | inline
stream_get_result(astra_streamconnection_t connection, astra_result_token_t token, uint32_t dataByteLength, astra_parameter_data_t dataDestination) | astra::StreamServiceProxy | inline
stream_invoke(astra_streamconnection_t connection, astra_command_id commandId, uint32_t inByteLength, astra_parameter_data_t inData, uint32_t *resultByteLength, astra_result_token_t *token) | astra::StreamServiceProxy | inline
stream_is_available(astra_streamconnection_t connection, bool *isAvailable) | astra::StreamServiceProxy | inline
stream_set_parameter(astra_streamconnection_t connection, astra_parameter_id parameterId, uint32_t inByteLength, astra_parameter_data_t inData) | astra::StreamServiceProxy | inline
stream_start(astra_streamconnection_t connection) | astra::StreamServiceProxy | inline
stream_stop(astra_streamconnection_t connection) | astra::StreamServiceProxy | inline
streamService (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
streamset_close(astra_streamsetconnection_t *streamSet) | astra::StreamServiceProxy | inline
streamset_get_uri(astra_streamsetconnection_t connection, char *uri, int32_t size) | astra::StreamServiceProxy | inline
streamset_is_available(astra_streamsetconnection_t connection, bool *isAvailable) | astra::StreamServiceProxy | inline
streamset_open(const char *connectionString, astra_streamsetconnection_t *streamSet) | astra::StreamServiceProxy | inline
uint32_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
uint32_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
uint32_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
uint32_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t |
update() | astra::StreamServiceProxy | inline


Astra SDK: Member List

  • astra
  • StreamSet
astra::StreamSet Member List

This is the complete list of members for astra::StreamSet, including all inherited members.

create_reader() | astra::StreamSet | inline
get_handle() const | astra::StreamSet | inline
is_available() | astra::StreamSet | inline
is_valid() | astra::StreamSet | inline
operator!= (defined in astra::StreamSet) | astra::StreamSet | friend
operator=(const StreamSet &rhs) | astra::StreamSet | inline
operator== (defined in astra::StreamSet) | astra::StreamSet | friend
StreamSet() | astra::StreamSet | inline
StreamSet(const char *uri) | astra::StreamSet | inline
StreamSet(const StreamSet &other) | astra::StreamSet | inline
uri() | astra::StreamSet | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • Astra
com.orbbec.astra.Astra Member List

This is the complete list of members for com.orbbec.astra.Astra, including all inherited members.

initialize() | com.orbbec.astra.Astra | inlinestatic
notifyResourceAvailable(String resourceUri) (defined in com.orbbec.astra.Astra) | com.orbbec.astra.Astra | inlinestatic
notifyResourceUnavailable(String resourceUri) (defined in com.orbbec.astra.Astra) | com.orbbec.astra.Astra | inlinestatic
terminate() | com.orbbec.astra.Astra | inlinestatic
update() | com.orbbec.astra.Astra | inlinestatic


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • Body
com.orbbec.astra.Body Member List

This is the complete list of members for com.orbbec.astra.Body, including all inherited members.

areHandPosesEnabled() | com.orbbec.astra.Body | inline
areJointsEnabled() | com.orbbec.astra.Body | inline
Body(int id, int status, int bodyFeatureFlag, Vector3D centerOfMass, Joint[] joints, HandPoseInfo handPoseInfo) | com.orbbec.astra.Body | inline
getCenterOfMass() | com.orbbec.astra.Body | inline
getHandPoseInfo() | com.orbbec.astra.Body | inline
getId() | com.orbbec.astra.Body | inline
getJoints() | com.orbbec.astra.Body | inline
getStatus() | com.orbbec.astra.Body | inline
toString() | com.orbbec.astra.Body | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • BodyFrame
com.orbbec.astra.BodyFrame Member List

This is the complete list of members for com.orbbec.astra.BodyFrame, including all inherited members.

DataFrame(long handle) (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | inlineprotected
get(ReaderFrame readerFrame, int subtype) | com.orbbec.astra.BodyFrame | inlinestatic
get(ReaderFrame readerFrame) | com.orbbec.astra.BodyFrame | inlinestatic
getBodies() | com.orbbec.astra.BodyFrame | inline
getBodyMask() | com.orbbec.astra.BodyFrame | inline
getFloorInfo() | com.orbbec.astra.BodyFrame | inline
getFrameIndex() | com.orbbec.astra.DataFrame | inline
getHeight() | com.orbbec.astra.BodyFrame | inline
getIsEstimated() | com.orbbec.astra.BodyFrame | inline
getWidth() | com.orbbec.astra.BodyFrame | inline
handle (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | protected
isValid() | com.orbbec.astra.DataFrame | inline
STREAM_TYPE (defined in com.orbbec.astra.BodyFrame) | com.orbbec.astra.BodyFrame | static


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • BodyFrameInfo
com.orbbec.astra.BodyFrameInfo Member List

This is the complete list of members for com.orbbec.astra.BodyFrameInfo, including all inherited members.

getHeight() | com.orbbec.astra.BodyFrameInfo | inline
getIsEstimated() | com.orbbec.astra.BodyFrameInfo | inline
getWidth() | com.orbbec.astra.BodyFrameInfo | inline
toString() | com.orbbec.astra.BodyFrameInfo | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • BodyMask
com.orbbec.astra.BodyMask Member List

This is the complete list of members for com.orbbec.astra.BodyMask, including all inherited members.

getHeight() | com.orbbec.astra.BodyMask | inline
getMask() | com.orbbec.astra.BodyMask | inline
getWidth() | com.orbbec.astra.BodyMask | inline
toString() | com.orbbec.astra.BodyMask | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • BodyStream
com.orbbec.astra.BodyStream Member List

This is the complete list of members for com.orbbec.astra.BodyStream, including all inherited members.

BodyStream(long handle) (defined in com.orbbec.astra.BodyStream) | com.orbbec.astra.BodyStream | inlineprotected
DataStream(long handle) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotected
get(StreamReader reader, int subtype) | com.orbbec.astra.BodyStream | inlinestatic
get(StreamReader reader) | com.orbbec.astra.BodyStream | inlinestatic
getBodyFeatures(int bodyId) | com.orbbec.astra.BodyStream | inline
getDefaultBodyFeatures() | com.orbbec.astra.BodyStream | inline
getFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotectedstatic
getIsAvailable() | com.orbbec.astra.DataStream | inline
getSkeletonOptimization() | com.orbbec.astra.BodyStream | inline
getSkeletonProfile() | com.orbbec.astra.BodyStream | inline
getSubtype() | com.orbbec.astra.DataStream | inline
getType() | com.orbbec.astra.DataStream | inline
handle (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | protected
setBodyFeatures(int bodyId, BodyTrackingFeatureFlags features) | com.orbbec.astra.BodyStream | inline
setDefaultBodyFeatures(BodyTrackingFeatureFlags features) | com.orbbec.astra.BodyStream | inline
setSkeletonOptimization(SkeletonOptimization optimization) | com.orbbec.astra.BodyStream | inline
setSkeletonProfile(SkeletonProfile profile) | com.orbbec.astra.BodyStream | inline
start() | com.orbbec.astra.DataStream | inline
stop() | com.orbbec.astra.DataStream | inline
STREAM_TYPE (defined in com.orbbec.astra.BodyStream) | com.orbbec.astra.BodyStream | static


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • BodyTracking
com.orbbec.astra.BodyTracking Member List

This is the complete list of members for com.orbbec.astra.BodyTracking, including all inherited members.

setLicense(String licenseString) com.orbbec.astra.BodyTracking inlinestatic


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • ColorFrame
com.orbbec.astra.ColorFrame Member List

This is the complete list of members for com.orbbec.astra.ColorFrame, including all inherited members.

DataFrame(long handle) (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | inlineprotected
get(ReaderFrame readerFrame, int subtype) | com.orbbec.astra.ColorFrame | inlinestatic
get(ReaderFrame readerFrame) | com.orbbec.astra.ColorFrame | inlinestatic
getByteBuffer() | com.orbbec.astra.ImageFrame | inline
getBytesPerPixel() | com.orbbec.astra.ImageFrame | inline
getFrameIndex() | com.orbbec.astra.DataFrame | inline
getHeight() | com.orbbec.astra.ImageFrame | inline
getImageFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.ImageFrame) | com.orbbec.astra.ImageFrame | inlineprotectedstatic
getNV21ColorFrame(ReaderFrame readerFrame) | com.orbbec.astra.ColorFrame | inlinestatic
getPixelFormat() | com.orbbec.astra.ImageFrame | inline
getWidth() | com.orbbec.astra.ImageFrame | inline
handle (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | protected
ImageFrame(long handle) (defined in com.orbbec.astra.ImageFrame) | com.orbbec.astra.ImageFrame | inlineprotected
isValid() | com.orbbec.astra.DataFrame | inline
STREAM_TYPE (defined in com.orbbec.astra.ColorFrame) | com.orbbec.astra.ColorFrame | static


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • ColorStream
com.orbbec.astra.ColorStream Member List

This is the complete list of members for com.orbbec.astra.ColorStream, including all inherited members.

ColorStream(long handle) (defined in com.orbbec.astra.ColorStream) | com.orbbec.astra.ColorStream | inlineprotected
DataStream(long handle) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotected
get(StreamReader reader, int subtype) | com.orbbec.astra.ColorStream | inlinestatic
get(StreamReader reader) | com.orbbec.astra.ColorStream | inlinestatic
getAvailableModes() | com.orbbec.astra.ImageStream | inline
getFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotectedstatic
getHorizontalFieldOfView() | com.orbbec.astra.ImageStream | inline
getIsAvailable() | com.orbbec.astra.DataStream | inline
getMirroring() | com.orbbec.astra.ImageStream | inline
getMode() | com.orbbec.astra.ImageStream | inline
getNV21ColorStream(StreamReader reader) | com.orbbec.astra.ColorStream | inlinestatic
getSubtype() | com.orbbec.astra.DataStream | inline
getType() | com.orbbec.astra.DataStream | inline
getUsbDeviceInfo() | com.orbbec.astra.ImageStream | inline
getVerticalFieldOfView() | com.orbbec.astra.ImageStream | inline
handle (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | protected
ImageStream(long handle) (defined in com.orbbec.astra.ImageStream) | com.orbbec.astra.ImageStream | inlineprotected
setMirroring(boolean mirroring) | com.orbbec.astra.ImageStream | inline
setMode(ImageStreamMode mode) | com.orbbec.astra.ImageStream | inline
start() | com.orbbec.astra.DataStream | inline
stop() | com.orbbec.astra.DataStream | inline
STREAM_TYPE (defined in com.orbbec.astra.ColorStream) | com.orbbec.astra.ColorStream | static


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • ColorizedBodyFrame
com.orbbec.astra.ColorizedBodyFrame Member List

This is the complete list of members for com.orbbec.astra.ColorizedBodyFrame, including all inherited members.

DataFrame(long handle) (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | inlineprotected
get(ReaderFrame readerFrame, int subtype) | com.orbbec.astra.ColorizedBodyFrame | inlinestatic
get(ReaderFrame readerFrame) | com.orbbec.astra.ColorizedBodyFrame | inlinestatic
getByteBuffer() | com.orbbec.astra.ImageFrame | inline
getBytesPerPixel() | com.orbbec.astra.ImageFrame | inline
getFrameIndex() | com.orbbec.astra.DataFrame | inline
getHeight() | com.orbbec.astra.ImageFrame | inline
getImageFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.ImageFrame) | com.orbbec.astra.ImageFrame | inlineprotectedstatic
getPixelFormat() | com.orbbec.astra.ImageFrame | inline
getWidth() | com.orbbec.astra.ImageFrame | inline
handle (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | protected
ImageFrame(long handle) (defined in com.orbbec.astra.ImageFrame) | com.orbbec.astra.ImageFrame | inlineprotected
isValid() | com.orbbec.astra.DataFrame | inline
STREAM_TYPE (defined in com.orbbec.astra.ColorizedBodyFrame) | com.orbbec.astra.ColorizedBodyFrame | static


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • ColorizedBodyStream
com.orbbec.astra.ColorizedBodyStream Member List

This is the complete list of members for com.orbbec.astra.ColorizedBodyStream, including all inherited members.

ColorizedBodyStream(long handle) (defined in com.orbbec.astra.ColorizedBodyStream) | com.orbbec.astra.ColorizedBodyStream | inlineprotected
DataStream(long handle) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotected
get(StreamReader reader, int subtype) | com.orbbec.astra.ColorizedBodyStream | inlinestatic
get(StreamReader reader) | com.orbbec.astra.ColorizedBodyStream | inlinestatic
getFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotectedstatic
getIsAvailable() | com.orbbec.astra.DataStream | inline
getSubtype() | com.orbbec.astra.DataStream | inline
getType() | com.orbbec.astra.DataStream | inline
handle (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | protected
start() | com.orbbec.astra.DataStream | inline
stop() | com.orbbec.astra.DataStream | inline
STREAM_TYPE (defined in com.orbbec.astra.ColorizedBodyStream) | com.orbbec.astra.ColorizedBodyStream | static


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • CoordinateMapper
com.orbbec.astra.CoordinateMapper Member List

This is the complete list of members for com.orbbec.astra.CoordinateMapper, including all inherited members.

CoordinateMapper(int resolutionX, int resolutionY, float hFov, float vFov) | com.orbbec.astra.CoordinateMapper | inline
mapDepthPointToWorldSpace(Vector3D depthPoint) | com.orbbec.astra.CoordinateMapper | inline
mapWorldPointToDepthSpace(Vector3D worldPoint) | com.orbbec.astra.CoordinateMapper | inline
toString() | com.orbbec.astra.CoordinateMapper | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • DataFrame
com.orbbec.astra.DataFrame Member List

This is the complete list of members for com.orbbec.astra.DataFrame, including all inherited members.

DataFrame(long handle) (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | inlineprotected
getFrameIndex() | com.orbbec.astra.DataFrame | inline
handle (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | protected
isValid() | com.orbbec.astra.DataFrame | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • DataStream
com.orbbec.astra.DataStream Member List

This is the complete list of members for com.orbbec.astra.DataStream, including all inherited members.

DataStream(long handle) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotected
getFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotectedstatic
getIsAvailable() | com.orbbec.astra.DataStream | inline
getSubtype() | com.orbbec.astra.DataStream | inline
getType() | com.orbbec.astra.DataStream | inline
handle (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | protected
start() | com.orbbec.astra.DataStream | inline
stop() | com.orbbec.astra.DataStream | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • DepthFrame
com.orbbec.astra.DepthFrame Member List

This is the complete list of members for com.orbbec.astra.DepthFrame, including all inherited members.

DataFrame(long handle) (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | inlineprotected
get(ReaderFrame readerFrame, int subtype) | com.orbbec.astra.DepthFrame | inlinestatic
get(ReaderFrame readerFrame) | com.orbbec.astra.DepthFrame | inlinestatic
getByteBuffer() | com.orbbec.astra.ImageFrame | inline
getBytesPerPixel() | com.orbbec.astra.ImageFrame | inline
getDepthBuffer() | com.orbbec.astra.DepthFrame | inline
getFrameIndex() | com.orbbec.astra.DataFrame | inline
getHeight() | com.orbbec.astra.ImageFrame | inline
getImageFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.ImageFrame) | com.orbbec.astra.ImageFrame | inlineprotectedstatic
getPixelFormat() | com.orbbec.astra.ImageFrame | inline
getWidth() | com.orbbec.astra.ImageFrame | inline
handle (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | protected
ImageFrame(long handle) (defined in com.orbbec.astra.ImageFrame) | com.orbbec.astra.ImageFrame | inlineprotected
isValid() | com.orbbec.astra.DataFrame | inline
STREAM_TYPE (defined in com.orbbec.astra.DepthFrame) | com.orbbec.astra.DepthFrame | static


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • DepthStream
com.orbbec.astra.DepthStream Member List

This is the complete list of members for com.orbbec.astra.DepthStream, including all inherited members.

DataStream(long handle) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotected
get(StreamReader reader, int subtype) | com.orbbec.astra.DepthStream | inlinestatic
get(StreamReader reader) | com.orbbec.astra.DepthStream | inlinestatic
getAvailableModes() | com.orbbec.astra.ImageStream | inline
getDeviceChipId() | com.orbbec.astra.DepthStream | inline
getDeviceSerialNumber() | com.orbbec.astra.DepthStream | inline
getFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotectedstatic
getHorizontalFieldOfView() | com.orbbec.astra.ImageStream | inline
getIsAvailable() | com.orbbec.astra.DataStream | inline
getMirroring() | com.orbbec.astra.ImageStream | inline
getMode() | com.orbbec.astra.ImageStream | inline
getRegistration() | com.orbbec.astra.DepthStream | inline
getSubtype() | com.orbbec.astra.DataStream | inline
getType() | com.orbbec.astra.DataStream | inline
getUsbDeviceInfo() | com.orbbec.astra.ImageStream | inline
getVerticalFieldOfView() | com.orbbec.astra.ImageStream | inline
handle (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | protected
ImageStream(long handle) (defined in com.orbbec.astra.ImageStream) | com.orbbec.astra.ImageStream | inlineprotected
setMirroring(boolean mirroring) | com.orbbec.astra.ImageStream | inline
setMode(ImageStreamMode mode) | com.orbbec.astra.ImageStream | inline
setRegistration(boolean registration) | com.orbbec.astra.DepthStream | inline
start() | com.orbbec.astra.DataStream | inline
stop() | com.orbbec.astra.DataStream | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • FloorInfo
com.orbbec.astra.FloorInfo Member List

This is the complete list of members for com.orbbec.astra.FloorInfo, including all inherited members.

getMask() | com.orbbec.astra.FloorInfo | inline
getPlane() | com.orbbec.astra.FloorInfo | inline
isDetected() | com.orbbec.astra.FloorInfo | inline
toString() | com.orbbec.astra.FloorInfo | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • FloorMask
com.orbbec.astra.FloorMask Member List

This is the complete list of members for com.orbbec.astra.FloorMask, including all inherited members.

getHeight() | com.orbbec.astra.FloorMask | inline
getMask() | com.orbbec.astra.FloorMask | inline
getWidth() | com.orbbec.astra.FloorMask | inline
toString() | com.orbbec.astra.FloorMask | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • HandPoseInfo
com.orbbec.astra.HandPoseInfo Member List

This is the complete list of members for com.orbbec.astra.HandPoseInfo, including all inherited members.

getLeftHand() | com.orbbec.astra.HandPoseInfo | inline
getRightHand() | com.orbbec.astra.HandPoseInfo | inline
HandPoseInfo(int leftHand, int rightHand) (defined in com.orbbec.astra.HandPoseInfo) | com.orbbec.astra.HandPoseInfo | inline
toString() | com.orbbec.astra.HandPoseInfo | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • ImageFrame
com.orbbec.astra.ImageFrame Member List

This is the complete list of members for com.orbbec.astra.ImageFrame, including all inherited members.

DataFrame(long handle) (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | inlineprotected
getByteBuffer() | com.orbbec.astra.ImageFrame | inline
getBytesPerPixel() | com.orbbec.astra.ImageFrame | inline
getFrameIndex() | com.orbbec.astra.DataFrame | inline
getHeight() | com.orbbec.astra.ImageFrame | inline
getImageFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.ImageFrame) | com.orbbec.astra.ImageFrame | inlineprotectedstatic
getPixelFormat() | com.orbbec.astra.ImageFrame | inline
getWidth() | com.orbbec.astra.ImageFrame | inline
handle (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | protected
ImageFrame(long handle) (defined in com.orbbec.astra.ImageFrame) | com.orbbec.astra.ImageFrame | inlineprotected
isValid() | com.orbbec.astra.DataFrame | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • ImageMetadata
com.orbbec.astra.ImageMetadata Member List

This is the complete list of members for com.orbbec.astra.ImageMetadata, including all inherited members.

getFormat() | com.orbbec.astra.ImageMetadata | inline
getHeight() | com.orbbec.astra.ImageMetadata | inline
getWidth() | com.orbbec.astra.ImageMetadata | inline
toString() | com.orbbec.astra.ImageMetadata | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • ImageStream
com.orbbec.astra.ImageStream Member List

This is the complete list of members for com.orbbec.astra.ImageStream, including all inherited members.

DataStream(long handle) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotected
getAvailableModes() | com.orbbec.astra.ImageStream | inline
getFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotectedstatic
getHorizontalFieldOfView() | com.orbbec.astra.ImageStream | inline
getIsAvailable() | com.orbbec.astra.DataStream | inline
getMirroring() | com.orbbec.astra.ImageStream | inline
getMode() | com.orbbec.astra.ImageStream | inline
getSubtype() | com.orbbec.astra.DataStream | inline
getType() | com.orbbec.astra.DataStream | inline
getUsbDeviceInfo() | com.orbbec.astra.ImageStream | inline
getVerticalFieldOfView() | com.orbbec.astra.ImageStream | inline
handle (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | protected
ImageStream(long handle) (defined in com.orbbec.astra.ImageStream) | com.orbbec.astra.ImageStream | inlineprotected
setMirroring(boolean mirroring) | com.orbbec.astra.ImageStream | inline
setMode(ImageStreamMode mode) | com.orbbec.astra.ImageStream | inline
start() | com.orbbec.astra.DataStream | inline
stop() | com.orbbec.astra.DataStream | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • ImageStreamMode
com.orbbec.astra.ImageStreamMode Member List

This is the complete list of members for com.orbbec.astra.ImageStreamMode, including all inherited members.

getFormat() | com.orbbec.astra.ImageStreamMode | inline
getFramesPerSecond() | com.orbbec.astra.ImageStreamMode | inline
getHeight() | com.orbbec.astra.ImageStreamMode | inline
getId() | com.orbbec.astra.ImageStreamMode | inline
getWidth() | com.orbbec.astra.ImageStreamMode | inline
ImageStreamMode(int id, int width, int height, int format, int framesPerSecond) | com.orbbec.astra.ImageStreamMode | inline
toString() | com.orbbec.astra.ImageStreamMode | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • InfraredFrame
com.orbbec.astra.InfraredFrame Member List

This is the complete list of members for com.orbbec.astra.InfraredFrame, including all inherited members.

DataFrame(long handle) (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | inlineprotected
get(ReaderFrame readerFrame, int subtype) | com.orbbec.astra.InfraredFrame | inlinestatic
get(ReaderFrame readerFrame) | com.orbbec.astra.InfraredFrame | inlinestatic
getByteBuffer() | com.orbbec.astra.ImageFrame | inline
getBytesPerPixel() | com.orbbec.astra.ImageFrame | inline
getFrameIndex() | com.orbbec.astra.DataFrame | inline
getHeight() | com.orbbec.astra.ImageFrame | inline
getImageFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.ImageFrame) | com.orbbec.astra.ImageFrame | inlineprotectedstatic
getPixelFormat() | com.orbbec.astra.ImageFrame | inline
getWidth() | com.orbbec.astra.ImageFrame | inline
handle (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | protected
ImageFrame(long handle) (defined in com.orbbec.astra.ImageFrame) | com.orbbec.astra.ImageFrame | inlineprotected
isValid() | com.orbbec.astra.DataFrame | inline
STREAM_TYPE (defined in com.orbbec.astra.InfraredFrame) | com.orbbec.astra.InfraredFrame | static


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • InfraredStream
com.orbbec.astra.InfraredStream Member List

This is the complete list of members for com.orbbec.astra.InfraredStream, including all inherited members.

DataStream(long handle) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotected
get(StreamReader reader, int subtype) | com.orbbec.astra.InfraredStream | inlinestatic
get(StreamReader reader) | com.orbbec.astra.InfraredStream | inlinestatic
getAvailableModes() | com.orbbec.astra.ImageStream | inline
getFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotectedstatic
getHorizontalFieldOfView() | com.orbbec.astra.ImageStream | inline
getIsAvailable() | com.orbbec.astra.DataStream | inline
getMirroring() | com.orbbec.astra.ImageStream | inline
getMode() | com.orbbec.astra.ImageStream | inline
getSubtype() | com.orbbec.astra.DataStream | inline
getType() | com.orbbec.astra.DataStream | inline
getUsbDeviceInfo() | com.orbbec.astra.ImageStream | inline
getVerticalFieldOfView() | com.orbbec.astra.ImageStream | inline
handle (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | protected
ImageStream(long handle) (defined in com.orbbec.astra.ImageStream) | com.orbbec.astra.ImageStream | inlineprotected
InfraredStream(long handle) (defined in com.orbbec.astra.InfraredStream) | com.orbbec.astra.InfraredStream | inlineprotected
setMirroring(boolean mirroring) | com.orbbec.astra.ImageStream | inline
setMode(ImageStreamMode mode) | com.orbbec.astra.ImageStream | inline
start() | com.orbbec.astra.DataStream | inline
stop() | com.orbbec.astra.DataStream | inline
STREAM_TYPE (defined in com.orbbec.astra.InfraredStream) | com.orbbec.astra.InfraredStream | static


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • Joint
com.orbbec.astra.Joint Member List

This is the complete list of members for com.orbbec.astra.Joint, including all inherited members.

getDepthPosition() | com.orbbec.astra.Joint | inline
getOrientation() | com.orbbec.astra.Joint | inline
getStatus() | com.orbbec.astra.Joint | inline
getType() | com.orbbec.astra.Joint | inline
getWorldPosition() | com.orbbec.astra.Joint | inline
toString() | com.orbbec.astra.Joint | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • MaskedColorFrame
com.orbbec.astra.MaskedColorFrame Member List

This is the complete list of members for com.orbbec.astra.MaskedColorFrame, including all inherited members.

DataFrame(long handle) (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | inlineprotected
get(ReaderFrame readerFrame, int subtype) | com.orbbec.astra.MaskedColorFrame | inlinestatic
get(ReaderFrame readerFrame) | com.orbbec.astra.MaskedColorFrame | inlinestatic
getByteBuffer() | com.orbbec.astra.ImageFrame | inline
getBytesPerPixel() | com.orbbec.astra.ImageFrame | inline
getFrameIndex() | com.orbbec.astra.DataFrame | inline
getHeight() | com.orbbec.astra.ImageFrame | inline
getImageFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.ImageFrame) | com.orbbec.astra.ImageFrame | inlineprotectedstatic
getPixelFormat() | com.orbbec.astra.ImageFrame | inline
getWidth() | com.orbbec.astra.ImageFrame | inline
handle (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | protected
ImageFrame(long handle) (defined in com.orbbec.astra.ImageFrame) | com.orbbec.astra.ImageFrame | inlineprotected
isValid() | com.orbbec.astra.DataFrame | inline
STREAM_TYPE (defined in com.orbbec.astra.MaskedColorFrame) | com.orbbec.astra.MaskedColorFrame | static


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • MaskedColorStream
com.orbbec.astra.MaskedColorStream Member List

This is the complete list of members for com.orbbec.astra.MaskedColorStream, including all inherited members.

DataStream(long handle) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotected
get(StreamReader reader, int subtype) | com.orbbec.astra.MaskedColorStream | inlinestatic
get(StreamReader reader) | com.orbbec.astra.MaskedColorStream | inlinestatic
getFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotectedstatic
getIsAvailable() | com.orbbec.astra.DataStream | inline
getSubtype() | com.orbbec.astra.DataStream | inline
getType() | com.orbbec.astra.DataStream | inline
handle (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | protected
MaskedColorStream(long handle) (defined in com.orbbec.astra.MaskedColorStream) | com.orbbec.astra.MaskedColorStream | inlineprotected
start() | com.orbbec.astra.DataStream | inline
stop() | com.orbbec.astra.DataStream | inline
STREAM_TYPE (defined in com.orbbec.astra.MaskedColorStream) | com.orbbec.astra.MaskedColorStream | static


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • Matrix3
com.orbbec.astra.Matrix3 Member List

This is the complete list of members for com.orbbec.astra.Matrix3, including all inherited members.

getAxisX() (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | inline
getAxisY() (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | inline
getAxisZ() (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | inline
getValues() (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | inline
M00 (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | static
M01 (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | static
M02 (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | static
M10 (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | static
M11 (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | static
M12 (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | static
M20 (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | static
M21 (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | static
M22 (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | static
Matrix3() (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | inline
Matrix3(float[] values) (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | inline
setValues(float[] values) (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | inline
toString() (defined in com.orbbec.astra.Matrix3) | com.orbbec.astra.Matrix3 | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • Plane
com.orbbec.astra.Plane Member List

This is the complete list of members for com.orbbec.astra.Plane, including all inherited members.

getA() (defined in com.orbbec.astra.Plane) | com.orbbec.astra.Plane | inline
getB() (defined in com.orbbec.astra.Plane) | com.orbbec.astra.Plane | inline
getC() (defined in com.orbbec.astra.Plane) | com.orbbec.astra.Plane | inline
getD() (defined in com.orbbec.astra.Plane) | com.orbbec.astra.Plane | inline
Plane(float a, float b, float c, float d) (defined in com.orbbec.astra.Plane) | com.orbbec.astra.Plane | inline
toString() (defined in com.orbbec.astra.Plane) | com.orbbec.astra.Plane | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • PointFrame
com.orbbec.astra.PointFrame Member List

This is the complete list of members for com.orbbec.astra.PointFrame, including all inherited members.

DataFrame(long handle) (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | inlineprotected
get(ReaderFrame readerFrame, int subtype) | com.orbbec.astra.PointFrame | inlinestatic
get(ReaderFrame readerFrame) | com.orbbec.astra.PointFrame | inlinestatic
getByteBuffer() | com.orbbec.astra.ImageFrame | inline
getBytesPerPixel() | com.orbbec.astra.ImageFrame | inline
getFrameIndex() | com.orbbec.astra.DataFrame | inline
getHeight() | com.orbbec.astra.ImageFrame | inline
getImageFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.ImageFrame) | com.orbbec.astra.ImageFrame | inlineprotectedstatic
getPixelFormat() | com.orbbec.astra.ImageFrame | inline
getPointBuffer() | com.orbbec.astra.PointFrame | inline
getWidth() | com.orbbec.astra.ImageFrame | inline
handle (defined in com.orbbec.astra.DataFrame) | com.orbbec.astra.DataFrame | protected
ImageFrame(long handle) (defined in com.orbbec.astra.ImageFrame) | com.orbbec.astra.ImageFrame | inlineprotected
isValid() | com.orbbec.astra.DataFrame | inline
STREAM_TYPE (defined in com.orbbec.astra.PointFrame) | com.orbbec.astra.PointFrame | static


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • PointStream
com.orbbec.astra.PointStream Member List

This is the complete list of members for com.orbbec.astra.PointStream, including all inherited members.

DataStream(long handle) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotected
get(StreamReader reader, int subtype) | com.orbbec.astra.PointStream | inlinestatic
get(StreamReader reader) | com.orbbec.astra.PointStream | inlinestatic
getFrameHandle(ReaderFrame frame, int type, int subtype) (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | inlineprotectedstatic
getIsAvailable() | com.orbbec.astra.DataStream | inline
getSubtype() | com.orbbec.astra.DataStream | inline
getType() | com.orbbec.astra.DataStream | inline
handle (defined in com.orbbec.astra.DataStream) | com.orbbec.astra.DataStream | protected
PointStream(long handle) (defined in com.orbbec.astra.PointStream) | com.orbbec.astra.PointStream | inlineprotected
start() | com.orbbec.astra.DataStream | inline
stop() | com.orbbec.astra.DataStream | inline
STREAM_TYPE (defined in com.orbbec.astra.PointStream) | com.orbbec.astra.PointStream | static


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • ReaderFrame
com.orbbec.astra.ReaderFrame Member List

This is the complete list of members for com.orbbec.astra.ReaderFrame, including all inherited members.

close() | com.orbbec.astra.ReaderFrame | inline
finalize() (defined in com.orbbec.astra.ReaderFrame) | com.orbbec.astra.ReaderFrame | inlineprotected


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • StreamDescription
com.orbbec.astra.StreamDescription Member List

This is the complete list of members for com.orbbec.astra.StreamDescription, including all inherited members.

getSubtype() | com.orbbec.astra.StreamDescription | inline
getType() | com.orbbec.astra.StreamDescription | inline
getTypeCode() | com.orbbec.astra.StreamDescription | inline
toString() | com.orbbec.astra.StreamDescription | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • StreamReader
com.orbbec.astra.StreamReader Member List

This is the complete list of members for com.orbbec.astra.StreamReader, including all inherited members.

addFrameListener(FrameListener listener) | com.orbbec.astra.StreamReader | inline
destroy() | com.orbbec.astra.StreamReader | inline
finalize() | com.orbbec.astra.StreamReader | inlineprotected
hasNewFrame() | com.orbbec.astra.StreamReader | inline
openFrame() | com.orbbec.astra.StreamReader | inline
removeFrameListener(FrameListener listener) | com.orbbec.astra.StreamReader | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • StreamSet
com.orbbec.astra.StreamSet Member List

This is the complete list of members for com.orbbec.astra.StreamSet, including all inherited members.

close() | com.orbbec.astra.StreamSet | inline
createReader() | com.orbbec.astra.StreamSet | inline
finalize() | com.orbbec.astra.StreamSet | inlineprotected
getIsAvailable() | com.orbbec.astra.StreamSet | inline
getUri() | com.orbbec.astra.StreamSet | inline
open(String connectionString) | com.orbbec.astra.StreamSet | inlinestatic
open() | com.orbbec.astra.StreamSet | inlinestatic


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • UsbDeviceInfo
com.orbbec.astra.UsbDeviceInfo Member List

This is the complete list of members for com.orbbec.astra.UsbDeviceInfo, including all inherited members.

getProductId() | com.orbbec.astra.UsbDeviceInfo | inline
getVendorId() | com.orbbec.astra.UsbDeviceInfo | inline
toString() | com.orbbec.astra.UsbDeviceInfo | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • Vector2D
com.orbbec.astra.Vector2D Member List

This is the complete list of members for com.orbbec.astra.Vector2D, including all inherited members.

getX() (defined in com.orbbec.astra.Vector2D) | com.orbbec.astra.Vector2D | inline
getY() (defined in com.orbbec.astra.Vector2D) | com.orbbec.astra.Vector2D | inline
setX(float x) (defined in com.orbbec.astra.Vector2D) | com.orbbec.astra.Vector2D | inline
setY(float y) (defined in com.orbbec.astra.Vector2D) | com.orbbec.astra.Vector2D | inline
toString() (defined in com.orbbec.astra.Vector2D) | com.orbbec.astra.Vector2D | inline
Vector2D(float x, float y) (defined in com.orbbec.astra.Vector2D) | com.orbbec.astra.Vector2D | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • Vector3D
com.orbbec.astra.Vector3D Member List

This is the complete list of members for com.orbbec.astra.Vector3D, including all inherited members.

getX() (defined in com.orbbec.astra.Vector3D) | com.orbbec.astra.Vector3D | inline
getY() (defined in com.orbbec.astra.Vector3D) | com.orbbec.astra.Vector3D | inline
getZ() (defined in com.orbbec.astra.Vector3D) | com.orbbec.astra.Vector3D | inline
setX(float x) (defined in com.orbbec.astra.Vector3D) | com.orbbec.astra.Vector3D | inline
setY(float y) (defined in com.orbbec.astra.Vector3D) | com.orbbec.astra.Vector3D | inline
setZ(float z) (defined in com.orbbec.astra.Vector3D) | com.orbbec.astra.Vector3D | inline
toString() (defined in com.orbbec.astra.Vector3D) | com.orbbec.astra.Vector3D | inline
Vector3D(float x, float y, float z) (defined in com.orbbec.astra.Vector3D) | com.orbbec.astra.Vector3D | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • android
  • AndroidCamera
com.orbbec.astra.android.AndroidCamera Member List

This is the complete list of members for com.orbbec.astra.android.AndroidCamera, including all inherited members.

closeCamera() (defined in com.orbbec.astra.android.AndroidCamera) | com.orbbec.astra.android.AndroidCamera | inline
getAvailableCameraModes() (defined in com.orbbec.astra.android.AndroidCamera) | com.orbbec.astra.android.AndroidCamera | inline
getCameraMode() (defined in com.orbbec.astra.android.AndroidCamera) | com.orbbec.astra.android.AndroidCamera | inline
getInstance() (defined in com.orbbec.astra.android.AndroidCamera) | com.orbbec.astra.android.AndroidCamera | inlinestatic
onPreviewFrame(byte[] data, Camera myCamera) (defined in com.orbbec.astra.android.AndroidCamera) | com.orbbec.astra.android.AndroidCamera | inline
openCamera() (defined in com.orbbec.astra.android.AndroidCamera) | com.orbbec.astra.android.AndroidCamera | inline
setCameraMode(ImageStreamMode mode) (defined in com.orbbec.astra.android.AndroidCamera) | com.orbbec.astra.android.AndroidCamera | inline
startCamera() (defined in com.orbbec.astra.android.AndroidCamera) | com.orbbec.astra.android.AndroidCamera | inline
stopCamera() (defined in com.orbbec.astra.android.AndroidCamera) | com.orbbec.astra.android.AndroidCamera | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • android
  • AstraAndroidContext
com.orbbec.astra.android.AstraAndroidContext Member List

This is the complete list of members for com.orbbec.astra.android.AstraAndroidContext, including all inherited members.

AstraAndroidContext(Context androidContext) | com.orbbec.astra.android.AstraAndroidContext | inline
AstraAndroidContext(Context androidContext, final AstraDeviceManagerListener listener) | com.orbbec.astra.android.AstraAndroidContext | inline
getAvailableDevicesSize() | com.orbbec.astra.android.AstraAndroidContext | inline
initialize() | com.orbbec.astra.android.AstraAndroidContext | inline
openAllDevices() | com.orbbec.astra.android.AstraAndroidContext | inline
set_android_context(Context appContext, String packageName) (defined in com.orbbec.astra.android.AstraAndroidContext) | com.orbbec.astra.android.AstraAndroidContext | static
terminate() | com.orbbec.astra.android.AstraAndroidContext | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • android
  • AstraDeviceManager
com.orbbec.astra.android.AstraDeviceManager Member List

This is the complete list of members for com.orbbec.astra.android.AstraDeviceManager, including all inherited members.

AstraDeviceManager(Context androidContext, AstraDeviceManagerListener listener) (defined in com.orbbec.astra.android.AstraDeviceManager) | com.orbbec.astra.android.AstraDeviceManager | inline
closeAllDevices() (defined in com.orbbec.astra.android.AstraDeviceManager) | com.orbbec.astra.android.AstraDeviceManager | inline
getAvailableDevices() (defined in com.orbbec.astra.android.AstraDeviceManager) | com.orbbec.astra.android.AstraDeviceManager | inline
getAvailableDevicesSize() (defined in com.orbbec.astra.android.AstraDeviceManager) | com.orbbec.astra.android.AstraDeviceManager | inline
openAllDevices() (defined in com.orbbec.astra.android.AstraDeviceManager) | com.orbbec.astra.android.AstraDeviceManager | inline
release() (defined in com.orbbec.astra.android.AstraDeviceManager) | com.orbbec.astra.android.AstraDeviceManager | inline
tryOpenDevice(UsbDevice device) (defined in com.orbbec.astra.android.AstraDeviceManager) | com.orbbec.astra.android.AstraDeviceManager | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • android
  • AstraDeviceMonitorActivity
com.orbbec.astra.android.AstraDeviceMonitorActivity Member List

This is the complete list of members for com.orbbec.astra.android.AstraDeviceMonitorActivity, including all inherited members.

ACTION_USB_DEVICE_ATTACHED (defined in com.orbbec.astra.android.AstraDeviceMonitorActivity) | com.orbbec.astra.android.AstraDeviceMonitorActivity | static
onCreate(Bundle savedInstanceState) (defined in com.orbbec.astra.android.AstraDeviceMonitorActivity) | com.orbbec.astra.android.AstraDeviceMonitorActivity | inline
onResume() (defined in com.orbbec.astra.android.AstraDeviceMonitorActivity) | com.orbbec.astra.android.AstraDeviceMonitorActivity | inlineprotected


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • android
  • UsbDeviceAccessBroker
com.orbbec.astra.android.UsbDeviceAccessBroker Member List

This is the complete list of members for com.orbbec.astra.android.UsbDeviceAccessBroker, including all inherited members.

open(UsbDevice device, UsbDeviceAccessEventListener listener) (defined in com.orbbec.astra.android.UsbDeviceAccessBroker) | com.orbbec.astra.android.UsbDeviceAccessBroker | inline
release() (defined in com.orbbec.astra.android.UsbDeviceAccessBroker) | com.orbbec.astra.android.UsbDeviceAccessBroker | inline
UsbDeviceAccessBroker(Context androidContext) (defined in com.orbbec.astra.android.UsbDeviceAccessBroker) | com.orbbec.astra.android.UsbDeviceAccessBroker | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • android
  • UsbDeviceInfo
com.orbbec.astra.android.UsbDeviceInfo Member List

This is the complete list of members for com.orbbec.astra.android.UsbDeviceInfo, including all inherited members.

equals(Object o) (defined in com.orbbec.astra.android.UsbDeviceInfo) | com.orbbec.astra.android.UsbDeviceInfo | inline
getDeviceName() (defined in com.orbbec.astra.android.UsbDeviceInfo) | com.orbbec.astra.android.UsbDeviceInfo | inline
getProductId() (defined in com.orbbec.astra.android.UsbDeviceInfo) | com.orbbec.astra.android.UsbDeviceInfo | inline
getVendorId() (defined in com.orbbec.astra.android.UsbDeviceInfo) | com.orbbec.astra.android.UsbDeviceInfo | inline
hashCode() (defined in com.orbbec.astra.android.UsbDeviceInfo) | com.orbbec.astra.android.UsbDeviceInfo | inline
toString() (defined in com.orbbec.astra.android.UsbDeviceInfo) | com.orbbec.astra.android.UsbDeviceInfo | inline
UsbDeviceInfo(int vendorId, int productId) (defined in com.orbbec.astra.android.UsbDeviceInfo) | com.orbbec.astra.android.UsbDeviceInfo | inline
UsbDeviceInfo(int vendorId, int productId, String deviceName) (defined in com.orbbec.astra.android.UsbDeviceInfo) | com.orbbec.astra.android.UsbDeviceInfo | inline


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • android
  • unity3d
  • AstraUnityPlayerActivity
com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity Member List

This is the complete list of members for com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity, including all inherited members.

AstraUnityPlayerActivity() (defined in com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity) | com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity | inline
Instance (defined in com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity) | com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity | static
onCreate(Bundle savedInstanceState) (defined in com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity) | com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity | inlineprotected
onDestroy() (defined in com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity) | com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity | inlineprotected
openAllDevices() (defined in com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity) | com.orbbec.astra.android.unity3d.AstraUnityPlayerActivity | inline


Astra SDK: java Directory Reference

  • wrappers
  • java
  • android
  • src
  • main
  • java
java Directory Reference


Astra SDK: Bindings Directory Reference

  • wrappers
  • dotnet
  • src
  • Bindings
Bindings Directory Reference


Astra SDK: src Directory Reference

  • wrappers
  • dotnet
  • src
src Directory Reference

Directories

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: capi Directory Reference

  • include
  • astra_core
  • capi
capi Directory Reference

Directories

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: com Directory Reference

  • wrappers
  • java
  • src
  • main
  • java
  • com
com Directory Reference


Astra SDK: dotnet Directory Reference

  • wrappers
  • dotnet
dotnet Directory Reference

Directories

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: wrappers Directory Reference

  • wrappers
wrappers Directory Reference


Astra SDK: src Directory Reference

  • wrappers
  • java
  • src
src Directory Reference


Astra SDK: Properties Directory Reference

  • wrappers
  • dotnet
  • src
  • Properties
Properties Directory Reference


Astra SDK: orbbec Directory Reference

  • wrappers
  • java
  • android
  • src
  • main
  • java
  • com
  • orbbec
orbbec Directory Reference


Astra SDK: java Directory Reference

  • wrappers
  • java
  • src
  • main
  • java
java Directory Reference


Astra SDK: astra Directory Reference

  • wrappers
  • java
  • src
  • main
  • java
  • com
  • orbbec
  • astra
astra Directory Reference


Astra SDK: com Directory Reference

  • wrappers
  • java
  • android
  • src
  • main
  • java
  • com
com Directory Reference


Astra SDK: unity3d Directory Reference

  • wrappers
  • java
  • android
  • src
  • main
  • java
  • com
  • orbbec
  • astra
  • android
  • unity3d
unity3d Directory Reference


Astra SDK: main Directory Reference

  • wrappers
  • java
  • android
  • src
  • main
main Directory Reference


Astra SDK: android Directory Reference

  • wrappers
  • java
  • android
  • src
  • main
  • java
  • com
  • orbbec
  • astra
  • android
android Directory Reference

Directories

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: capi Directory Reference

  • include
  • astra
  • capi
capi Directory Reference

Directories

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: astra Directory Reference

  • wrappers
  • java
  • android
  • src
  • main
  • java
  • com
  • orbbec
  • astra
astra Directory Reference

Directories

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: Core Directory Reference

  • wrappers
  • dotnet
  • src
  • Core
Core Directory Reference


Astra SDK: streams Directory Reference

  • include
  • astra
  • streams
streams Directory Reference


Astra SDK: main Directory Reference

  • wrappers
  • java
  • src
  • main
main Directory Reference


Astra SDK: astra_core Directory Reference

  • include
  • astra_core
astra_core Directory Reference

Directories

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: streams Directory Reference

  • include
  • astra
  • capi
  • streams
streams Directory Reference


Astra SDK: Extensions Directory Reference

  • wrappers
  • dotnet
  • src
  • Extensions
Extensions Directory Reference


Astra SDK: orbbec Directory Reference

  • wrappers
  • java
  • src
  • main
  • java
  • com
  • orbbec
orbbec Directory Reference

Directories

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: plugins Directory Reference

  • include
  • astra_core
  • capi
  • plugins
plugins Directory Reference


Astra SDK: java Directory Reference

  • wrappers
  • java
java Directory Reference


Astra SDK: include Directory Reference

  • include
include Directory Reference

Directories

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: astra Directory Reference

  • include
  • astra
astra Directory Reference

Directories

© 2018 Orbbec 3D All Rights Reserved.


Astra SDK: src Directory Reference

  • wrappers
  • java
  • android
  • src
src Directory Reference


Astra SDK: android Directory Reference

  • wrappers
  • java
  • android
android Directory Reference


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • ApiStatus
com.orbbec.astra.ApiStatus Member List

This is the complete list of members for com.orbbec.astra.ApiStatus, including all inherited members.

DEVICE_ERROR (defined in com.orbbec.astra.ApiStatus) | com.orbbec.astra.ApiStatus |
fromNativeStatus(int code) (defined in com.orbbec.astra.ApiStatus) | com.orbbec.astra.ApiStatus | inlinestatic
getCode() (defined in com.orbbec.astra.ApiStatus) | com.orbbec.astra.ApiStatus | inline
INTERNAL_ERROR (defined in com.orbbec.astra.ApiStatus) | com.orbbec.astra.ApiStatus |
INVALID_OPERATION (defined in com.orbbec.astra.ApiStatus) | com.orbbec.astra.ApiStatus |
INVALID_PARAMETER (defined in com.orbbec.astra.ApiStatus) | com.orbbec.astra.ApiStatus |
INVALID_PARAMETER_TOKEN (defined in com.orbbec.astra.ApiStatus) | com.orbbec.astra.ApiStatus |
SUCCESS (defined in com.orbbec.astra.ApiStatus) | com.orbbec.astra.ApiStatus |
throwIfError() (defined in com.orbbec.astra.ApiStatus) | com.orbbec.astra.ApiStatus | inline
TIMEOUT (defined in com.orbbec.astra.ApiStatus) | com.orbbec.astra.ApiStatus |
UNINITIALIZED (defined in com.orbbec.astra.ApiStatus) | com.orbbec.astra.ApiStatus |


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • BodyStatus
com.orbbec.astra.BodyStatus Member List

This is the complete list of members for com.orbbec.astra.BodyStatus, including all inherited members.

fromNativeCode(int code) | com.orbbec.astra.BodyStatus | inlinestatic
getCode() | com.orbbec.astra.BodyStatus | inline
LOST | com.orbbec.astra.BodyStatus |
NOT_TRACKING | com.orbbec.astra.BodyStatus |
TRACKING | com.orbbec.astra.BodyStatus |
TRACKING_STARTED | com.orbbec.astra.BodyStatus |


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • BodyTrackingFeatureFlags
com.orbbec.astra.BodyTrackingFeatureFlags Member List

This is the complete list of members for com.orbbec.astra.BodyTrackingFeatureFlags, including all inherited members.

BodyTrackingFeatureFlags(int code) (defined in com.orbbec.astra.BodyTrackingFeatureFlags) | com.orbbec.astra.BodyTrackingFeatureFlags | inline
getCode() (defined in com.orbbec.astra.BodyTrackingFeatureFlags) | com.orbbec.astra.BodyTrackingFeatureFlags | inline
HAND_POSES | com.orbbec.astra.BodyTrackingFeatureFlags |
hasHandPoses() | com.orbbec.astra.BodyTrackingFeatureFlags | inline
hasJoints() | com.orbbec.astra.BodyTrackingFeatureFlags | inline
hasSegmentation() | com.orbbec.astra.BodyTrackingFeatureFlags | inline
JOINTS | com.orbbec.astra.BodyTrackingFeatureFlags |
SEGMENTATION | com.orbbec.astra.BodyTrackingFeatureFlags |


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • HandPose
com.orbbec.astra.HandPose Member List

This is the complete list of members for com.orbbec.astra.HandPose, including all inherited members.

fromNativeCode(int code) (defined in com.orbbec.astra.HandPose) | com.orbbec.astra.HandPose | inlinestatic
getCode() (defined in com.orbbec.astra.HandPose) | com.orbbec.astra.HandPose | inline
GRIP | com.orbbec.astra.HandPose |
HandPose(int code) (defined in com.orbbec.astra.HandPose) | com.orbbec.astra.HandPose | inline
UNKNOWN | com.orbbec.astra.HandPose |


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • JointStatus
com.orbbec.astra.JointStatus Member List

This is the complete list of members for com.orbbec.astra.JointStatus, including all inherited members.

fromNativeCode(int code) (defined in com.orbbec.astra.JointStatus) | com.orbbec.astra.JointStatus | inlinestatic
getCode() (defined in com.orbbec.astra.JointStatus) | com.orbbec.astra.JointStatus | inline
LOW_CONFIDENCE | com.orbbec.astra.JointStatus |
NOT_TRACKED | com.orbbec.astra.JointStatus |
TRACKED | com.orbbec.astra.JointStatus |


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • JointType
com.orbbec.astra.JointType Member List

This is the complete list of members for com.orbbec.astra.JointType, including all inherited members.

[static initializer] (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType | inlinestatic
BASE_SPINE (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
getCode() (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType | inline
HEAD (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
JointType(int code) (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType | inline
LEFT_ELBOW (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
LEFT_FOOT (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
LEFT_HAND (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
LEFT_HIP (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
LEFT_KNEE (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
LEFT_SHOULDER (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
LEFT_WRIST (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
MID_SPINE (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
NECK (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
RIGHT_ELBOW (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
RIGHT_FOOT (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
RIGHT_HAND (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
RIGHT_HIP (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
RIGHT_KNEE (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
RIGHT_SHOULDER (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
RIGHT_WRIST (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
SHOULDER_SPINE (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |
UNKNOWN (defined in com.orbbec.astra.JointType) | com.orbbec.astra.JointType |


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • PixelFormat
com.orbbec.astra.PixelFormat Member List

This is the complete list of members for com.orbbec.astra.PixelFormat, including all inherited members.

DEPTH_MM (defined in com.orbbec.astra.PixelFormat) | com.orbbec.astra.PixelFormat |
fromNativeCode(int code) (defined in com.orbbec.astra.PixelFormat) | com.orbbec.astra.PixelFormat | inlinestatic
getBytesPerPixel() (defined in com.orbbec.astra.PixelFormat) | com.orbbec.astra.PixelFormat | inline
getCode() (defined in com.orbbec.astra.PixelFormat) | com.orbbec.astra.PixelFormat | inline
GRAY16 (defined in com.orbbec.astra.PixelFormat) | com.orbbec.astra.PixelFormat |
GRAY8 (defined in com.orbbec.astra.PixelFormat) | com.orbbec.astra.PixelFormat |
POINT (defined in com.orbbec.astra.PixelFormat) | com.orbbec.astra.PixelFormat |
RGB888 (defined in com.orbbec.astra.PixelFormat) | com.orbbec.astra.PixelFormat |
RGBA (defined in com.orbbec.astra.PixelFormat) | com.orbbec.astra.PixelFormat |
UNKNOWN (defined in com.orbbec.astra.PixelFormat) | com.orbbec.astra.PixelFormat |
YUV422 (defined in com.orbbec.astra.PixelFormat) | com.orbbec.astra.PixelFormat |
YUVY (defined in com.orbbec.astra.PixelFormat) | com.orbbec.astra.PixelFormat |


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • SkeletonOptimization
com.orbbec.astra.SkeletonOptimization Member List

This is the complete list of members for com.orbbec.astra.SkeletonOptimization, including all inherited members.

BALANCED | com.orbbec.astra.SkeletonOptimization |
BEST_ACCURACY | com.orbbec.astra.SkeletonOptimization |
fromNativeCode(int code) (defined in com.orbbec.astra.SkeletonOptimization) | com.orbbec.astra.SkeletonOptimization | inlinestatic
getCode() (defined in com.orbbec.astra.SkeletonOptimization) | com.orbbec.astra.SkeletonOptimization | inline
MINIMIZE_MEMORY | com.orbbec.astra.SkeletonOptimization |
OPTIMIZATION1 (defined in com.orbbec.astra.SkeletonOptimization) | com.orbbec.astra.SkeletonOptimization |
OPTIMIZATION2 (defined in com.orbbec.astra.SkeletonOptimization) | com.orbbec.astra.SkeletonOptimization |
OPTIMIZATION3 (defined in com.orbbec.astra.SkeletonOptimization) | com.orbbec.astra.SkeletonOptimization |
OPTIMIZATION4 (defined in com.orbbec.astra.SkeletonOptimization) | com.orbbec.astra.SkeletonOptimization |
OPTIMIZATION5 (defined in com.orbbec.astra.SkeletonOptimization) | com.orbbec.astra.SkeletonOptimization |
OPTIMIZATION6 (defined in com.orbbec.astra.SkeletonOptimization) | com.orbbec.astra.SkeletonOptimization |
OPTIMIZATION7 (defined in com.orbbec.astra.SkeletonOptimization) | com.orbbec.astra.SkeletonOptimization |
OPTIMIZATION8 (defined in com.orbbec.astra.SkeletonOptimization) | com.orbbec.astra.SkeletonOptimization |
OPTIMIZATION9 (defined in com.orbbec.astra.SkeletonOptimization) | com.orbbec.astra.SkeletonOptimization |


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • SkeletonProfile
com.orbbec.astra.SkeletonProfile Member List

This is the complete list of members for com.orbbec.astra.SkeletonProfile, including all inherited members.

BASIC | com.orbbec.astra.SkeletonProfile |
fromNativeCode(int code) (defined in com.orbbec.astra.SkeletonProfile) | com.orbbec.astra.SkeletonProfile | inlinestatic
FULL | com.orbbec.astra.SkeletonProfile |
getCode() (defined in com.orbbec.astra.SkeletonProfile) | com.orbbec.astra.SkeletonProfile | inline
UPPER_BODY | com.orbbec.astra.SkeletonProfile |


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • StreamType
com.orbbec.astra.StreamType Member List

This is the complete list of members for com.orbbec.astra.StreamType, including all inherited members.

BODY (defined in com.orbbec.astra.StreamType) | com.orbbec.astra.StreamType |
COLOR (defined in com.orbbec.astra.StreamType) | com.orbbec.astra.StreamType |
COLORIZED_BODY (defined in com.orbbec.astra.StreamType) | com.orbbec.astra.StreamType |
DEFAULT_SUBTYPE (defined in com.orbbec.astra.StreamType) | com.orbbec.astra.StreamType | static
DEPTH (defined in com.orbbec.astra.StreamType) | com.orbbec.astra.StreamType |
fromNativeStatus(int code) (defined in com.orbbec.astra.StreamType) | com.orbbec.astra.StreamType | inlinestatic
getCode() (defined in com.orbbec.astra.StreamType) | com.orbbec.astra.StreamType | inline
HAND (defined in com.orbbec.astra.StreamType) | com.orbbec.astra.StreamType |
INFRARED (defined in com.orbbec.astra.StreamType) | com.orbbec.astra.StreamType |
MASKED_COLOR (defined in com.orbbec.astra.StreamType) | com.orbbec.astra.StreamType |
POINT (defined in com.orbbec.astra.StreamType) | com.orbbec.astra.StreamType |
STYLIZED_DEPTH (defined in com.orbbec.astra.StreamType) | com.orbbec.astra.StreamType |
UNKNOWN (defined in com.orbbec.astra.StreamType) | com.orbbec.astra.StreamType |


Astra SDK: The First Group

Classes | Functions
The First Group

Classes

class | C1
class C1 in group 1 More...
class | C2
class C2 in group 1 More...

Functions

void | func ()
void | func2 ()
void | func3 ()

Detailed Description

This is the first group

More documentation for the first group.

Function Documentation

◆ func()

void func ( )

function in group 1

◆ func2()

void func2 ( )

another function in group 1

◆ func3()

void func3 ( )

yet another function in group 1


Astra SDK: The Second Group

Classes
The Second Group

Classes

class | C3
class C3 in group 2 More...
class | C4
class C4 in group 2 More...

Detailed Description

This is the second group


Astra SDK: The Third Group

Modules | Files | Classes
The Third Group

Modules

The Fourth Group

Files

file astra_core.h
this file in group 3

Classes

class C5
class C5 in the third group. More...

Detailed Description

This is the third group


Astra SDK: The Fourth Group

Functions
The Fourth Group
The Third Group

Functions

int a ()

Detailed Description

Group 4 is a subgroup of group 3

Function Documentation

◆ a()

int a ( )

namespace N1 is in four groups

See also
The first group, The Second Group, The Third Group, The Fourth Group

Also see This is another section in group 5


Astra SDK: The Fifth Group

The Fifth Group

This is the fifth group

This is a section in group 5

Text of the first section

This is another section in group 5

Text of the second section


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • StreamReader
  • FrameListener
com.orbbec.astra.StreamReader.FrameListener Member List

This is the complete list of members for com.orbbec.astra.StreamReader.FrameListener, including all inherited members.

onFrameReady(StreamReader reader, ReaderFrame frame) com.orbbec.astra.StreamReader.FrameListener


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • android
  • AstraDeviceManagerListener
com.orbbec.astra.android.AstraDeviceManagerListener Member List

This is the complete list of members for com.orbbec.astra.android.AstraDeviceManagerListener, including all inherited members.

onNoDevice() | com.orbbec.astra.android.AstraDeviceManagerListener
onOpenAllDevicesCompleted(Iterable< UsbDevice > availableDevices) | com.orbbec.astra.android.AstraDeviceManagerListener
onOpenDeviceCompleted(UsbDevice device, boolean opened) | com.orbbec.astra.android.AstraDeviceManagerListener
onPermissionDenied(UsbDevice device) | com.orbbec.astra.android.AstraDeviceManagerListener


Astra SDK: Member List

  • com
  • orbbec
  • astra
  • android
  • UsbDeviceAccessBroker
  • UsbDeviceAccessEventListener
com.orbbec.astra.android.UsbDeviceAccessBroker.UsbDeviceAccessEventListener Member List

This is the complete list of members for com.orbbec.astra.android.UsbDeviceAccessBroker.UsbDeviceAccessEventListener, including all inherited members.

onDeviceOpened(UsbDevice device, UsbDeviceConnection connection) (defined in com.orbbec.astra.android.UsbDeviceAccessBroker.UsbDeviceAccessEventListener) | com.orbbec.astra.android.UsbDeviceAccessBroker.UsbDeviceAccessEventListener
onDeviceOpenFailed(UsbDevice device) (defined in com.orbbec.astra.android.UsbDeviceAccessBroker.UsbDeviceAccessEventListener) | com.orbbec.astra.android.UsbDeviceAccessBroker.UsbDeviceAccessEventListener
onPermissionDenied(UsbDevice device) (defined in com.orbbec.astra.android.UsbDeviceAccessBroker.UsbDeviceAccessEventListener) | com.orbbec.astra.android.UsbDeviceAccessBroker.UsbDeviceAccessEventListener


Astra SDK: Astra.Bindings Namespace Reference

  • Astra
  • Bindings
Classes | Functions
Astra.Bindings Namespace Reference

Classes

struct | Body
struct | BodyFrameInfo
struct | BodyList
class | FloorInfo
struct | HandPoseInfo
struct | ImageMetadataInternal
struct | ImageMode
class | Imports
struct | Joint
struct | Plane
struct | StreamDescription
struct | USBInfo

Functions

delegate void FrameReadyCallback (IntPtr clientTag, IntPtr readerHandle, IntPtr readerFrameHandle)


Astra SDK: Related Pages

Related Pages
Here is a list of all related documentation pages:
[detail level 12]
Overview
Introduction
Concepts
Architecture
Installation
Tutorials
▼ Samples
C
C++
▼ Legal stuff
Copyright
Acknowledgements
License
FAQ


Astra SDK: Member List

_astra_bitmapmask Member List

This is the complete list of members for _astra_bitmapmask, including all inherited members.

data | _astra_bitmapmask
height | _astra_bitmapmask
width | _astra_bitmapmask


Astra SDK: Member List

_astra_body Member List

This is the complete list of members for _astra_body, including all inherited members.

centerOfMass | _astra_body
features | _astra_body
handPoses | _astra_body
id | _astra_body
joints | _astra_body
status | _astra_body


Astra SDK: Member List

_astra_body_list Member List

This is the complete list of members for _astra_body_list, including all inherited members.

bodies | _astra_body_list
count | _astra_body_list


Astra SDK: Member List

_astra_bodyframe Member List

This is the complete list of members for _astra_bodyframe, including all inherited members.

ASTRA_ALIGN(32) astra_bodymask_t bodyMask (defined in _astra_bodyframe) | _astra_bodyframe
bodyList (defined in _astra_bodyframe) | _astra_bodyframe
floorInfo (defined in _astra_bodyframe) | _astra_bodyframe
frame (defined in _astra_bodyframe) | _astra_bodyframe
info (defined in _astra_bodyframe) | _astra_bodyframe
pad0 (defined in _astra_bodyframe) | _astra_bodyframe


Astra SDK: Member List

_astra_bodyframe_info Member List

This is the complete list of members for _astra_bodyframe_info, including all inherited members.

height | _astra_bodyframe_info
isEstimated | _astra_bodyframe_info
width | _astra_bodyframe_info


Astra SDK: Member List

_astra_bodyframe_wrapper Member List

This is the complete list of members for _astra_bodyframe_wrapper, including all inherited members.

frame (defined in _astra_bodyframe_wrapper) | _astra_bodyframe_wrapper
frame_data (defined in _astra_bodyframe_wrapper) | _astra_bodyframe_wrapper


Astra SDK: Member List

_astra_floor_info Member List

This is the complete list of members for _astra_floor_info, including all inherited members.

floorDetected | _astra_floor_info
floorMask | _astra_floor_info
floorPlane | _astra_floor_info


Astra SDK: Member List

_astra_frame Member List

This is the complete list of members for _astra_frame, including all inherited members.

byteLength (defined in _astra_frame) | _astra_frame
data (defined in _astra_frame) | _astra_frame
frameIndex (defined in _astra_frame) | _astra_frame
pad0 (defined in _astra_frame) | _astra_frame


Astra SDK: Member List

_astra_handframe Member List

This is the complete list of members for _astra_handframe, including all inherited members.

frame (defined in _astra_handframe) | _astra_handframe
handCount (defined in _astra_handframe) | _astra_handframe
handpoints (defined in _astra_handframe) | _astra_handframe
pad0 (defined in _astra_handframe) | _astra_handframe
pad1 (defined in _astra_handframe) | _astra_handframe


Astra SDK: Member List

_astra_handframe_wrapper Member List

This is the complete list of members for _astra_handframe_wrapper, including all inherited members.

frame (defined in _astra_handframe_wrapper) | _astra_handframe_wrapper
frame_data (defined in _astra_handframe_wrapper) | _astra_handframe_wrapper


Astra SDK: Member List

_astra_handpose_info Member List

This is the complete list of members for _astra_handpose_info, including all inherited members.

leftHand (defined in _astra_handpose_info) | _astra_handpose_info
rightHand (defined in _astra_handpose_info) | _astra_handpose_info


Astra SDK: Member List

_astra_imageframe Member List

This is the complete list of members for _astra_imageframe, including all inherited members.

data (defined in _astra_imageframe) | _astra_imageframe
frame (defined in _astra_imageframe) | _astra_imageframe
metadata (defined in _astra_imageframe) | _astra_imageframe
pad0 (defined in _astra_imageframe) | _astra_imageframe
pad1 (defined in _astra_imageframe) | _astra_imageframe


Astra SDK: Member List

_astra_imageframe_wrapper Member List

This is the complete list of members for _astra_imageframe_wrapper, including all inherited members.

ASTRA_ALIGN(32) char frame_data[] (defined in _astra_imageframe_wrapper) | _astra_imageframe_wrapper
frame (defined in _astra_imageframe_wrapper) | _astra_imageframe_wrapper


Astra SDK: Member List

_astra_joint Member List

This is the complete list of members for _astra_joint, including all inherited members.

depthPosition | _astra_joint
orientation | _astra_joint
status | _astra_joint
type | _astra_joint
worldPosition | _astra_joint


Astra SDK: Member List

_astra_matrix3x3 Member List

This is the complete list of members for _astra_matrix3x3, including all inherited members.

m00 (defined in _astra_matrix3x3) | _astra_matrix3x3
m01 (defined in _astra_matrix3x3) | _astra_matrix3x3
m02 (defined in _astra_matrix3x3) | _astra_matrix3x3
m10 (defined in _astra_matrix3x3) | _astra_matrix3x3
m11 (defined in _astra_matrix3x3) | _astra_matrix3x3
m12 (defined in _astra_matrix3x3) | _astra_matrix3x3
m20 (defined in _astra_matrix3x3) | _astra_matrix3x3
m21 (defined in _astra_matrix3x3) | _astra_matrix3x3
m22 (defined in _astra_matrix3x3) | _astra_matrix3x3
xAxis (defined in _astra_matrix3x3) | _astra_matrix3x3
yAxis (defined in _astra_matrix3x3) | _astra_matrix3x3
zAxis (defined in _astra_matrix3x3) | _astra_matrix3x3


Astra SDK: Member List

_astra_plane Member List

This is the complete list of members for _astra_plane, including all inherited members.

a | _astra_plane
b | _astra_plane
c | _astra_plane
d | _astra_plane


Astra SDK: Member List

_astra_reader_callback_id Member List

This is the complete list of members for _astra_reader_callback_id, including all inherited members.

callbackId (defined in _astra_reader_callback_id) | _astra_reader_callback_id
reader (defined in _astra_reader_callback_id) | _astra_reader_callback_id


Astra SDK: Member List

_astra_streamconnection Member List

This is the complete list of members for _astra_streamconnection, including all inherited members.

desc (defined in _astra_streamconnection) | _astra_streamconnection
handle (defined in _astra_streamconnection) | _astra_streamconnection


Astra SDK: Member List

  • Astra
  • BodyFrameInfo
Astra.BodyFrameInfo Member List

This is the complete list of members for Astra.BodyFrameInfo, including all inherited members.

BodyFrameInfo(int width, int height, bool isEstimated) (defined in Astra.BodyFrameInfo) | Astra.BodyFrameInfo | inline
Height (defined in Astra.BodyFrameInfo) | Astra.BodyFrameInfo |
IsEstimated (defined in Astra.BodyFrameInfo) | Astra.BodyFrameInfo |
Width (defined in Astra.BodyFrameInfo) | Astra.BodyFrameInfo |


Astra SDK: Member List

  • Astra
  • Core
  • ImageMetadata
Astra.Core.ImageMetadata Member List

This is the complete list of members for Astra.Core.ImageMetadata, including all inherited members.

Height (defined in Astra.Core.ImageMetadata) | Astra.Core.ImageMetadata |
ImageMetadata(int width, int height, PixelFormat pixelFormat) (defined in Astra.Core.ImageMetadata) | Astra.Core.ImageMetadata | inline
PixelFormat (defined in Astra.Core.ImageMetadata) | Astra.Core.ImageMetadata |
Width (defined in Astra.Core.ImageMetadata) | Astra.Core.ImageMetadata |


Astra SDK: Member List

  • Astra
  • HandPoseInfo
Astra.HandPoseInfo Member List

This is the complete list of members for Astra.HandPoseInfo, including all inherited members.

HandPoseInfo(HandPose leftHand, HandPose rightHand) (defined in Astra.HandPoseInfo) | Astra.HandPoseInfo | inline
LeftHand (defined in Astra.HandPoseInfo) | Astra.HandPoseInfo |
RightHand (defined in Astra.HandPoseInfo) | Astra.HandPoseInfo |


Astra SDK: Member List

  • Astra
  • Matrix3x3
Astra.Matrix3x3 Member List

This is the complete list of members for Astra.Matrix3x3, including all inherited members.

AxisX | Astra.Matrix3x3
AxisY | Astra.Matrix3x3
AxisZ | Astra.Matrix3x3
M00 (defined in Astra.Matrix3x3) | Astra.Matrix3x3
M01 (defined in Astra.Matrix3x3) | Astra.Matrix3x3
M02 (defined in Astra.Matrix3x3) | Astra.Matrix3x3
M10 (defined in Astra.Matrix3x3) | Astra.Matrix3x3
M11 (defined in Astra.Matrix3x3) | Astra.Matrix3x3
M12 (defined in Astra.Matrix3x3) | Astra.Matrix3x3
M20 (defined in Astra.Matrix3x3) | Astra.Matrix3x3
M21 (defined in Astra.Matrix3x3) | Astra.Matrix3x3
M22 (defined in Astra.Matrix3x3) | Astra.Matrix3x3


Astra SDK: Member List

  • Astra
  • Vector2D
Astra.Vector2D Member List

This is the complete list of members for Astra.Vector2D, including all inherited members.

ToString() (defined in Astra.Vector2D) | Astra.Vector2D | inline
Vector2D(float x, float y) (defined in Astra.Vector2D) | Astra.Vector2D | inline
X (defined in Astra.Vector2D) | Astra.Vector2D |
Y (defined in Astra.Vector2D) | Astra.Vector2D |


Astra SDK: Member List

  • Astra
  • Vector3D
Astra.Vector3D Member List

This is the complete list of members for Astra.Vector3D, including all inherited members.

ToString() (defined in Astra.Vector3D) | Astra.Vector3D | inline
Vector3D(float x, float y, float z) (defined in Astra.Vector3D) | Astra.Vector3D | inline
X (defined in Astra.Vector3D) | Astra.Vector3D |
Y (defined in Astra.Vector3D) | Astra.Vector3D |
Z (defined in Astra.Vector3D) | Astra.Vector3D |


Astra SDK: Member List

  • astra
  • _Unique_if
astra::_Unique_if< _Ty > Member List

This is the complete list of members for astra::_Unique_if< _Ty >, including all inherited members.

_Single_object typedef (defined in astra::_Unique_if< _Ty >) astra::_Unique_if< _Ty >


Astra SDK: Member List

  • astra
  • _Unique_if< _Ty[]>
astra::_Unique_if< _Ty[]> Member List

This is the complete list of members for astra::_Unique_if< _Ty[]>, including all inherited members.

_Unknown_bound typedef (defined in astra::_Unique_if< _Ty[]>) astra::_Unique_if< _Ty[]>


Astra SDK: Member List

  • astra
  • _Unique_if< _Ty[N]>
astra::_Unique_if< _Ty[N]> Member List

This is the complete list of members for astra::_Unique_if< _Ty[N]>, including all inherited members.

_Known_bound typedef (defined in astra::_Unique_if< _Ty[N]>) astra::_Unique_if< _Ty[N]>


Astra SDK: Member List

  • astra
  • Matrix3x3
astra::Matrix3x3 Member List

This is the complete list of members for astra::Matrix3x3, including all inherited members.

Joint (defined in astra::Matrix3x3) | astra::Matrix3x3 | friend
m00() const | astra::Matrix3x3 | inline
m00 (defined in _astra_matrix3x3) | _astra_matrix3x3 | private
m01() const | astra::Matrix3x3 | inline
m01 (defined in _astra_matrix3x3) | _astra_matrix3x3 | private
m02() const | astra::Matrix3x3 | inline
m02 (defined in _astra_matrix3x3) | _astra_matrix3x3 | private
m10() const | astra::Matrix3x3 | inline
m10 (defined in _astra_matrix3x3) | _astra_matrix3x3 | private
m11() const | astra::Matrix3x3 | inline
m11 (defined in _astra_matrix3x3) | _astra_matrix3x3 | private
m12() const | astra::Matrix3x3 | inline
m12 (defined in _astra_matrix3x3) | _astra_matrix3x3 | private
m20() const | astra::Matrix3x3 | inline
m20 (defined in _astra_matrix3x3) | _astra_matrix3x3 | private
m21() const | astra::Matrix3x3 | inline
m21 (defined in _astra_matrix3x3) | _astra_matrix3x3 | private
m22() const | astra::Matrix3x3 | inline
m22 (defined in _astra_matrix3x3) | _astra_matrix3x3 | private
Matrix3x3() | astra::Matrix3x3 | inline
x_axis() const | astra::Matrix3x3 | inline
xAxis (defined in _astra_matrix3x3) | _astra_matrix3x3 | private
y_axis() const | astra::Matrix3x3 | inline
yAxis (defined in _astra_matrix3x3) | _astra_matrix3x3 | private
z_axis() const | astra::Matrix3x3 | inline
zAxis (defined in _astra_matrix3x3) | _astra_matrix3x3 | private


Astra SDK: Member List

  • astra
  • RgbPixel
astra::RgbPixel Member List

This is the complete list of members for astra::RgbPixel, including all inherited members.

b (defined in astra_rgb_pixel_t) | astra_rgb_pixel_t |
g (defined in astra_rgb_pixel_t) | astra_rgb_pixel_t |
r (defined in astra_rgb_pixel_t) | astra_rgb_pixel_t |
RgbPixel() | astra::RgbPixel | inline
RgbPixel(std::uint8_t r, std::uint8_t g, std::uint8_t b) | astra::RgbPixel | inline


Astra SDK: Member List

  • astra
  • RgbaPixel
astra::RgbaPixel Member List

This is the complete list of members for astra::RgbaPixel, including all inherited members.

alpha (defined in astra_rgba_pixel_t) | astra_rgba_pixel_t |
b (defined in astra_rgba_pixel_t) | astra_rgba_pixel_t |
g (defined in astra_rgba_pixel_t) | astra_rgba_pixel_t |
r (defined in astra_rgba_pixel_t) | astra_rgba_pixel_t |
RgbaPixel() | astra::RgbaPixel | inline
RgbaPixel(std::uint8_t r, std::uint8_t g, std::uint8_t b, std::uint8_t alpha) | astra::RgbaPixel | inline


Astra SDK: Member List

  • astra
  • Vector2f
astra::Vector2f Member List

This is the complete list of members for astra::Vector2f, including all inherited members.

dot(const Vector2f &v) const | astra::Vector2f | inline
is_zero() const | astra::Vector2f | inline
length() const | astra::Vector2f | inline
length_squared() const | astra::Vector2f | inline
normalize(Vector2f v) | astra::Vector2f | inlinestatic
operator const ::astra_vector2f_t *() const (defined in astra::Vector2f) | astra::Vector2f | inline
operator* (defined in astra::Vector2f) | astra::Vector2f | friend
operator* (defined in astra::Vector2f) | astra::Vector2f | friend
operator*=(const float &rhs) (defined in astra::Vector2f) | astra::Vector2f | inline
operator+ (defined in astra::Vector2f) | astra::Vector2f | friend
operator+=(const Vector2f &rhs) (defined in astra::Vector2f) | astra::Vector2f | inline
operator- (defined in astra::Vector2f) | astra::Vector2f | friend
operator-() (defined in astra::Vector2f) | astra::Vector2f | inline
operator-=(const Vector2f &rhs) (defined in astra::Vector2f) | astra::Vector2f | inline
operator/ (defined in astra::Vector2f) | astra::Vector2f | friend
operator/=(const float &rhs) (defined in astra::Vector2f) | astra::Vector2f | inline
operator::astra_vector2f_t *() (defined in astra::Vector2f) | astra::Vector2f | inline
operator=(const astra_vector2f_t &rhs) | astra::Vector2f | inline
operator== (defined in astra::Vector2f) | astra::Vector2f | friend
Vector2f() | astra::Vector2f | inline
Vector2f(const astra_vector2f_t &v) | astra::Vector2f | inline
Vector2f(float x, float y) | astra::Vector2f | inline
x (defined in astra_vector2f_t) | astra_vector2f_t |
y (defined in astra_vector2f_t) | astra_vector2f_t |
zero() | astra::Vector2f | inlinestatic


Astra SDK: Member List

  • astra
  • Vector2i
astra::Vector2i Member List

This is the complete list of members for astra::Vector2i, including all inherited members.

dot(const Vector2i &v) const | astra::Vector2i | inline
is_zero() const | astra::Vector2i | inline
length() const | astra::Vector2i | inline
length_squared() const | astra::Vector2i | inline
normalize(const Vector2i &v) | astra::Vector2i | inlinestatic
operator const ::astra_vector2i_t *() const (defined in astra::Vector2i) | astra::Vector2i | inline
operator* (defined in astra::Vector2i) | astra::Vector2i | friend
operator* (defined in astra::Vector2i) | astra::Vector2i | friend
operator*=(const std::int32_t rhs) (defined in astra::Vector2i) | astra::Vector2i | inline
operator+ (defined in astra::Vector2i) | astra::Vector2i | friend
operator+=(const Vector2i &rhs) (defined in astra::Vector2i) | astra::Vector2i | inline
operator- (defined in astra::Vector2i) | astra::Vector2i | friend
operator-() (defined in astra::Vector2i) | astra::Vector2i | inline
operator-=(const Vector2i &rhs) (defined in astra::Vector2i) | astra::Vector2i | inline
operator/ (defined in astra::Vector2i) | astra::Vector2i | friend
operator/=(const std::int32_t rhs) (defined in astra::Vector2i) | astra::Vector2i | inline
operator::astra_vector2i_t *() (defined in astra::Vector2i) | astra::Vector2i | inline
operator=(const astra_vector2i_t &rhs) | astra::Vector2i | inline
operator== (defined in astra::Vector2i) | astra::Vector2i | friend
Vector2i() | astra::Vector2i | inline
Vector2i(const astra_vector2i_t &v) | astra::Vector2i | inline
Vector2i(int x, int y) | astra::Vector2i | inline
x (defined in astra_vector2i_t) | astra_vector2i_t |
y (defined in astra_vector2i_t) | astra_vector2i_t |
zero() | astra::Vector2i | inlinestatic


Astra SDK: Member List

  • astra
  • Vector3f
astra::Vector3f Member List

This is the complete list of members for astra::Vector3f, including all inherited members.

cross(const Vector3f &v) const | astra::Vector3f | inline
dot(const Vector3f &v) const | astra::Vector3f | inline
is_zero() const | astra::Vector3f | inline
length() const | astra::Vector3f | inline
length_squared() const | astra::Vector3f | inline
normalize(Vector3f v) | astra::Vector3f | inlinestatic
operator const ::astra_vector3f_t *() const (defined in astra::Vector3f) | astra::Vector3f | inline
operator!= (defined in astra::Vector3f) | astra::Vector3f | friend
operator* (defined in astra::Vector3f) | astra::Vector3f | friend
operator* (defined in astra::Vector3f) | astra::Vector3f | friend
operator*=(const float &rhs) (defined in astra::Vector3f) | astra::Vector3f | inline
operator+ (defined in astra::Vector3f) | astra::Vector3f | friend
operator+=(const Vector3f &rhs) (defined in astra::Vector3f) | astra::Vector3f | inline
operator- (defined in astra::Vector3f) | astra::Vector3f | friend
operator-() (defined in astra::Vector3f) | astra::Vector3f | inline
operator-=(const Vector3f &rhs) (defined in astra::Vector3f) | astra::Vector3f | inline
operator/ (defined in astra::Vector3f) | astra::Vector3f | friend
operator/=(const float &rhs) (defined in astra::Vector3f) | astra::Vector3f | inline
operator::astra_vector3f_t *() (defined in astra::Vector3f) | astra::Vector3f | inline
operator=(const astra_vector3f_t &rhs) | astra::Vector3f | inline
operator== (defined in astra::Vector3f) | astra::Vector3f | friend
Vector3f() | astra::Vector3f | inline
Vector3f(const astra_vector3f_t &v) | astra::Vector3f | inline
Vector3f(float x, float y, float z) | astra::Vector3f | inline
x (defined in astra_vector3f_t) | astra_vector3f_t |
y (defined in astra_vector3f_t) | astra_vector3f_t |
z (defined in astra_vector3f_t) | astra_vector3f_t |
zero() | astra::Vector3f | inlinestatic


Astra SDK: Member List

  • astra
  • Vector3i
astra::Vector3i Member List

This is the complete list of members for astra::Vector3i, including all inherited members.

cross(const Vector3i &v) const | astra::Vector3i | inline
dot(const Vector3i &v) const | astra::Vector3i | inline
is_zero() const | astra::Vector3i | inline
length() const | astra::Vector3i | inline
length_squared() const | astra::Vector3i | inline
normalize(const Vector3i &v) | astra::Vector3i | inlinestatic
operator const ::astra_vector3i_t *() const (defined in astra::Vector3i) | astra::Vector3i | inline
operator!= (defined in astra::Vector3i) | astra::Vector3i | friend
operator* (defined in astra::Vector3i) | astra::Vector3i | friend
operator* (defined in astra::Vector3i) | astra::Vector3i | friend
operator*=(const std::int32_t rhs) (defined in astra::Vector3i) | astra::Vector3i | inline
operator+ (defined in astra::Vector3i) | astra::Vector3i | friend
operator+=(const Vector3i &rhs) (defined in astra::Vector3i) | astra::Vector3i | inline
operator- (defined in astra::Vector3i) | astra::Vector3i | friend
operator-() (defined in astra::Vector3i) | astra::Vector3i | inline
operator-=(const Vector3i &rhs) (defined in astra::Vector3i) | astra::Vector3i | inline
operator/ (defined in astra::Vector3i) | astra::Vector3i | friend
operator/=(const std::int32_t rhs) (defined in astra::Vector3i) | astra::Vector3i | inline
operator::astra_vector3i_t *() (defined in astra::Vector3i) | astra::Vector3i | inline
operator=(const astra_vector3i_t &rhs) | astra::Vector3i | inline
operator== (defined in astra::Vector3i) | astra::Vector3i | friend
Vector3i() | astra::Vector3i | inline
Vector3i(const astra_vector3i_t &v) | astra::Vector3i | inline
Vector3i(int x, int y, int z) | astra::Vector3i | inline
x (defined in astra_vector3i_t) | astra_vector3i_t |
y (defined in astra_vector3i_t) | astra_vector3i_t |
z (defined in astra_vector3i_t) | astra_vector3i_t |
zero() | astra::Vector3i | inlinestatic


Astra SDK: Member List

astra_body_feature_command_t Member List

This is the complete list of members for astra_body_feature_command_t, including all inherited members.

bodyId (defined in astra_body_feature_command_t) | astra_body_feature_command_t
feature (defined in astra_body_feature_command_t) | astra_body_feature_command_t


Astra SDK: Member List

astra_conversion_cache_t Member List

This is the complete list of members for astra_conversion_cache_t, including all inherited members.

coeffX (defined in astra_conversion_cache_t) | astra_conversion_cache_t
coeffY (defined in astra_conversion_cache_t) | astra_conversion_cache_t
halfResX (defined in astra_conversion_cache_t) | astra_conversion_cache_t
halfResY (defined in astra_conversion_cache_t) | astra_conversion_cache_t
resolutionX (defined in astra_conversion_cache_t) | astra_conversion_cache_t
resolutionY (defined in astra_conversion_cache_t) | astra_conversion_cache_t
xzFactor (defined in astra_conversion_cache_t) | astra_conversion_cache_t
yzFactor (defined in astra_conversion_cache_t) | astra_conversion_cache_t


Astra SDK: Member List

astra_handpoint_t Member List

This is the complete list of members for astra_handpoint_t, including all inherited members.

depthPosition (defined in astra_handpoint_t) | astra_handpoint_t
status (defined in astra_handpoint_t) | astra_handpoint_t
trackingId (defined in astra_handpoint_t) | astra_handpoint_t
worldDeltaPosition (defined in astra_handpoint_t) | astra_handpoint_t
worldPosition (defined in astra_handpoint_t) | astra_handpoint_t


Astra SDK: Member List

astra_image_metadata_t Member List

This is the complete list of members for astra_image_metadata_t, including all inherited members.

height (defined in astra_image_metadata_t) | astra_image_metadata_t
pixelFormat (defined in astra_image_metadata_t) | astra_image_metadata_t
width (defined in astra_image_metadata_t) | astra_image_metadata_t


Astra SDK: Member List

astra_imagestream_mode_t Member List

This is the complete list of members for astra_imagestream_mode_t, including all inherited members.

fps (defined in astra_imagestream_mode_t) | astra_imagestream_mode_t
height (defined in astra_imagestream_mode_t) | astra_imagestream_mode_t
id (defined in astra_imagestream_mode_t) | astra_imagestream_mode_t
pixelFormat (defined in astra_imagestream_mode_t) | astra_imagestream_mode_t
width (defined in astra_imagestream_mode_t) | astra_imagestream_mode_t


Astra SDK: Member List

astra_plugin_info_t Member List

This is the complete list of members for astra_plugin_info_t, including all inherited members.

versionInfo (defined in astra_plugin_info_t) astra_plugin_info_t


Astra SDK: Member List

astra_pluginservice_proxy_t Member List

This is the complete list of members for astra_pluginservice_proxy_t, including all inherited members.

astra_bin_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_bin_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_bin_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_callback_id_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_callback_id_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_log_severity_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *register_stream_registered_callback)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *register_stream_unregistering_callback)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *register_host_event_callback)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *unregister_host_event_callback)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *unregister_stream_registered_callback)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *unregister_stream_unregistering_callback)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *create_stream_set)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *destroy_stream_set)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *get_streamset_uri)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *create_stream)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *register_stream)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *unregister_stream)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *destroy_stream)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *create_stream_bin)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *destroy_stream_bin)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *bin_has_connections)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *cycle_bin_buffers)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *link_connection_to_bin)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *get_parameter_bin)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_status_t(ASTRA_CALLBACK *log)(void * (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_stream_desc_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_stream_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_stream_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_stream_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_stream_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_streamconnection_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_streamset_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
astra_streamset_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
host_event_callback_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
int (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
pluginService (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
stream_callbacks_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
stream_registered_callback_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
stream_unregistering_callback_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
uint32_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
uint32_t (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t
va_list (defined in astra_pluginservice_proxy_t) | astra_pluginservice_proxy_t


Astra SDK: Member List

astra_rgb_pixel_t Member List

This is the complete list of members for astra_rgb_pixel_t, including all inherited members.

b (defined in astra_rgb_pixel_t) | astra_rgb_pixel_t
g (defined in astra_rgb_pixel_t) | astra_rgb_pixel_t
r (defined in astra_rgb_pixel_t) | astra_rgb_pixel_t


Astra SDK: Member List

astra_rgba_pixel_t Member List

This is the complete list of members for astra_rgba_pixel_t, including all inherited members.

alpha (defined in astra_rgba_pixel_t) | astra_rgba_pixel_t
b (defined in astra_rgba_pixel_t) | astra_rgba_pixel_t
g (defined in astra_rgba_pixel_t) | astra_rgba_pixel_t
r (defined in astra_rgba_pixel_t) | astra_rgba_pixel_t


Astra SDK: Member List

astra_stream_desc_t Member List

This is the complete list of members for astra_stream_desc_t, including all inherited members.

subtype (defined in astra_stream_desc_t) | astra_stream_desc_t
type (defined in astra_stream_desc_t) | astra_stream_desc_t


Astra SDK: Member List

astra_streamservice_proxy_t Member List

This is the complete list of members for astra_streamservice_proxy_t, including all inherited members.

astra_command_id (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_event_id (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_frame_ready_callback_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_parameter_data_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_parameter_data_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_parameter_data_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_parameter_id (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_parameter_id (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_reader_frame_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_reader_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_reader_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_reader_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_reader_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_result_token_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *notify_plugin_event)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *streamset_is_available)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *streamset_open)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *streamset_close)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *streamset_get_uri)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *reader_create)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *reader_destroy)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *reader_get_stream)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *stream_get_description)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *stream_is_available)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *stream_start)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *stream_stop)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *reader_has_new_frame)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *reader_open_frame)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *reader_close_frame)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *reader_register_frame_ready_callback)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *reader_unregister_frame_ready_callback)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *reader_get_frame)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *stream_set_parameter)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *stream_get_parameter)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *stream_get_result)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *stream_invoke)(void * (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_status_t(ASTRA_CALLBACK *update)(void *) (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_stream_subtype_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_stream_subtype_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_stream_type_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_stream_type_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_streamconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_streamconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_streamconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_streamconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_streamconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_streamconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_streamsetconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
astra_streamsetconnection_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
int (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
int32_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
streamService (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
uint32_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
uint32_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
uint32_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t
uint32_t (defined in astra_streamservice_proxy_t) | astra_streamservice_proxy_t


Astra SDK: Member List

astra_usb_info_t Member List

This is the complete list of members for astra_usb_info_t, including all inherited members.

pid (defined in astra_usb_info_t) | astra_usb_info_t
vid (defined in astra_usb_info_t) | astra_usb_info_t


Astra SDK: Member List

astra_vector2f_t Member List

This is the complete list of members for astra_vector2f_t, including all inherited members.

x (defined in astra_vector2f_t) | astra_vector2f_t
y (defined in astra_vector2f_t) | astra_vector2f_t


Astra SDK: Member List

astra_vector2i_t Member List

This is the complete list of members for astra_vector2i_t, including all inherited members.

x (defined in astra_vector2i_t) | astra_vector2i_t
y (defined in astra_vector2i_t) | astra_vector2i_t


Astra SDK: Member List

astra_vector3f_t Member List

This is the complete list of members for astra_vector3f_t, including all inherited members.

x (defined in astra_vector3f_t) | astra_vector3f_t
y (defined in astra_vector3f_t) | astra_vector3f_t
z (defined in astra_vector3f_t) | astra_vector3f_t


Astra SDK: Member List

astra_vector3i_t Member List

This is the complete list of members for astra_vector3i_t, including all inherited members.

x (defined in astra_vector3i_t) | astra_vector3i_t
y (defined in astra_vector3i_t) | astra_vector3i_t
z (defined in astra_vector3i_t) | astra_vector3i_t


Astra SDK: Member List

astra_version_info_t Member List

This is the complete list of members for astra_version_info_t, including all inherited members.

apiLevel (defined in astra_version_info_t) | astra_version_info_t
friendlyVersionString (defined in astra_version_info_t) | astra_version_info_t
gitCommitSha1 (defined in astra_version_info_t) | astra_version_info_t
majorVersion (defined in astra_version_info_t) | astra_version_info_t
minorVersion (defined in astra_version_info_t) | astra_version_info_t
patchVersion (defined in astra_version_info_t) | astra_version_info_t
versionSuffix (defined in astra_version_info_t) | astra_version_info_t


Astra SDK: Member List

stream_callbacks_t Member List

This is the complete list of members for stream_callbacks_t, including all inherited members.

connection_added_callback (defined in stream_callbacks_t) | stream_callbacks_t
connection_removed_callback (defined in stream_callbacks_t) | stream_callbacks_t
connection_started_callback (defined in stream_callbacks_t) | stream_callbacks_t
connection_stopped_callback (defined in stream_callbacks_t) | stream_callbacks_t
context (defined in stream_callbacks_t) | stream_callbacks_t
get_parameter_callback (defined in stream_callbacks_t) | stream_callbacks_t
invoke_callback (defined in stream_callbacks_t) | stream_callbacks_t
set_parameter_callback (defined in stream_callbacks_t) | stream_callbacks_t