Instantiates fakeFrameGrabber device implemented by FakeFrameGrabber.
Instantiates fakeFrameGrabber device implemented by FakeFrameGrabber.
# start up a fake image source of size 640x480, with 4 images per second device fakeFrameGrabber width 640 height 480 period 0.25
If this text is saved in a file called fakeFrameGrabber_basic.ini then the device can be created by doing:
yarpdev --file fakeFrameGrabber_basic.ini
Of course, the configuration could be passed just as command line options, or as a yarp::os::Property object in a program:
Here is a list of properties checked when starting up a device based on this configuration file. Note that which properties are checked can depend on whether other properties are present. In some cases properties can also vary between operating systems. So this is just an example
PROPERTY | DESCRIPTION | DEFAULT |
device | ||
fakeFrameGrabber_rpc_port | rpc port for the fakeFrameGrabber | /fakeFrameGrabber/rpc |
width | desired width of test image | 320 |
height | desired height of test image | 240 |
horizontalFov | desired horizontal fov of test image | 1.0 |
verticalFov | desired vertical fov of test image | 2.0 |
mirror | mirroring disabled by default | 0 |
syncro | syncronize producer and consumer, so that all images are used once and only once | 0 |
topIsLow | explicitly set the topIsLow field in the images | 1 |
physFocalLength | Physical focal length of the fakeFrameGrabber | 3.0 |
focalLengthX | Horizontal component of the focal length of the fakeFrameGrabber | 4.0 |
focalLengthY | Vertical component of the focal length of the fakeFrameGrabber | 5.0 |
principalPointX | X coordinate of the principal point of the fakeFrameGrabber | 6.0 |
principalPointY | Y coordinate of the principal point of the fakeFrameGrabber | 7.0 |
rectificationMatrix | Matrix that describes the lens' distortion(fake) | 1.0 0.0 0.0 0.0 1.0 0.0 0.0 0.0 1.0 |
distortionModel | Reference to group of parameters describing the distortion model of the camera | FishEye |
k1 | Radial distortion coefficient of the lens(fake) | 8.0 |
k2 | Radial distortion coefficient of the lens(fake) | 9.0 |
k3 | Radial distortion coefficient of the lens(fake) | 10.0 |
t1 | Tangential distortion of the lens(fake) | 11.0 |
t2 | Tangential distortion of the lens(fake) | 12.0 |
freq | rate of test images in Hz | |
period | period of test images in seconds | |
mode | bouncy [ball], scrolly [line], grid [grid], grid multisize [size], random [rand], none [none], time test[time] | line |
src | ||
timestamp | should write the timestamp in the first bytes of the image | |
noise | Should add noise to the image (uses snr) | |
snr | Signal noise ratio ([0.0-1.0] default 0.5) | 0.5 |
bayer | should emit bayer test image? | |
mono | should emit a monochrome image? |