pub struct WebCompositeRenderer { /* private fields */ }
Implementations§
Source§impl WebCompositeRenderer
impl WebCompositeRenderer
pub fn new(canvas: HtmlCanvasElement) -> Self
pub fn with_state(canvas: HtmlCanvasElement, state: RenderState) -> Self
Trait Implementations§
Source§impl CompositeRenderer for WebCompositeRenderer
impl CompositeRenderer for WebCompositeRenderer
fn execute<'a, I>(&mut self, commands: I) -> Result<(usize, usize)>where
I: IntoIterator<Item = Command<'a>>,
fn images_count(&self) -> usize
fn fontfaces_count(&self) -> usize
fn surfaces_count(&self) -> usize
fn state(&self) -> &RenderState
fn state_mut(&mut self) -> &mut RenderState
fn view_size(&self) -> Vec2
fn update_state(&mut self)
fn update_cache(&mut self, assets: &AssetsDatabase)
fn create_surface(&mut self, name: &str, width: usize, height: usize) -> bool
fn destroy_surface(&mut self, name: &str) -> bool
fn has_surface(&mut self, name: &str) -> bool
fn get_surface_size(&self, name: &str) -> Option<(usize, usize)>
fn update_surface<'a, I>(
&mut self,
name: &str,
commands: I,
) -> Result<(usize, usize)>where
I: IntoIterator<Item = Command<'a>>,
Source§impl CompositeRendererResources<HtmlCanvasElement> for WebCompositeRenderer
impl CompositeRendererResources<HtmlCanvasElement> for WebCompositeRenderer
fn add_resource( &mut self, id: String, resource: HtmlCanvasElement, ) -> Result<AssetId>
fn remove_resource(&mut self, id: AssetId) -> Result<HtmlCanvasElement>
impl Send for WebCompositeRenderer
impl Sync for WebCompositeRenderer
Auto Trait Implementations§
impl Freeze for WebCompositeRenderer
impl RefUnwindSafe for WebCompositeRenderer
impl Unpin for WebCompositeRenderer
impl UnwindSafe for WebCompositeRenderer
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
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more