1
2
3
/* automatically generated by rust-bindgen */

# [ doc = " Represent a 2D array." ] # [ doc = " The 2D array is stored in a single array, to improve cache usage." ] # [ repr ( C ) ] # [ derive ( Debug , Copy , Clone ) ] pub struct Array2D { pub _address : u8 , } # [ doc = " Options needed to use the overlapping wfc." ] # [ repr ( C ) ] # [ derive ( Debug , Copy , Clone ) ] pub struct OverlappingWFCOptions { pub periodic_input : bool , pub periodic_output : bool , pub out_height : :: std :: os :: raw :: c_uint , pub out_width : :: std :: os :: raw :: c_uint , pub symmetry : :: std :: os :: raw :: c_uint , pub ground : bool , pub pattern_size : :: std :: os :: raw :: c_uint , } # [ test ] fn bindgen_test_layout_OverlappingWFCOptions ( ) { assert_eq ! ( :: std :: mem :: size_of :: < OverlappingWFCOptions > ( ) , 24usize , concat ! ( "Size of: " , stringify ! ( OverlappingWFCOptions ) ) ) ; assert_eq ! ( :: std :: mem :: align_of :: < OverlappingWFCOptions > ( ) , 4usize , concat ! ( "Alignment of " , stringify ! ( OverlappingWFCOptions ) ) ) ; assert_eq ! ( unsafe { & ( * ( :: std :: ptr :: null :: < OverlappingWFCOptions > ( ) ) ) . periodic_input as * const _ as usize } , 0usize , concat ! ( "Offset of field: " , stringify ! ( OverlappingWFCOptions ) , "::" , stringify ! ( periodic_input ) ) ) ; assert_eq ! ( unsafe { & ( * ( :: std :: ptr :: null :: < OverlappingWFCOptions > ( ) ) ) . periodic_output as * const _ as usize } , 1usize , concat ! ( "Offset of field: " , stringify ! ( OverlappingWFCOptions ) , "::" , stringify ! ( periodic_output ) ) ) ; assert_eq ! ( unsafe { & ( * ( :: std :: ptr :: null :: < OverlappingWFCOptions > ( ) ) ) . out_height as * const _ as usize } , 4usize , concat ! ( "Offset of field: " , stringify ! ( OverlappingWFCOptions ) , "::" , stringify ! ( out_height ) ) ) ; assert_eq ! ( unsafe { & ( * ( :: std :: ptr :: null :: < OverlappingWFCOptions > ( ) ) ) . out_width as * const _ as usize } , 8usize , concat ! ( "Offset of field: " , stringify ! ( OverlappingWFCOptions ) , "::" , stringify ! ( out_width ) ) ) ; assert_eq ! ( unsafe { & ( * ( :: std :: ptr :: null :: < OverlappingWFCOptions > ( ) ) ) . symmetry as * const _ as usize } , 12usize , concat ! ( "Offset of field: " , stringify ! ( OverlappingWFCOptions ) , "::" , stringify ! ( symmetry ) ) ) ; assert_eq ! ( unsafe { & ( * ( :: std :: ptr :: null :: < OverlappingWFCOptions > ( ) ) ) . ground as * const _ as usize } , 16usize , concat ! ( "Offset of field: " , stringify ! ( OverlappingWFCOptions ) , "::" , stringify ! ( ground ) ) ) ; assert_eq ! ( unsafe { & ( * ( :: std :: ptr :: null :: < OverlappingWFCOptions > ( ) ) ) . pattern_size as * const _ as usize } , 20usize , concat ! ( "Offset of field: " , stringify ! ( OverlappingWFCOptions ) , "::" , stringify ! ( pattern_size ) ) ) ; } # [ repr ( C ) ] # [ derive ( Debug , Copy , Clone ) ] pub struct Color { pub r : :: std :: os :: raw :: c_uchar , pub g : :: std :: os :: raw :: c_uchar , pub b : :: std :: os :: raw :: c_uchar , pub a : :: std :: os :: raw :: c_uchar , } # [ test ] fn bindgen_test_layout_Color ( ) { assert_eq ! ( :: std :: mem :: size_of :: < Color > ( ) , 4usize , concat ! ( "Size of: " , stringify ! ( Color ) ) ) ; assert_eq ! ( :: std :: mem :: align_of :: < Color > ( ) , 1usize , concat ! ( "Alignment of " , stringify ! ( Color ) ) ) ; assert_eq ! ( unsafe { & ( * ( :: std :: ptr :: null :: < Color > ( ) ) ) . r as * const _ as usize } , 0usize , concat ! ( "Offset of field: " , stringify ! ( Color ) , "::" , stringify ! ( r ) ) ) ; assert_eq ! ( unsafe { & ( * ( :: std :: ptr :: null :: < Color > ( ) ) ) . g as * const _ as usize } , 1usize , concat ! ( "Offset of field: " , stringify ! ( Color ) , "::" , stringify ! ( g ) ) ) ; assert_eq ! ( unsafe { & ( * ( :: std :: ptr :: null :: < Color > ( ) ) ) . b as * const _ as usize } , 2usize , concat ! ( "Offset of field: " , stringify ! ( Color ) , "::" , stringify ! ( b ) ) ) ; assert_eq ! ( unsafe { & ( * ( :: std :: ptr :: null :: < Color > ( ) ) ) . a as * const _ as usize } , 3usize , concat ! ( "Offset of field: " , stringify ! ( Color ) , "::" , stringify ! ( a ) ) ) ; } # [ repr ( C ) ] # [ derive ( Debug , Copy , Clone ) ] pub struct ArrayColor2D { pub init : bool , pub inner : [ u64 ; 4usize ] , pub ref_ : * mut :: std :: os :: raw :: c_void , } # [ test ] fn bindgen_test_layout_ArrayColor2D ( ) { assert_eq ! ( :: std :: mem :: size_of :: < ArrayColor2D > ( ) , 48usize , concat ! ( "Size of: " , stringify ! ( ArrayColor2D ) ) ) ; assert_eq ! ( :: std :: mem :: align_of :: < ArrayColor2D > ( ) , 8usize , concat ! ( "Alignment of " , stringify ! ( ArrayColor2D ) ) ) ; assert_eq ! ( unsafe { & ( * ( :: std :: ptr :: null :: < ArrayColor2D > ( ) ) ) . init as * const _ as usize } , 0usize , concat ! ( "Offset of field: " , stringify ! ( ArrayColor2D ) , "::" , stringify ! ( init ) ) ) ; assert_eq ! ( unsafe { & ( * ( :: std :: ptr :: null :: < ArrayColor2D > ( ) ) ) . inner as * const _ as usize } , 8usize , concat ! ( "Offset of field: " , stringify ! ( ArrayColor2D ) , "::" , stringify ! ( inner ) ) ) ; assert_eq ! ( unsafe { & ( * ( :: std :: ptr :: null :: < ArrayColor2D > ( ) ) ) . ref_ as * const _ as usize } , 40usize , concat ! ( "Offset of field: " , stringify ! ( ArrayColor2D ) , "::" , stringify ! ( ref_ ) ) ) ; } extern "C" { # [ link_name = "\u{1}_Z18new_array_color_2dv" ] pub fn new_array_color_2d ( ) -> * mut ArrayColor2D ; } extern "C" { # [ link_name = "\u{1}_Z22destroy_array_color_2dP12ArrayColor2D" ] pub fn destroy_array_color_2d ( c : * mut ArrayColor2D ) ; } extern "C" { # [ link_name = "\u{1}_Z24array_color_2d_set_widthP12ArrayColor2Di" ] pub fn array_color_2d_set_width ( c : * mut ArrayColor2D , width : :: std :: os :: raw :: c_int ) ; } extern "C" { # [ link_name = "\u{1}_Z25array_color_2d_set_heightP12ArrayColor2Di" ] pub fn array_color_2d_set_height ( c : * mut ArrayColor2D , height : :: std :: os :: raw :: c_int ) ; } extern "C" { # [ link_name = "\u{1}_Z23array_color_2d_set_dataP12ArrayColor2DP5ColorPv" ] pub fn array_color_2d_set_data ( c : * mut ArrayColor2D , ptr : * mut Color , ref_ : * mut :: std :: os :: raw :: c_void ) ; } extern "C" { # [ link_name = "\u{1}_Z24array_color_2d_get_widthP12ArrayColor2D" ] pub fn array_color_2d_get_width ( c : * mut ArrayColor2D ) -> :: std :: os :: raw :: c_int ; } extern "C" { # [ link_name = "\u{1}_Z25array_color_2d_get_heightP12ArrayColor2D" ] pub fn array_color_2d_get_height ( c : * mut ArrayColor2D ) -> :: std :: os :: raw :: c_int ; } extern "C" { # [ link_name = "\u{1}_Z23array_color_2d_get_dataP12ArrayColor2D" ] pub fn array_color_2d_get_data ( c : * mut ArrayColor2D ) -> * mut :: std :: os :: raw :: c_void ; } extern "C" { # [ link_name = "\u{1}_Z22array_color_2d_get_refP12ArrayColor2D" ] pub fn array_color_2d_get_ref ( c : * mut ArrayColor2D ) -> * mut :: std :: os :: raw :: c_void ; } extern "C" { # [ link_name = "\u{1}_Z15run_overlappingP12ArrayColor2D21OverlappingWFCOptionsj" ] pub fn run_overlapping ( m : * mut ArrayColor2D , options : OverlappingWFCOptions , tries : :: std :: os :: raw :: c_uint ) -> * mut ArrayColor2D ; } extern "C" { # [ link_name = "\u{1}_Z25run_overlapping_with_seedP12ArrayColor2D21OverlappingWFCOptionsi" ] pub fn run_overlapping_with_seed ( m : * mut ArrayColor2D , options : OverlappingWFCOptions , seed : :: std :: os :: raw :: c_int ) -> * mut ArrayColor2D ; }