pub fn import_from_file(&self, file_name: &str) -> Option<Scene> {
        unsafe {
            let cfile_name = CString::new(file_name).unwrap();
            let raw = ffi::aiImportFileExWithProperties(
                cfile_name.as_ptr(), 
                self.flags, 
                ptr::null_mut(), 
                self.property_store as *const ffi::PropertyStore);
            //let raw = file_name.with_c_str(|file|
                //ffi::aiImportFileExWithProperties(
                    //file,
                    //self.flags,
                    //ptr::null_mut(), // no custom file io system
                    //self.property_store as *const ffi::PropertyStore));
            if raw.is_null() {
                None
            } else {
                Some(Scene::from_raw_scene(raw))
            }
        }
    }
/// Create a `Scene` from the given file.
Create a `Scene` from the given file.
Create a ` Scene ` from the given file .
pub fn import_from_file(&self, file_name: &str) -> Option<Scene> {
        unsafe {
            let cfile_name = CString::new(file_name).unwrap();
            let raw = ffi::aiImportFileExWithProperties(
                cfile_name.as_ptr(), 
                self.flags, 
                ptr::null_mut(), 
                self.property_store as *const ffi::PropertyStore);
            //let raw = file_name.with_c_str(|file|
                //ffi::aiImportFileExWithProperties(
                    //file,
                    //self.flags,
                    //ptr::null_mut(), // no custom file io system
                    //self.property_store as *const ffi::PropertyStore));
            if raw.is_null() {
                None
            } else {
                Some(Scene::from_raw_scene(raw))
            }
        }
    }
pub fn import_from_file ( & self , file_name : & str ) -> Option < Scene > { unsafe { let cfile_name = CString :: new ( file_name ) . unwrap ( ) ; let raw = ffi :: aiImportFileExWithProperties ( cfile_name . as_ptr ( ) , self . flags , ptr :: null_mut ( ) , self . property_store as * const ffi :: PropertyStore ) ; //let raw = file_name.with_c_str(|file| //ffi::aiImportFileExWithProperties( //file, //self.flags, //ptr::null_mut(), // no custom file io system //self.property_store as *const ffi::PropertyStore)); if raw . is_null ( ) { None } else { Some ( Scene :: from_raw_scene ( raw ) ) } } }
Create a `Scene` from the given file.
Create a ` Scene ` from the given file .
&self
file_name
&str
&self
file_name
&str