Class
List
Heirarchy
Modules
Common
Events
Math
Messages
Physics
Rendering
Sensors
Transport
Links
Gazebo Website
Wiki
Tutorials
Download
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
gazebo
physics
ode
ODERayShape.hh
Go to the documentation of this file.
1
/*
2
* Copyright 2011 Nate Koenig
3
*
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
* you may not use this file except in compliance with the License.
6
* You may obtain a copy of the License at
7
*
8
* http://www.apache.org/licenses/LICENSE-2.0
9
*
10
* Unless required by applicable law or agreed to in writing, software
11
* distributed under the License is distributed on an "AS IS" BASIS,
12
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
* See the License for the specific language governing permissions and
14
* limitations under the License.
15
*
16
*/
17
/* Desc: A ray
18
* Author: Nate Koenig, Andrew Howard
19
* Date: 14 Oct 2009
20
*/
21
22
#ifndef ODERAYSHAPE_HH
23
#define ODERAYSHAPE_HH
24
25
#include <string>
26
27
#include "
physics/RayShape.hh
"
28
#include "
physics/Shape.hh
"
29
30
namespace
gazebo
31
{
32
namespace
physics
33
{
37
39
class
ODERayShape
:
public
RayShape
40
{
42
public
:
ODERayShape
(
PhysicsEnginePtr
_physicsEngine);
43
46
public
:
ODERayShape
(
CollisionPtr
collision);
47
49
public
:
virtual
~ODERayShape
();
50
52
public
:
virtual
void
Update
();
53
55
public
:
virtual
void
GetIntersection
(
double
&_dist,
56
std::string &_entity);
57
62
public
:
virtual
void
SetPoints
(
const
math::Vector3
&posStart,
63
const
math::Vector3
&posEnd);
64
65
private
:
static
void
UpdateCallback(
void
*data, dGeomID o1, dGeomID o2);
66
67
private
: dGeomID geomId;
68
private
:
ODEPhysicsPtr
physicsEngine;
69
72
private
:
class
Intersection
73
{
74
public
:
double
depth;
75
public
: std::string name;
76
};
77
};
79
}
80
}
81
#endif
82
83
84
85
86
87