Skip to content
This repository has been archived by the owner on Jan 24, 2018. It is now read-only.

Commit

Permalink
HF 0.2.9
Browse files Browse the repository at this point in the history
  • Loading branch information
matkatz committed Sep 7, 2016
1 parent ca63bdd commit 1169e8a
Show file tree
Hide file tree
Showing 9 changed files with 29 additions and 11 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
[ ![Release] [release-image] ] [releases]
[ ![License] [license-image] ] [license]

[release-image]: http://img.shields.io/badge/release-0.2.7-blue.svg?style=flat
[release-image]: http://img.shields.io/badge/release-0.2.9-blue.svg?style=flat
[releases]: https://github.com/IntelRealSense/realsense_sdk

[license-image]: http://img.shields.io/badge/license-Apache--2-blue.svg?style=flat
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ void frame_handler(rs::frame new_frame)
info.width = new_frame.get_width();
info.height = new_frame.get_height();
info.format = rs::utils::convert_pixel_format(new_frame.get_format());
info.pitch = ( new_frame.get_bpp() / 8 ) * info.width;
info.pitch = new_frame.get_stride();

auto st_type = rs::utils::convert_stream_type(new_frame.get_stream_type());

Expand Down
2 changes: 1 addition & 1 deletion sdk/CMakeVersion
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
set(SDK_VERSION_MAJOR 0 )
set(SDK_VERSION_MINOR 2 )
set(SDK_VERSION_COMMIT_NUMBER 8 )
set(SDK_VERSION_COMMIT_NUMBER 9 )
set(SDK_VERSION_COMMIT_ID 0 )
2 changes: 1 addition & 1 deletion sdk/include/rs/core/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ namespace rs
int32_t width; /* width of the image in pixels */
int32_t height; /* height of the image in pixels */
pixel_format format; /* image pixel format */
int32_t pitch; /* pitch of the image in pixels, also known as stride*/
int32_t pitch; /* number of bytes in a single image row of pixels, also known as stride*/
};

struct pointI32
Expand Down
10 changes: 8 additions & 2 deletions sdk/include/rs_sdk_version.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2016 Intel Corporation. All Rights Reserved.
#pragma once

#define SDK_VER_MAJOR 0
#define SDK_VER_MINOR 2
#define SDK_VER_COMMIT_NUMBER 8
#define SDK_VER_COMMIT_NUMBER 9
#define SDK_VER_COMMIT_ID 0
#define SDK_VERSION_STRING static char version_id[] = "VERSION: 0.2.8.0";
#define SDK_VERSION_STRING static volatile char version_id[] = "VERSION: 0.2.9.0";

SDK_VERSION_STRING
3 changes: 2 additions & 1 deletion sdk/src/core/projection/projection_r200.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@
#include "image_utils.h"
#pragma warning (disable : 4068)
#include "math_projection_interface.h"

#include "rs_sdk_version.h"
#include "rs/utils/self_releasing_array_data_releaser.h"


using namespace rs::utils;

static void *aligned_malloc(int size);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2016 Intel Corporation. All Rights Reserved.

#include "rs_sdk_version.h"
#include <iostream>
#include <thread>
#include <cstring>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2016 Intel Corporation. All Rights Reserved.

#include "rs_sdk_version.h"
#include <iostream>
#include <thread>
#include <cstring>
Expand Down Expand Up @@ -179,13 +180,21 @@ namespace rs
//protect algorithm exception safety
try
{
const uint16_t * current_pixel = static_cast<const uint16_t * >(depth_image->query_data());
const uint8_t * current_pixel = static_cast<const uint8_t * >(depth_image->query_data());
auto depth_image_info = depth_image->query_info();
for(auto i = 0; i < depth_image_info.height * depth_image_info.pitch; i++)

for(auto y = 0; y < depth_image_info.height; y++)
{
if(current_pixel[i] > max_depth_value)
for(auto x = 0; x < depth_image_info.width; x+=2)
{
max_depth_value = current_pixel[i];
auto pixel_with_pitch_allignment = y * depth_image_info.pitch + x;
//combine 2 uint8_t to uint16_t
uint16_t current_pixel_value = current_pixel[pixel_with_pitch_allignment] | current_pixel[pixel_with_pitch_allignment + 1] << 8;

if(current_pixel_value > max_depth_value)
{
max_depth_value = current_pixel_value ;
}
}
}

Expand Down
1 change: 1 addition & 0 deletions sdk/src/utilities/logger/log_utils/log_utils.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
// License: Apache 2.0. See LICENSE file in root directory.
// Copyright(c) 2016 Intel Corporation. All Rights Reserved.
#include "rs_sdk_version.h"
#include "rs/utils/log_utils.h"
#include "rs/core/status.h"
#include "fstream"
Expand Down

0 comments on commit 1169e8a

Please sign in to comment.