Changeset 222 for osgVisual/trunk/src
- Timestamp:
- Feb 9, 2011, 9:11:44 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
osgVisual/trunk/src/object/visual_object.cpp
r221 r222 116 116 std::string attr_name=reinterpret_cast<const char*>(attr->name); 117 117 std::string attr_value=reinterpret_cast<const char*>(attr->children->content); 118 if( attr_name == "lat" ) lat = util::strToDouble(attr_value);119 if( attr_name == "lon" ) lon = util::strToDouble(attr_value);118 if( attr_name == "lat" ) lat = osg::DegreesToRadians(util::strToDouble(attr_value)); 119 if( attr_name == "lon" ) lon = osg::DegreesToRadians(util::strToDouble(attr_value)); 120 120 if( attr_name == "alt" ) alt = util::strToDouble(attr_value); 121 121 … … 131 131 std::string attr_name=reinterpret_cast<const char*>(attr->name); 132 132 std::string attr_value=reinterpret_cast<const char*>(attr->children->content); 133 if( attr_name == "rot_x" ) rot_x = util::strToDouble(attr_value);134 if( attr_name == "rot_y" ) rot_y = util::strToDouble(attr_value);135 if( attr_name == "rot_z" ) rot_z = util::strToDouble(attr_value);133 if( attr_name == "rot_x" ) rot_x = osg::DegreesToRadians(util::strToDouble(attr_value)); 134 if( attr_name == "rot_y" ) rot_y = osg::DegreesToRadians(util::strToDouble(attr_value)); 135 if( attr_name == "rot_z" ) rot_z = osg::DegreesToRadians(util::strToDouble(attr_value)); 136 136 137 137 attr = attr->next; … … 217 217 std::string attr_name=reinterpret_cast<const char*>(attr->name); 218 218 std::string attr_value=reinterpret_cast<const char*>(attr->children->content); 219 if( attr_name == "rot_x" ) cam_rot_x = util::strToDouble(attr_value);220 if( attr_name == "rot_y" ) cam_rot_y = util::strToDouble(attr_value);221 if( attr_name == "rot_z" ) cam_rot_z = util::strToDouble(attr_value);219 if( attr_name == "rot_x" ) cam_rot_x = osg::DegreesToRadians(util::strToDouble(attr_value)); 220 if( attr_name == "rot_y" ) cam_rot_y = osg::DegreesToRadians(util::strToDouble(attr_value)); 221 if( attr_name == "rot_z" ) cam_rot_z = osg::DegreesToRadians(util::strToDouble(attr_value)); 222 222 223 223 attr = attr->next; … … 251 251 std::string attr_name=reinterpret_cast<const char*>(attr->name); 252 252 std::string attr_value=reinterpret_cast<const char*>(attr->children->content); 253 if( attr_name == "rot_x" ) geometry_rot_x = util::strToDouble(attr_value);254 if( attr_name == "rot_y" ) geometry_rot_y = util::strToDouble(attr_value);255 if( attr_name == "rot_z" ) geometry_rot_z = util::strToDouble(attr_value);253 if( attr_name == "rot_x" ) geometry_rot_x = osg::DegreesToRadians(util::strToDouble(attr_value)); 254 if( attr_name == "rot_y" ) geometry_rot_y = osg::DegreesToRadians(util::strToDouble(attr_value)); 255 if( attr_name == "rot_z" ) geometry_rot_z = osg::DegreesToRadians(util::strToDouble(attr_value)); 256 256 257 257 attr = attr->next;
Note: See TracChangeset
for help on using the changeset viewer.