mirror of
https://github.com/storytold/wgpu.git
synced 2026-11-30 10:03:58 +01:00
Merge #1227
1227: Derive more things for primitive and multisampling states r=kvark a=kvark **Connections** Related to https://github.com/gfx-rs/wgpu-rs/issues/769 **Description** Adding a few derives and fixing a doc comment. **Testing** CI gets it Co-authored-by: Dzmitry Malyshau <kvarkus@gmail.com>
This commit is contained in:
commit
e5f1f6a5c0
1 file changed
+6
-6
@@ -348,7 +348,7 @@ bitflags::bitflags! {
|
||||
///
|
||||
/// This is a web and native feature.
|
||||
const ADDRESS_MODE_CLAMP_TO_BORDER = 0x0000_0000_0100_0000;
|
||||
/// Allows the user to set a non-fill polygon mode in [`RasterizationStateDescriptor::polygon_mode`]
|
||||
/// Allows the user to set a non-fill polygon mode in [`PrimitiveState::polygon_mode`]
|
||||
///
|
||||
/// This allows drawing polygons/triangles as lines (wireframe) or points instead of filled
|
||||
///
|
||||
@@ -807,7 +807,7 @@ impl Default for PrimitiveTopology {
|
||||
|
||||
/// Winding order which classifies the "front" face.
|
||||
#[repr(C)]
|
||||
#[derive(Copy, Clone, Debug, Hash, Eq, PartialEq)]
|
||||
#[derive(Copy, Clone, Debug, PartialEq, Eq, Hash)]
|
||||
#[cfg_attr(feature = "trace", derive(Serialize))]
|
||||
#[cfg_attr(feature = "replay", derive(Deserialize))]
|
||||
pub enum FrontFace {
|
||||
@@ -829,7 +829,7 @@ impl Default for FrontFace {
|
||||
|
||||
/// Face of a vertex.
|
||||
#[repr(C)]
|
||||
#[derive(Copy, Clone, Debug, Hash, Eq, PartialEq)]
|
||||
#[derive(Copy, Clone, Debug, PartialEq, Eq, Hash)]
|
||||
#[cfg_attr(feature = "trace", derive(Serialize))]
|
||||
#[cfg_attr(feature = "replay", derive(Deserialize))]
|
||||
pub enum Face {
|
||||
@@ -841,7 +841,7 @@ pub enum Face {
|
||||
|
||||
/// Type of drawing mode for polygons
|
||||
#[repr(C)]
|
||||
#[derive(Copy, Clone, Debug, Hash, Eq, PartialEq)]
|
||||
#[derive(Copy, Clone, Debug, PartialEq, Eq, Hash)]
|
||||
#[cfg_attr(feature = "trace", derive(Serialize))]
|
||||
#[cfg_attr(feature = "replay", derive(Deserialize))]
|
||||
pub enum PolygonMode {
|
||||
@@ -861,7 +861,7 @@ impl Default for PolygonMode {
|
||||
|
||||
/// Describes the state of primitive assembly and rasterization in a render pipeline.
|
||||
#[repr(C)]
|
||||
#[derive(Clone, Debug, Default, PartialEq)]
|
||||
#[derive(Clone, Debug, Default, PartialEq, Eq, Hash)]
|
||||
#[cfg_attr(feature = "trace", derive(Serialize))]
|
||||
#[cfg_attr(feature = "replay", derive(Deserialize))]
|
||||
pub struct PrimitiveState {
|
||||
@@ -886,7 +886,7 @@ pub struct PrimitiveState {
|
||||
|
||||
/// Describes the multi-sampling state of a render pipeline.
|
||||
#[repr(C)]
|
||||
#[derive(Clone, Debug, PartialEq)]
|
||||
#[derive(Clone, Debug, PartialEq, Eq, Hash)]
|
||||
#[cfg_attr(feature = "trace", derive(Serialize))]
|
||||
#[cfg_attr(feature = "replay", derive(Deserialize))]
|
||||
pub struct MultisampleState {
|
||||
|
||||
Reference in new issue
Block a user