Skip to content

Commit

Permalink
Reverting the GL support of Align-Depth filter
Browse files Browse the repository at this point in the history
  • Loading branch information
Arun-Prasad-V committed Jan 25, 2024
1 parent 73df46b commit 447f1e9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions realsense2_camera/src/base_realsense_node.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -239,15 +239,15 @@ void BaseRealSenseNode::setupFilters()
#if defined (ACCELERATE_WITH_GPU)
_colorizer_filter = std::make_shared<NamedFilter>(std::make_shared<rs2::gl::colorizer>(), _parameters, _logger);
_pc_filter = std::make_shared<PointcloudFilter>(std::make_shared<rs2::gl::pointcloud>(), _node, _parameters, _logger);
_align_depth_filter = std::make_shared<AlignDepthFilter>(std::make_shared<rs2::gl::align>(RS2_STREAM_COLOR), update_align_depth_func, _parameters, _logger);
#else
_colorizer_filter = std::make_shared<NamedFilter>(std::make_shared<rs2::colorizer>(), _parameters, _logger);
_pc_filter = std::make_shared<PointcloudFilter>(std::make_shared<rs2::pointcloud>(), _node, _parameters, _logger);
_align_depth_filter = std::make_shared<AlignDepthFilter>(std::make_shared<rs2::align>(RS2_STREAM_COLOR), update_align_depth_func, _parameters, _logger);
#endif

_filters.push_back(_colorizer_filter);
_filters.push_back(_pc_filter);

_align_depth_filter = std::make_shared<AlignDepthFilter>(std::make_shared<rs2::align>(RS2_STREAM_COLOR), update_align_depth_func, _parameters, _logger);
_filters.push_back(_align_depth_filter);
}

Expand Down
3 changes: 2 additions & 1 deletion realsense2_camera/src/gl_gpu_processing.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ void BaseRealSenseNode::initOpenGLProcessing(bool use_gpu_processing)
// Pass our window to enable sharing of textures between processed frames and the window
// The "use_gpu_processing" is going to control if we will use CPU or GPU for data processing
rs2::gl::init_processing(_app, use_gpu_processing);
rs2::gl::init_rendering();
if (use_gpu_processing)
rs2::gl::init_rendering();

_timer = _node.create_wall_timer(1000ms, std::bind(&BaseRealSenseNode::glfwPollEventCallback, this));
}
Expand Down

0 comments on commit 447f1e9

Please sign in to comment.