pub struct Graphchain {
pub info: EffectiveGraphchainInfo,
pub swapchain: Swapchain,
/* private fields */
}Expand description
A physical display interface.
Fields§
§info: EffectiveGraphchainInfoEffective runtime information for the live graphchain.
Calls to set_info update the requested configuration. This field is
updated lazily after the next successful acquire recreates the swapchain.
Note: This field is read-only.
swapchain: SwapchainThe driver swapchain backing this graphchain.
Note: This field is read-only.
Implementations§
Source§impl Graphchain
impl Graphchain
Sourcepub fn new(
surface: Surface,
info: impl Into<GraphchainInfo>,
) -> Result<Self, DriverError>
pub fn new( surface: Surface, info: impl Into<GraphchainInfo>, ) -> Result<Self, DriverError>
Constructs a new Graphchain object.
Sourcepub fn acquire_next_image(
&mut self,
) -> Result<Option<SwapchainImage>, GraphchainError>
pub fn acquire_next_image( &mut self, ) -> Result<Option<SwapchainImage>, GraphchainError>
Acquires the next available swapchain image for rendering.
Sourcepub fn present_image<P>(
&mut self,
pool: &mut P,
graph: Graph,
image_node: SwapchainImageNode,
queue_index: u32,
) -> Result<SubmissionQueryPool, GraphchainError>
pub fn present_image<P>( &mut self, pool: &mut P, graph: Graph, image_node: SwapchainImageNode, queue_index: u32, ) -> Result<SubmissionQueryPool, GraphchainError>
Displays the given swapchain image using passes specified in graph, if possible.
Sourcepub fn set_info(&mut self, info: impl Into<GraphchainInfo>)
pub fn set_info(&mut self, info: impl Into<GraphchainInfo>)
Updates the requested information which controls the graphchain.
Previously acquired swapchain images should be discarded after calling this function.
The live effective info field updates acquire_timeout
immediately. Other fields are updated lazily after the next successful acquire recreates the
swapchain and reflects the runtime values that were actually selected.
Trait Implementations§
Source§impl Debug for Graphchain
impl Debug for Graphchain
Source§impl Drop for Graphchain
impl Drop for Graphchain
Auto Trait Implementations§
impl !RefUnwindSafe for Graphchain
impl !Sync for Graphchain
impl !UnwindSafe for Graphchain
impl Freeze for Graphchain
impl Send for Graphchain
impl Unpin for Graphchain
impl UnsafeUnpin for Graphchain
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.