Skip to content

Commit

Permalink
Merge pull request #1 from AutonomyLab/indigo-devel
Browse files Browse the repository at this point in the history
Bug fix during catkin build (AutonomyLab#164)
  • Loading branch information
lincolnxlw authored Jul 29, 2018
2 parents e00904c + b0cf0a7 commit 505ba79
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
5 changes: 5 additions & 0 deletions bebop_driver/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@
Changelog for package bebop_driver
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

0.7.1 (2018-05-31)
------------------
* Fixed the bug appearing when you run the catkin build command
* Contributors: Giuseppe Silano

0.7.0 (2017-07-29)
------------------
* SDK 3.12.6 support (except 64bit Ubuntu Xenial, working on fix)
Expand Down
2 changes: 1 addition & 1 deletion bebop_driver/package.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<package>
<name>bebop_driver</name>
<version>0.7.0</version>
<version>0.7.1</version>
<description>ROS driver for Parrot Bebop drone, based on Parrot’s official ARDroneSDK3</description>

<maintainer email="[email protected]">Mani Monajjemi</maintainer>
Expand Down
6 changes: 3 additions & 3 deletions bebop_driver/src/bebop_video_decoder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ bool VideoDecoder::ReallocateBuffers()
boost::lexical_cast<std::string>(codec_ctx_ptr_->width) +
" x " + boost::lexical_cast<std::string>(codec_ctx_ptr_->width));

const uint32_t num_bytes = avpicture_get_size(PIX_FMT_RGB24, codec_ctx_ptr_->width, codec_ctx_ptr_->width);
const uint32_t num_bytes = avpicture_get_size(AV_PIX_FMT_RGB24, codec_ctx_ptr_->width, codec_ctx_ptr_->width);
frame_rgb_ptr_ = av_frame_alloc();

ThrowOnCondition(!frame_rgb_ptr_, "Can not allocate memory for frames!");
Expand All @@ -143,12 +143,12 @@ bool VideoDecoder::ReallocateBuffers()
std::string("Can not allocate memory for the buffer: ") +
boost::lexical_cast<std::string>(num_bytes));
ThrowOnCondition(0 == avpicture_fill(
reinterpret_cast<AVPicture*>(frame_rgb_ptr_), frame_rgb_raw_ptr_, PIX_FMT_RGB24,
reinterpret_cast<AVPicture*>(frame_rgb_ptr_), frame_rgb_raw_ptr_, AV_PIX_FMT_RGB24,
codec_ctx_ptr_->width, codec_ctx_ptr_->height),
"Failed to initialize the picture data structure.");

img_convert_ctx_ptr_ = sws_getContext(codec_ctx_ptr_->width, codec_ctx_ptr_->height, codec_ctx_ptr_->pix_fmt,
codec_ctx_ptr_->width, codec_ctx_ptr_->height, PIX_FMT_RGB24,
codec_ctx_ptr_->width, codec_ctx_ptr_->height, AV_PIX_FMT_RGB24,
SWS_FAST_BILINEAR, NULL, NULL, NULL);
}
catch (const std::runtime_error& e)
Expand Down

0 comments on commit 505ba79

Please sign in to comment.