diff options
Diffstat (limited to 'client/src/render/scene/pipelines.rs')
-rw-r--r-- | client/src/render/scene/pipelines.rs | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/client/src/render/scene/pipelines.rs b/client/src/render/scene/pipelines.rs index dfc5d19..53064c9 100644 --- a/client/src/render/scene/pipelines.rs +++ b/client/src/render/scene/pipelines.rs @@ -14,6 +14,8 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see <https://www.gnu.org/licenses/>. */ +use super::{GraphicsConfig, PipelineSpec}; +use crate::render::shaders::SceneShaders; use wgpu::{ BindGroupLayout, BindGroupLayoutDescriptor, BindGroupLayoutEntry, BindingType, BlendState, BufferBindingType, ColorTargetState, ColorWrites, CompareFunction, DepthBiasState, @@ -25,10 +27,6 @@ use wgpu::{ VertexStepMode, }; -use crate::shaders::SceneShaders; - -use super::PipelineSpec; - pub struct SceneBgLayouts { pub texture: BindGroupLayout, pub material: BindGroupLayout, @@ -95,6 +93,7 @@ impl PipelineSpec { device: &Device, layouts: &SceneBgLayouts, shaders: &SceneShaders, + config: &GraphicsConfig, ) -> RenderPipeline { let pipeline_layout = device.create_pipeline_layout(&PipelineLayoutDescriptor { label: None, @@ -188,7 +187,10 @@ impl PipelineSpec { bias: DepthBiasState::default(), stencil: StencilState::default(), }), - multisample: MultisampleState::default(), + multisample: MultisampleState { + count: config.sample_count, + ..Default::default() + }, multiview: None, cache: None, }) |