//
// Asura_Direct3D_Skybox.h
//
// Created by RJF - 21 August 2006
//
// Copyright (C) 2006 Rebellion, All Rights Reserved.
//

#ifdef ASURA_USE_PRAGMA_ONCE
#pragma once
#endif

#ifndef __ASURA_DIRECT3D_SKYBOX_H__
#define __ASURA_DIRECT3D_SKYBOX_H__

#include "Rendering/Asura_Direct3D.h"

class Asura_Direct3D_Effect;
class Asura_RGBA;
class Asura_Direct3D_EffectParameterBlock;

class Asura_Direct3D_Skybox
{
public:
	static void Initialise();
	static void Reset();
	static void Shutdown();

	static void Render();

private:
	static Direct3D_VertexBuffer* s_pxVB;
	static Direct3D_VertexDeclaration* s_pxVD;

	static int s_aiTextureIDs[6];

	static Asura_Direct3D_Effect* s_pxEffect;

	static void LoadTextures();

#if defined( ASURA_TARGET_SM3)
	static float		s_afSkyboxColour[ 3 ];
	static float		s_afHazeColour1[ 3 ];
	static float		s_fHazeStrength1;
	static float		s_afHazeColour2[ 3 ];
	static float		s_fHazeStrength2;
	static float		s_afSunColour1[ 3 ];
	static float		s_fSunStrength1;
	static float		s_afSunColour2[ 3 ];
	static float		s_fSunStrength2;
	static float		s_afSunDir1[ 3 ];
	static float		s_afSunDir2[ 3 ];
#endif
	static Asura_RGBA	s_xSkyboxColour;
	static Asura_RGBA	s_xFogColour;
	static float		s_fFogBlendFactor;
	static bool			s_bFlipTextureVertical;
#if defined( ASURA_TARGET_SM3)
	static bool			s_b1MirrorBelowHorizon;
	static bool			s_b2MirrorBelowHorizon;
	static bool			s_bDisableHaze;
	static bool			s_bDisable2Haze;
	static bool			s_bDisableSun;
	static bool			s_bDisable2Sun;
	static D3DXMATRIX	s_xFrustumToCamDir;
	static float		s_fDistance;
#endif
	static D3DXMATRIX	s_xFaceTransform;
	static Asura_Direct3D_EffectParameterBlock* s_pxEPB;
};

#endif//__ASURA_DIRECT3D_SKYBOX_H__