-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Labels
dev:YORGBDSensorupstreamIssue coming from outside the scope of roboticslab-uc3m, fix it on that end (outside)Issue coming from outside the scope of roboticslab-uc3m, fix it on that end (outside)
Description
YarpOpenraveRGBDSensor remove hard-coded depthWidth/depthHeight pairs.
Attempt: Via https://github.com/rdiankov/openrave/blob/v0.9.0/plugins/basesensors/baseflashlidar3d.h#L116-L121 we can replace/remove the ugly hard-coded lines:
openrave-yarp-plugins/libraries/YarpPlugins/YarpOpenraveRGBDSensor/IRGBDSensorImpl.cpp
Lines 85 to 121 in 8e7dd25
| if( (depthHeight == 0) || (depthWidth == 0) ) | |
| { | |
| if (sensorRanges.size()==3072) | |
| { | |
| depthWidth = 64; | |
| depthHeight = 48; | |
| } | |
| else if (sensorRanges.size()==12288) | |
| { | |
| depthWidth = 128; | |
| depthHeight = 96; | |
| } | |
| else if (sensorRanges.size()==49152) | |
| { | |
| depthWidth = 256; | |
| depthHeight = 192; | |
| } | |
| else if (sensorRanges.size()==307200) | |
| { | |
| depthWidth = 640; | |
| depthHeight = 480; | |
| } | |
| else if (sensorRanges.size()==4) | |
| { | |
| depthWidth = 2; | |
| depthHeight = 2; | |
| } | |
| else if (sensorRanges.size()==0) | |
| { | |
| CD_WARNING("sensorRanges.size()==0\n"); | |
| } | |
| else | |
| { | |
| depthWidth = sensorRanges.size(); | |
| depthHeight = 1; | |
| } | |
| } |
Metadata
Metadata
Assignees
Labels
dev:YORGBDSensorupstreamIssue coming from outside the scope of roboticslab-uc3m, fix it on that end (outside)Issue coming from outside the scope of roboticslab-uc3m, fix it on that end (outside)