Keeping some game object same size while zooming?

I’m using orthographic camera extension for setting zoom. I want some game objects size remain same while zooming happening.

You would need to scale the game objects relative to the amount of zoom.

1 Like

Alternatively, use the GUI for the objects you’d like to stay the same size. What’s the use case here?

2 Likes

I think another option is to create a separate render predicate for the object that should stay the same size. Then in your render script, before you draw the same-size objects, set the camera projection matrix such that it isn’t zoomed in.

  1. Camera zooms in,
  2. Draw objects,
  3. Set camera projection matrix to no-zoom,
  4. Draw same-size objects,
  5. Restore camera projection matrix.

…but like @niclas_aberg_winkel said, it sounds like a weird use-case that could probably be solved with the GUI.

2 Likes

adjust-anchor-point-display-size_1-1

I want it for control points of object, i want it to render in go world. I want some game objects render below everything. As gui always render on top. Unless i have used seperate predicate.

In this case, you can simply increase the scale of each square. I’m assuming each square is a separate game object, right?

2 Likes