servo: Update rust-stb-image

Source-Repo: https://github.com/servo/servo
Source-Revision: 0866359a100c34861e8306c2a1903ce43f9d3e6d
This commit is contained in:
Brian Anderson 2012-11-03 23:17:49 -07:00
parent 6c6760cfa1
commit a4687d12d5

View File

@ -22,7 +22,11 @@ fn test_image_bin() -> ~[u8] {
}
pub fn load_from_memory(buffer: &[u8]) -> Option<Image> {
do stb_image::load_from_memory(buffer).map |image| {
// Can't remember why we do this. Maybe it's what cairo wants
const FORCE_DEPTH: uint = 4;
do stb_image::load_from_memory_with_depth(buffer, FORCE_DEPTH).map |image| {
assert image.depth == 4;
// Do color space conversion :(