image.h
Go to the documentation of this file.
1 // License: Apache 2.0. See LICENSE file in root directory.
2 // Copyright(c) 2015 Intel Corporation. All Rights Reserved.
3 
4 #pragma once
5 #ifndef LIBREALSENSE_IMAGE_H
6 #define LIBREALSENSE_IMAGE_H
7 
8 #include "types.h"
9 
10 namespace rsimpl
11 {
12 
13  size_t get_image_size (int width, int height, rs_format format);
14  int get_image_bpp (rs_format format);
15  void deproject_z (float * points, const rs_intrinsics & z_intrin, const uint16_t * z_pixels, float z_scale);
16  void deproject_disparity (float * points, const rs_intrinsics & disparity_intrin, const uint16_t * disparity_pixels, float disparity_scale);
17 
18  void align_z_to_other (byte * z_aligned_to_other, const uint16_t * z_pixels, float z_scale, const rs_intrinsics & z_intrin,
19  const rs_extrinsics & z_to_other, const rs_intrinsics & other_intrin);
20  void align_disparity_to_other (byte * disparity_aligned_to_other, const uint16_t * disparity_pixels, float disparity_scale, const rs_intrinsics & disparity_intrin,
21  const rs_extrinsics & disparity_to_other, const rs_intrinsics & other_intrin);
22  void align_other_to_z (byte * other_aligned_to_z, const uint16_t * z_pixels, float z_scale, const rs_intrinsics & z_intrin,
23  const rs_extrinsics & z_to_other, const rs_intrinsics & other_intrin, const byte * other_pixels, rs_format other_format);
24  void align_other_to_disparity (byte * other_aligned_to_disparity, const uint16_t * disparity_pixels, float disparity_scale, const rs_intrinsics & disparity_intrin,
25  const rs_extrinsics & disparity_to_other, const rs_intrinsics & other_intrin, const byte * other_pixels, rs_format other_format);
26 
27  std::vector<int> compute_rectification_table (const rs_intrinsics & rect_intrin, const rs_extrinsics & rect_to_unrect, const rs_intrinsics & unrect_intrin);
28  void rectify_image (uint8_t * rect_pixels, const std::vector<int> & rectification_table, const uint8_t * unrect_pixels, rs_format format);
29 
30  extern const native_pixel_format pf_raw8; // Four 8 bit luminance
31  extern const native_pixel_format pf_rw10; // Four 10 bit luminance values in one 40 bit macropixel
32  extern const native_pixel_format pf_rw16; // 10 bit in 16 bit WORD with 6 bit unused
33  extern const native_pixel_format pf_yuy2; // Y0 U Y1 V ordered chroma subsampled macropixel
34  extern const native_pixel_format pf_y8; // 8 bit (left) IR image
35  extern const native_pixel_format pf_y8i; // 8 bits left IR + 8 bits right IR per pixel
36  extern const native_pixel_format pf_y16; // 16 bit (left) IR image
37  extern const native_pixel_format pf_y12i; // 12 bits left IR + 12 bits right IR per pixel
38  extern const native_pixel_format pf_z16; // 16 bit Z image
39  extern const native_pixel_format pf_invz; // 16 bit Z image
40  extern const native_pixel_format pf_f200_invi; // 8-bit IR image
41  extern const native_pixel_format pf_f200_inzi; // 16-bit Z + 8 bit IR per pixel
42  extern const native_pixel_format pf_sr300_invi; // 16-bit IR image
43  extern const native_pixel_format pf_sr300_inzi; // Planar 16-bit IR image followed by 16-bit Z image
44 }
45 
46 #endif
void align_other_to_z(byte *other_aligned_to_z, const uint16_t *z_pixels, float z_scale, const rs_intrinsics &z_intrin, const rs_extrinsics &z_to_other, const rs_intrinsics &other_intrin, const byte *other_pixels, rs_format other_format)
Definition: image.cpp:594
const native_pixel_format pf_sr300_invi
Definition: image.cpp:478
const native_pixel_format pf_rw10
Definition: image.cpp:461
GLint GLint GLsizei GLsizei height
Definition: glext.h:112
const native_pixel_format pf_y8i
Definition: image.cpp:469
void align_disparity_to_other(byte *disparity_aligned_to_other, const uint16_t *disparity_pixels, float disparity_scale, const rs_intrinsics &disparity_intrin, const rs_extrinsics &disparity_to_other, const rs_intrinsics &other_intrin)
Definition: image.cpp:560
const native_pixel_format pf_y12i
Definition: image.cpp:470
Definition: archive.h:12
int get_image_bpp(rs_format format)
Definition: image.cpp:29
const native_pixel_format pf_y16
Definition: image.cpp:468
void deproject_disparity(float *points, const rs_intrinsics &disparity_intrin, const uint16_t *disparity_pixels, float disparity_scale)
Definition: image.cpp:506
const native_pixel_format pf_y8
Definition: image.cpp:467
GLfixed GLfixed GLint GLint GLfixed points
Definition: glext.h:4927
const native_pixel_format pf_sr300_inzi
Definition: image.cpp:480
void deproject_z(float *points, const rs_intrinsics &z_intrin, const uint16_t *z_pixels, float z_scale)
Definition: image.cpp:501
rs_format
Formats: defines how each stream can be encoded.
Definition: rs.h:53
std::vector< int > compute_rectification_table(const rs_intrinsics &rect_intrin, const rs_extrinsics &rect_to_unrect, const rs_intrinsics &unrect_intrin)
Definition: image.cpp:608
const native_pixel_format pf_f200_inzi
Definition: image.cpp:476
const native_pixel_format pf_z16
Definition: image.cpp:471
Video stream intrinsics.
Definition: rs.h:300
Cross-stream extrinsics: encode the topology describing how the different devices are connected...
Definition: rs.h:332
const native_pixel_format pf_rw16
Definition: image.cpp:460
void align_z_to_other(byte *z_aligned_to_other, const uint16_t *z_pixels, float z_scale, const rs_intrinsics &z_intrin, const rs_extrinsics &z_to_other, const rs_intrinsics &other_intrin)
Definition: image.cpp:552
void rectify_image(uint8_t *rect_pixels, const std::vector< int > &rectification_table, const uint8_t *unrect_pixels, rs_format format)
Definition: image.cpp:622
uint8_t byte
Definition: types.h:42
GLint GLint GLsizei width
Definition: glext.h:112
size_t get_image_size(int width, int height, rs_format format)
Definition: image.cpp:22
GLint GLint GLsizei GLsizei GLsizei GLint GLenum format
Definition: glext.h:112
const native_pixel_format pf_yuy2
Definition: image.cpp:462
void align_other_to_disparity(byte *other_aligned_to_disparity, const uint16_t *disparity_pixels, float disparity_scale, const rs_intrinsics &disparity_intrin, const rs_extrinsics &disparity_to_other, const rs_intrinsics &other_intrin, const byte *other_pixels, rs_format other_format)
Definition: image.cpp:599
const native_pixel_format pf_f200_invi
Definition: image.cpp:474
const native_pixel_format pf_invz
Definition: image.cpp:473
const native_pixel_format pf_raw8
Definition: image.cpp:459


librealsense
Author(s): Sergey Dorodnicov , Mark Horn , Reagan Lopez
autogenerated on Fri Mar 13 2020 03:16:17