Skip to content

Commit

Permalink
Merge pull request #170 from wilcockj/master
Browse files Browse the repository at this point in the history
added comment explaining filetype variable of load_image_from_mem
  • Loading branch information
Dacode45 authored Sep 17, 2023
2 parents 0cb8626 + 2a671db commit 31776ec
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion raylib/src/core/texture.rs
Original file line number Diff line number Diff line change
Expand Up @@ -692,8 +692,9 @@ impl Image {
}
Ok(Image(i))
}

/// Loads image from a given memory buffer as a vector of arrays
/// ensure filetype is extension, for example, ".png"
pub fn load_image_from_mem(filetype: &str, bytes: &Vec<u8>, size: i32) -> Result<Image, String> {
let c_filetype = CString::new(filetype).unwrap();
let c_bytes = bytes.as_ptr();
Expand Down

0 comments on commit 31776ec

Please sign in to comment.