gazebo_ros_multicamera.h
Go to the documentation of this file.
00001 /*
00002  * Copyright 2012 Open Source Robotics Foundation
00003  *
00004  * Licensed under the Apache License, Version 2.0 (the "License");
00005  * you may not use this file except in compliance with the License.
00006  * You may obtain a copy of the License at
00007  *
00008  *     http://www.apache.org/licenses/LICENSE-2.0
00009  *
00010  * Unless required by applicable law or agreed to in writing, software
00011  * distributed under the License is distributed on an "AS IS" BASIS,
00012  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013  * See the License for the specific language governing permissions and
00014  * limitations under the License.
00015  *
00016 */
00017 
00018 #ifndef GAZEBO_ROS_MULTICAMERA_HH
00019 #define GAZEBO_ROS_MULTICAMERA_HH
00020 
00021 #include <string>
00022 #include <vector>
00023 
00024 // library for processing camera data for gazebo / ros conversions
00025 #include <gazebo_plugins/gazebo_ros_camera_utils.h>
00026 #include <gazebo_plugins/MultiCameraPlugin.h>
00027 
00028 namespace gazebo
00029 {
00030   class GazeboRosMultiCamera : public MultiCameraPlugin
00031   {
00034     public: GazeboRosMultiCamera();
00035 
00037     public: ~GazeboRosMultiCamera();
00038 
00041     public: void Load(sensors::SensorPtr _parent, sdf::ElementPtr _sdf);
00042 
00043     std::vector<GazeboRosCameraUtils*> utils;
00044 
00047     protected: virtual void OnNewFrameLeft(const unsigned char *_image,
00048                    unsigned int _width, unsigned int _height,
00049                    unsigned int _depth, const std::string &_format);
00050     protected: virtual void OnNewFrameRight(const unsigned char *_image,
00051                    unsigned int _width, unsigned int _height,
00052                    unsigned int _depth, const std::string &_format);
00053 
00057     private: boost::shared_ptr<int> image_connect_count_;
00058     private: boost::shared_ptr<boost::mutex> image_connect_count_lock_;
00059     private: boost::shared_ptr<bool> was_active_;
00060   };
00061 }
00062 #endif
00063 


gazebo_plugins
Author(s): John Hsu
autogenerated on Fri Aug 28 2015 10:47:25