pub fn sdl2_init() -> Sdl2Systems {
    // Setup SDL
    let context = sdl2::init().expect("Failed to initialize sdl2");
    let video_subsystem = context
        .video()
        .expect("Failed to create sdl video subsystem");

    // Create the window
    let window = video_subsystem
        .window("Render Graph Example", WINDOW_WIDTH, WINDOW_HEIGHT)
        .position_centered()
        .allow_highdpi()
        .resizable()
        .build()
        .expect("Failed to create window");

    Sdl2Systems {
        context,
        video_subsystem,
        window,
    }
}
// Setup SDL2 and create a window
Setup SDL2 and create a window
Setup SDL2 and create a window
pub fn sdl2_init() -> Sdl2Systems {
    // Setup SDL
    let context = sdl2::init().expect("Failed to initialize sdl2");
    let video_subsystem = context
        .video()
        .expect("Failed to create sdl video subsystem");
    // Create the window
    let window = video_subsystem
        .window("Render Graph Example", WINDOW_WIDTH, WINDOW_HEIGHT)
        .position_centered()
        .allow_highdpi()
        .resizable()
        .build()
        .expect("Failed to create window");
    Sdl2Systems {
        context,
        video_subsystem,
        window,
    }
}
pub fn sdl2_init ( ) -> Sdl2Systems { // Setup SDL let context = sdl2 :: init ( ) . expect ( " " ) ; let video_subsystem = context . video ( ) . expect ( " " ) ; // Create the window let window = video_subsystem . window ( " " , WINDOW_WIDTH , WINDOW_HEIGHT ) . position_centered ( ) . allow_highdpi ( ) . resizable ( ) . build ( ) . expect ( " " ) ; Sdl2Systems { context , video_subsystem , window , } }
Setup SDL2 and create a window
Setup SDL2 and create a window