pub struct Parser { /* private fields */ }Implementations§
Source§impl Parser
impl Parser
pub fn parse_file( &mut self, fs: Option<&HostFileSystem>, file_path: &str, ) -> Option<Model>
pub fn parse_casc_fs_buffer( &mut self, casc_fs: &[u8], buffer: &[u8], ) -> Option<Model>
Sourcepub fn set_lazy_animations(&mut self, enable: bool)
pub fn set_lazy_animations(&mut self, enable: bool)
Leave the keys of sequences stored in .anim siblings unread until m2::loadSequence() asks for them. Off by default.
This is what the client does — nothing reads a .anim until something plays that sequence — and on a character model with a hundred of them it is the difference between a load that reads one file and one that reads a hundred. See sequence_loader.h.
The @p fs passed to parse() has to outlive the returned Model, because the deferred reads go back through it.
pub fn has_issues(&self) -> bool
pub fn issues(&self) -> Vec<String>
Trait Implementations§
impl Send for Parser
Auto Trait Implementations§
impl !Sync for Parser
impl Freeze for Parser
impl RefUnwindSafe for Parser
impl Unpin for Parser
impl UnsafeUnpin for Parser
impl UnwindSafe for Parser
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