Struct imgui_vulkano_renderer_unsafe::Renderer[][src]

pub struct Renderer { /* fields omitted */ }

Implementations

impl Renderer[src]

pub fn init(
    ctx: &mut Context,
    device: Arc<Device>,
    queue: Arc<Queue>,
    format: Format
) -> Result<Renderer, RendererError>
[src]

Initialize the renderer object, including vertex buffers, ImGui font textures, and the Vulkan graphics pipeline.


ctx: the ImGui Context object

device: the Vulkano Device object for the device you want to render the UI on.

queue: the Vulkano Queue object for the queue the font atlas texture will be created on.

format: the Vulkano Format that the render pass will use when storing the frame in the target image.

pub fn draw_commands<I, P>(
    &mut self,
    cmd_buf_builder: &mut AutoCommandBufferBuilder<P>,
    _queue: Arc<Queue>,
    target: I,
    draw_data: &DrawData
) -> Result<(), RendererError> where
    I: ImageViewAccess + Send + Sync + 'static, 
[src]

Appends the draw commands for the UI frame to an AutoCommandBufferBuilder.


cmd_buf_builder: An AutoCommandBufferBuilder from vulkano to add commands to

device: the Vulkano Device object for the device you want to render the UI on

queue: the Vulkano Queue object for buffer creation

target: the target image to render to

draw_data: the ImGui DrawData that each UI frame creates

pub unsafe fn unsafe_draw_commands<I, P>(
    &mut self,
    cmd_buf_builder: &mut UnsafeCommandBufferBuilder<P>,
    _queue: Arc<Queue>,
    target: I,
    draw_data: &DrawData
) -> Result<(), RendererError> where
    I: ImageViewAccess + Send + Sync + 'static, 
[src]

pub fn reload_font_texture(
    &mut self,
    ctx: &mut Context,
    device: Arc<Device>,
    queue: Arc<Queue>
) -> Result<(), RendererError>
[src]

Update the ImGui font atlas texture.


ctx: the ImGui Context object

device: the Vulkano Device object for the device you want to render the UI on.

queue: the Vulkano Queue object for the queue the font atlas texture will be created on.

pub fn textures(&mut self) -> &mut Textures<Texture>[src]

Get the texture library that the renderer uses

Auto Trait Implementations

impl !RefUnwindSafe for Renderer

impl !Send for Renderer

impl !Sync for Renderer

impl Unpin for Renderer

impl !UnwindSafe for Renderer

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Content for T[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.