# Camera

This topic is 2974 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

Hi, I've one question regarding to camera projection

consider my object position is at (0,0,0)

my camera position (0,50,0)

Look at (0,0,0)

up vector (0,1,0)

in this case object can be visible in output?

##### Share on other sites
Seems you can see the object.

But...
If your object's dimensions are bigger than 50.f, that means your camera is inside the object and maybe it can't be seen :D

It also depends on the projection matrix.

[Edited by - programci_84 on October 21, 2010 6:50:27 AM]

##### Share on other sites
I hesitate to agree.

The Look vector is not defined. It should have a magnitude of 1, atm it has a magnitude of zero.

If you were to change the Look vector to (0, -1, 0) and the Up vector to (0, 0, 1), then what progamci_84 wrote would apply.

##### Share on other sites
Quote:
 Original post by forsandifsThe Look vector is not defined. It should have a magnitude of 1, atm it has a magnitude of zero.

There's no need to define look vector here, because it equals to Normalize (targetPos - cameraPos).

targetPos = (0, 0, 0), cameraPos = (0, 50, 0)

##### Share on other sites
Quote:
 Original post by maheshbinnyin this case object can be visible in output?
That depends on the values of:
1. The near clip plane
2. The far clip plane
3. The camera FOV
4. The object size (As programci_84 said)

##### Share on other sites
Quote:
 Original post by forsandifsI hesitate to agree.The Look vector is not defined. It should have a magnitude of 1, atm it has a magnitude of zero.
A 'look' vector and a 'look at' vector (or point) are not the same thing.

A 'look at' vector of (0, 0, 0) is perfectly valid.

##### Share on other sites
You are both correct. I got confused. Been spending too long working on my own camera system. :P My apologies.

##### Share on other sites
Quote:
 my camera position (0,50,0)LookAt(0,0,0)Up Vector(0,1,0)

Your up vector is y, and your camera forward vector is -y(<0,0,0> - <0,50,0>, Not sure if that's the issue, but as they are colinear, they might be fudging the view matrix...

##### Share on other sites
Thanks everyone for ur replies

Actually the object is visible only if I say up vector is positve/negative z. I don't know i'm really messed up with camera projections. Can someone can tell where i can get best tutorial regarding to camera projections.

1. 1
2. 2
3. 3
4. 4
Rutin
13
5. 5

• 13
• 10
• 9
• 9
• 11
• ### Forum Statistics

• Total Topics
633692
• Total Posts
3013355
×