Base class for cameras in MORSE
A generic camera class, which is expected to be used as a base class for real camera. Concrete instantiation are currently:
Note
The cameras make use of Blender’s bge.texture module, which requires a graphic card capable of GLSL shading. Also, the 3D view window in Blender must be set to draw Textured objects.
Note
The streaming of data from this sensor can be toggled off and on by pressing the SPACE key during the simulation. This will affect all the video cameras on the scene.
Toggling off the cameras can help make the simulation run faster, specially when there are several cameras. However, the lack of data on the stream may cause problems to some middlewares.
Warning
Contrary to most of objects in Morse, the X axis of the camera is not “in front” of the camera. Here, Morse follows the “standard convention for camera”, i.e. X and Y are in the image plane, and Z is in the depth axis of the camera.
You can set these properties in your scripts with <component>.properties(<property1>=..., <property2>=...).
(no documentation available yet)
(no documentation available yet)
(no documentation available yet)
(no documentation available yet)
(no documentation available yet)
(no documentation available yet)
(no documentation available yet)
(no documentation available yet)
This sensor exports these datafields at each simulation step:
number of milliseconds in simulated time
Interface support:
(attention, no interface support!)
Returns the properties of a component.
Return value
a dictionary of the current component’s properties
Returns the configurations of a component (parsed from the properties).
Return value
a dictionary of the current component’s configurations
Returns the current data stored in the sensor.
Return value
a dictionary of the current sensor’s data
The following examples show how to use this component in a Builder script:
from morse.builder import *
robot = ATRV()
# creates a new instance of the sensor
camera = Camera()
# place your component at the correct location
camera.translate(<x>, <y>, <z>)
camera.rotate(<rx>, <ry>, <rz>)
robot.append(camera)
# define one or several communication interface, like 'socket'
camera.add_interface(<interface>)
env = Environment('empty')
(This page has been auto-generated from MORSE module morse.sensors.camera.)