From 023051d400f45be58891db6b2de4528b55cac356 Mon Sep 17 00:00:00 2001 From: Cobrand Date: Wed, 3 Apr 2019 13:04:54 +0000 Subject: [PATCH] Make ttf,image,mixer,gfx work withut use-bindgen --- sdl2-sys/sdl_gfx_framerate_bindings.rs | 22 +- sdl2-sys/sdl_gfx_imagefilter_bindings.rs | 280 +++++++++++----------- sdl2-sys/sdl_gfx_primitives_bindings.rs | 158 ++++++------ sdl2-sys/sdl_gfx_rotozoom_bindings.rs | 42 ++-- sdl2-sys/sdl_image_bindings.rs | 83 ++++--- sdl2-sys/sdl_mixer_bindings.rs | 292 ++++++++++------------- sdl2-sys/sdl_ttf_bindings.rs | 135 ++++++----- 7 files changed, 481 insertions(+), 531 deletions(-) diff --git a/sdl2-sys/sdl_gfx_framerate_bindings.rs b/sdl2-sys/sdl_gfx_framerate_bindings.rs index 4f836f7c..e1d54a12 100644 --- a/sdl2-sys/sdl_gfx_framerate_bindings.rs +++ b/sdl2-sys/sdl_gfx_framerate_bindings.rs @@ -3,7 +3,7 @@ pub const FPS_UPPER_LIMIT: u32 = 200; pub const FPS_LOWER_LIMIT: u32 = 1; pub const FPS_DEFAULT: u32 = 30; -pub type __uint32_t = ::std::os::raw::c_uint; +pub type __uint32_t = libc::c_uint; pub type Uint32 = u32; #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -17,17 +17,17 @@ pub struct FPSmanager { #[test] fn bindgen_test_layout_FPSmanager() { assert_eq!( - ::std::mem::size_of::(), + ::core::mem::size_of::(), 20usize, concat!("Size of: ", stringify!(FPSmanager)) ); assert_eq!( - ::std::mem::align_of::(), + ::core::mem::align_of::(), 4usize, concat!("Alignment of ", stringify!(FPSmanager)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::())).framecount as *const _ as usize }, + unsafe { &(*(::core::ptr::null::())).framecount as *const _ as usize }, 0usize, concat!( "Offset of field: ", @@ -37,7 +37,7 @@ fn bindgen_test_layout_FPSmanager() { ) ); assert_eq!( - unsafe { &(*(::std::ptr::null::())).rateticks as *const _ as usize }, + unsafe { &(*(::core::ptr::null::())).rateticks as *const _ as usize }, 4usize, concat!( "Offset of field: ", @@ -47,7 +47,7 @@ fn bindgen_test_layout_FPSmanager() { ) ); assert_eq!( - unsafe { &(*(::std::ptr::null::())).baseticks as *const _ as usize }, + unsafe { &(*(::core::ptr::null::())).baseticks as *const _ as usize }, 8usize, concat!( "Offset of field: ", @@ -57,7 +57,7 @@ fn bindgen_test_layout_FPSmanager() { ) ); assert_eq!( - unsafe { &(*(::std::ptr::null::())).lastticks as *const _ as usize }, + unsafe { &(*(::core::ptr::null::())).lastticks as *const _ as usize }, 12usize, concat!( "Offset of field: ", @@ -67,7 +67,7 @@ fn bindgen_test_layout_FPSmanager() { ) ); assert_eq!( - unsafe { &(*(::std::ptr::null::())).rate as *const _ as usize }, + unsafe { &(*(::core::ptr::null::())).rate as *const _ as usize }, 16usize, concat!( "Offset of field: ", @@ -81,13 +81,13 @@ extern "C" { pub fn SDL_initFramerate(manager: *mut FPSmanager); } extern "C" { - pub fn SDL_setFramerate(manager: *mut FPSmanager, rate: Uint32) -> ::std::os::raw::c_int; + pub fn SDL_setFramerate(manager: *mut FPSmanager, rate: Uint32) -> libc::c_int; } extern "C" { - pub fn SDL_getFramerate(manager: *mut FPSmanager) -> ::std::os::raw::c_int; + pub fn SDL_getFramerate(manager: *mut FPSmanager) -> libc::c_int; } extern "C" { - pub fn SDL_getFramecount(manager: *mut FPSmanager) -> ::std::os::raw::c_int; + pub fn SDL_getFramecount(manager: *mut FPSmanager) -> libc::c_int; } extern "C" { pub fn SDL_framerateDelay(manager: *mut FPSmanager) -> Uint32; diff --git a/sdl2-sys/sdl_gfx_imagefilter_bindings.rs b/sdl2-sys/sdl_gfx_imagefilter_bindings.rs index 4ba0182f..ca5d68c5 100644 --- a/sdl2-sys/sdl_gfx_imagefilter_bindings.rs +++ b/sdl2-sys/sdl_gfx_imagefilter_bindings.rs @@ -1,7 +1,7 @@ /* automatically generated by rust-bindgen */ extern "C" { - pub fn SDL_imageFilterMMXdetect() -> ::std::os::raw::c_int; + pub fn SDL_imageFilterMMXdetect() -> libc::c_int; } extern "C" { pub fn SDL_imageFilterMMXoff(); @@ -11,221 +11,221 @@ extern "C" { } extern "C" { pub fn SDL_imageFilterAdd( - Src1: *mut ::std::os::raw::c_uchar, - Src2: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Src2: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterMean( - Src1: *mut ::std::os::raw::c_uchar, - Src2: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Src2: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterSub( - Src1: *mut ::std::os::raw::c_uchar, - Src2: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Src2: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterAbsDiff( - Src1: *mut ::std::os::raw::c_uchar, - Src2: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Src2: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterMult( - Src1: *mut ::std::os::raw::c_uchar, - Src2: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Src2: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterMultNor( - Src1: *mut ::std::os::raw::c_uchar, - Src2: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Src2: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterMultDivby2( - Src1: *mut ::std::os::raw::c_uchar, - Src2: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Src2: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterMultDivby4( - Src1: *mut ::std::os::raw::c_uchar, - Src2: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Src2: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterBitAnd( - Src1: *mut ::std::os::raw::c_uchar, - Src2: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Src2: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterBitOr( - Src1: *mut ::std::os::raw::c_uchar, - Src2: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Src2: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterDiv( - Src1: *mut ::std::os::raw::c_uchar, - Src2: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Src2: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterBitNegation( - Src1: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterAddByte( - Src1: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - C: ::std::os::raw::c_uchar, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + C: libc::c_uchar, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterAddUint( - Src1: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - C: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + C: libc::c_uint, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterAddByteToHalf( - Src1: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - C: ::std::os::raw::c_uchar, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + C: libc::c_uchar, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterSubByte( - Src1: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - C: ::std::os::raw::c_uchar, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + C: libc::c_uchar, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterSubUint( - Src1: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - C: ::std::os::raw::c_uint, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + C: libc::c_uint, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterShiftRight( - Src1: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - N: ::std::os::raw::c_uchar, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + N: libc::c_uchar, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterShiftRightUint( - Src1: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - N: ::std::os::raw::c_uchar, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + N: libc::c_uchar, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterMultByByte( - Src1: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - C: ::std::os::raw::c_uchar, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + C: libc::c_uchar, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterShiftRightAndMultByByte( - Src1: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - N: ::std::os::raw::c_uchar, - C: ::std::os::raw::c_uchar, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + N: libc::c_uchar, + C: libc::c_uchar, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterShiftLeftByte( - Src1: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - N: ::std::os::raw::c_uchar, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + N: libc::c_uchar, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterShiftLeftUint( - Src1: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - N: ::std::os::raw::c_uchar, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + N: libc::c_uchar, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterShiftLeft( - Src1: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - N: ::std::os::raw::c_uchar, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + N: libc::c_uchar, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterBinarizeUsingThreshold( - Src1: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - T: ::std::os::raw::c_uchar, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + T: libc::c_uchar, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterClipToRange( - Src1: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - Tmin: ::std::os::raw::c_uchar, - Tmax: ::std::os::raw::c_uchar, - ) -> ::std::os::raw::c_int; + Src1: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + Tmin: libc::c_uchar, + Tmax: libc::c_uchar, + ) -> libc::c_int; } extern "C" { pub fn SDL_imageFilterNormalizeLinear( - Src: *mut ::std::os::raw::c_uchar, - Dest: *mut ::std::os::raw::c_uchar, - length: ::std::os::raw::c_uint, - Cmin: ::std::os::raw::c_int, - Cmax: ::std::os::raw::c_int, - Nmin: ::std::os::raw::c_int, - Nmax: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + Src: *mut libc::c_uchar, + Dest: *mut libc::c_uchar, + length: libc::c_uint, + Cmin: libc::c_int, + Cmax: libc::c_int, + Nmin: libc::c_int, + Nmax: libc::c_int, + ) -> libc::c_int; } diff --git a/sdl2-sys/sdl_gfx_primitives_bindings.rs b/sdl2-sys/sdl_gfx_primitives_bindings.rs index 517a2542..4df10c1c 100644 --- a/sdl2-sys/sdl_gfx_primitives_bindings.rs +++ b/sdl2-sys/sdl_gfx_primitives_bindings.rs @@ -1,8 +1,10 @@ /* automatically generated by rust-bindgen */ -pub type __uint8_t = ::std::os::raw::c_uchar; -pub type __int16_t = ::std::os::raw::c_short; -pub type __uint32_t = ::std::os::raw::c_uint; +use crate::*; + +pub type __uint8_t = libc::c_uchar; +pub type __int16_t = libc::c_short; +pub type __uint32_t = libc::c_uint; pub type Uint8 = u8; pub type Sint16 = i16; pub type Uint32 = u32; @@ -12,7 +14,7 @@ extern "C" { x: Sint16, y: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn pixelRGBA( @@ -23,7 +25,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn hlineColor( @@ -32,7 +34,7 @@ extern "C" { x2: Sint16, y: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn hlineRGBA( @@ -44,7 +46,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn vlineColor( @@ -53,7 +55,7 @@ extern "C" { y1: Sint16, y2: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn vlineRGBA( @@ -65,7 +67,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn rectangleColor( @@ -75,7 +77,7 @@ extern "C" { x2: Sint16, y2: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn rectangleRGBA( @@ -88,7 +90,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn roundedRectangleColor( @@ -99,7 +101,7 @@ extern "C" { y2: Sint16, rad: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn roundedRectangleRGBA( @@ -113,7 +115,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn boxColor( @@ -123,7 +125,7 @@ extern "C" { x2: Sint16, y2: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn boxRGBA( @@ -136,7 +138,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn roundedBoxColor( @@ -147,7 +149,7 @@ extern "C" { y2: Sint16, rad: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn roundedBoxRGBA( @@ -161,7 +163,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn lineColor( @@ -171,7 +173,7 @@ extern "C" { x2: Sint16, y2: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn lineRGBA( @@ -184,7 +186,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn aalineColor( @@ -194,7 +196,7 @@ extern "C" { x2: Sint16, y2: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn aalineRGBA( @@ -207,7 +209,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn thickLineColor( @@ -218,7 +220,7 @@ extern "C" { y2: Sint16, width: Uint8, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn thickLineRGBA( @@ -232,7 +234,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn circleColor( @@ -241,7 +243,7 @@ extern "C" { y: Sint16, rad: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn circleRGBA( @@ -253,7 +255,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn arcColor( @@ -264,7 +266,7 @@ extern "C" { start: Sint16, end: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn arcRGBA( @@ -278,7 +280,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn aacircleColor( @@ -287,7 +289,7 @@ extern "C" { y: Sint16, rad: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn aacircleRGBA( @@ -299,7 +301,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn filledCircleColor( @@ -308,7 +310,7 @@ extern "C" { y: Sint16, r: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn filledCircleRGBA( @@ -320,7 +322,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn ellipseColor( @@ -330,7 +332,7 @@ extern "C" { rx: Sint16, ry: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn ellipseRGBA( @@ -343,7 +345,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn aaellipseColor( @@ -353,7 +355,7 @@ extern "C" { rx: Sint16, ry: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn aaellipseRGBA( @@ -366,7 +368,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn filledEllipseColor( @@ -376,7 +378,7 @@ extern "C" { rx: Sint16, ry: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn filledEllipseRGBA( @@ -389,7 +391,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn pieColor( @@ -400,7 +402,7 @@ extern "C" { start: Sint16, end: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn pieRGBA( @@ -414,7 +416,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn filledPieColor( @@ -425,7 +427,7 @@ extern "C" { start: Sint16, end: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn filledPieRGBA( @@ -439,7 +441,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn trigonColor( @@ -451,7 +453,7 @@ extern "C" { x3: Sint16, y3: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn trigonRGBA( @@ -466,7 +468,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn aatrigonColor( @@ -478,7 +480,7 @@ extern "C" { x3: Sint16, y3: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn aatrigonRGBA( @@ -493,7 +495,7 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn filledTrigonColor( @@ -505,7 +507,7 @@ extern "C" { x3: Sint16, y3: Sint16, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn filledTrigonRGBA( @@ -520,107 +522,107 @@ extern "C" { g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn polygonColor( renderer: *mut SDL_Renderer, vx: *const Sint16, vy: *const Sint16, - n: ::std::os::raw::c_int, + n: libc::c_int, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn polygonRGBA( renderer: *mut SDL_Renderer, vx: *const Sint16, vy: *const Sint16, - n: ::std::os::raw::c_int, + n: libc::c_int, r: Uint8, g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn aapolygonColor( renderer: *mut SDL_Renderer, vx: *const Sint16, vy: *const Sint16, - n: ::std::os::raw::c_int, + n: libc::c_int, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn aapolygonRGBA( renderer: *mut SDL_Renderer, vx: *const Sint16, vy: *const Sint16, - n: ::std::os::raw::c_int, + n: libc::c_int, r: Uint8, g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn filledPolygonColor( renderer: *mut SDL_Renderer, vx: *const Sint16, vy: *const Sint16, - n: ::std::os::raw::c_int, + n: libc::c_int, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn filledPolygonRGBA( renderer: *mut SDL_Renderer, vx: *const Sint16, vy: *const Sint16, - n: ::std::os::raw::c_int, + n: libc::c_int, r: Uint8, g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn texturedPolygon( renderer: *mut SDL_Renderer, vx: *const Sint16, vy: *const Sint16, - n: ::std::os::raw::c_int, + n: libc::c_int, texture: *mut SDL_Surface, - texture_dx: ::std::os::raw::c_int, - texture_dy: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + texture_dx: libc::c_int, + texture_dy: libc::c_int, + ) -> libc::c_int; } extern "C" { pub fn bezierColor( renderer: *mut SDL_Renderer, vx: *const Sint16, vy: *const Sint16, - n: ::std::os::raw::c_int, - s: ::std::os::raw::c_int, + n: libc::c_int, + s: libc::c_int, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn bezierRGBA( renderer: *mut SDL_Renderer, vx: *const Sint16, vy: *const Sint16, - n: ::std::os::raw::c_int, - s: ::std::os::raw::c_int, + n: libc::c_int, + s: libc::c_int, r: Uint8, g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { - pub fn gfxPrimitivesSetFont(fontdata: *const ::libc::c_void, cw: Uint32, ch: Uint32); + pub fn gfxPrimitivesSetFont(fontdata: *const libc::c_void, cw: Uint32, ch: Uint32); } extern "C" { pub fn gfxPrimitivesSetFontRotation(rotation: Uint32); @@ -630,40 +632,40 @@ extern "C" { renderer: *mut SDL_Renderer, x: Sint16, y: Sint16, - c: ::std::os::raw::c_char, + c: libc::c_char, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn characterRGBA( renderer: *mut SDL_Renderer, x: Sint16, y: Sint16, - c: ::std::os::raw::c_char, + c: libc::c_char, r: Uint8, g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn stringColor( renderer: *mut SDL_Renderer, x: Sint16, y: Sint16, - s: *const ::std::os::raw::c_char, + s: *const libc::c_char, color: Uint32, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn stringRGBA( renderer: *mut SDL_Renderer, x: Sint16, y: Sint16, - s: *const ::std::os::raw::c_char, + s: *const libc::c_char, r: Uint8, g: Uint8, b: Uint8, a: Uint8, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } diff --git a/sdl2-sys/sdl_gfx_rotozoom_bindings.rs b/sdl2-sys/sdl_gfx_rotozoom_bindings.rs index 76d40d94..370cc910 100644 --- a/sdl2-sys/sdl_gfx_rotozoom_bindings.rs +++ b/sdl2-sys/sdl_gfx_rotozoom_bindings.rs @@ -1,7 +1,9 @@ /* automatically generated by rust-bindgen */ -pub type __uint8_t = ::std::os::raw::c_uchar; -pub type __uint32_t = ::std::os::raw::c_uint; +use crate::*; + +pub type __uint8_t = libc::c_uchar; +pub type __uint32_t = libc::c_uint; pub type Uint8 = u8; pub type Uint32 = u32; extern "C" { @@ -9,7 +11,7 @@ extern "C" { src: *mut SDL_Surface, angle: f64, zoom: f64, - smooth: ::std::os::raw::c_int, + smooth: libc::c_int, ) -> *mut SDL_Surface; } extern "C" { @@ -18,28 +20,28 @@ extern "C" { angle: f64, zoomx: f64, zoomy: f64, - smooth: ::std::os::raw::c_int, + smooth: libc::c_int, ) -> *mut SDL_Surface; } extern "C" { pub fn rotozoomSurfaceSize( - width: ::std::os::raw::c_int, - height: ::std::os::raw::c_int, + width: libc::c_int, + height: libc::c_int, angle: f64, zoom: f64, - dstwidth: *mut ::std::os::raw::c_int, - dstheight: *mut ::std::os::raw::c_int, + dstwidth: *mut libc::c_int, + dstheight: *mut libc::c_int, ); } extern "C" { pub fn rotozoomSurfaceSizeXY( - width: ::std::os::raw::c_int, - height: ::std::os::raw::c_int, + width: libc::c_int, + height: libc::c_int, angle: f64, zoomx: f64, zoomy: f64, - dstwidth: *mut ::std::os::raw::c_int, - dstheight: *mut ::std::os::raw::c_int, + dstwidth: *mut libc::c_int, + dstheight: *mut libc::c_int, ); } extern "C" { @@ -47,29 +49,29 @@ extern "C" { src: *mut SDL_Surface, zoomx: f64, zoomy: f64, - smooth: ::std::os::raw::c_int, + smooth: libc::c_int, ) -> *mut SDL_Surface; } extern "C" { pub fn zoomSurfaceSize( - width: ::std::os::raw::c_int, - height: ::std::os::raw::c_int, + width: libc::c_int, + height: libc::c_int, zoomx: f64, zoomy: f64, - dstwidth: *mut ::std::os::raw::c_int, - dstheight: *mut ::std::os::raw::c_int, + dstwidth: *mut libc::c_int, + dstheight: *mut libc::c_int, ); } extern "C" { pub fn shrinkSurface( src: *mut SDL_Surface, - factorx: ::std::os::raw::c_int, - factory: ::std::os::raw::c_int, + factorx: libc::c_int, + factory: libc::c_int, ) -> *mut SDL_Surface; } extern "C" { pub fn rotateSurface90Degrees( src: *mut SDL_Surface, - numClockwiseTurns: ::std::os::raw::c_int, + numClockwiseTurns: libc::c_int, ) -> *mut SDL_Surface; } diff --git a/sdl2-sys/sdl_image_bindings.rs b/sdl2-sys/sdl_image_bindings.rs index 0b482607..8fa66d3b 100644 --- a/sdl2-sys/sdl_image_bindings.rs +++ b/sdl2-sys/sdl_image_bindings.rs @@ -1,10 +1,12 @@ /* automatically generated by rust-bindgen */ -pub type __uint8_t = ::std::os::raw::c_uchar; -pub type __uint32_t = ::std::os::raw::c_uint; -pub type __int64_t = ::std::os::raw::c_long; -pub type __off_t = ::std::os::raw::c_long; -pub type __off64_t = ::std::os::raw::c_long; +use crate::*; + +pub type __uint8_t = libc::c_uchar; +pub type __uint32_t = libc::c_uint; +pub type __int64_t = libc::c_long; +pub type __off_t = libc::c_long; +pub type __off64_t = libc::c_long; pub type Uint8 = u8; pub type Uint32 = u32; pub type Sint64 = i64; @@ -17,7 +19,7 @@ pub const IMG_InitFlags_IMG_INIT_TIF: IMG_InitFlags = 4; pub const IMG_InitFlags_IMG_INIT_WEBP: IMG_InitFlags = 8; pub type IMG_InitFlags = u32; extern "C" { - pub fn IMG_Init(flags: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn IMG_Init(flags: libc::c_int) -> libc::c_int; } extern "C" { pub fn IMG_Quit(); @@ -25,81 +27,81 @@ extern "C" { extern "C" { pub fn IMG_LoadTyped_RW( src: *mut SDL_RWops, - freesrc: ::std::os::raw::c_int, - type_: *const ::std::os::raw::c_char, + freesrc: libc::c_int, + type_: *const libc::c_char, ) -> *mut SDL_Surface; } extern "C" { - pub fn IMG_Load(file: *const ::std::os::raw::c_char) -> *mut SDL_Surface; + pub fn IMG_Load(file: *const libc::c_char) -> *mut SDL_Surface; } extern "C" { - pub fn IMG_Load_RW(src: *mut SDL_RWops, freesrc: ::std::os::raw::c_int) -> *mut SDL_Surface; + pub fn IMG_Load_RW(src: *mut SDL_RWops, freesrc: libc::c_int) -> *mut SDL_Surface; } extern "C" { pub fn IMG_LoadTexture( renderer: *mut SDL_Renderer, - file: *const ::std::os::raw::c_char, + file: *const libc::c_char, ) -> *mut SDL_Texture; } extern "C" { pub fn IMG_LoadTexture_RW( renderer: *mut SDL_Renderer, src: *mut SDL_RWops, - freesrc: ::std::os::raw::c_int, + freesrc: libc::c_int, ) -> *mut SDL_Texture; } extern "C" { pub fn IMG_LoadTextureTyped_RW( renderer: *mut SDL_Renderer, src: *mut SDL_RWops, - freesrc: ::std::os::raw::c_int, - type_: *const ::std::os::raw::c_char, + freesrc: libc::c_int, + type_: *const libc::c_char, ) -> *mut SDL_Texture; } extern "C" { - pub fn IMG_isICO(src: *mut SDL_RWops) -> ::std::os::raw::c_int; + pub fn IMG_isICO(src: *mut SDL_RWops) -> libc::c_int; } extern "C" { - pub fn IMG_isCUR(src: *mut SDL_RWops) -> ::std::os::raw::c_int; + pub fn IMG_isCUR(src: *mut SDL_RWops) -> libc::c_int; } extern "C" { - pub fn IMG_isBMP(src: *mut SDL_RWops) -> ::std::os::raw::c_int; + pub fn IMG_isBMP(src: *mut SDL_RWops) -> libc::c_int; } extern "C" { - pub fn IMG_isGIF(src: *mut SDL_RWops) -> ::std::os::raw::c_int; + pub fn IMG_isGIF(src: *mut SDL_RWops) -> libc::c_int; } extern "C" { - pub fn IMG_isJPG(src: *mut SDL_RWops) -> ::std::os::raw::c_int; + pub fn IMG_isJPG(src: *mut SDL_RWops) -> libc::c_int; } extern "C" { - pub fn IMG_isLBM(src: *mut SDL_RWops) -> ::std::os::raw::c_int; + pub fn IMG_isLBM(src: *mut SDL_RWops) -> libc::c_int; } extern "C" { - pub fn IMG_isPCX(src: *mut SDL_RWops) -> ::std::os::raw::c_int; + pub fn IMG_isPCX(src: *mut SDL_RWops) -> libc::c_int; } extern "C" { - pub fn IMG_isPNG(src: *mut SDL_RWops) -> ::std::os::raw::c_int; + pub fn IMG_isPNG(src: *mut SDL_RWops) -> libc::c_int; } extern "C" { - pub fn IMG_isPNM(src: *mut SDL_RWops) -> ::std::os::raw::c_int; + pub fn IMG_isPNM(src: *mut SDL_RWops) -> libc::c_int; } extern "C" { - pub fn IMG_isSVG(src: *mut SDL_RWops) -> ::std::os::raw::c_int; + pub fn IMG_isSVG(src: *mut SDL_RWops) -> libc::c_int; } extern "C" { - pub fn IMG_isTIF(src: *mut SDL_RWops) -> ::std::os::raw::c_int; + pub fn IMG_isTIF(src: *mut SDL_RWops) -> libc::c_int; } extern "C" { - pub fn IMG_isXCF(src: *mut SDL_RWops) -> ::std::os::raw::c_int; + pub fn IMG_isXCF(src: *mut SDL_RWops) -> libc::c_int; } extern "C" { - pub fn IMG_isXPM(src: *mut SDL_RWops) -> ::std::os::raw::c_int; + pub fn IMG_isXPM(src: *mut SDL_RWops) -> libc::c_int; } extern "C" { - pub fn IMG_isXV(src: *mut SDL_RWops) -> ::std::os::raw::c_int; + pub fn IMG_isXV(src: *mut SDL_RWops) -> libc::c_int; } extern "C" { - pub fn IMG_isWEBP(src: *mut SDL_RWops) -> ::std::os::raw::c_int; + pub fn IMG_isWEBP(src: *mut SDL_RWops) -> libc::c_int; } extern "C" { pub fn IMG_LoadICO_RW(src: *mut SDL_RWops) -> *mut SDL_Surface; @@ -150,33 +152,30 @@ extern "C" { pub fn IMG_LoadWEBP_RW(src: *mut SDL_RWops) -> *mut SDL_Surface; } extern "C" { - pub fn IMG_ReadXPMFromArray(xpm: *mut *mut ::std::os::raw::c_char) -> *mut SDL_Surface; + pub fn IMG_ReadXPMFromArray(xpm: *mut *mut libc::c_char) -> *mut SDL_Surface; } extern "C" { - pub fn IMG_SavePNG( - surface: *mut SDL_Surface, - file: *const ::std::os::raw::c_char, - ) -> ::std::os::raw::c_int; + pub fn IMG_SavePNG(surface: *mut SDL_Surface, file: *const libc::c_char) -> libc::c_int; } extern "C" { pub fn IMG_SavePNG_RW( surface: *mut SDL_Surface, dst: *mut SDL_RWops, - freedst: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + freedst: libc::c_int, + ) -> libc::c_int; } extern "C" { pub fn IMG_SaveJPG( surface: *mut SDL_Surface, - file: *const ::std::os::raw::c_char, - quality: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + file: *const libc::c_char, + quality: libc::c_int, + ) -> libc::c_int; } extern "C" { pub fn IMG_SaveJPG_RW( surface: *mut SDL_Surface, dst: *mut SDL_RWops, - freedst: ::std::os::raw::c_int, - quality: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + freedst: libc::c_int, + quality: libc::c_int, + ) -> libc::c_int; } diff --git a/sdl2-sys/sdl_mixer_bindings.rs b/sdl2-sys/sdl_mixer_bindings.rs index b0fe8c62..5f91ceaa 100644 --- a/sdl2-sys/sdl_mixer_bindings.rs +++ b/sdl2-sys/sdl_mixer_bindings.rs @@ -1,8 +1,10 @@ /* automatically generated by rust-bindgen */ +use crate::*; + pub const MIX_MAJOR_VERSION: u32 = 2; pub const MIX_MINOR_VERSION: u32 = 0; -pub const MIX_PATCHLEVEL: u32 = 2; +pub const MIX_PATCHLEVEL: u32 = 4; pub const MIX_CHANNELS: u32 = 8; pub const MIX_DEFAULT_FREQUENCY: u32 = 22050; pub const MIX_DEFAULT_FORMAT: u32 = 32784; @@ -10,13 +12,13 @@ pub const MIX_DEFAULT_CHANNELS: u32 = 2; pub const MIX_MAX_VOLUME: u32 = 128; pub const MIX_CHANNEL_POST: i32 = -2; pub const MIX_EFFECTSMAXSPEED: &'static [u8; 20usize] = b"MIX_EFFECTSMAXSPEED\0"; -pub type __uint8_t = ::std::os::raw::c_uchar; -pub type __int16_t = ::std::os::raw::c_short; -pub type __uint16_t = ::std::os::raw::c_ushort; -pub type __uint32_t = ::std::os::raw::c_uint; -pub type __int64_t = ::std::os::raw::c_long; -pub type __off_t = ::std::os::raw::c_long; -pub type __off64_t = ::std::os::raw::c_long; +pub type __uint8_t = libc::c_uchar; +pub type __int16_t = libc::c_short; +pub type __uint16_t = libc::c_ushort; +pub type __uint32_t = libc::c_uint; +pub type __int64_t = libc::c_long; +pub type __off_t = libc::c_long; +pub type __off64_t = libc::c_long; pub type Uint8 = u8; pub type Sint16 = i16; pub type Uint16 = u16; @@ -30,9 +32,10 @@ pub const MIX_InitFlags_MIX_INIT_MOD: MIX_InitFlags = 2; pub const MIX_InitFlags_MIX_INIT_MP3: MIX_InitFlags = 8; pub const MIX_InitFlags_MIX_INIT_OGG: MIX_InitFlags = 16; pub const MIX_InitFlags_MIX_INIT_MID: MIX_InitFlags = 32; +pub const MIX_InitFlags_MIX_INIT_OPUS: MIX_InitFlags = 64; pub type MIX_InitFlags = u32; extern "C" { - pub fn Mix_Init(flags: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn Mix_Init(flags: libc::c_int) -> libc::c_int; } extern "C" { pub fn Mix_Quit(); @@ -40,7 +43,7 @@ extern "C" { #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct Mix_Chunk { - pub allocated: ::std::os::raw::c_int, + pub allocated: libc::c_int, pub abuf: *mut Uint8, pub alen: Uint32, pub volume: Uint8, @@ -48,17 +51,17 @@ pub struct Mix_Chunk { #[test] fn bindgen_test_layout_Mix_Chunk() { assert_eq!( - ::std::mem::size_of::(), + ::core::mem::size_of::(), 24usize, concat!("Size of: ", stringify!(Mix_Chunk)) ); assert_eq!( - ::std::mem::align_of::(), + ::core::mem::align_of::(), 8usize, concat!("Alignment of ", stringify!(Mix_Chunk)) ); assert_eq!( - unsafe { &(*(::std::ptr::null::())).allocated as *const _ as usize }, + unsafe { &(*(::core::ptr::null::())).allocated as *const _ as usize }, 0usize, concat!( "Offset of field: ", @@ -68,7 +71,7 @@ fn bindgen_test_layout_Mix_Chunk() { ) ); assert_eq!( - unsafe { &(*(::std::ptr::null::())).abuf as *const _ as usize }, + unsafe { &(*(::core::ptr::null::())).abuf as *const _ as usize }, 8usize, concat!( "Offset of field: ", @@ -78,7 +81,7 @@ fn bindgen_test_layout_Mix_Chunk() { ) ); assert_eq!( - unsafe { &(*(::std::ptr::null::())).alen as *const _ as usize }, + unsafe { &(*(::core::ptr::null::())).alen as *const _ as usize }, 16usize, concat!( "Offset of field: ", @@ -88,7 +91,7 @@ fn bindgen_test_layout_Mix_Chunk() { ) ); assert_eq!( - unsafe { &(*(::std::ptr::null::())).volume as *const _ as usize }, + unsafe { &(*(::core::ptr::null::())).volume as *const _ as usize }, 20usize, concat!( "Offset of field: ", @@ -112,6 +115,7 @@ pub const Mix_MusicType_MUS_MP3: Mix_MusicType = 6; pub const Mix_MusicType_MUS_MP3_MAD_UNUSED: Mix_MusicType = 7; pub const Mix_MusicType_MUS_FLAC: Mix_MusicType = 8; pub const Mix_MusicType_MUS_MODPLUG_UNUSED: Mix_MusicType = 9; +pub const Mix_MusicType_MUS_OPUS: Mix_MusicType = 10; pub type Mix_MusicType = u32; #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -121,46 +125,46 @@ pub struct _Mix_Music { pub type Mix_Music = _Mix_Music; extern "C" { pub fn Mix_OpenAudio( - frequency: ::std::os::raw::c_int, + frequency: libc::c_int, format: Uint16, - channels: ::std::os::raw::c_int, - chunksize: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + channels: libc::c_int, + chunksize: libc::c_int, + ) -> libc::c_int; } extern "C" { pub fn Mix_OpenAudioDevice( - frequency: ::std::os::raw::c_int, + frequency: libc::c_int, format: Uint16, - channels: ::std::os::raw::c_int, - chunksize: ::std::os::raw::c_int, - device: *const ::std::os::raw::c_char, - allowed_changes: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + channels: libc::c_int, + chunksize: libc::c_int, + device: *const libc::c_char, + allowed_changes: libc::c_int, + ) -> libc::c_int; } extern "C" { - pub fn Mix_AllocateChannels(numchans: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn Mix_AllocateChannels(numchans: libc::c_int) -> libc::c_int; } extern "C" { pub fn Mix_QuerySpec( - frequency: *mut ::std::os::raw::c_int, + frequency: *mut libc::c_int, format: *mut Uint16, - channels: *mut ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + channels: *mut libc::c_int, + ) -> libc::c_int; } extern "C" { - pub fn Mix_LoadWAV_RW(src: *mut SDL_RWops, freesrc: ::std::os::raw::c_int) -> *mut Mix_Chunk; + pub fn Mix_LoadWAV_RW(src: *mut SDL_RWops, freesrc: libc::c_int) -> *mut Mix_Chunk; } extern "C" { - pub fn Mix_LoadMUS(file: *const ::std::os::raw::c_char) -> *mut Mix_Music; + pub fn Mix_LoadMUS(file: *const libc::c_char) -> *mut Mix_Music; } extern "C" { - pub fn Mix_LoadMUS_RW(src: *mut SDL_RWops, freesrc: ::std::os::raw::c_int) -> *mut Mix_Music; + pub fn Mix_LoadMUS_RW(src: *mut SDL_RWops, freesrc: libc::c_int) -> *mut Mix_Music; } extern "C" { pub fn Mix_LoadMUSType_RW( src: *mut SDL_RWops, type_: Mix_MusicType, - freesrc: ::std::os::raw::c_int, + freesrc: libc::c_int, ) -> *mut Mix_Music; } extern "C" { @@ -176,242 +180,189 @@ extern "C" { pub fn Mix_FreeMusic(music: *mut Mix_Music); } extern "C" { - pub fn Mix_GetNumChunkDecoders() -> ::std::os::raw::c_int; + pub fn Mix_GetNumChunkDecoders() -> libc::c_int; } extern "C" { - pub fn Mix_GetChunkDecoder(index: ::std::os::raw::c_int) -> *const ::std::os::raw::c_char; + pub fn Mix_GetChunkDecoder(index: libc::c_int) -> *const libc::c_char; } extern "C" { - pub fn Mix_HasChunkDecoder(name: *const ::std::os::raw::c_char) -> SDL_bool; + pub fn Mix_HasChunkDecoder(name: *const libc::c_char) -> SDL_bool; } extern "C" { - pub fn Mix_GetNumMusicDecoders() -> ::std::os::raw::c_int; + pub fn Mix_GetNumMusicDecoders() -> libc::c_int; } extern "C" { - pub fn Mix_GetMusicDecoder(index: ::std::os::raw::c_int) -> *const ::std::os::raw::c_char; + pub fn Mix_GetMusicDecoder(index: libc::c_int) -> *const libc::c_char; } extern "C" { - pub fn Mix_HasMusicDecoder(name: *const ::std::os::raw::c_char) -> SDL_bool; + pub fn Mix_HasMusicDecoder(name: *const libc::c_char) -> SDL_bool; } extern "C" { pub fn Mix_GetMusicType(music: *const Mix_Music) -> Mix_MusicType; } extern "C" { pub fn Mix_SetPostMix( - mix_func: ::std::option::Option< - unsafe extern "C" fn( - udata: *mut ::libc::c_void, - stream: *mut Uint8, - len: ::std::os::raw::c_int, - ), + mix_func: ::core::option::Option< + unsafe extern "C" fn(udata: *mut libc::c_void, stream: *mut Uint8, len: libc::c_int), >, - arg: *mut ::libc::c_void, + arg: *mut libc::c_void, ); } extern "C" { pub fn Mix_HookMusic( - mix_func: ::std::option::Option< - unsafe extern "C" fn( - udata: *mut ::libc::c_void, - stream: *mut Uint8, - len: ::std::os::raw::c_int, - ), + mix_func: ::core::option::Option< + unsafe extern "C" fn(udata: *mut libc::c_void, stream: *mut Uint8, len: libc::c_int), >, - arg: *mut ::libc::c_void, + arg: *mut libc::c_void, ); } extern "C" { - pub fn Mix_HookMusicFinished(music_finished: ::std::option::Option); + pub fn Mix_HookMusicFinished(music_finished: ::core::option::Option); } extern "C" { - pub fn Mix_GetMusicHookData() -> *mut ::libc::c_void; + pub fn Mix_GetMusicHookData() -> *mut libc::c_void; } extern "C" { pub fn Mix_ChannelFinished( - channel_finished: ::std::option::Option< - unsafe extern "C" fn(channel: ::std::os::raw::c_int), - >, + channel_finished: ::core::option::Option, ); } -pub type Mix_EffectFunc_t = ::std::option::Option< +pub type Mix_EffectFunc_t = ::core::option::Option< unsafe extern "C" fn( - chan: ::std::os::raw::c_int, - stream: *mut ::libc::c_void, - len: ::std::os::raw::c_int, - udata: *mut ::libc::c_void, + chan: libc::c_int, + stream: *mut libc::c_void, + len: libc::c_int, + udata: *mut libc::c_void, ), >; -pub type Mix_EffectDone_t = ::std::option::Option< - unsafe extern "C" fn(chan: ::std::os::raw::c_int, udata: *mut ::libc::c_void), ->; +pub type Mix_EffectDone_t = + ::core::option::Option; extern "C" { pub fn Mix_RegisterEffect( - chan: ::std::os::raw::c_int, + chan: libc::c_int, f: Mix_EffectFunc_t, d: Mix_EffectDone_t, - arg: *mut ::libc::c_void, - ) -> ::std::os::raw::c_int; + arg: *mut libc::c_void, + ) -> libc::c_int; } extern "C" { - pub fn Mix_UnregisterEffect( - channel: ::std::os::raw::c_int, - f: Mix_EffectFunc_t, - ) -> ::std::os::raw::c_int; + pub fn Mix_UnregisterEffect(channel: libc::c_int, f: Mix_EffectFunc_t) -> libc::c_int; } extern "C" { - pub fn Mix_UnregisterAllEffects(channel: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn Mix_UnregisterAllEffects(channel: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_SetPanning( - channel: ::std::os::raw::c_int, - left: Uint8, - right: Uint8, - ) -> ::std::os::raw::c_int; + pub fn Mix_SetPanning(channel: libc::c_int, left: Uint8, right: Uint8) -> libc::c_int; } extern "C" { - pub fn Mix_SetPosition( - channel: ::std::os::raw::c_int, - angle: Sint16, - distance: Uint8, - ) -> ::std::os::raw::c_int; + pub fn Mix_SetPosition(channel: libc::c_int, angle: Sint16, distance: Uint8) -> libc::c_int; } extern "C" { - pub fn Mix_SetDistance( - channel: ::std::os::raw::c_int, - distance: Uint8, - ) -> ::std::os::raw::c_int; + pub fn Mix_SetDistance(channel: libc::c_int, distance: Uint8) -> libc::c_int; } extern "C" { - pub fn Mix_SetReverseStereo( - channel: ::std::os::raw::c_int, - flip: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + pub fn Mix_SetReverseStereo(channel: libc::c_int, flip: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_ReserveChannels(num: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn Mix_ReserveChannels(num: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_GroupChannel( - which: ::std::os::raw::c_int, - tag: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + pub fn Mix_GroupChannel(which: libc::c_int, tag: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_GroupChannels( - from: ::std::os::raw::c_int, - to: ::std::os::raw::c_int, - tag: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + pub fn Mix_GroupChannels(from: libc::c_int, to: libc::c_int, tag: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_GroupAvailable(tag: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn Mix_GroupAvailable(tag: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_GroupCount(tag: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn Mix_GroupCount(tag: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_GroupOldest(tag: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn Mix_GroupOldest(tag: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_GroupNewer(tag: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn Mix_GroupNewer(tag: libc::c_int) -> libc::c_int; } extern "C" { pub fn Mix_PlayChannelTimed( - channel: ::std::os::raw::c_int, + channel: libc::c_int, chunk: *mut Mix_Chunk, - loops: ::std::os::raw::c_int, - ticks: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + loops: libc::c_int, + ticks: libc::c_int, + ) -> libc::c_int; } extern "C" { - pub fn Mix_PlayMusic( - music: *mut Mix_Music, - loops: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + pub fn Mix_PlayMusic(music: *mut Mix_Music, loops: libc::c_int) -> libc::c_int; } extern "C" { pub fn Mix_FadeInMusic( music: *mut Mix_Music, - loops: ::std::os::raw::c_int, - ms: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + loops: libc::c_int, + ms: libc::c_int, + ) -> libc::c_int; } extern "C" { pub fn Mix_FadeInMusicPos( music: *mut Mix_Music, - loops: ::std::os::raw::c_int, - ms: ::std::os::raw::c_int, + loops: libc::c_int, + ms: libc::c_int, position: f64, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; } extern "C" { pub fn Mix_FadeInChannelTimed( - channel: ::std::os::raw::c_int, + channel: libc::c_int, chunk: *mut Mix_Chunk, - loops: ::std::os::raw::c_int, - ms: ::std::os::raw::c_int, - ticks: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + loops: libc::c_int, + ms: libc::c_int, + ticks: libc::c_int, + ) -> libc::c_int; } extern "C" { - pub fn Mix_Volume( - channel: ::std::os::raw::c_int, - volume: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + pub fn Mix_Volume(channel: libc::c_int, volume: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_VolumeChunk( - chunk: *mut Mix_Chunk, - volume: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + pub fn Mix_VolumeChunk(chunk: *mut Mix_Chunk, volume: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_VolumeMusic(volume: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn Mix_VolumeMusic(volume: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_HaltChannel(channel: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn Mix_HaltChannel(channel: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_HaltGroup(tag: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn Mix_HaltGroup(tag: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_HaltMusic() -> ::std::os::raw::c_int; + pub fn Mix_HaltMusic() -> libc::c_int; } extern "C" { - pub fn Mix_ExpireChannel( - channel: ::std::os::raw::c_int, - ticks: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + pub fn Mix_ExpireChannel(channel: libc::c_int, ticks: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_FadeOutChannel( - which: ::std::os::raw::c_int, - ms: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + pub fn Mix_FadeOutChannel(which: libc::c_int, ms: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_FadeOutGroup( - tag: ::std::os::raw::c_int, - ms: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + pub fn Mix_FadeOutGroup(tag: libc::c_int, ms: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_FadeOutMusic(ms: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn Mix_FadeOutMusic(ms: libc::c_int) -> libc::c_int; } extern "C" { pub fn Mix_FadingMusic() -> Mix_Fading; } extern "C" { - pub fn Mix_FadingChannel(which: ::std::os::raw::c_int) -> Mix_Fading; + pub fn Mix_FadingChannel(which: libc::c_int) -> Mix_Fading; } extern "C" { - pub fn Mix_Pause(channel: ::std::os::raw::c_int); + pub fn Mix_Pause(channel: libc::c_int); } extern "C" { - pub fn Mix_Resume(channel: ::std::os::raw::c_int); + pub fn Mix_Resume(channel: libc::c_int); } extern "C" { - pub fn Mix_Paused(channel: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn Mix_Paused(channel: libc::c_int) -> libc::c_int; } extern "C" { pub fn Mix_PauseMusic(); @@ -423,45 +374,42 @@ extern "C" { pub fn Mix_RewindMusic(); } extern "C" { - pub fn Mix_PausedMusic() -> ::std::os::raw::c_int; + pub fn Mix_PausedMusic() -> libc::c_int; } extern "C" { - pub fn Mix_SetMusicPosition(position: f64) -> ::std::os::raw::c_int; + pub fn Mix_SetMusicPosition(position: f64) -> libc::c_int; } extern "C" { - pub fn Mix_Playing(channel: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn Mix_Playing(channel: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_PlayingMusic() -> ::std::os::raw::c_int; + pub fn Mix_PlayingMusic() -> libc::c_int; } extern "C" { - pub fn Mix_SetMusicCMD(command: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; + pub fn Mix_SetMusicCMD(command: *const libc::c_char) -> libc::c_int; } extern "C" { - pub fn Mix_SetSynchroValue(value: ::std::os::raw::c_int) -> ::std::os::raw::c_int; + pub fn Mix_SetSynchroValue(value: libc::c_int) -> libc::c_int; } extern "C" { - pub fn Mix_GetSynchroValue() -> ::std::os::raw::c_int; + pub fn Mix_GetSynchroValue() -> libc::c_int; } extern "C" { - pub fn Mix_SetSoundFonts(paths: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int; + pub fn Mix_SetSoundFonts(paths: *const libc::c_char) -> libc::c_int; } extern "C" { - pub fn Mix_GetSoundFonts() -> *const ::std::os::raw::c_char; + pub fn Mix_GetSoundFonts() -> *const libc::c_char; } extern "C" { pub fn Mix_EachSoundFont( - function: ::std::option::Option< - unsafe extern "C" fn( - arg1: *const ::std::os::raw::c_char, - arg2: *mut ::libc::c_void, - ) -> ::std::os::raw::c_int, + function: ::core::option::Option< + unsafe extern "C" fn(arg1: *const libc::c_char, arg2: *mut libc::c_void) -> libc::c_int, >, - data: *mut ::libc::c_void, - ) -> ::std::os::raw::c_int; + data: *mut libc::c_void, + ) -> libc::c_int; } extern "C" { - pub fn Mix_GetChunk(channel: ::std::os::raw::c_int) -> *mut Mix_Chunk; + pub fn Mix_GetChunk(channel: libc::c_int) -> *mut Mix_Chunk; } extern "C" { pub fn Mix_CloseAudio(); diff --git a/sdl2-sys/sdl_ttf_bindings.rs b/sdl2-sys/sdl_ttf_bindings.rs index 2c43e41f..523764cb 100644 --- a/sdl2-sys/sdl_ttf_bindings.rs +++ b/sdl2-sys/sdl_ttf_bindings.rs @@ -1,8 +1,10 @@ /* automatically generated by rust-bindgen */ +use crate::*; + pub const TTF_MAJOR_VERSION: u32 = 2; pub const TTF_MINOR_VERSION: u32 = 0; -pub const TTF_PATCHLEVEL: u32 = 14; +pub const TTF_PATCHLEVEL: u32 = 15; pub const TTF_STYLE_NORMAL: u32 = 0; pub const TTF_STYLE_BOLD: u32 = 1; pub const TTF_STYLE_ITALIC: u32 = 2; @@ -12,12 +14,12 @@ pub const TTF_HINTING_NORMAL: u32 = 0; pub const TTF_HINTING_LIGHT: u32 = 1; pub const TTF_HINTING_MONO: u32 = 2; pub const TTF_HINTING_NONE: u32 = 3; -pub type __uint8_t = ::std::os::raw::c_uchar; -pub type __uint16_t = ::std::os::raw::c_ushort; -pub type __uint32_t = ::std::os::raw::c_uint; -pub type __int64_t = ::std::os::raw::c_long; -pub type __off_t = ::std::os::raw::c_long; -pub type __off64_t = ::std::os::raw::c_long; +pub type __uint8_t = libc::c_uchar; +pub type __uint16_t = libc::c_ushort; +pub type __uint32_t = libc::c_uint; +pub type __int64_t = libc::c_long; +pub type __off_t = libc::c_long; +pub type __off64_t = libc::c_long; pub type Uint8 = u8; pub type Uint16 = u16; pub type Uint32 = u32; @@ -26,7 +28,7 @@ extern "C" { pub fn TTF_Linked_Version() -> *const SDL_version; } extern "C" { - pub fn TTF_ByteSwappedUNICODE(swapped: ::std::os::raw::c_int); + pub fn TTF_ByteSwappedUNICODE(swapped: libc::c_int); } #[repr(C)] #[derive(Debug, Copy, Clone)] @@ -35,133 +37,130 @@ pub struct _TTF_Font { } pub type TTF_Font = _TTF_Font; extern "C" { - pub fn TTF_Init() -> ::std::os::raw::c_int; + pub fn TTF_Init() -> libc::c_int; } extern "C" { - pub fn TTF_OpenFont( - file: *const ::std::os::raw::c_char, - ptsize: ::std::os::raw::c_int, - ) -> *mut TTF_Font; + pub fn TTF_OpenFont(file: *const libc::c_char, ptsize: libc::c_int) -> *mut TTF_Font; } extern "C" { pub fn TTF_OpenFontIndex( - file: *const ::std::os::raw::c_char, - ptsize: ::std::os::raw::c_int, - index: ::std::os::raw::c_long, + file: *const libc::c_char, + ptsize: libc::c_int, + index: libc::c_long, ) -> *mut TTF_Font; } extern "C" { pub fn TTF_OpenFontRW( src: *mut SDL_RWops, - freesrc: ::std::os::raw::c_int, - ptsize: ::std::os::raw::c_int, + freesrc: libc::c_int, + ptsize: libc::c_int, ) -> *mut TTF_Font; } extern "C" { pub fn TTF_OpenFontIndexRW( src: *mut SDL_RWops, - freesrc: ::std::os::raw::c_int, - ptsize: ::std::os::raw::c_int, - index: ::std::os::raw::c_long, + freesrc: libc::c_int, + ptsize: libc::c_int, + index: libc::c_long, ) -> *mut TTF_Font; } extern "C" { - pub fn TTF_GetFontStyle(font: *const TTF_Font) -> ::std::os::raw::c_int; + pub fn TTF_GetFontStyle(font: *const TTF_Font) -> libc::c_int; } extern "C" { - pub fn TTF_SetFontStyle(font: *mut TTF_Font, style: ::std::os::raw::c_int); + pub fn TTF_SetFontStyle(font: *mut TTF_Font, style: libc::c_int); } extern "C" { - pub fn TTF_GetFontOutline(font: *const TTF_Font) -> ::std::os::raw::c_int; + pub fn TTF_GetFontOutline(font: *const TTF_Font) -> libc::c_int; } extern "C" { - pub fn TTF_SetFontOutline(font: *mut TTF_Font, outline: ::std::os::raw::c_int); + pub fn TTF_SetFontOutline(font: *mut TTF_Font, outline: libc::c_int); } extern "C" { - pub fn TTF_GetFontHinting(font: *const TTF_Font) -> ::std::os::raw::c_int; + pub fn TTF_GetFontHinting(font: *const TTF_Font) -> libc::c_int; } extern "C" { - pub fn TTF_SetFontHinting(font: *mut TTF_Font, hinting: ::std::os::raw::c_int); + pub fn TTF_SetFontHinting(font: *mut TTF_Font, hinting: libc::c_int); } extern "C" { - pub fn TTF_FontHeight(font: *const TTF_Font) -> ::std::os::raw::c_int; + pub fn TTF_FontHeight(font: *const TTF_Font) -> libc::c_int; } extern "C" { - pub fn TTF_FontAscent(font: *const TTF_Font) -> ::std::os::raw::c_int; + pub fn TTF_FontAscent(font: *const TTF_Font) -> libc::c_int; } extern "C" { - pub fn TTF_FontDescent(font: *const TTF_Font) -> ::std::os::raw::c_int; + pub fn TTF_FontDescent(font: *const TTF_Font) -> libc::c_int; } extern "C" { - pub fn TTF_FontLineSkip(font: *const TTF_Font) -> ::std::os::raw::c_int; + pub fn TTF_FontLineSkip(font: *const TTF_Font) -> libc::c_int; } extern "C" { - pub fn TTF_GetFontKerning(font: *const TTF_Font) -> ::std::os::raw::c_int; + pub fn TTF_GetFontKerning(font: *const TTF_Font) -> libc::c_int; } extern "C" { - pub fn TTF_SetFontKerning(font: *mut TTF_Font, allowed: ::std::os::raw::c_int); + pub fn TTF_SetFontKerning(font: *mut TTF_Font, allowed: libc::c_int); } extern "C" { - pub fn TTF_FontFaces(font: *const TTF_Font) -> ::std::os::raw::c_long; + pub fn TTF_FontFaces(font: *const TTF_Font) -> libc::c_long; } extern "C" { - pub fn TTF_FontFaceIsFixedWidth(font: *const TTF_Font) -> ::std::os::raw::c_int; + pub fn TTF_FontFaceIsFixedWidth(font: *const TTF_Font) -> libc::c_int; } extern "C" { - pub fn TTF_FontFaceFamilyName(font: *const TTF_Font) -> *mut ::std::os::raw::c_char; + pub fn TTF_FontFaceFamilyName(font: *const TTF_Font) -> *mut libc::c_char; } extern "C" { - pub fn TTF_FontFaceStyleName(font: *const TTF_Font) -> *mut ::std::os::raw::c_char; + pub fn TTF_FontFaceStyleName(font: *const TTF_Font) -> *mut libc::c_char; } extern "C" { - pub fn TTF_GlyphIsProvided(font: *const TTF_Font, ch: Uint16) -> ::std::os::raw::c_int; + pub fn TTF_GlyphIsProvided(font: *const TTF_Font, ch: Uint16) -> libc::c_int; } extern "C" { pub fn TTF_GlyphMetrics( font: *mut TTF_Font, ch: Uint16, - minx: *mut ::std::os::raw::c_int, - maxx: *mut ::std::os::raw::c_int, - miny: *mut ::std::os::raw::c_int, - maxy: *mut ::std::os::raw::c_int, - advance: *mut ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + minx: *mut libc::c_int, + maxx: *mut libc::c_int, + miny: *mut libc::c_int, + maxy: *mut libc::c_int, + advance: *mut libc::c_int, + ) -> libc::c_int; } extern "C" { pub fn TTF_SizeText( font: *mut TTF_Font, - text: *const ::std::os::raw::c_char, - w: *mut ::std::os::raw::c_int, - h: *mut ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + text: *const libc::c_char, + w: *mut libc::c_int, + h: *mut libc::c_int, + ) -> libc::c_int; } extern "C" { pub fn TTF_SizeUTF8( font: *mut TTF_Font, - text: *const ::std::os::raw::c_char, - w: *mut ::std::os::raw::c_int, - h: *mut ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + text: *const libc::c_char, + w: *mut libc::c_int, + h: *mut libc::c_int, + ) -> libc::c_int; } extern "C" { pub fn TTF_SizeUNICODE( font: *mut TTF_Font, text: *const Uint16, - w: *mut ::std::os::raw::c_int, - h: *mut ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + w: *mut libc::c_int, + h: *mut libc::c_int, + ) -> libc::c_int; } extern "C" { pub fn TTF_RenderText_Solid( font: *mut TTF_Font, - text: *const ::std::os::raw::c_char, + text: *const libc::c_char, fg: SDL_Color, ) -> *mut SDL_Surface; } extern "C" { pub fn TTF_RenderUTF8_Solid( font: *mut TTF_Font, - text: *const ::std::os::raw::c_char, + text: *const libc::c_char, fg: SDL_Color, ) -> *mut SDL_Surface; } @@ -182,7 +181,7 @@ extern "C" { extern "C" { pub fn TTF_RenderText_Shaded( font: *mut TTF_Font, - text: *const ::std::os::raw::c_char, + text: *const libc::c_char, fg: SDL_Color, bg: SDL_Color, ) -> *mut SDL_Surface; @@ -190,7 +189,7 @@ extern "C" { extern "C" { pub fn TTF_RenderUTF8_Shaded( font: *mut TTF_Font, - text: *const ::std::os::raw::c_char, + text: *const libc::c_char, fg: SDL_Color, bg: SDL_Color, ) -> *mut SDL_Surface; @@ -214,14 +213,14 @@ extern "C" { extern "C" { pub fn TTF_RenderText_Blended( font: *mut TTF_Font, - text: *const ::std::os::raw::c_char, + text: *const libc::c_char, fg: SDL_Color, ) -> *mut SDL_Surface; } extern "C" { pub fn TTF_RenderUTF8_Blended( font: *mut TTF_Font, - text: *const ::std::os::raw::c_char, + text: *const libc::c_char, fg: SDL_Color, ) -> *mut SDL_Surface; } @@ -235,7 +234,7 @@ extern "C" { extern "C" { pub fn TTF_RenderText_Blended_Wrapped( font: *mut TTF_Font, - text: *const ::std::os::raw::c_char, + text: *const libc::c_char, fg: SDL_Color, wrapLength: Uint32, ) -> *mut SDL_Surface; @@ -243,7 +242,7 @@ extern "C" { extern "C" { pub fn TTF_RenderUTF8_Blended_Wrapped( font: *mut TTF_Font, - text: *const ::std::os::raw::c_char, + text: *const libc::c_char, fg: SDL_Color, wrapLength: Uint32, ) -> *mut SDL_Surface; @@ -270,19 +269,19 @@ extern "C" { pub fn TTF_Quit(); } extern "C" { - pub fn TTF_WasInit() -> ::std::os::raw::c_int; + pub fn TTF_WasInit() -> libc::c_int; } extern "C" { pub fn TTF_GetFontKerningSize( font: *mut TTF_Font, - prev_index: ::std::os::raw::c_int, - index: ::std::os::raw::c_int, - ) -> ::std::os::raw::c_int; + prev_index: libc::c_int, + index: libc::c_int, + ) -> libc::c_int; } extern "C" { pub fn TTF_GetFontKerningSizeGlyphs( font: *mut TTF_Font, previous_ch: Uint16, ch: Uint16, - ) -> ::std::os::raw::c_int; + ) -> libc::c_int; }