Struct psp::sys::SceFontNewLibParams
source · #[repr(C)]pub struct SceFontNewLibParams {
pub user_data_addr: u32,
pub num_fonts: u32,
pub cache_data: u32,
pub alloc_func: Option<extern "C" fn(unk_ptr: *mut c_void, amount: usize) -> *mut c_void>,
pub free_func: Option<extern "C" fn(unk_ptr: *mut c_void, ptr: *mut c_void)>,
pub open_func: Option<extern "C" fn(unk_ptr: *mut c_void, filename: *const u8, error_code: &mut SceFontErrorCode) -> SceUid>,
pub close_func: Option<extern "C" fn(unk_ptr: *mut c_void, fd: SceUid) -> SceFontErrorCode>,
pub read_func: Option<extern "C" fn(unk_ptr: *mut c_void, data: *mut c_void, type_size: u32) -> u32>,
pub seek_func: Option<extern "C" fn(unk_ptr: *mut c_void, fd: SceUid, offset: i32) -> SceFontErrorCode>,
pub error_func: Option<extern "C" fn()>,
pub io_finish_func: Option<extern "C" fn()>,
}
Expand description
The library works with only num_fonts, alloc_func, and free_func set to non-null values so long as you don’t load a font from a file. Function signatures reversed from 11 Eyes Crossover.
Fields§
§user_data_addr: u32
§num_fonts: u32
§cache_data: u32
§alloc_func: Option<extern "C" fn(unk_ptr: *mut c_void, amount: usize) -> *mut c_void>
Returns pointer to allocated memory
free_func: Option<extern "C" fn(unk_ptr: *mut c_void, ptr: *mut c_void)>
§open_func: Option<extern "C" fn(unk_ptr: *mut c_void, filename: *const u8, error_code: &mut SceFontErrorCode) -> SceUid>
Returns fd of opened file
close_func: Option<extern "C" fn(unk_ptr: *mut c_void, fd: SceUid) -> SceFontErrorCode>
Returns an SceFontErrorCode
read_func: Option<extern "C" fn(unk_ptr: *mut c_void, data: *mut c_void, type_size: u32) -> u32>
Returns number of “type“s read (ie bytes_read / type_size)
seek_func: Option<extern "C" fn(unk_ptr: *mut c_void, fd: SceUid, offset: i32) -> SceFontErrorCode>
Returns an SceFontErrorCode
error_func: Option<extern "C" fn()>
Unknown, pass None
io_finish_func: Option<extern "C" fn()>
Unknown, pass None
Trait Implementations§
source§impl Clone for SceFontNewLibParams
impl Clone for SceFontNewLibParams
source§fn clone(&self) -> SceFontNewLibParams
fn clone(&self) -> SceFontNewLibParams
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreimpl Copy for SceFontNewLibParams
Auto Trait Implementations§
impl Freeze for SceFontNewLibParams
impl RefUnwindSafe for SceFontNewLibParams
impl Send for SceFontNewLibParams
impl Sync for SceFontNewLibParams
impl Unpin for SceFontNewLibParams
impl UnwindSafe for SceFontNewLibParams
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