[Positioning] Input*: initialise real_position
When provided for non-calibration requests, the real position is initialised.
This commit is contained in:
parent
00bbc9c49d
commit
17e12a9735
|
@ -139,5 +139,10 @@ const Request& InputCSV::get_next_request()
|
|||
direction, type) ;
|
||||
}
|
||||
|
||||
// We set the real coordinates (if found) only for non-calibration
|
||||
// requests
|
||||
else if (pos)
|
||||
current_request->set_real_position(pos) ;
|
||||
|
||||
return *current_request ;
|
||||
}
|
||||
|
|
|
@ -154,5 +154,16 @@ const Request& InputUDPSocket::get_next_request()
|
|||
request.type) ;
|
||||
}
|
||||
|
||||
// We set the real coordinates (if found) only for non-calibration
|
||||
// requests
|
||||
else
|
||||
{
|
||||
Point3D pos(owl_ntohf(request.x_position),
|
||||
owl_ntohf(request.y_position),
|
||||
owl_ntohf(request.z_position)) ;
|
||||
if (pos)
|
||||
current_request->set_real_position(pos) ;
|
||||
}
|
||||
|
||||
return *current_request ;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue