pub struct EditorPreviewState(Mutex<Option<EditorPreviewSession>>);Expand description
Tauri-managed state for the live editor preview (AUT-510).
Tuple Fields§
§0: Mutex<Option<EditorPreviewSession>>Implementations§
Source§impl EditorPreviewState
impl EditorPreviewState
Sourcepub fn open(&self, project: EditProject) -> Result<(), String>
pub fn open(&self, project: EditProject) -> Result<(), String>
Open or update the preview for project.
Re-opens the decode stream + compose pipeline only when the source clip or the output canvas changed (a new clip, or an aspect-ratio change that reshapes the canvas — AUT-513); otherwise it just swaps the stored project — re-applying the background only when it changed — so edits (zoom / speed / crop / cursor) take effect on the next composed frame without rebuilding wgpu on every keystroke.
§Errors
Returns a message if the source can’t be opened or the wgpu compose pipeline can’t be created.
Trait Implementations§
Source§impl Debug for EditorPreviewState
impl Debug for EditorPreviewState
Source§impl Default for EditorPreviewState
impl Default for EditorPreviewState
Source§fn default() -> EditorPreviewState
fn default() -> EditorPreviewState
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl !Freeze for EditorPreviewState
impl RefUnwindSafe for EditorPreviewState
impl Send for EditorPreviewState
impl Sync for EditorPreviewState
impl Unpin for EditorPreviewState
impl UnsafeUnpin for EditorPreviewState
impl UnwindSafe for EditorPreviewState
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian().