pub struct Engine<'q, NL: NativeLinker> { /* private fields */ }
Implementations§
Source§impl<'q, PL: NativeLinker> Engine<'q, PL>
impl<'q, PL: NativeLinker> Engine<'q, PL>
pub fn new( name: &str, version: Version, native_link: PL, requested_features: VkPhysicalDeviceFeatures, engine_events_bus: (Sender<EngineEvent>, Receiver<EngineEvent>), frame_timing_receiver: Receiver<()>, shared_event_queue: &'q EventQueue, ) -> Self
pub fn post_init(&mut self)
Source§impl<'q, NL: NativeLinker> Engine<'q, NL>
impl<'q, NL: NativeLinker> Engine<'q, NL>
pub fn event_receivers(&self) -> &mut EngineEventReceiver
pub fn next_event(&self) -> impl Future<Output = Event> + 'q
pub async fn quit(&self)
pub const fn graphics(&self) -> &Graphics
pub fn graphics_mut(&mut self) -> &mut Graphics
pub const fn graphics_device(&self) -> &VulkanGfx
pub const fn graphics_queue_family_index(&self) -> u32
pub const fn transfer_queue_family_index(&self) -> u32
pub fn back_buffer_format(&self) -> VkFormat
pub fn back_buffer_size(&self) -> Vector2<u32>
pub fn back_buffer_count(&self) -> usize
pub fn back_buffer(&self, index: usize) -> Option<VkHandleRef<'_, VkImage>>
pub fn iter_back_buffers<'s>( &'s self, ) -> impl Iterator<Item = VkHandleRef<'s, VkImage>> + 's
pub fn requesting_back_buffer_layout(&self) -> (ImageLayout, PipelineStageFlags)
pub fn back_buffer_attachment_desc(&self) -> VkAttachmentDescription
pub fn screen_size(&self) -> Vector2<u32>
pub fn input(&self) -> &InputProcess
pub fn input_mut(&mut self) -> &mut InputProcess
pub fn submit_commands( &mut self, generator: impl for<'a> FnOnce(CmdRecord<'a, VulkanGfx>) -> CmdRecord<'a, VulkanGfx>, ) -> Result<()>
pub fn submit_buffered_commands( &mut self, batches: &[SubmitInfo<'_, '_, '_>], fence: &mut impl VkHandleMut<Handle = VkFence>, ) -> Result<()>
pub const fn audio_mixer(&self) -> &Arc<RwLock<Mixer>>
Source§impl<PL: NativeLinker> Engine<'_, PL>
impl<PL: NativeLinker> Engine<'_, PL>
Source§impl<PL: NativeLinker> Engine<'_, PL>
impl<PL: NativeLinker> Engine<'_, PL>
pub fn prepare_frame(&mut self) -> Result<FrameData, PrepareFrameError>
pub fn do_render( &mut self, bb_index: u32, copy_submission: Option<SubmissionBatchBuilder<'_>>, render_submission: SubmissionBatchBuilder<'_>, ) -> Result<()>
pub fn wait_for_last_rendering_completion(&mut self) -> Result<()>
pub fn resize_presenter_backbuffers(&mut self, new_size: Vector2<u32>)
pub fn sound_backend_callback(&self, output_buffer: &mut [f32])
Trait Implementations§
Auto Trait Implementations§
impl<'q, NL> !Freeze for Engine<'q, NL>
impl<'q, NL> !RefUnwindSafe for Engine<'q, NL>
impl<'q, NL> !Send for Engine<'q, NL>
impl<'q, NL> !Sync for Engine<'q, NL>
impl<'q, NL> Unpin for Engine<'q, NL>
impl<'q, NL> !UnwindSafe for Engine<'q, NL>
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§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