14 Microsoft::WRL::ComPtr<Rendering::RenderStateSnapshot> state;
16 if (FAILED(hr))
return hr;
64 volumeEffect->SetMatrix(
"ringWorld",&world);
65 volumeEffect->SetVector(
"ringViewport",&screen);
66 volumeEffect->SetFloat(
"ringScale",physicalScale);
67 volumeEffect->SetTexture(
"atmosphereImage",texture);
68 hr=volumeEffect->Begin(
nullptr,0);
71 hr=volumeEffect->BeginPass(3);
75 volumeEffect->EndPass();
79 volumeEffect->SetTexture(
"atmosphereImage",
nullptr);
82 const HRESULT restored=state->Apply();
83 return FAILED(hr) ? hr : restored;
HRESULT(WINAPI *CUniBuffer::_ScriptApplyDigitSubstitution)(const SCRIPT_DIGITSUBSTITUTE *
HRESULT DrawPrimitive(Primitive type, UINT first, UINT count)
HRESULT CreateStateBlock(UINT type, RenderStateSnapshot **result)
HRESULT SetPixelShader(std::nullptr_t)
HRESULT GetViewport(Viewport *value) const
HRESULT SetStreamSource(UINT stream, RenderBuffer *buffer, UINT offset, UINT stride)
HRESULT SetRenderState(DWORD state, DWORD value)
HRESULT SetFVF(DWORD value)
HRESULT SetTransform(DWORD slot, const RiseMath::Matrix *value)
HRESULT SetTextureStageState(DWORD stage, DWORD state, DWORD value)
HRESULT SetTexture(DWORD stage, RenderTexture *texture)
HRESULT SetSamplerState(DWORD sampler, DWORD state, DWORD value)
HRESULT SetVertexShader(std::nullptr_t)
constexpr uint32_t INVSRCALPHA
constexpr uint32_t SRCALPHA
constexpr uint32_t GREATER
constexpr uint32_t ALWAYS
constexpr uint32_t LESSEQUAL
constexpr uint32_t LINEAR
constexpr uint32_t COLORWRITEENABLE
constexpr uint32_t SRCBLEND
constexpr uint32_t STENCILFUNC
constexpr uint32_t SEPARATEALPHABLENDENABLE
constexpr uint32_t CULLMODE
constexpr uint32_t STENCILREF
constexpr uint32_t ALPHABLENDENABLE
constexpr uint32_t STENCILENABLE
constexpr uint32_t ALPHATESTENABLE
constexpr uint32_t STENCILPASS
constexpr uint32_t FOGENABLE
constexpr uint32_t STENCILMASK
constexpr uint32_t DESTBLEND
constexpr uint32_t LIGHTING
constexpr uint32_t SRGBWRITEENABLE
constexpr uint32_t ZWRITEENABLE
constexpr uint32_t ZENABLE
constexpr uint32_t STENCILZFAIL
constexpr uint32_t BLENDOP
constexpr uint32_t STENCILFAIL
constexpr uint32_t SRGBTEXTURE
constexpr uint32_t ADDRESSU
constexpr uint32_t ADDRESSV
constexpr uint32_t MIPFILTER
constexpr uint32_t MAGFILTER
constexpr uint32_t MINFILTER
constexpr uint32_t DIFFUSE
constexpr uint32_t TEXTURE
constexpr uint32_t DISABLE
constexpr uint32_t SELECTARG1
constexpr uint32_t MODULATE
constexpr uint32_t COLOROP
constexpr uint32_t COLORARG1
constexpr uint32_t ALPHAARG1
constexpr uint32_t ALPHAOP
constexpr uint32_t TEXCOORDINDEX
constexpr uint32_t COLORARG2
constexpr uint32_t TEXTURETRANSFORMFLAGS
constexpr uint32_t DISABLE
HRESULT Draw(Rendering::RenderDevice *device, Rendering::RenderTexture *texture, Rendering::RenderBuffer *vertices, const RiseMath::Matrix &world, UINT segments, Rendering::RenderMaterial *volumeEffect=nullptr, float physicalScale=1)
constexpr unsigned Segments