Utility/MaterialData: Fix FaceCulling being used for FaceSide
Former-commit-id: c6dea66694fbcce15d266e280e8048048e2523fa [formerly be83776dfb6acd33b6e86bf4e8aa74eaf253826a] Former-commit-id: 018a5d60be15d1e476ccd739a9b171cc997ee355
This commit is contained in:
parent
4f29015c05
commit
884c8528f4
|
|
@ -22,6 +22,7 @@ namespace Nz
|
||||||
static constexpr const char* BackFaceStencilReference = "MatBackFaceStencilReference";
|
static constexpr const char* BackFaceStencilReference = "MatBackFaceStencilReference";
|
||||||
static constexpr const char* BackFaceStencilZFail = "MatBackFaceStencilZFail";
|
static constexpr const char* BackFaceStencilZFail = "MatBackFaceStencilZFail";
|
||||||
static constexpr const char* Blending = "MatBlending";
|
static constexpr const char* Blending = "MatBlending";
|
||||||
|
static constexpr const char* CullingSide = "MatCullingSide";
|
||||||
static constexpr const char* CustomDefined = "MatCustomDefined";
|
static constexpr const char* CustomDefined = "MatCustomDefined";
|
||||||
static constexpr const char* ColorWrite = "MatColorWrite";
|
static constexpr const char* ColorWrite = "MatColorWrite";
|
||||||
static constexpr const char* DepthBuffer = "MatDepthBuffer";
|
static constexpr const char* DepthBuffer = "MatDepthBuffer";
|
||||||
|
|
|
||||||
|
|
@ -170,6 +170,9 @@ namespace Nz
|
||||||
if (matData.GetColorParameter(MaterialData::AmbientColor, &color))
|
if (matData.GetColorParameter(MaterialData::AmbientColor, &color))
|
||||||
SetAmbientColor(color);
|
SetAmbientColor(color);
|
||||||
|
|
||||||
|
if (matData.GetIntegerParameter(MaterialData::CullingSide, &iValue))
|
||||||
|
SetFaceCulling(static_cast<FaceSide>(iValue));
|
||||||
|
|
||||||
if (matData.GetIntegerParameter(MaterialData::DepthFunc, &iValue))
|
if (matData.GetIntegerParameter(MaterialData::DepthFunc, &iValue))
|
||||||
SetDepthFunc(static_cast<RendererComparison>(iValue));
|
SetDepthFunc(static_cast<RendererComparison>(iValue));
|
||||||
|
|
||||||
|
|
@ -182,9 +185,6 @@ namespace Nz
|
||||||
if (matData.GetIntegerParameter(MaterialData::DstBlend, &iValue))
|
if (matData.GetIntegerParameter(MaterialData::DstBlend, &iValue))
|
||||||
SetDstBlend(static_cast<BlendFunc>(iValue));
|
SetDstBlend(static_cast<BlendFunc>(iValue));
|
||||||
|
|
||||||
if (matData.GetIntegerParameter(MaterialData::FaceCulling, &iValue))
|
|
||||||
SetFaceCulling(static_cast<FaceSide>(iValue));
|
|
||||||
|
|
||||||
if (matData.GetIntegerParameter(MaterialData::FaceFilling, &iValue))
|
if (matData.GetIntegerParameter(MaterialData::FaceFilling, &iValue))
|
||||||
SetFaceFilling(static_cast<FaceFilling>(iValue));
|
SetFaceFilling(static_cast<FaceFilling>(iValue));
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue