void Bind(int stencilRef) const{
		mRasterizerState->Bind();
		mBlendState->Bind();	
		if (sForceIncrementalStencil) {
			Renderer::GetInstance().BindIncrementalStencilState(2);
		}
		else {
			mDepthStencilState->Bind(stencilRef);
		}
	}
void GraphicsDriver::SetBlendState(BlendStatePtr inBlendState)
{
	float blendFactor[4];


	// Setup the blend factor.
	blendFactor[0] = 0.0f;
	blendFactor[1] = 0.0f;
	blendFactor[2] = 0.0f;
	blendFactor[3] = 0.0f;
	g_pImmediateContext->OMSetBlendState(inBlendState.get(), blendFactor, 0xffffffff);
}
	void DebugPrint() const{
		Logger::Log(FB_DEFAULT_LOG_ARG, FormatString("(info) RasterizerStates : 0x%x", mRasterizerState.get()).c_str());
		Logger::Log(FB_DEFAULT_LOG_ARG, FormatString("(info) BlendStates : 0x%x", mBlendState.get()).c_str());
		Logger::Log(FB_DEFAULT_LOG_ARG, FormatString("(info) DepthStencilStates : 0x%x", mDepthStencilState.get()).c_str());

		if (mRDesc){
			Logger::Log(FB_DEFAULT_LOG_ARG, FormatString("(info) RDesc scissor: %d", mRDesc->GetScissorEnable() ? 1 : 0).c_str());
		}
		else{
			Logger::Log(FB_DEFAULT_LOG_ARG, FormatString("(info) RDesc null").c_str());
		}

	}
Beispiel #4
0
	void UGraphicsDevice::SetBlendState(BlendStatePtr inBlendState)
	{
		mD3dDeviceCtx->OMSetBlendState(inBlendState.get(), nullptr, D3D11_COLOR_WRITE_ENABLE_ALL);
	}