Fit object to bounds

Started by GfK, January 23, 2018, 20:52:52

Previous topic - Next topic

Steve Elliott

ENAY is probably the man to answer your question.  Hopefully he'll jump in at some point.
Win11 64Gb 12th Gen Intel i9 12900K 3.2Ghz Nvidia RTX 3070Ti 8Gb
Win11 16Gb 12th Gen Intel i5 12450H 2Ghz Nvidia RTX 2050 8Gb
Win11  Pro 8Gb Celeron Intel UHD Graphics 600
Win10/Linux Mint 16Gb 4th Gen Intel i5 4570 3.2GHz, Nvidia GeForce GTX 1050 2Gb
macOS 32Gb Apple M2Max
pi5 8Gb
Spectrum Next 2Mb

ENAY

Hi Dave, do you have it solved, except you're trying to get the scale to match up correctly to a certain size?

Not entirely sure what you're trying to achieve.

Have you seen this post?

https://answers.unity.com/questions/1268885/rescaling-mesh-or-gameobject-to-fit-in-gui-rect.html

ENAY

RenderToTexture in Unity is awesome. Good luck with your project Dave.

Not really related to your project but if you're fannying about with viewable and non viewable objects in and outside a hub. I highly recommend reading up on stencil shaders, for Z ordering, and hiding and showing objects in various camera was really handy.

Will only take up 10 mins your time. Just watch this video. I did and it really helped. :)

https://www.youtube.com/watch?v=xkcCWqifT9M&t=102s