About 3D Model Static/Non Static

Dear All,

 

I have a questions about 3D Model...

 

1. Generally it seems that 3D model is fixed when it is draw in the mobile screen.That means 3D object (which is import from 3D studio Max as .pod format) is static in the screen. Bascially I am using this 3D model for Augmented Reality purposes.But for Augmented Reality the object should not be static in the display screen. The object/model will be bigger/smaller depend on marker position from camera. I already Implemented 3D model in my AR enviroment using PowerVR SDK's.But the object/model all time static/fixed in the screen. Maximum example used g_fCameraNear/g_fCameraFur parameter which may be reason for static.but im not sure. that means:

 

m_mProjection = PVRTMat4::PerspectiveFovRH(fFOV, f2vt((float)iScreenWidth/(float)iScreenHeight), f2vt(g_fCameraNear), f2vt(g_fCameraFar), PVRTMat4::OGL, bRotate=false);

 

So is there any way that to draw object/3d Model in non-static(not fixed) way as I want to use 3D Model for Augmented Realty purposes..

thanks

 

Rassall

The g_fCameraNear and g_fCameraFar parameters refer to the near and far dimensions of the view frustum. For an explanation see here:





http://en.wikipedia.org/wiki/Viewing_frustum





To move models in a 3D application you can (conceptually at least) move the individual meshes or move the camera. In practical terms, you either manipulate the individual transformations required to position the individual models or you manipulate the transformation for the camera. This all boils down to changing the MODELVIEW matrix in OpenGL ES 1.1.





Use glMatrixMode(GL_MODELVIEW); to tell GL you want to alter this matrix then glLoadMatrix(your_matrix) to load a value for GL to use.





Hope this helps…


Thanks Gordon...

 

Its now working.Now the screen is not fixed. object become smaller/bigger depend on marker postion. anyway in this way animation is not working. that means if i export a 3d model with animation from 3d studio max previously animation working. if i use  glModelview matrix /my glLoad matrix then 3d model draw but no animation play..

 

any idea/suggestion.....

 

thanks

Rassall