Trait veloren_common_net::msg::compression::VoxelImageEncoding
source · pub trait VoxelImageEncoding {
type Workspace;
type Output;
// Required methods
fn create(width: u32, height: u32) -> Self::Workspace;
fn put_solid(
&self,
ws: &mut Self::Workspace,
x: u32,
y: u32,
kind: BlockKind,
rgb: Rgb<u8>,
);
fn put_sprite(
&self,
ws: &mut Self::Workspace,
x: u32,
y: u32,
kind: BlockKind,
sprite_data: [u8; 3],
);
fn finish(ws: &Self::Workspace) -> Option<Self::Output>;
}
Required Associated Types§
Required Methods§
fn create(width: u32, height: u32) -> Self::Workspace
fn put_solid( &self, ws: &mut Self::Workspace, x: u32, y: u32, kind: BlockKind, rgb: Rgb<u8>, )
fn put_sprite( &self, ws: &mut Self::Workspace, x: u32, y: u32, kind: BlockKind, sprite_data: [u8; 3], )
fn finish(ws: &Self::Workspace) -> Option<Self::Output>
Object Safety§
This trait is not object safe.