Merge branch 'master' into wgpu/better-architecture
This commit is contained in:
commit
13289dbd19
41 changed files with 318 additions and 267 deletions
|
|
@ -31,12 +31,13 @@ pub struct Frame {
|
|||
stroke_tessellator: tessellation::StrokeTessellator,
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
pub enum Geometry {
|
||||
Live { meshes: Vec<Mesh>, text: Vec<Text> },
|
||||
Cached(Cache),
|
||||
}
|
||||
|
||||
#[derive(Clone)]
|
||||
#[derive(Debug, Clone)]
|
||||
pub struct Cache {
|
||||
pub meshes: Option<triangle::Cache>,
|
||||
pub text: Option<text::Cache>,
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
pub use crate::graphics::Image;
|
||||
|
||||
#[derive(Default)]
|
||||
#[derive(Debug, Default)]
|
||||
pub struct Batch;
|
||||
|
||||
impl Batch {
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ use crate::quad::{self, Quad};
|
|||
use crate::text::{self, Text};
|
||||
use crate::triangle;
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct Layer {
|
||||
pub bounds: Rectangle,
|
||||
pub quads: quad::Batch,
|
||||
|
|
@ -28,6 +29,7 @@ impl Default for Layer {
|
|||
}
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct Stack {
|
||||
layers: Vec<Layer>,
|
||||
transformations: Vec<Transformation>,
|
||||
|
|
|
|||
|
|
@ -20,15 +20,8 @@
|
|||
#![doc(
|
||||
html_logo_url = "https://raw.githubusercontent.com/iced-rs/iced/9ab6923e943f784985e9ef9ca28b10278297225d/docs/logo.svg"
|
||||
)]
|
||||
#![forbid(rust_2018_idioms)]
|
||||
#![deny(
|
||||
// missing_debug_implementations,
|
||||
//missing_docs,
|
||||
unsafe_code,
|
||||
unused_results,
|
||||
rustdoc::broken_intra_doc_links
|
||||
)]
|
||||
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
|
||||
#![allow(missing_docs)]
|
||||
pub mod layer;
|
||||
pub mod primitive;
|
||||
pub mod settings;
|
||||
|
|
|
|||
|
|
@ -16,6 +16,7 @@ const INITIAL_VERTEX_COUNT: usize = 1_000;
|
|||
|
||||
pub type Batch = Vec<Item>;
|
||||
|
||||
#[derive(Debug)]
|
||||
pub enum Item {
|
||||
Group {
|
||||
transformation: Transformation,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue