26#include "../3d_fastmath.h"
51 aCamera.
MakeRay(
SFVEC2I( aWindowsPosition.x + x, aWindowsPosition.y + y ),
75 const SFVEC2F& a2DWindowsPosDisplacementFactor )
78 a2DWindowsPosDisplacementFactor,
m_ray );
85 const SFVEC3F& aDirectionDisplacementFactor )
96 aCamera.
MakeRay(
SFVEC2I( aWindowsPosition.x + x, aWindowsPosition.y + y ),
103 m_ray[i].
Init( rayOrigin, glm::normalize( rayDir + randVector ) );
116 unsigned int aPixelMultiple )
127 aCamera.
MakeRay(
SFVEC2I( aWindowsPosition.x + x * aPixelMultiple,
128 aWindowsPosition.y + y * aPixelMultiple),
153 aWindowsPosition.y + (
float)y ),
156 aRayPck[i].
Init( rayOrigin, rayDir );
163 const SFVEC2F& a2DWindowsPosDisplacementFactor,
175 aWindowsPosition.y + (
float)y +
179 aRayPck[i].
Init( rayOrigin, rayDir );
A class used to derive camera objects from.
void MakeRay(const SFVEC2I &aWindowPos, SFVEC3F &aOutOrigin, SFVEC3F &aOutDirection) const
Make a ray based on a windows screen position.
static void RAYPACKET_GenerateFrustum(FRUSTUM *m_Frustum, RAY *m_ray)
void RAYPACKET_InitRays_with2DDisplacement(const CAMERA &aCamera, const SFVEC2F &aWindowsPosition, const SFVEC2F &a2DWindowsPosDisplacementFactor, RAY *aRayPck)
void RAYPACKET_InitRays(const CAMERA &aCamera, const SFVEC2F &aWindowsPosition, RAY *aRayPck)
#define RAYPACKET_RAYS_PER_PACKET
void RAYPACKET_InitRays_with2DDisplacement(const CAMERA &aCamera, const SFVEC2F &aWindowsPosition, const SFVEC2F &a2DWindowsPosDisplacementFactor, RAY *aRayPck)
void RAYPACKET_InitRays(const CAMERA &aCamera, const SFVEC2F &aWindowsPosition, RAY *aRayPck)
void GenerateFrustum(const RAY &topLeft, const RAY &topRight, const RAY &bottomLeft, const RAY &bottomRight)
RAY m_ray[RAYPACKET_RAYS_PER_PACKET]
RAYPACKET(const CAMERA &aCamera, const SFVEC2I &aWindowsPosition)
void Init(const SFVEC3F &o, const SFVEC3F &d)