pub enum ViewportsState {
    Fixed {
        data: Vec<(Viewport, Scissor)>,
    },
    DynamicViewports {
        scissors: Vec<Scissor>,
    },
    DynamicScissors {
        viewports: Vec<Viewport>,
    },
    Dynamic {
        num: u32,
    },
}
Expand description

List of viewports and scissors that are used when creating a graphics pipeline object.

Note that the number of viewports and scissors must be the same.

Variants

Fixed

Fields

data: Vec<(Viewport, Scissor)>

State of the viewports and scissors.

The state is known in advance.

DynamicViewports

Fields

scissors: Vec<Scissor>

State of the scissors.

The state of scissors is known in advance, but the state of viewports is dynamic and will bet set when drawing.

Note that the number of viewports and scissors must be the same.

DynamicScissors

Fields

viewports: Vec<Viewport>

State of the viewports

The state of viewports is known in advance, but the state of scissors is dynamic and will bet set when drawing.

Note that the number of viewports and scissors must be the same.

Dynamic

Fields

num: u32

Number of viewports and scissors.

The state of both the viewports and scissors is dynamic and will be set when drawing.

Implementations

Returns true if the state of the viewports is dynamic.

Returns true if the state of the scissors is dynamic.

Returns the number of viewports and scissors.

Trait Implementations

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more
Builds a pointer to this type from a raw pointer.
Returns true if the size is suitable to store a type like this.
Returns the size of an individual element.

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.