1
\$\begingroup\$

I am running into a problem when I set the resolution of my screen and the objects in the HUD. When an increase of resolution happens the reticule image becomes bigger, when I want it to stay the same. Anyone got any tips?

Thanks in advice.

\$\endgroup\$
1
  • \$\begingroup\$ Which engine/toolset are you using? What does your draw call for the reticule look like? etc. \$\endgroup\$
    – Jim
    Commented Aug 9, 2012 at 0:38

1 Answer 1

2
\$\begingroup\$

You can draw the reticule by using a percentage of the width and height of your resolution.

For example if you want the reticule to be a 5% size:

Resolution  | Reticule Size
1024 x 768  | 51.2 x 38.4
1280 x 1024 | 64 x 51.2

So the size of the reticule will change depending on the resolution, but it would look the same to you.

\$\endgroup\$
2
  • \$\begingroup\$ as of right now I dont have a texture or anything for the reticule, what I have rendering is a quad in the middle of the screen representing that reticule. I wanted to make this reticule a square and then put a texture on it.So currently I am doing this world[0] = XMMatrixTransformation(scaleOrigin,ScaleOrientation,Scale,rotOrigin,rotQuaternion,Position); So I need to work with the scale varibale to make it a perfect quad in the screen that does not get bigger when the resolution is increased. Not sure if the OrthoCamera that I am using for the HUD can cause some issues with this. \$\endgroup\$
    – ricardo
    Commented Aug 9, 2012 at 4:47
  • \$\begingroup\$ You can also draw the reticule using a orthographic camera, so that you can actually measure the size dependent on the screen size. \$\endgroup\$ Commented Aug 9, 2012 at 17:53

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .