Rise
The Vieneo Province
Loading...
Searching...
No Matches
Rendering::FogBeams11 Class Reference

#include <FogBeams11.h>

Collaboration diagram for Rendering::FogBeams11:
[legend]

Classes

struct  Light

Public Types

using Vector = DirectX::XMFLOAT3
using Matrix = DirectX::XMFLOAT4X4

Public Member Functions

HRESULT Initialize (ID3D11Device *device, const std::filesystem::path &directory={})
void Reset ()
HRESULT ConfigureOrganic (bool enabled)
bool Ready () const
bool OrganicAvailable () const
HRESULT Render (ID3D11DeviceContext *context, ID3D11RenderTargetView *scene, const SceneDepth11 &depth, const D3D11_VIEWPORT &viewport, const Matrix &view, const Matrix &projection, const std::vector< Light > &lights, const Parameters11 *clouds=nullptr)
unsigned LastDraws () const
void SetResolutionDivisor (unsigned value)
void ReleaseTargets ()

Static Public Attributes

static constexpr unsigned MaxLights =8

Private Member Functions

HRESULT PreparePrograms (unsigned variant)
HRESULT PrepareTargets (unsigned width, unsigned height)

Private Attributes

std::filesystem::path shaderDirectory
Microsoft::WRL::ComPtr< ID3D11Device > device
Microsoft::WRL::ComPtr< ID3DDeviceContextState > state
Microsoft::WRL::ComPtr< ID3D11RasterizerState > raster
Microsoft::WRL::ComPtr< ID3D11DepthStencilState > stencil
Microsoft::WRL::ComPtr< ID3D11BlendState > blend
Microsoft::WRL::ComPtr< ID3D11BlendState > lowBlend
Microsoft::WRL::ComPtr< ID3D11SamplerState > fallbackSampler
std::array< Program11, 4 > pixel
std::array< Program11, 4 > edge
std::array< Program11, 4 > organicPixel
std::array< Program11, 4 > organicEdge
std::array< Program11, 4 > lowPixel
std::array< Program11, 4 > organicLowPixel
std::array< Program11, 4 > resolvePixel
std::array< Program11, 4 > resolveEdge
Microsoft::WRL::ComPtr< ID3D11Texture2D > scattering
Microsoft::WRL::ComPtr< ID3D11ShaderResourceView > scatteringView
Microsoft::WRL::ComPtr< ID3D11RenderTargetView > scatteringAll
unsigned bufferWidth =0
unsigned bufferHeight =0
unsigned resolutionDivisor =0
bool organicReady =false
bool organic =false
unsigned lastDraws =0

Detailed Description

Definition at line 14 of file FogBeams11.h.

Member Typedef Documentation

◆ Matrix

using Rendering::FogBeams11::Matrix = DirectX::XMFLOAT4X4

Definition at line 19 of file FogBeams11.h.

◆ Vector

using Rendering::FogBeams11::Vector = DirectX::XMFLOAT3

Definition at line 18 of file FogBeams11.h.

Member Function Documentation

◆ ConfigureOrganic()

HRESULT Rendering::FogBeams11::ConfigureOrganic ( bool enabled)
inline

Definition at line 30 of file FogBeams11.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Initialize()

HRESULT Rendering::FogBeams11::Initialize ( ID3D11Device * device,
const std::filesystem::path & directory = {} )

Definition at line 63 of file FogBeams11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ LastDraws()

unsigned Rendering::FogBeams11::LastDraws ( ) const
inline

Definition at line 40 of file FogBeams11.h.

◆ OrganicAvailable()

bool Rendering::FogBeams11::OrganicAvailable ( ) const
inline

Definition at line 36 of file FogBeams11.h.

Here is the caller graph for this function:

◆ PreparePrograms()

HRESULT Rendering::FogBeams11::PreparePrograms ( unsigned variant)
private

Definition at line 105 of file FogBeams11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PrepareTargets()

HRESULT Rendering::FogBeams11::PrepareTargets ( unsigned width,
unsigned height )
private

Definition at line 141 of file FogBeams11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Ready()

bool Rendering::FogBeams11::Ready ( ) const
inline

Definition at line 35 of file FogBeams11.h.

Here is the caller graph for this function:

◆ ReleaseTargets()

void Rendering::FogBeams11::ReleaseTargets ( )

Definition at line 137 of file FogBeams11.cpp.

Here is the caller graph for this function:

◆ Render()

HRESULT Rendering::FogBeams11::Render ( ID3D11DeviceContext * context,
ID3D11RenderTargetView * scene,
const SceneDepth11 & depth,
const D3D11_VIEWPORT & viewport,
const Matrix & view,
const Matrix & projection,
const std::vector< Light > & lights,
const Parameters11 * clouds = nullptr )

