Log in or register to post comments

Model is not shown proper after zooming

May 12, 2015 - 4:10am #1

I've tried zoom the 3D Model appear in the camera attached Model but when zoom certain limit then the model is not showing proper. Please check the attached image and below is the code. I suspect the model is going above the camera. So, it's not showing proper. How to fix this,

Zoom In:
 
float oldScale = modalcloneTransform.localScale.x;
float newScale = oldScale * 1.2f;
modalcloneTransform.localScale = new Vector3(newScale, newScale, newScale);
 
Zoom out:
 
float oldScale = modalcloneTransform.localScale.x;
float newScale = oldScale / 1.2f;
modalcloneTransform.localScale = new Vector3(newScale, newScale, newScale);

 

AttachmentSize
Image icon ModelZoom.png1.16 MB

Model is not shown proper after zooming

May 13, 2015 - 1:22am #3

Got it...Set Near clip plane is 0.1 and it works fine.. Thank you..

Model is not shown proper after zooming

May 12, 2015 - 3:38pm #2

1. Put ARCamera into empty gameobject
2. Set transform XYZ GameObject (0,0,0)
3. Set transform XYZ ARCamera (0,Y,0)
4. Scale this gameobject (in your zoom-script)

5. Set near clip plane in ARCamera 0.1

Log in or register to post comments