Skip to content

attrib::Info::check<T>(&self) -> bool #55

@LexiBigCheese

Description

@LexiBigCheese
impl attrib::Info {
  pub fn check<T>(&self) -> bool {
    std::mem::size_of<T>() == self.size
  }
}

use when creating buffer slices to ensure one vertex is one struct (though allow user to bypass this functionality at their own risk, for example, if they just want to send u8, but point them at bytemuck first)

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions