Index: /osgVisual/trunk/bin/osgVisualConfig.xml
===================================================================
--- /osgVisual/trunk/bin/osgVisualConfig.xml	(revision 204)
+++ /osgVisual/trunk/bin/osgVisualConfig.xml	(revision 205)
@@ -41,30 +41,30 @@
     <animationpath filename="salzburg.path"></animationpath>
     <models>
-      <!-- Models can be loaded and placed in the scenerey.
-        - filename: 3D model to load. Leave empty to use model without 3D model.
-        - type: [plain] ? todo
+      <!-- Models can be loaded and placed in the scenery.
+        - objectname: Name of the object to identify it in the scenegraph.
         - label: text to label the model with.
-        - dynamic: Add an standard updater to the model. todo
-        - position: Poisition to place the model
-        - attitude: Orientation to place the model
+        - dynamic: "yes" to add an standard updater to the model. 
+        - position: Position to place the model
+        - attitude: Orientation in degree to place the model
         - updater [optional]: Channels to use for position and attitude update
-        - modeloffset [optional]: Offset for the loaded 3D model to the visual_object (if the 3D model has a wrong coordinate frame)
-        - cameraoffset [optional]: Offset for the object mounted camera manipulator to the visual_object   
+        - cameraoffset [optional]: Rotational (in degree) and translational offset for the object mounted camera manipulator to the visual_object   
+        - Geometry [optional]: 3D model to display. Leave empty to use model without 3D model.
+        - Geometryoffset [optional]: Rotational offset (in degree) for the loaded 3D model to the visual_object (if the 3D model has a wrong coordinate frame)
+        - Geometryscale [optional]: Scale factors for the loaded 3D model in all three dimensions.
       -->
-      <model filename="cessna.osg" type="plain" label="TestText!" dynamic="yes">
+      <model objectname="TestObject" label="TestText!" dynamic="yes">
         <position lat="47.12345" lon="11.234567" alt="1500.0"></position>
         <attitude rot_x="0.0" rot_y="0.0" rot_z="0.0"></attitude>
         <updater>
-          <position lat="channelXYZ" lon="channelXYZ" alt="channelXYZ"></position>
-          <attitude rot_x="channelXYZ" rot_y="channelXYZ" rot_z="channelXYZ"></attitude>
+          <translation-slots>todo</translation-slots>
         </updater>
-        <modeloffset>
-          <translation trans_x="0.0" trans_y="0.0" trans_z="0.0"></translation>
-          <rotation rot_x="0.0" rot_y="0.0" rot_z="0.0"></rotation>
-        </modeloffset>
         <cameraoffset>
           <translation trans_x="0.0" trans_y="0.0" trans_z="0.0"></translation>
           <rotation rot_x="0.0" rot_y="0.0" rot_z="0.0"></rotation>
         </cameraoffset>
+        <geometry filename="cessna">
+          <offset rot_x="0.0" rot_y="0.0" rot_z="0.0"></offset>
+          <scalefactor scale_x="1.0" scale_y="1.0" scale_z="1.0"></scalefactor>
+        </geometry>
       </model>
     </models>
Index: /osgVisual/trunk/src/object/visual_object.cpp
===================================================================
--- /osgVisual/trunk/src/object/visual_object.cpp	(revision 204)
+++ /osgVisual/trunk/src/object/visual_object.cpp	(revision 205)
@@ -43,5 +43,5 @@
 	geometry_offset_rotation.makeRotate( 0.0, 1.0, 1.0, 1.0 );
 
-	// Init Scale
+	// Init Scale factor
 	scaleX = 1.0;
 	scaleY = 1.0;
@@ -74,21 +74,46 @@
 	//osg::ref<visual_object> object = new visual_object( root, nodeName);
 
-	std::string filename="", type
-
-			/*
-			<models>
-			  <model filename="cessna" type="plain" label="TestText!" dynamic="yes">
-				<position lat="47.12345" lon="11.234567" alt="1500.0"></position>
-				<attitude rot_x="0.0" rot_y="0.0" rot_z="0.0"></attitude>
-				<cameraoffset>
-				  <translation trans_x="0.0" trans_y="0.0" trans_z="0.0"></translation>
-				  <rotation rot_x="0.0" rot_y="0.0" rot_z="0.0"></rotation>
-				</cameraoffset>
-			  </model>
-			</models>
-			*/
+	std::string objectname="", filename="", label="";
+	bool dynamic = false;
+	double lat=0.0, lon=0.0, alt=0.0, rot_x=0.0, rot_y=0.0, rot_z=0.0;
+	double cam_trans_x=0.0, cam_trans_y=0.0, cam_trans_z=0.0, cam_rot_x=0.0, cam_rot_y=0.0, cam_rot_z=0.0;
+	double geometry_rot_x=0.0, geometry_rot_y=0.0, geometry_rot_z=0.0;
+	double geometry_scale_x=1.0, geometry_scale_y=1.0, geometry_scale_z=1.0;
+	osg::ref_ptr<osgVisual::object_updater> updater = NULL;
+
+	osgVisual::visual_object* object = new osgVisual::visual_object( sceneRoot_, objectname );
+	object->lat = lat;
+	object->lon = lon;
+	object->alt = alt;
+	object->azimuthAngle_psi = rot_x;
+	object->pitchAngle_theta = rot_y;
+	object->bankAngle_phi = rot_z;
+	if(label!="")
+		object->addLabel("XML_defined_label", label);
+	if(dynamic)
+	{
+		updater = new osgVisual::object_updater(object);
+	}
+	object->setCameraOffset( cam_trans_x, cam_trans_y, cam_trans_z, cam_rot_x, cam_rot_y, cam_rot_z);
+	if(filename!="")
+	{
+		object->loadGeometry( filename );
+		object->setGeometryOffset( geometry_rot_x, geometry_rot_y, geometry_rot_z );
+		object->setScale( geometry_scale_x, geometry_scale_y, geometry_scale_z ); 
+	}
+
+	if(updater.valid())
+ 		object->addUpdater( updater );	
+
+	/*
+        - updater [optional]: Channels to use for position and attitude update
+
+        <updater>
+          <translation-slots>todo</translation-slots>
+        </updater>
+    */
 
 	OSG_NOTIFY( osg::ALWAYS ) << "Done." << std::endl;
-	return NULL;
+	return object;
 }
 
