From b27cc55aa631c52dae4a1a9c8c6888fc063fe022 Mon Sep 17 00:00:00 2001 From: quou Date: Mon, 30 Dec 2024 10:25:26 +1100 Subject: backface culling --- pipeline.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'pipeline.cpp') diff --git a/pipeline.cpp b/pipeline.cpp index cb052b8..2dc8ce9 100644 --- a/pipeline.cpp +++ b/pipeline.cpp @@ -180,6 +180,10 @@ void Pipeline_Builder::blend( ); } +void Pipeline_Builder::cull(Cull_Mode mode) { + pip->cull_mode = mode; +} + void Pipeline_Builder::blend( Blend_Mode mode_col, Blend_Factor src_col, @@ -265,6 +269,7 @@ Pipeline& Pipeline_Builder::build() { h(pip->pipeline_hash, pip->blend_dst); h(pip->pipeline_hash, pip->blend_src_alpha); h(pip->pipeline_hash, pip->blend_dst_alpha); + h(pip->pipeline_hash, pip->cull_mode); { int i, e = pip->descriptor_count; pip->descriptor_resource_hash = fnv1a64(0, 0); -- cgit v1.2.3-54-g00ecf