Are you clever? Distance Problem.

Started by
11 comments, last by Paul Griffiths 7 years, 2 months ago

Spent 2 months

Advertisement

Solved: though if

solved.jpgsolved.jpg

Found a

could be at any angle like rotated 180.

Think I may get somewhere, may involve Pythagorean theorem, or the areas of triangles?

I think I've worked it out, some angles are positive and some are negative, got to work them out.

Simpler than that, calculate if portals rotated by <>180 and then do distance plane equation, simple!

If your portals are planar polygons, which portal a ray from the camera sees can only change

  • at the edges of a portal
  • at the intersection of two portals

Distances between portals and camera do not matter, except to define depth buffers that can be used.to locate portal edges and intersections in screen space.

You also don't seem to clip portals against the view frustum of your camera.

Omae Wa Mou Shindeiru

edit:

a reliable way to know if the camera is behind the portals and which portal is the furthest away?

edit:

This topic is closed to new replies.

Advertisement