Definition at line 157 of file FogBeams11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Reset()

void Rendering::FogBeams11::Reset ( )

Definition at line 53 of file FogBeams11.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetResolutionDivisor()

void Rendering::FogBeams11::SetResolutionDivisor ( unsigned value)
inline

Definition at line 43 of file FogBeams11.h.

Member Data Documentation

◆ blend

Microsoft::WRL::ComPtr<ID3D11BlendState> Rendering::FogBeams11::blend
private

Definition at line 53 of file FogBeams11.h.

◆ bufferHeight

unsigned Rendering::FogBeams11::bufferHeight =0
private

Definition at line 61 of file FogBeams11.h.

◆ bufferWidth

unsigned Rendering::FogBeams11::bufferWidth =0
private

Definition at line 61 of file FogBeams11.h.

◆ device

Microsoft::WRL::ComPtr<ID3D11Device> Rendering::FogBeams11::device
private

Definition at line 49 of file FogBeams11.h.

◆ edge

std::array<Program11,4> Rendering::FogBeams11::edge
private

Definition at line 55 of file FogBeams11.h.

◆ fallbackSampler

Microsoft::WRL::ComPtr<ID3D11SamplerState> Rendering::FogBeams11::fallbackSampler
private

Definition at line 54 of file FogBeams11.h.

◆ lastDraws

unsigned Rendering::FogBeams11::lastDraws =0
private

Definition at line 63 of file FogBeams11.h.

◆ lowBlend

Microsoft::WRL::ComPtr<ID3D11BlendState> Rendering::FogBeams11::lowBlend
private

Definition at line 53 of file FogBeams11.h.

◆ lowPixel

std::array<Program11,4> Rendering::FogBeams11::lowPixel
private

Definition at line 57 of file FogBeams11.h.

◆ MaxLights

unsigned Rendering::FogBeams11::MaxLights =8
staticconstexpr

Definition at line 17 of file FogBeams11.h.

◆ organic

bool Rendering::FogBeams11::organic =false
private

Definition at line 62 of file FogBeams11.h.

◆ organicEdge

std::array<Program11,4> Rendering::FogBeams11::organicEdge
private

Definition at line 56 of file FogBeams11.h.

◆ organicLowPixel

std::array<Program11,4> Rendering::FogBeams11::organicLowPixel
private

Definition at line 57 of file FogBeams11.h.

◆ organicPixel

std::array<Program11,4> Rendering::FogBeams11::organicPixel
private

Definition at line 56 of file FogBeams11.h.

◆ organicReady

bool Rendering::FogBeams11::organicReady =false
private

Definition at line 62 of file FogBeams11.h.

◆ pixel

std::array<Program11,4> Rendering::FogBeams11::pixel
private

Definition at line 55 of file FogBeams11.h.

◆ raster

Microsoft::WRL::ComPtr<ID3D11RasterizerState> Rendering::FogBeams11::raster
private

Definition at line 51 of file FogBeams11.h.

◆ resolutionDivisor

unsigned Rendering::FogBeams11::resolutionDivisor =0
private

Definition at line 61 of file FogBeams11.h.

◆ resolveEdge

std::array<Program11,4> Rendering::FogBeams11::resolveEdge
private

Definition at line 57 of file FogBeams11.h.

◆ resolvePixel

std::array<Program11,4> Rendering::FogBeams11::resolvePixel
private

Definition at line 57 of file FogBeams11.h.

◆ scattering

Microsoft::WRL::ComPtr<ID3D11Texture2D> Rendering::FogBeams11::scattering
private

Definition at line 58 of file FogBeams11.h.

◆ scatteringAll

Microsoft::WRL::ComPtr<ID3D11RenderTargetView> Rendering::FogBeams11::scatteringAll
private

Definition at line 60 of file FogBeams11.h.

◆ scatteringView

Microsoft::WRL::ComPtr<ID3D11ShaderResourceView> Rendering::FogBeams11::scatteringView
private

Definition at line 59 of file FogBeams11.h.

◆ shaderDirectory

std::filesystem::path Rendering::FogBeams11::shaderDirectory
private

Definition at line 48 of file FogBeams11.h.

◆ state

Microsoft::WRL::ComPtr<ID3DDeviceContextState> Rendering::FogBeams11::state
private

Definition at line 50 of file FogBeams11.h.

◆ stencil

Microsoft::WRL::ComPtr<ID3D11DepthStencilState> Rendering::FogBeams11::stencil
private

Definition at line 52 of file FogBeams11.h.


The documentation for this class was generated from the following files: