/* automatically generated by rust-bindgen 0.72.1 */

#![allow(non_camel_case_types)]
#![allow(non_snake_case)]
#![allow(non_upper_case_globals)]

pub const _LIBCPP_AVAILABILITY_HAS_FILESYSTEM_LIBRARY: u32 = 1;
pub const EMSCRIPTEN_RESULT_SUCCESS: u32 = 0;
pub const EMSCRIPTEN_RESULT_DEFERRED: u32 = 1;
pub const EMSCRIPTEN_RESULT_NOT_SUPPORTED: i32 = -1;
pub const EMSCRIPTEN_RESULT_FAILED_NOT_DEFERRED: i32 = -2;
pub const EMSCRIPTEN_RESULT_INVALID_TARGET: i32 = -3;
pub const EMSCRIPTEN_RESULT_UNKNOWN_TARGET: i32 = -4;
pub const EMSCRIPTEN_RESULT_INVALID_PARAM: i32 = -5;
pub const EMSCRIPTEN_RESULT_FAILED: i32 = -6;
pub const EMSCRIPTEN_RESULT_NO_DATA: i32 = -7;
pub const EMSCRIPTEN_RESULT_TIMED_OUT: i32 = -8;
pub const EMSCRIPTEN_NOTIFY_ALL_WAITERS: i32 = -1;
pub const SEM_VALUE_MAX: u32 = 2147483647;
pub const SEM_NSEMS_MAX: u32 = 256;
pub const _POSIX_SEM_NSEMS_MAX: u32 = 256;
pub const _POSIX_SEM_VALUE_MAX: u32 = 32767;
pub const EMSCRIPTEN_HAS_UNBOUND_TYPE_NAMES: u32 = 1;
pub const __EMSCRIPTEN_major__: u32 = 4;
pub const __EMSCRIPTEN_minor__: u32 = 0;
pub const __EMSCRIPTEN_tiny__: u32 = 12;
pub const EM_TIMING_SETTIMEOUT: u32 = 0;
pub const EM_TIMING_RAF: u32 = 1;
pub const EM_TIMING_SETIMMEDIATE: u32 = 2;
pub const EM_LOG_CONSOLE: u32 = 1;
pub const EM_LOG_WARN: u32 = 2;
pub const EM_LOG_ERROR: u32 = 4;
pub const EM_LOG_C_STACK: u32 = 8;
pub const EM_LOG_JS_STACK: u32 = 16;
pub const EM_LOG_DEMANGLE: u32 = 32;
pub const EM_LOG_NO_PATHS: u32 = 64;
pub const EM_LOG_FUNC_PARAMS: u32 = 128;
pub const EM_LOG_DEBUG: u32 = 256;
pub const EM_LOG_INFO: u32 = 512;
pub const EM_MATH_E: f64 = 2.718281828459045;
pub const EM_MATH_LN2: f64 = 0.6931471805599453;
pub const EM_MATH_LN10: f64 = 2.302585092994046;
pub const EM_MATH_LOG2E: f64 = 1.4426950408889634;
pub const EM_MATH_LOG10E: f64 = 0.4342944819032518;
pub const EM_MATH_PI: f64 = 3.141592653589793;
pub const EM_MATH_SQRT1_2: f64 = 0.7071067811865476;
pub const EM_MATH_SQRT2: f64 = 1.4142135623730951;
pub const EMSCRIPTEN_FETCH_LOAD_TO_MEMORY: u32 = 1;
pub const EMSCRIPTEN_FETCH_STREAM_DATA: u32 = 2;
pub const EMSCRIPTEN_FETCH_PERSIST_FILE: u32 = 4;
pub const EMSCRIPTEN_FETCH_APPEND: u32 = 8;
pub const EMSCRIPTEN_FETCH_REPLACE: u32 = 16;
pub const EMSCRIPTEN_FETCH_NO_DOWNLOAD: u32 = 32;
pub const EMSCRIPTEN_FETCH_SYNCHRONOUS: u32 = 64;
pub const EMSCRIPTEN_FETCH_WAITABLE: u32 = 128;
pub const EMSCRIPTEN_PAGE_SIZE: u32 = 65536;
pub const EMSCRIPTEN_WEBGL_CONTEXT_PROXY_DISALLOW: u32 = 0;
pub const EMSCRIPTEN_WEBGL_CONTEXT_PROXY_FALLBACK: u32 = 1;
pub const EMSCRIPTEN_WEBGL_CONTEXT_PROXY_ALWAYS: u32 = 2;
pub const EM_WEBGL_POWER_PREFERENCE_DEFAULT: u32 = 0;
pub const EM_WEBGL_POWER_PREFERENCE_LOW_POWER: u32 = 1;
pub const EM_WEBGL_POWER_PREFERENCE_HIGH_PERFORMANCE: u32 = 2;
pub const EMSCRIPTEN_WEBGL_PARAM_TYPE_INT: u32 = 0;
pub const EMSCRIPTEN_WEBGL_PARAM_TYPE_FLOAT: u32 = 1;
pub const EMSCRIPTEN_EVENT_KEYPRESS: u32 = 1;
pub const EMSCRIPTEN_EVENT_KEYDOWN: u32 = 2;
pub const EMSCRIPTEN_EVENT_KEYUP: u32 = 3;
pub const EMSCRIPTEN_EVENT_CLICK: u32 = 4;
pub const EMSCRIPTEN_EVENT_MOUSEDOWN: u32 = 5;
pub const EMSCRIPTEN_EVENT_MOUSEUP: u32 = 6;
pub const EMSCRIPTEN_EVENT_DBLCLICK: u32 = 7;
pub const EMSCRIPTEN_EVENT_MOUSEMOVE: u32 = 8;
pub const EMSCRIPTEN_EVENT_WHEEL: u32 = 9;
pub const EMSCRIPTEN_EVENT_RESIZE: u32 = 10;
pub const EMSCRIPTEN_EVENT_SCROLL: u32 = 11;
pub const EMSCRIPTEN_EVENT_BLUR: u32 = 12;
pub const EMSCRIPTEN_EVENT_FOCUS: u32 = 13;
pub const EMSCRIPTEN_EVENT_FOCUSIN: u32 = 14;
pub const EMSCRIPTEN_EVENT_FOCUSOUT: u32 = 15;
pub const EMSCRIPTEN_EVENT_DEVICEORIENTATION: u32 = 16;
pub const EMSCRIPTEN_EVENT_DEVICEMOTION: u32 = 17;
pub const EMSCRIPTEN_EVENT_ORIENTATIONCHANGE: u32 = 18;
pub const EMSCRIPTEN_EVENT_FULLSCREENCHANGE: u32 = 19;
pub const EMSCRIPTEN_EVENT_POINTERLOCKCHANGE: u32 = 20;
pub const EMSCRIPTEN_EVENT_VISIBILITYCHANGE: u32 = 21;
pub const EMSCRIPTEN_EVENT_TOUCHSTART: u32 = 22;
pub const EMSCRIPTEN_EVENT_TOUCHEND: u32 = 23;
pub const EMSCRIPTEN_EVENT_TOUCHMOVE: u32 = 24;
pub const EMSCRIPTEN_EVENT_TOUCHCANCEL: u32 = 25;
pub const EMSCRIPTEN_EVENT_GAMEPADCONNECTED: u32 = 26;
pub const EMSCRIPTEN_EVENT_GAMEPADDISCONNECTED: u32 = 27;
pub const EMSCRIPTEN_EVENT_BEFOREUNLOAD: u32 = 28;
pub const EMSCRIPTEN_EVENT_BATTERYCHARGINGCHANGE: u32 = 29;
pub const EMSCRIPTEN_EVENT_BATTERYLEVELCHANGE: u32 = 30;
pub const EMSCRIPTEN_EVENT_WEBGLCONTEXTLOST: u32 = 31;
pub const EMSCRIPTEN_EVENT_WEBGLCONTEXTRESTORED: u32 = 32;
pub const EMSCRIPTEN_EVENT_MOUSEENTER: u32 = 33;
pub const EMSCRIPTEN_EVENT_MOUSELEAVE: u32 = 34;
pub const EMSCRIPTEN_EVENT_MOUSEOVER: u32 = 35;
pub const EMSCRIPTEN_EVENT_MOUSEOUT: u32 = 36;
pub const EMSCRIPTEN_EVENT_CANVASRESIZED: u32 = 37;
pub const EMSCRIPTEN_EVENT_POINTERLOCKERROR: u32 = 38;
pub const EMSCRIPTEN_EVENT_TARGET_INVALID: u32 = 0;
pub const EM_HTML5_SHORT_STRING_LEN_BYTES: u32 = 32;
pub const EM_HTML5_MEDIUM_STRING_LEN_BYTES: u32 = 64;
pub const EM_HTML5_LONG_STRING_LEN_BYTES: u32 = 128;
pub const EMSCRIPTEN_DEVICE_MOTION_EVENT_SUPPORTS_ACCELERATION: u32 = 1;
pub const EMSCRIPTEN_DEVICE_MOTION_EVENT_SUPPORTS_ACCELERATION_INCLUDING_GRAVITY: u32 = 2;
pub const EMSCRIPTEN_DEVICE_MOTION_EVENT_SUPPORTS_ROTATION_RATE: u32 = 4;
pub const EMSCRIPTEN_ORIENTATION_UNSUPPORTED: u32 = 0;
pub const EMSCRIPTEN_ORIENTATION_PORTRAIT_PRIMARY: u32 = 1;
pub const EMSCRIPTEN_ORIENTATION_PORTRAIT_SECONDARY: u32 = 2;
pub const EMSCRIPTEN_ORIENTATION_LANDSCAPE_PRIMARY: u32 = 4;
pub const EMSCRIPTEN_ORIENTATION_LANDSCAPE_SECONDARY: u32 = 8;
pub const EMSCRIPTEN_FULLSCREEN_SCALE_DEFAULT: u32 = 0;
pub const EMSCRIPTEN_FULLSCREEN_SCALE_STRETCH: u32 = 1;
pub const EMSCRIPTEN_FULLSCREEN_SCALE_ASPECT: u32 = 2;
pub const EMSCRIPTEN_FULLSCREEN_SCALE_CENTER: u32 = 3;
pub const EMSCRIPTEN_FULLSCREEN_CANVAS_SCALE_NONE: u32 = 0;
pub const EMSCRIPTEN_FULLSCREEN_CANVAS_SCALE_STDDEF: u32 = 1;
pub const EMSCRIPTEN_FULLSCREEN_CANVAS_SCALE_HIDEF: u32 = 2;
pub const EMSCRIPTEN_FULLSCREEN_FILTERING_DEFAULT: u32 = 0;
pub const EMSCRIPTEN_FULLSCREEN_FILTERING_NEAREST: u32 = 1;
pub const EMSCRIPTEN_FULLSCREEN_FILTERING_BILINEAR: u32 = 2;
pub const EMSCRIPTEN_VISIBILITY_HIDDEN: u32 = 0;
pub const EMSCRIPTEN_VISIBILITY_VISIBLE: u32 = 1;
pub const EMSCRIPTEN_VISIBILITY_PRERENDER: u32 = 2;
pub const EMSCRIPTEN_VISIBILITY_UNLOADED: u32 = 3;
pub const DOM_VK_WIN_OEM_FJ_JISHO: u32 = 146;
pub const DOM_VK_WIN_OEM_FJ_MASSHOU: u32 = 147;
pub const DOM_VK_WIN_OEM_FJ_TOUROKU: u32 = 148;
pub const DOM_VK_WIN_OEM_FJ_LOYA: u32 = 149;
pub const DOM_VK_WIN_OEM_FJ_ROYA: u32 = 150;
pub const DOM_VK_WIN_OEM_RESET: u32 = 233;
pub const DOM_VK_WIN_OEM_JUMP: u32 = 234;
pub const DOM_VK_WIN_OEM_PA1: u32 = 235;
pub const DOM_VK_WIN_OEM_PA2: u32 = 236;
pub const DOM_VK_WIN_OEM_PA3: u32 = 237;
pub const DOM_VK_WIN_OEM_WSCTRL: u32 = 238;
pub const DOM_VK_WIN_OEM_CUSEL: u32 = 239;
pub const DOM_VK_WIN_OEM_ATTN: u32 = 240;
pub const DOM_VK_WIN_OEM_FINISH: u32 = 241;
pub const DOM_VK_WIN_OEM_COPY: u32 = 242;
pub const DOM_VK_WIN_OEM_AUTO: u32 = 243;
pub const DOM_VK_WIN_OEM_ENLW: u32 = 244;
pub const DOM_VK_WIN_OEM_BACKTAB: u32 = 245;
pub const DOM_VK_WIN_OEM_CLEAR: u32 = 254;
pub const EM_QUEUED_JS_CALL_MAX_ARGS: u32 = 20;
pub const EM_FUNC_SIG_RETURN_VALUE_MASK: u32 = 3758096384;
pub const EM_FUNC_SIG_RETURN_VALUE_V: u32 = 0;
pub const EM_FUNC_SIG_RETURN_VALUE_I: u32 = 536870912;
pub const EM_FUNC_SIG_RETURN_VALUE_J: u32 = 1073741824;
pub const EM_FUNC_SIG_RETURN_VALUE_F: u32 = 1610612736;
pub const EM_FUNC_SIG_RETURN_VALUE_D: u32 = 2147483648;
pub const EM_FUNC_SIG_RETURN_VALUE_P: u32 = 536870912;
pub const EM_FUNC_SIG_NUM_PARAMETERS_SHIFT: u32 = 25;
pub const EM_FUNC_SIG_NUM_PARAMETERS_MASK: u32 = 503316480;
pub const EM_FUNC_SIG_ARGUMENTS_TYPE_MASK: i64 = -4261412865;
pub const EM_FUNC_SIG_ARGUMENT_TYPE_SIZE_MASK: u32 = 3;
pub const EM_FUNC_SIG_ARGUMENT_TYPE_SIZE_SHIFT: u32 = 2;
pub const EM_FUNC_SIG_PARAM_I: u32 = 0;
pub const EM_FUNC_SIG_PARAM_J: u32 = 1;
pub const EM_FUNC_SIG_PARAM_F: u32 = 2;
pub const EM_FUNC_SIG_PARAM_D: u32 = 3;
pub const EM_FUNC_SIG_PARAM_P: u32 = 0;
pub const EM_FUNC_SIG_PARAM_B: u32 = 4;
pub const EM_FUNC_SIG_PARAM_F2I: u32 = 5;
pub const EM_FUNC_SIG_SPECIAL_INTERNAL: u32 = 16777216;
pub const EMSCRIPTEN_WASM_WORKER_ID_PARENT: u32 = 0;
pub const EMSCRIPTEN_LOCK_T_STATIC_INITIALIZER: u32 = 0;
pub const EMSCRIPTEN_AUDIO_MAIN_THREAD: u32 = 0;
pub type emscripten_align1_short = ::std::os::raw::c_short;
pub type emscripten_align4_int64 = ::std::os::raw::c_longlong;
pub type emscripten_align2_int64 = ::std::os::raw::c_longlong;
pub type emscripten_align1_int64 = ::std::os::raw::c_longlong;
pub type emscripten_align2_int = ::std::os::raw::c_int;
pub type emscripten_align1_int = ::std::os::raw::c_int;
pub type emscripten_align2_float = f32;
pub type emscripten_align1_float = f32;
pub type emscripten_align4_double = f64;
pub type emscripten_align2_double = f64;
pub type emscripten_align1_double = f64;
pub type em_callback_func = ::std::option::Option<unsafe extern "C" fn()>;
pub type em_arg_callback_func =
    ::std::option::Option<unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void)>;
pub type em_str_callback_func =
    ::std::option::Option<unsafe extern "C" fn(arg1: *const ::std::os::raw::c_char)>;
pub type emscripten_async_wait_callback_t = ::std::option::Option<
    unsafe extern "C" fn(
        address: *mut i32,
        value: u32,
        waitResult: ::std::os::raw::c_int,
        userData: *mut ::std::os::raw::c_void,
    ),
>;
unsafe extern "C" {
    pub fn emscripten_atomic_wait_async(
        addr: *mut ::std::os::raw::c_void,
        value: u32,
        asyncWaitFinished: emscripten_async_wait_callback_t,
        userData: *mut ::std::os::raw::c_void,
        maxWaitMilliseconds: f64,
    ) -> i32;
}
unsafe extern "C" {
    pub fn emscripten_atomic_cancel_wait_async(waitToken: i32) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_atomic_cancel_all_wait_asyncs() -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_atomic_cancel_all_wait_asyncs_at_address(
        addr: *mut ::std::os::raw::c_void,
    ) -> ::std::os::raw::c_int;
}
pub type va_list = __builtin_va_list;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _IO_FILE {
    _unused: [u8; 0],
}
pub type FILE = _IO_FILE;
#[repr(C)]
#[derive(Copy, Clone)]
pub struct pthread_attr_t {
    pub __u: pthread_attr_t__bindgen_ty_1,
    pub _a_transferredcanvases: *const ::std::os::raw::c_char,
}
#[repr(C)]
#[derive(Copy, Clone)]
pub union pthread_attr_t__bindgen_ty_1 {
    pub __i: [::std::os::raw::c_int; 10usize],
    pub __vi: [::std::os::raw::c_int; 10usize],
    pub __s: [::std::os::raw::c_ulong; 10usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of pthread_attr_t__bindgen_ty_1"]
        [::std::mem::size_of::<pthread_attr_t__bindgen_ty_1>() - 40usize];
    ["Alignment of pthread_attr_t__bindgen_ty_1"]
        [::std::mem::align_of::<pthread_attr_t__bindgen_ty_1>() - 4usize];
    ["Offset of field: pthread_attr_t__bindgen_ty_1::__i"]
        [::std::mem::offset_of!(pthread_attr_t__bindgen_ty_1, __i) - 0usize];
    ["Offset of field: pthread_attr_t__bindgen_ty_1::__vi"]
        [::std::mem::offset_of!(pthread_attr_t__bindgen_ty_1, __vi) - 0usize];
    ["Offset of field: pthread_attr_t__bindgen_ty_1::__s"]
        [::std::mem::offset_of!(pthread_attr_t__bindgen_ty_1, __s) - 0usize];
};
impl Default for pthread_attr_t__bindgen_ty_1 {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of pthread_attr_t"][::std::mem::size_of::<pthread_attr_t>() - 44usize];
    ["Alignment of pthread_attr_t"][::std::mem::align_of::<pthread_attr_t>() - 4usize];
    ["Offset of field: pthread_attr_t::__u"][::std::mem::offset_of!(pthread_attr_t, __u) - 0usize];
    ["Offset of field: pthread_attr_t::_a_transferredcanvases"]
        [::std::mem::offset_of!(pthread_attr_t, _a_transferredcanvases) - 40usize];
};
impl Default for pthread_attr_t {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
pub type pthread_t = ::std::os::raw::c_ulong;
unsafe extern "C" {
    pub fn emscripten_asm_const_int(
        code: *const ::std::os::raw::c_char,
        arg_sigs: *const ::std::os::raw::c_char,
        ...
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_asm_const_ptr(
        code: *const ::std::os::raw::c_char,
        arg_sigs: *const ::std::os::raw::c_char,
        ...
    ) -> *mut ::std::os::raw::c_void;
}
unsafe extern "C" {
    pub fn emscripten_asm_const_double(
        code: *const ::std::os::raw::c_char,
        arg_sigs: *const ::std::os::raw::c_char,
        ...
    ) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_asm_const_int_sync_on_main_thread(
        code: *const ::std::os::raw::c_char,
        arg_sigs: *const ::std::os::raw::c_char,
        ...
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_asm_const_ptr_sync_on_main_thread(
        code: *const ::std::os::raw::c_char,
        arg_sigs: *const ::std::os::raw::c_char,
        ...
    ) -> *mut ::std::os::raw::c_void;
}
unsafe extern "C" {
    pub fn emscripten_asm_const_double_sync_on_main_thread(
        code: *const ::std::os::raw::c_char,
        arg_sigs: *const ::std::os::raw::c_char,
        ...
    ) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_asm_const_async_on_main_thread(
        code: *const ::std::os::raw::c_char,
        arg_sigs: *const ::std::os::raw::c_char,
        ...
    );
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct __em_asm_sig {
    pub _address: u8,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_float_void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_float_void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_double_void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_double_void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_char_void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_char_void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_signed_char_void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_signed_char_void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_unsigned_char_void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_unsigned_char_void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_short_void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_short_void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_unsigned_short_void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_unsigned_short_void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_int_void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_int_void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_unsigned_int_void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_unsigned_int_void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_long_void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_long_void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_unsigned_long_void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_unsigned_long_void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_bool__void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_bool__void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_wchar_t_void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_wchar_t_void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_long_long_void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_long_long_void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_unsigned_long_long_void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_unsigned_long_long_void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct __em_asm_type_tuple {
    pub _address: u8,
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct __em_asm_sig_builder {
    pub _address: u8,
}
pub type emscripten_internal_TYPEID = *const ::std::os::raw::c_void;
pub const emscripten_internal_EM_INVOKER_KIND_FUNCTION: emscripten_internal_EM_INVOKER_KIND = 0;
pub const emscripten_internal_EM_INVOKER_KIND_METHOD: emscripten_internal_EM_INVOKER_KIND = 1;
pub const emscripten_internal_EM_INVOKER_KIND_CONSTRUCTOR: emscripten_internal_EM_INVOKER_KIND = 2;
pub const emscripten_internal_EM_INVOKER_KIND_CAST: emscripten_internal_EM_INVOKER_KIND = 3;
pub type emscripten_internal_EM_INVOKER_KIND = ::std::os::raw::c_int;
unsafe extern "C" {
    #[link_name = "\u{1}_emval_register_symbol"]
    pub fn emscripten_internal__emval_register_symbol(arg1: *const ::std::os::raw::c_char);
}
pub const _EMVAL_UNDEFINED: emscripten_internal__bindgen_ty_1 = 2;
pub const _EMVAL_NULL: emscripten_internal__bindgen_ty_1 = 4;
pub const _EMVAL_TRUE: emscripten_internal__bindgen_ty_1 = 6;
pub const _EMVAL_FALSE: emscripten_internal__bindgen_ty_1 = 8;
pub const _EMVAL_LAST_RESERVED_HANDLE: emscripten_internal__bindgen_ty_1 = 8;
pub type emscripten_internal__bindgen_ty_1 = ::std::os::raw::c_uint;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct emscripten_internal__EM_DESTRUCTORS {
    _unused: [u8; 0],
}
pub type emscripten_internal_EM_DESTRUCTORS = *mut emscripten_internal__EM_DESTRUCTORS;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct emscripten_internal__EM_INVOKER {
    _unused: [u8; 0],
}
pub type emscripten_internal_EM_INVOKER = *mut emscripten_internal__EM_INVOKER;
pub type emscripten_internal_EM_GENERIC_WIRE_TYPE = f64;
pub type emscripten_internal_EM_VAR_ARGS = *const ::std::os::raw::c_void;
unsafe extern "C" {
    #[link_name = "\u{1}_emval_incref"]
    pub fn emscripten_internal__emval_incref(value: emscripten_EM_VAL);
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_decref"]
    pub fn emscripten_internal__emval_decref(value: emscripten_EM_VAL);
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_run_destructors"]
    pub fn emscripten_internal__emval_run_destructors(handle: emscripten_internal_EM_DESTRUCTORS);
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_new_array"]
    pub fn emscripten_internal__emval_new_array() -> emscripten_EM_VAL;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_new_array_from_memory_view"]
    pub fn emscripten_internal__emval_new_array_from_memory_view(
        mv: emscripten_EM_VAL,
    ) -> emscripten_EM_VAL;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_new_object"]
    pub fn emscripten_internal__emval_new_object() -> emscripten_EM_VAL;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_new_cstring"]
    pub fn emscripten_internal__emval_new_cstring(
        arg1: *const ::std::os::raw::c_char,
    ) -> emscripten_EM_VAL;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_new_u8string"]
    pub fn emscripten_internal__emval_new_u8string(
        arg1: *const ::std::os::raw::c_char,
    ) -> emscripten_EM_VAL;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_new_u16string"]
    pub fn emscripten_internal__emval_new_u16string(arg1: *const u16) -> emscripten_EM_VAL;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_get_global"]
    pub fn emscripten_internal__emval_get_global(
        name: *const ::std::os::raw::c_char,
    ) -> emscripten_EM_VAL;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_get_module_property"]
    pub fn emscripten_internal__emval_get_module_property(
        name: *const ::std::os::raw::c_char,
    ) -> emscripten_EM_VAL;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_get_property"]
    pub fn emscripten_internal__emval_get_property(
        object: emscripten_EM_VAL,
        key: emscripten_EM_VAL,
    ) -> emscripten_EM_VAL;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_set_property"]
    pub fn emscripten_internal__emval_set_property(
        object: emscripten_EM_VAL,
        key: emscripten_EM_VAL,
        value: emscripten_EM_VAL,
    );
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_equals"]
    pub fn emscripten_internal__emval_equals(
        first: emscripten_EM_VAL,
        second: emscripten_EM_VAL,
    ) -> bool;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_strictly_equals"]
    pub fn emscripten_internal__emval_strictly_equals(
        first: emscripten_EM_VAL,
        second: emscripten_EM_VAL,
    ) -> bool;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_greater_than"]
    pub fn emscripten_internal__emval_greater_than(
        first: emscripten_EM_VAL,
        second: emscripten_EM_VAL,
    ) -> bool;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_less_than"]
    pub fn emscripten_internal__emval_less_than(
        first: emscripten_EM_VAL,
        second: emscripten_EM_VAL,
    ) -> bool;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_not"]
    pub fn emscripten_internal__emval_not(object: emscripten_EM_VAL) -> bool;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_create_invoker"]
    pub fn emscripten_internal__emval_create_invoker(
        argCount: ::std::os::raw::c_uint,
        argTypes: *const emscripten_internal_TYPEID,
        kind: emscripten_internal_EM_INVOKER_KIND,
    ) -> emscripten_internal_EM_INVOKER;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_invoke"]
    pub fn emscripten_internal__emval_invoke(
        caller: emscripten_internal_EM_INVOKER,
        handle: emscripten_EM_VAL,
        methodName: *const ::std::os::raw::c_char,
        destructors: *mut emscripten_internal_EM_DESTRUCTORS,
        argv: emscripten_internal_EM_VAR_ARGS,
    ) -> emscripten_internal_EM_GENERIC_WIRE_TYPE;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_invoke_i64"]
    pub fn emscripten_internal__emval_invoke_i64(
        caller: emscripten_internal_EM_INVOKER,
        handle: emscripten_EM_VAL,
        methodName: *const ::std::os::raw::c_char,
        destructors: *mut emscripten_internal_EM_DESTRUCTORS,
        argv: emscripten_internal_EM_VAR_ARGS,
    ) -> i64;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_typeof"]
    pub fn emscripten_internal__emval_typeof(value: emscripten_EM_VAL) -> emscripten_EM_VAL;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_instanceof"]
    pub fn emscripten_internal__emval_instanceof(
        object: emscripten_EM_VAL,
        constructor: emscripten_EM_VAL,
    ) -> bool;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_is_number"]
    pub fn emscripten_internal__emval_is_number(object: emscripten_EM_VAL) -> bool;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_is_string"]
    pub fn emscripten_internal__emval_is_string(object: emscripten_EM_VAL) -> bool;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_in"]
    pub fn emscripten_internal__emval_in(
        item: emscripten_EM_VAL,
        object: emscripten_EM_VAL,
    ) -> bool;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_delete"]
    pub fn emscripten_internal__emval_delete(
        object: emscripten_EM_VAL,
        property: emscripten_EM_VAL,
    ) -> bool;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_throw"]
    pub fn emscripten_internal__emval_throw(object: emscripten_EM_VAL) -> bool;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_await"]
    pub fn emscripten_internal__emval_await(promise: emscripten_EM_VAL) -> emscripten_EM_VAL;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_iter_begin"]
    pub fn emscripten_internal__emval_iter_begin(iterable: emscripten_EM_VAL) -> emscripten_EM_VAL;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_iter_next"]
    pub fn emscripten_internal__emval_iter_next(iterator: emscripten_EM_VAL) -> emscripten_EM_VAL;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_coro_suspend"]
    pub fn emscripten_internal__emval_coro_suspend(
        promise: emscripten_EM_VAL,
        coro_ptr: *mut ::std::os::raw::c_void,
    );
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_from_current_cxa_exception"]
    pub fn emscripten_internal__emval_from_current_cxa_exception() -> emscripten_EM_VAL;
}
unsafe extern "C" {
    #[link_name = "\u{1}_emval_coro_make_promise"]
    pub fn emscripten_internal__emval_coro_make_promise(
        resolve: *mut emscripten_EM_VAL,
        reject: *mut emscripten_EM_VAL,
    ) -> emscripten_EM_VAL;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct emscripten__EM_VAL {
    _unused: [u8; 0],
}
pub type emscripten_EM_VAL = *mut emscripten__EM_VAL;
unsafe extern "C" {
    pub fn emscripten_console_log(utf8String: *const ::std::os::raw::c_char);
}
unsafe extern "C" {
    pub fn emscripten_console_warn(utf8String: *const ::std::os::raw::c_char);
}
unsafe extern "C" {
    pub fn emscripten_console_error(utf8String: *const ::std::os::raw::c_char);
}
unsafe extern "C" {
    pub fn emscripten_console_trace(utf8String: *const ::std::os::raw::c_char);
}
unsafe extern "C" {
    pub fn emscripten_out(utf8String: *const ::std::os::raw::c_char);
}
unsafe extern "C" {
    pub fn emscripten_err(utf8String: *const ::std::os::raw::c_char);
}
unsafe extern "C" {
    pub fn emscripten_dbg(utf8String: *const ::std::os::raw::c_char);
}
unsafe extern "C" {
    pub fn emscripten_dbg_backtrace(utf8String: *const ::std::os::raw::c_char);
}
unsafe extern "C" {
    pub fn emscripten_outn(utf8String: *const ::std::os::raw::c_char, len: usize);
}
unsafe extern "C" {
    pub fn emscripten_errn(utf8String: *const ::std::os::raw::c_char, len: usize);
}
unsafe extern "C" {
    pub fn emscripten_dbgn(utf8String: *const ::std::os::raw::c_char, len: usize);
}
unsafe extern "C" {
    pub fn emscripten_console_logf(format: *const ::std::os::raw::c_char, ...);
}
unsafe extern "C" {
    pub fn emscripten_console_warnf(format: *const ::std::os::raw::c_char, ...);
}
unsafe extern "C" {
    pub fn emscripten_console_errorf(format: *const ::std::os::raw::c_char, ...);
}
unsafe extern "C" {
    pub fn emscripten_console_tracef(format: *const ::std::os::raw::c_char, ...);
}
unsafe extern "C" {
    pub fn emscripten_outf(format: *const ::std::os::raw::c_char, ...);
}
unsafe extern "C" {
    pub fn emscripten_errf(format: *const ::std::os::raw::c_char, ...);
}
unsafe extern "C" {
    pub fn emscripten_dbgf(format: *const ::std::os::raw::c_char, ...);
}
unsafe extern "C" {
    pub fn emscripten_dbg_backtracef(format: *const ::std::os::raw::c_char, ...);
}
unsafe extern "C" {
    pub fn emscripten_compute_dom_pk_code(
        keyCodeString: *const ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_dom_pk_code_to_string(
        code: ::std::os::raw::c_int,
    ) -> *const ::std::os::raw::c_char;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _em_promise {
    _unused: [u8; 0],
}
pub type em_promise_t = *mut _em_promise;
pub const em_promise_result_t_EM_PROMISE_FULFILL: em_promise_result_t = 0;
pub const em_promise_result_t_EM_PROMISE_MATCH: em_promise_result_t = 1;
pub const em_promise_result_t_EM_PROMISE_MATCH_RELEASE: em_promise_result_t = 2;
pub const em_promise_result_t_EM_PROMISE_REJECT: em_promise_result_t = 3;
pub type em_promise_result_t = ::std::os::raw::c_uint;
pub type em_promise_callback_t = ::std::option::Option<
    unsafe extern "C" fn(
        result: *mut *mut ::std::os::raw::c_void,
        data: *mut ::std::os::raw::c_void,
        value: *mut ::std::os::raw::c_void,
    ) -> em_promise_result_t,
>;
unsafe extern "C" {
    pub fn emscripten_promise_create() -> em_promise_t;
}
unsafe extern "C" {
    pub fn emscripten_promise_destroy(promise: em_promise_t);
}
unsafe extern "C" {
    pub fn emscripten_promise_resolve(
        promise: em_promise_t,
        result: em_promise_result_t,
        value: *mut ::std::os::raw::c_void,
    );
}
unsafe extern "C" {
    pub fn emscripten_promise_then(
        promise: em_promise_t,
        on_fulfilled: em_promise_callback_t,
        on_rejected: em_promise_callback_t,
        data: *mut ::std::os::raw::c_void,
    ) -> em_promise_t;
}
unsafe extern "C" {
    pub fn emscripten_promise_all(
        promises: *mut em_promise_t,
        results: *mut *mut ::std::os::raw::c_void,
        num_promises: usize,
    ) -> em_promise_t;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct em_settled_result_t {
    pub result: em_promise_result_t,
    pub value: *mut ::std::os::raw::c_void,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of em_settled_result_t"][::std::mem::size_of::<em_settled_result_t>() - 8usize];
    ["Alignment of em_settled_result_t"][::std::mem::align_of::<em_settled_result_t>() - 4usize];
    ["Offset of field: em_settled_result_t::result"]
        [::std::mem::offset_of!(em_settled_result_t, result) - 0usize];
    ["Offset of field: em_settled_result_t::value"]
        [::std::mem::offset_of!(em_settled_result_t, value) - 4usize];
};
impl Default for em_settled_result_t {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
unsafe extern "C" {
    pub fn emscripten_promise_all_settled(
        promises: *mut em_promise_t,
        results: *mut em_settled_result_t,
        num_promises: usize,
    ) -> em_promise_t;
}
unsafe extern "C" {
    pub fn emscripten_promise_any(
        promises: *mut em_promise_t,
        errors: *mut *mut ::std::os::raw::c_void,
        num_promises: usize,
    ) -> em_promise_t;
}
unsafe extern "C" {
    pub fn emscripten_promise_race(
        promises: *mut em_promise_t,
        num_promises: usize,
    ) -> em_promise_t;
}
unsafe extern "C" {
    pub fn emscripten_promise_await(promise: em_promise_t) -> em_settled_result_t;
}
unsafe extern "C" {
    pub fn emscripten_async_wget(
        url: *const ::std::os::raw::c_char,
        file: *const ::std::os::raw::c_char,
        onload: em_str_callback_func,
        onerror: em_str_callback_func,
    );
}
pub type em_async_wget_onload_func = ::std::option::Option<
    unsafe extern "C" fn(
        userdata: *mut ::std::os::raw::c_void,
        data: *mut ::std::os::raw::c_void,
        size: ::std::os::raw::c_int,
    ),
>;
unsafe extern "C" {
    pub fn emscripten_async_wget_data(
        url: *const ::std::os::raw::c_char,
        userdata: *mut ::std::os::raw::c_void,
        onload: em_async_wget_onload_func,
        onerror: em_arg_callback_func,
    );
}
pub type em_async_wget2_onload_func = ::std::option::Option<
    unsafe extern "C" fn(
        handle: ::std::os::raw::c_uint,
        userdata: *mut ::std::os::raw::c_void,
        data: *const ::std::os::raw::c_char,
    ),
>;
pub type em_async_wget2_onstatus_func = ::std::option::Option<
    unsafe extern "C" fn(
        handle: ::std::os::raw::c_uint,
        userdata: *mut ::std::os::raw::c_void,
        status: ::std::os::raw::c_int,
    ),
>;
unsafe extern "C" {
    pub fn emscripten_async_wget2(
        url: *const ::std::os::raw::c_char,
        file: *const ::std::os::raw::c_char,
        requesttype: *const ::std::os::raw::c_char,
        param: *const ::std::os::raw::c_char,
        userdata: *mut ::std::os::raw::c_void,
        onload: em_async_wget2_onload_func,
        onerror: em_async_wget2_onstatus_func,
        onprogress: em_async_wget2_onstatus_func,
    ) -> ::std::os::raw::c_int;
}
pub type em_async_wget2_data_onload_func = ::std::option::Option<
    unsafe extern "C" fn(
        handle: ::std::os::raw::c_uint,
        userdata: *mut ::std::os::raw::c_void,
        data: *mut ::std::os::raw::c_void,
        size: ::std::os::raw::c_uint,
    ),
>;
pub type em_async_wget2_data_onerror_func = ::std::option::Option<
    unsafe extern "C" fn(
        handle: ::std::os::raw::c_uint,
        userdata: *mut ::std::os::raw::c_void,
        status: ::std::os::raw::c_int,
        status_text: *const ::std::os::raw::c_char,
    ),
>;
pub type em_async_wget2_data_onprogress_func = ::std::option::Option<
    unsafe extern "C" fn(
        handle: ::std::os::raw::c_uint,
        userdata: *mut ::std::os::raw::c_void,
        loaded: ::std::os::raw::c_int,
        total: ::std::os::raw::c_int,
    ),
>;
unsafe extern "C" {
    pub fn emscripten_async_wget2_data(
        url: *const ::std::os::raw::c_char,
        requesttype: *const ::std::os::raw::c_char,
        param: *const ::std::os::raw::c_char,
        arg: *mut ::std::os::raw::c_void,
        free: ::std::os::raw::c_int,
        onload: em_async_wget2_data_onload_func,
        onerror: em_async_wget2_data_onerror_func,
        onprogress: em_async_wget2_data_onprogress_func,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_async_wget2_abort(handle: ::std::os::raw::c_int);
}
unsafe extern "C" {
    pub fn emscripten_wget(
        url: *const ::std::os::raw::c_char,
        file: *const ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_wget_data(
        url: *const ::std::os::raw::c_char,
        pbuffer: *mut *mut ::std::os::raw::c_void,
        pnum: *mut ::std::os::raw::c_int,
        perror: *mut ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_run_script(script: *const ::std::os::raw::c_char);
}
unsafe extern "C" {
    pub fn emscripten_run_script_int(
        script: *const ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_run_script_string(
        script: *const ::std::os::raw::c_char,
    ) -> *mut ::std::os::raw::c_char;
}
unsafe extern "C" {
    pub fn emscripten_async_run_script(
        script: *const ::std::os::raw::c_char,
        millis: ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_async_load_script(
        script: *const ::std::os::raw::c_char,
        onload: em_callback_func,
        onerror: em_callback_func,
    );
}
unsafe extern "C" {
    pub fn emscripten_set_main_loop(
        func: em_callback_func,
        fps: ::std::os::raw::c_int,
        simulate_infinite_loop: bool,
    );
}
unsafe extern "C" {
    pub fn emscripten_set_main_loop_timing(
        mode: ::std::os::raw::c_int,
        value: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_get_main_loop_timing(
        mode: *mut ::std::os::raw::c_int,
        value: *mut ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_set_main_loop_arg(
        func: em_arg_callback_func,
        arg: *mut ::std::os::raw::c_void,
        fps: ::std::os::raw::c_int,
        simulate_infinite_loop: bool,
    );
}
unsafe extern "C" {
    pub fn emscripten_pause_main_loop();
}
unsafe extern "C" {
    pub fn emscripten_resume_main_loop();
}
unsafe extern "C" {
    pub fn emscripten_cancel_main_loop();
}
pub type em_socket_callback = ::std::option::Option<
    unsafe extern "C" fn(fd: ::std::os::raw::c_int, userData: *mut ::std::os::raw::c_void),
>;
pub type em_socket_error_callback = ::std::option::Option<
    unsafe extern "C" fn(
        fd: ::std::os::raw::c_int,
        err: ::std::os::raw::c_int,
        msg: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
    ),
>;
unsafe extern "C" {
    pub fn emscripten_set_socket_error_callback(
        userData: *mut ::std::os::raw::c_void,
        callback: em_socket_error_callback,
    );
}
unsafe extern "C" {
    pub fn emscripten_set_socket_open_callback(
        userData: *mut ::std::os::raw::c_void,
        callback: em_socket_callback,
    );
}
unsafe extern "C" {
    pub fn emscripten_set_socket_listen_callback(
        userData: *mut ::std::os::raw::c_void,
        callback: em_socket_callback,
    );
}
unsafe extern "C" {
    pub fn emscripten_set_socket_connection_callback(
        userData: *mut ::std::os::raw::c_void,
        callback: em_socket_callback,
    );
}
unsafe extern "C" {
    pub fn emscripten_set_socket_message_callback(
        userData: *mut ::std::os::raw::c_void,
        callback: em_socket_callback,
    );
}
unsafe extern "C" {
    pub fn emscripten_set_socket_close_callback(
        userData: *mut ::std::os::raw::c_void,
        callback: em_socket_callback,
    );
}
unsafe extern "C" {
    pub fn _emscripten_push_main_loop_blocker(
        func: em_arg_callback_func,
        arg: *mut ::std::os::raw::c_void,
        name: *const ::std::os::raw::c_char,
    );
}
unsafe extern "C" {
    pub fn _emscripten_push_uncounted_main_loop_blocker(
        func: em_arg_callback_func,
        arg: *mut ::std::os::raw::c_void,
        name: *const ::std::os::raw::c_char,
    );
}
unsafe extern "C" {
    pub fn emscripten_set_main_loop_expected_blockers(num: ::std::os::raw::c_int);
}
unsafe extern "C" {
    pub fn emscripten_async_call(
        func: em_arg_callback_func,
        arg: *mut ::std::os::raw::c_void,
        millis: ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_exit_with_live_runtime() -> !;
}
unsafe extern "C" {
    pub fn emscripten_force_exit(status: ::std::os::raw::c_int) -> !;
}
unsafe extern "C" {
    pub fn emscripten_get_device_pixel_ratio() -> f64;
}
unsafe extern "C" {
    pub fn emscripten_get_window_title() -> *mut ::std::os::raw::c_char;
}
unsafe extern "C" {
    pub fn emscripten_set_window_title(arg1: *const ::std::os::raw::c_char);
}
unsafe extern "C" {
    pub fn emscripten_get_screen_size(
        width: *mut ::std::os::raw::c_int,
        height: *mut ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_hide_mouse();
}
unsafe extern "C" {
    pub fn emscripten_set_canvas_size(width: ::std::os::raw::c_int, height: ::std::os::raw::c_int);
}
unsafe extern "C" {
    pub fn emscripten_get_canvas_size(
        width: *mut ::std::os::raw::c_int,
        height: *mut ::std::os::raw::c_int,
        isFullscreen: *mut ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_get_now() -> f64;
}
unsafe extern "C" {
    pub fn emscripten_random() -> f32;
}
pub type em_idb_onload_func = ::std::option::Option<
    unsafe extern "C" fn(
        arg1: *mut ::std::os::raw::c_void,
        arg2: *mut ::std::os::raw::c_void,
        arg3: ::std::os::raw::c_int,
    ),
>;
unsafe extern "C" {
    pub fn emscripten_idb_async_load(
        db_name: *const ::std::os::raw::c_char,
        file_id: *const ::std::os::raw::c_char,
        arg: *mut ::std::os::raw::c_void,
        onload: em_idb_onload_func,
        onerror: em_arg_callback_func,
    );
}
unsafe extern "C" {
    pub fn emscripten_idb_async_store(
        db_name: *const ::std::os::raw::c_char,
        file_id: *const ::std::os::raw::c_char,
        ptr: *mut ::std::os::raw::c_void,
        num: ::std::os::raw::c_int,
        arg: *mut ::std::os::raw::c_void,
        onstore: em_arg_callback_func,
        onerror: em_arg_callback_func,
    );
}
unsafe extern "C" {
    pub fn emscripten_idb_async_delete(
        db_name: *const ::std::os::raw::c_char,
        file_id: *const ::std::os::raw::c_char,
        arg: *mut ::std::os::raw::c_void,
        ondelete: em_arg_callback_func,
        onerror: em_arg_callback_func,
    );
}
pub type em_idb_exists_func = ::std::option::Option<
    unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void, arg2: ::std::os::raw::c_int),
>;
unsafe extern "C" {
    pub fn emscripten_idb_async_exists(
        db_name: *const ::std::os::raw::c_char,
        file_id: *const ::std::os::raw::c_char,
        arg: *mut ::std::os::raw::c_void,
        oncheck: em_idb_exists_func,
        onerror: em_arg_callback_func,
    );
}
unsafe extern "C" {
    pub fn emscripten_idb_async_clear(
        db_name: *const ::std::os::raw::c_char,
        arg: *mut ::std::os::raw::c_void,
        onclear: em_arg_callback_func,
        onerror: em_arg_callback_func,
    );
}
unsafe extern "C" {
    pub fn emscripten_idb_load(
        db_name: *const ::std::os::raw::c_char,
        file_id: *const ::std::os::raw::c_char,
        pbuffer: *mut *mut ::std::os::raw::c_void,
        pnum: *mut ::std::os::raw::c_int,
        perror: *mut ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_idb_store(
        db_name: *const ::std::os::raw::c_char,
        file_id: *const ::std::os::raw::c_char,
        buffer: *mut ::std::os::raw::c_void,
        num: ::std::os::raw::c_int,
        perror: *mut ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_idb_delete(
        db_name: *const ::std::os::raw::c_char,
        file_id: *const ::std::os::raw::c_char,
        perror: *mut ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_idb_exists(
        db_name: *const ::std::os::raw::c_char,
        file_id: *const ::std::os::raw::c_char,
        pexists: *mut ::std::os::raw::c_int,
        perror: *mut ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_idb_clear(
        db_name: *const ::std::os::raw::c_char,
        perror: *mut ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_idb_load_blob(
        db_name: *const ::std::os::raw::c_char,
        file_id: *const ::std::os::raw::c_char,
        pblob: *mut ::std::os::raw::c_int,
        perror: *mut ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_idb_store_blob(
        db_name: *const ::std::os::raw::c_char,
        file_id: *const ::std::os::raw::c_char,
        buffer: *mut ::std::os::raw::c_void,
        num: ::std::os::raw::c_int,
        perror: *mut ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_idb_read_from_blob(
        blob: ::std::os::raw::c_int,
        start: ::std::os::raw::c_int,
        num: ::std::os::raw::c_int,
        buffer: *mut ::std::os::raw::c_void,
    );
}
unsafe extern "C" {
    pub fn emscripten_idb_free_blob(blob: ::std::os::raw::c_int);
}
unsafe extern "C" {
    pub fn emscripten_run_preload_plugins(
        file: *const ::std::os::raw::c_char,
        onload: em_str_callback_func,
        onerror: em_str_callback_func,
    ) -> ::std::os::raw::c_int;
}
pub type em_run_preload_plugins_data_onload_func = ::std::option::Option<
    unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void, arg2: *const ::std::os::raw::c_char),
>;
unsafe extern "C" {
    pub fn emscripten_run_preload_plugins_data(
        data: *mut ::std::os::raw::c_char,
        size: ::std::os::raw::c_int,
        suffix: *const ::std::os::raw::c_char,
        arg: *mut ::std::os::raw::c_void,
        onload: em_run_preload_plugins_data_onload_func,
        onerror: em_arg_callback_func,
    );
}
unsafe extern "C" {
    pub fn emscripten_lazy_load_code();
}
pub type worker_handle = ::std::os::raw::c_int;
unsafe extern "C" {
    pub fn emscripten_create_worker(url: *const ::std::os::raw::c_char) -> worker_handle;
}
unsafe extern "C" {
    pub fn emscripten_destroy_worker(worker: worker_handle);
}
pub type em_worker_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        arg1: *mut ::std::os::raw::c_char,
        arg2: ::std::os::raw::c_int,
        arg3: *mut ::std::os::raw::c_void,
    ),
>;
unsafe extern "C" {
    pub fn emscripten_call_worker(
        worker: worker_handle,
        funcname: *const ::std::os::raw::c_char,
        data: *mut ::std::os::raw::c_char,
        size: ::std::os::raw::c_int,
        callback: em_worker_callback_func,
        arg: *mut ::std::os::raw::c_void,
    );
}
unsafe extern "C" {
    pub fn emscripten_worker_respond(
        data: *mut ::std::os::raw::c_char,
        size: ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_worker_respond_provisionally(
        data: *mut ::std::os::raw::c_char,
        size: ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_get_worker_queue_size(worker: worker_handle) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_get_compiler_setting(
        name: *const ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_long;
}
unsafe extern "C" {
    pub fn emscripten_has_asyncify() -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_debugger();
}
unsafe extern "C" {
    pub fn emscripten_get_preloaded_image_data(
        path: *const ::std::os::raw::c_char,
        w: *mut ::std::os::raw::c_int,
        h: *mut ::std::os::raw::c_int,
    ) -> *mut ::std::os::raw::c_char;
}
unsafe extern "C" {
    pub fn emscripten_get_preloaded_image_data_from_FILE(
        file: *mut FILE,
        w: *mut ::std::os::raw::c_int,
        h: *mut ::std::os::raw::c_int,
    ) -> *mut ::std::os::raw::c_char;
}
unsafe extern "C" {
    pub fn emscripten_log(flags: ::std::os::raw::c_int, format: *const ::std::os::raw::c_char, ...);
}
unsafe extern "C" {
    pub fn emscripten_get_callstack(
        flags: ::std::os::raw::c_int,
        out: *mut ::std::os::raw::c_char,
        maxbytes: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_print_double(
        x: f64,
        to: *mut ::std::os::raw::c_char,
        max: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
pub type em_scan_func = ::std::option::Option<
    unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void, arg2: *mut ::std::os::raw::c_void),
>;
unsafe extern "C" {
    pub fn emscripten_scan_registers(func: em_scan_func);
}
unsafe extern "C" {
    pub fn emscripten_scan_stack(func: em_scan_func);
}
pub type em_dlopen_callback = ::std::option::Option<
    unsafe extern "C" fn(
        user_data: *mut ::std::os::raw::c_void,
        handle: *mut ::std::os::raw::c_void,
    ),
>;
unsafe extern "C" {
    pub fn emscripten_dlopen(
        filename: *const ::std::os::raw::c_char,
        flags: ::std::os::raw::c_int,
        user_data: *mut ::std::os::raw::c_void,
        onsuccess: em_dlopen_callback,
        onerror: em_arg_callback_func,
    );
}
unsafe extern "C" {
    pub fn emscripten_dlopen_promise(
        filename: *const ::std::os::raw::c_char,
        flags: ::std::os::raw::c_int,
    ) -> em_promise_t;
}
unsafe extern "C" {
    pub fn emscripten_throw_number(number: f64);
}
unsafe extern "C" {
    pub fn emscripten_throw_string(utf8String: *const ::std::os::raw::c_char);
}
unsafe extern "C" {
    pub fn emscripten_sleep(ms: ::std::os::raw::c_uint);
}
unsafe extern "C" {
    pub fn emscripten_math_acos(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_acosh(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_asin(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_asinh(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_atan(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_atan2(y: f64, x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_atanh(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_cbrt(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_cos(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_cosh(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_exp(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_expm1(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_fmod(x: f64, y: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_hypot(count: ::std::os::raw::c_int, ...) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_log(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_log1p(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_log10(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_log2(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_pow(x: f64, y: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_random() -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_round(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_sign(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_sin(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_sinh(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_sqrt(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_tan(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_math_tanh(x: f64) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_unwind_to_js_event_loop() -> !;
}
unsafe extern "C" {
    pub fn emscripten_set_timeout(
        cb: ::std::option::Option<unsafe extern "C" fn(user_data: *mut ::std::os::raw::c_void)>,
        msecs: f64,
        user_data: *mut ::std::os::raw::c_void,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_clear_timeout(id: ::std::os::raw::c_int);
}
unsafe extern "C" {
    pub fn emscripten_set_timeout_loop(
        cb: ::std::option::Option<
            unsafe extern "C" fn(time: f64, user_data: *mut ::std::os::raw::c_void) -> bool,
        >,
        interval_ms: f64,
        user_data: *mut ::std::os::raw::c_void,
    );
}
unsafe extern "C" {
    pub fn emscripten_set_immediate(
        cb: ::std::option::Option<unsafe extern "C" fn(user_data: *mut ::std::os::raw::c_void)>,
        user_data: *mut ::std::os::raw::c_void,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_clear_immediate(id: ::std::os::raw::c_int);
}
unsafe extern "C" {
    pub fn emscripten_set_immediate_loop(
        cb: ::std::option::Option<
            unsafe extern "C" fn(user_data: *mut ::std::os::raw::c_void) -> bool,
        >,
        user_data: *mut ::std::os::raw::c_void,
    );
}
unsafe extern "C" {
    pub fn emscripten_set_interval(
        cb: ::std::option::Option<unsafe extern "C" fn(user_data: *mut ::std::os::raw::c_void)>,
        interval_ms: f64,
        user_data: *mut ::std::os::raw::c_void,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_clear_interval(id: ::std::os::raw::c_int);
}
unsafe extern "C" {
    pub fn emscripten_runtime_keepalive_push();
}
unsafe extern "C" {
    pub fn emscripten_runtime_keepalive_pop();
}
unsafe extern "C" {
    pub fn emscripten_runtime_keepalive_check() -> bool;
}
unsafe extern "C" {
    pub fn emscripten_get_exported_function(
        fname: *const ::std::os::raw::c_char,
    ) -> *mut ::std::os::raw::c_void;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct emscripten_fetch_attr_t {
    pub requestMethod: [::std::os::raw::c_char; 32usize],
    pub userData: *mut ::std::os::raw::c_void,
    pub onsuccess: ::std::option::Option<unsafe extern "C" fn(fetch: *mut emscripten_fetch_t)>,
    pub onerror: ::std::option::Option<unsafe extern "C" fn(fetch: *mut emscripten_fetch_t)>,
    pub onprogress: ::std::option::Option<unsafe extern "C" fn(fetch: *mut emscripten_fetch_t)>,
    pub onreadystatechange:
        ::std::option::Option<unsafe extern "C" fn(fetch: *mut emscripten_fetch_t)>,
    pub attributes: u32,
    pub timeoutMSecs: u32,
    pub withCredentials: bool,
    pub destinationPath: *const ::std::os::raw::c_char,
    pub userName: *const ::std::os::raw::c_char,
    pub password: *const ::std::os::raw::c_char,
    pub requestHeaders: *const *const ::std::os::raw::c_char,
    pub overriddenMimeType: *const ::std::os::raw::c_char,
    pub requestData: *const ::std::os::raw::c_char,
    pub requestDataSize: usize,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of emscripten_fetch_attr_t"][::std::mem::size_of::<emscripten_fetch_attr_t>() - 92usize];
    ["Alignment of emscripten_fetch_attr_t"]
        [::std::mem::align_of::<emscripten_fetch_attr_t>() - 4usize];
    ["Offset of field: emscripten_fetch_attr_t::requestMethod"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, requestMethod) - 0usize];
    ["Offset of field: emscripten_fetch_attr_t::userData"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, userData) - 32usize];
    ["Offset of field: emscripten_fetch_attr_t::onsuccess"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, onsuccess) - 36usize];
    ["Offset of field: emscripten_fetch_attr_t::onerror"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, onerror) - 40usize];
    ["Offset of field: emscripten_fetch_attr_t::onprogress"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, onprogress) - 44usize];
    ["Offset of field: emscripten_fetch_attr_t::onreadystatechange"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, onreadystatechange) - 48usize];
    ["Offset of field: emscripten_fetch_attr_t::attributes"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, attributes) - 52usize];
    ["Offset of field: emscripten_fetch_attr_t::timeoutMSecs"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, timeoutMSecs) - 56usize];
    ["Offset of field: emscripten_fetch_attr_t::withCredentials"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, withCredentials) - 60usize];
    ["Offset of field: emscripten_fetch_attr_t::destinationPath"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, destinationPath) - 64usize];
    ["Offset of field: emscripten_fetch_attr_t::userName"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, userName) - 68usize];
    ["Offset of field: emscripten_fetch_attr_t::password"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, password) - 72usize];
    ["Offset of field: emscripten_fetch_attr_t::requestHeaders"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, requestHeaders) - 76usize];
    ["Offset of field: emscripten_fetch_attr_t::overriddenMimeType"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, overriddenMimeType) - 80usize];
    ["Offset of field: emscripten_fetch_attr_t::requestData"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, requestData) - 84usize];
    ["Offset of field: emscripten_fetch_attr_t::requestDataSize"]
        [::std::mem::offset_of!(emscripten_fetch_attr_t, requestDataSize) - 88usize];
};
impl Default for emscripten_fetch_attr_t {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct emscripten_fetch_t {
    pub id: u32,
    pub userData: *mut ::std::os::raw::c_void,
    pub url: *const ::std::os::raw::c_char,
    pub data: *const ::std::os::raw::c_char,
    pub numBytes: u64,
    pub dataOffset: u64,
    pub totalBytes: u64,
    pub readyState: ::std::os::raw::c_ushort,
    pub status: ::std::os::raw::c_ushort,
    pub statusText: [::std::os::raw::c_char; 64usize],
    pub __attributes: emscripten_fetch_attr_t,
    pub responseUrl: *const ::std::os::raw::c_char,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of emscripten_fetch_t"][::std::mem::size_of::<emscripten_fetch_t>() - 208usize];
    ["Alignment of emscripten_fetch_t"][::std::mem::align_of::<emscripten_fetch_t>() - 8usize];
    ["Offset of field: emscripten_fetch_t::id"]
        [::std::mem::offset_of!(emscripten_fetch_t, id) - 0usize];
    ["Offset of field: emscripten_fetch_t::userData"]
        [::std::mem::offset_of!(emscripten_fetch_t, userData) - 4usize];
    ["Offset of field: emscripten_fetch_t::url"]
        [::std::mem::offset_of!(emscripten_fetch_t, url) - 8usize];
    ["Offset of field: emscripten_fetch_t::data"]
        [::std::mem::offset_of!(emscripten_fetch_t, data) - 12usize];
    ["Offset of field: emscripten_fetch_t::numBytes"]
        [::std::mem::offset_of!(emscripten_fetch_t, numBytes) - 16usize];
    ["Offset of field: emscripten_fetch_t::dataOffset"]
        [::std::mem::offset_of!(emscripten_fetch_t, dataOffset) - 24usize];
    ["Offset of field: emscripten_fetch_t::totalBytes"]
        [::std::mem::offset_of!(emscripten_fetch_t, totalBytes) - 32usize];
    ["Offset of field: emscripten_fetch_t::readyState"]
        [::std::mem::offset_of!(emscripten_fetch_t, readyState) - 40usize];
    ["Offset of field: emscripten_fetch_t::status"]
        [::std::mem::offset_of!(emscripten_fetch_t, status) - 42usize];
    ["Offset of field: emscripten_fetch_t::statusText"]
        [::std::mem::offset_of!(emscripten_fetch_t, statusText) - 44usize];
    ["Offset of field: emscripten_fetch_t::__attributes"]
        [::std::mem::offset_of!(emscripten_fetch_t, __attributes) - 108usize];
    ["Offset of field: emscripten_fetch_t::responseUrl"]
        [::std::mem::offset_of!(emscripten_fetch_t, responseUrl) - 200usize];
};
impl Default for emscripten_fetch_t {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
unsafe extern "C" {
    pub fn emscripten_fetch_attr_init(fetch_attr: *mut emscripten_fetch_attr_t);
}
unsafe extern "C" {
    pub fn emscripten_fetch(
        fetch_attr: *mut emscripten_fetch_attr_t,
        url: *const ::std::os::raw::c_char,
    ) -> *mut emscripten_fetch_t;
}
unsafe extern "C" {
    pub fn emscripten_fetch_wait(
        fetch: *mut emscripten_fetch_t,
        timeoutMSecs: f64,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_fetch_close(fetch: *mut emscripten_fetch_t) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_fetch_get_response_headers_length(fetch: *mut emscripten_fetch_t) -> usize;
}
unsafe extern "C" {
    pub fn emscripten_fetch_get_response_headers(
        fetch: *mut emscripten_fetch_t,
        dst: *mut ::std::os::raw::c_char,
        dstSizeBytes: usize,
    ) -> usize;
}
unsafe extern "C" {
    pub fn emscripten_fetch_unpack_response_headers(
        headersString: *const ::std::os::raw::c_char,
    ) -> *mut *mut ::std::os::raw::c_char;
}
unsafe extern "C" {
    pub fn emscripten_fetch_free_unpacked_response_headers(
        unpackedHeaders: *mut *mut ::std::os::raw::c_char,
    );
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct asyncify_data_s {
    pub stack_ptr: *mut ::std::os::raw::c_void,
    #[doc = " Current position in the Asyncify stack (*not* the C stack)"]
    pub stack_limit: *mut ::std::os::raw::c_void,
    #[doc = " Where the Asyncify stack ends."]
    pub rewind_id: ::std::os::raw::c_int,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of asyncify_data_s"][::std::mem::size_of::<asyncify_data_s>() - 12usize];
    ["Alignment of asyncify_data_s"][::std::mem::align_of::<asyncify_data_s>() - 4usize];
    ["Offset of field: asyncify_data_s::stack_ptr"]
        [::std::mem::offset_of!(asyncify_data_s, stack_ptr) - 0usize];
    ["Offset of field: asyncify_data_s::stack_limit"]
        [::std::mem::offset_of!(asyncify_data_s, stack_limit) - 4usize];
    ["Offset of field: asyncify_data_s::rewind_id"]
        [::std::mem::offset_of!(asyncify_data_s, rewind_id) - 8usize];
};
impl Default for asyncify_data_s {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
pub type asyncify_data_t = asyncify_data_s;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct emscripten_fiber_s {
    pub stack_base: *mut ::std::os::raw::c_void,
    #[doc = " Where the C stack starts (NOTE: grows down)."]
    pub stack_limit: *mut ::std::os::raw::c_void,
    #[doc = " Where the C stack ends."]
    pub stack_ptr: *mut ::std::os::raw::c_void,
    #[doc = " Current position in the C stack."]
    pub entry: em_arg_callback_func,
    #[doc = " Function to call when resuming this context. If NULL, asyncify_data is used to rewind the call stack."]
    pub user_data: *mut ::std::os::raw::c_void,
    #[doc = " Opaque pointer, passed as-is to the entry function."]
    pub asyncify_data: asyncify_data_t,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of emscripten_fiber_s"][::std::mem::size_of::<emscripten_fiber_s>() - 32usize];
    ["Alignment of emscripten_fiber_s"][::std::mem::align_of::<emscripten_fiber_s>() - 4usize];
    ["Offset of field: emscripten_fiber_s::stack_base"]
        [::std::mem::offset_of!(emscripten_fiber_s, stack_base) - 0usize];
    ["Offset of field: emscripten_fiber_s::stack_limit"]
        [::std::mem::offset_of!(emscripten_fiber_s, stack_limit) - 4usize];
    ["Offset of field: emscripten_fiber_s::stack_ptr"]
        [::std::mem::offset_of!(emscripten_fiber_s, stack_ptr) - 8usize];
    ["Offset of field: emscripten_fiber_s::entry"]
        [::std::mem::offset_of!(emscripten_fiber_s, entry) - 12usize];
    ["Offset of field: emscripten_fiber_s::user_data"]
        [::std::mem::offset_of!(emscripten_fiber_s, user_data) - 16usize];
    ["Offset of field: emscripten_fiber_s::asyncify_data"]
        [::std::mem::offset_of!(emscripten_fiber_s, asyncify_data) - 20usize];
};
impl Default for emscripten_fiber_s {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
pub type emscripten_fiber_t = emscripten_fiber_s;
unsafe extern "C" {
    pub fn emscripten_fiber_init(
        fiber: *mut emscripten_fiber_t,
        entry_func: em_arg_callback_func,
        entry_func_arg: *mut ::std::os::raw::c_void,
        c_stack: *mut ::std::os::raw::c_void,
        c_stack_size: usize,
        asyncify_stack: *mut ::std::os::raw::c_void,
        asyncify_stack_size: usize,
    );
}
unsafe extern "C" {
    pub fn emscripten_fiber_init_from_current_context(
        fiber: *mut emscripten_fiber_t,
        asyncify_stack: *mut ::std::os::raw::c_void,
        asyncify_stack_size: usize,
    );
}
unsafe extern "C" {
    pub fn emscripten_fiber_swap(
        old_fiber: *mut emscripten_fiber_t,
        new_fiber: *mut emscripten_fiber_t,
    );
}
unsafe extern "C" {
    pub fn emscripten_get_sbrk_ptr() -> *mut usize;
}
unsafe extern "C" {
    pub fn emscripten_resize_heap(requested_size: usize) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_get_heap_size() -> usize;
}
unsafe extern "C" {
    pub fn emscripten_get_heap_max() -> usize;
}
unsafe extern "C" {
    pub fn emscripten_builtin_memalign(
        alignment: usize,
        size: usize,
    ) -> *mut ::std::os::raw::c_void;
}
unsafe extern "C" {
    pub fn emscripten_builtin_malloc(size: usize) -> *mut ::std::os::raw::c_void;
}
unsafe extern "C" {
    pub fn emscripten_builtin_realloc(
        ptr: *mut ::std::os::raw::c_void,
        size: usize,
    ) -> *mut ::std::os::raw::c_void;
}
unsafe extern "C" {
    pub fn emscripten_builtin_calloc(nmemb: usize, size: usize) -> *mut ::std::os::raw::c_void;
}
unsafe extern "C" {
    pub fn emscripten_builtin_free(ptr: *mut ::std::os::raw::c_void);
}
pub type EMSCRIPTEN_WEBGL_CONTEXT_HANDLE = usize;
pub type EMSCRIPTEN_WEBGL_CONTEXT_PROXY_MODE = ::std::os::raw::c_int;
pub type EM_WEBGL_POWER_PREFERENCE = ::std::os::raw::c_int;
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct EmscriptenWebGLContextAttributes {
    pub alpha: bool,
    pub depth: bool,
    pub stencil: bool,
    pub antialias: bool,
    pub premultipliedAlpha: bool,
    pub preserveDrawingBuffer: bool,
    pub powerPreference: EM_WEBGL_POWER_PREFERENCE,
    pub failIfMajorPerformanceCaveat: bool,
    pub majorVersion: ::std::os::raw::c_int,
    pub minorVersion: ::std::os::raw::c_int,
    pub enableExtensionsByDefault: bool,
    pub explicitSwapControl: bool,
    pub proxyContextToMainThread: EMSCRIPTEN_WEBGL_CONTEXT_PROXY_MODE,
    pub renderViaOffscreenBackBuffer: bool,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenWebGLContextAttributes"]
        [::std::mem::size_of::<EmscriptenWebGLContextAttributes>() - 36usize];
    ["Alignment of EmscriptenWebGLContextAttributes"]
        [::std::mem::align_of::<EmscriptenWebGLContextAttributes>() - 4usize];
    ["Offset of field: EmscriptenWebGLContextAttributes::alpha"]
        [::std::mem::offset_of!(EmscriptenWebGLContextAttributes, alpha) - 0usize];
    ["Offset of field: EmscriptenWebGLContextAttributes::depth"]
        [::std::mem::offset_of!(EmscriptenWebGLContextAttributes, depth) - 1usize];
    ["Offset of field: EmscriptenWebGLContextAttributes::stencil"]
        [::std::mem::offset_of!(EmscriptenWebGLContextAttributes, stencil) - 2usize];
    ["Offset of field: EmscriptenWebGLContextAttributes::antialias"]
        [::std::mem::offset_of!(EmscriptenWebGLContextAttributes, antialias) - 3usize];
    ["Offset of field: EmscriptenWebGLContextAttributes::premultipliedAlpha"]
        [::std::mem::offset_of!(EmscriptenWebGLContextAttributes, premultipliedAlpha) - 4usize];
    ["Offset of field: EmscriptenWebGLContextAttributes::preserveDrawingBuffer"]
        [::std::mem::offset_of!(EmscriptenWebGLContextAttributes, preserveDrawingBuffer) - 5usize];
    ["Offset of field: EmscriptenWebGLContextAttributes::powerPreference"]
        [::std::mem::offset_of!(EmscriptenWebGLContextAttributes, powerPreference) - 8usize];
    ["Offset of field: EmscriptenWebGLContextAttributes::failIfMajorPerformanceCaveat"][::std::mem::offset_of!(
        EmscriptenWebGLContextAttributes,
        failIfMajorPerformanceCaveat
    )
        - 12usize];
    ["Offset of field: EmscriptenWebGLContextAttributes::majorVersion"]
        [::std::mem::offset_of!(EmscriptenWebGLContextAttributes, majorVersion) - 16usize];
    ["Offset of field: EmscriptenWebGLContextAttributes::minorVersion"]
        [::std::mem::offset_of!(EmscriptenWebGLContextAttributes, minorVersion) - 20usize];
    ["Offset of field: EmscriptenWebGLContextAttributes::enableExtensionsByDefault"][::std::mem::offset_of!(
        EmscriptenWebGLContextAttributes,
        enableExtensionsByDefault
    ) - 24usize];
    ["Offset of field: EmscriptenWebGLContextAttributes::explicitSwapControl"]
        [::std::mem::offset_of!(EmscriptenWebGLContextAttributes, explicitSwapControl) - 25usize];
    ["Offset of field: EmscriptenWebGLContextAttributes::proxyContextToMainThread"][::std::mem::offset_of!(
        EmscriptenWebGLContextAttributes,
        proxyContextToMainThread
    ) - 28usize];
    ["Offset of field: EmscriptenWebGLContextAttributes::renderViaOffscreenBackBuffer"][::std::mem::offset_of!(
        EmscriptenWebGLContextAttributes,
        renderViaOffscreenBackBuffer
    )
        - 32usize];
};
unsafe extern "C" {
    pub fn emscripten_webgl_init_context_attributes(
        attributes: *mut EmscriptenWebGLContextAttributes,
    );
}
unsafe extern "C" {
    pub fn emscripten_webgl_create_context(
        target: *const ::std::os::raw::c_char,
        attributes: *const EmscriptenWebGLContextAttributes,
    ) -> EMSCRIPTEN_WEBGL_CONTEXT_HANDLE;
}
unsafe extern "C" {
    pub fn emscripten_webgl_make_context_current(
        context: EMSCRIPTEN_WEBGL_CONTEXT_HANDLE,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_current_context() -> EMSCRIPTEN_WEBGL_CONTEXT_HANDLE;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_drawing_buffer_size(
        context: EMSCRIPTEN_WEBGL_CONTEXT_HANDLE,
        width: *mut ::std::os::raw::c_int,
        height: *mut ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_context_attributes(
        context: EMSCRIPTEN_WEBGL_CONTEXT_HANDLE,
        outAttributes: *mut EmscriptenWebGLContextAttributes,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgl_destroy_context(
        context: EMSCRIPTEN_WEBGL_CONTEXT_HANDLE,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgl_enable_extension(
        context: EMSCRIPTEN_WEBGL_CONTEXT_HANDLE,
        extension: *const ::std::os::raw::c_char,
    ) -> bool;
}
unsafe extern "C" {
    pub fn emscripten_webgl_enable_ANGLE_instanced_arrays(
        context: EMSCRIPTEN_WEBGL_CONTEXT_HANDLE,
    ) -> bool;
}
unsafe extern "C" {
    pub fn emscripten_webgl_enable_OES_vertex_array_object(
        context: EMSCRIPTEN_WEBGL_CONTEXT_HANDLE,
    ) -> bool;
}
unsafe extern "C" {
    pub fn emscripten_webgl_enable_WEBGL_draw_buffers(
        context: EMSCRIPTEN_WEBGL_CONTEXT_HANDLE,
    ) -> bool;
}
unsafe extern "C" {
    pub fn emscripten_webgl_enable_WEBGL_draw_instanced_base_vertex_base_instance(
        context: EMSCRIPTEN_WEBGL_CONTEXT_HANDLE,
    ) -> bool;
}
unsafe extern "C" {
    pub fn emscripten_webgl_enable_WEBGL_multi_draw(
        context: EMSCRIPTEN_WEBGL_CONTEXT_HANDLE,
    ) -> bool;
}
unsafe extern "C" {
    pub fn emscripten_webgl_enable_WEBGL_multi_draw_instanced_base_vertex_base_instance(
        context: EMSCRIPTEN_WEBGL_CONTEXT_HANDLE,
    ) -> bool;
}
unsafe extern "C" {
    pub fn emscripten_webgl_enable_EXT_polygon_offset_clamp(
        context: EMSCRIPTEN_WEBGL_CONTEXT_HANDLE,
    ) -> bool;
}
unsafe extern "C" {
    pub fn emscripten_webgl_enable_EXT_clip_control(
        context: EMSCRIPTEN_WEBGL_CONTEXT_HANDLE,
    ) -> bool;
}
unsafe extern "C" {
    pub fn emscripten_webgl_enable_WEBGL_polygon_mode(
        context: EMSCRIPTEN_WEBGL_CONTEXT_HANDLE,
    ) -> bool;
}
pub type em_webgl_context_callback = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        reserved: *const ::std::os::raw::c_void,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_webglcontextlost_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_webgl_context_callback,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_webglcontextrestored_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_webgl_context_callback,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_is_webgl_context_lost(context: EMSCRIPTEN_WEBGL_CONTEXT_HANDLE) -> bool;
}
unsafe extern "C" {
    pub fn emscripten_webgl_commit_frame() -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_supports_offscreencanvas() -> bool;
}
unsafe extern "C" {
    pub fn emscripten_webgl1_get_proc_address(
        name: *const ::std::os::raw::c_char,
    ) -> *mut ::std::os::raw::c_void;
}
unsafe extern "C" {
    pub fn emscripten_webgl2_get_proc_address(
        name: *const ::std::os::raw::c_char,
    ) -> *mut ::std::os::raw::c_void;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_proc_address(
        name: *const ::std::os::raw::c_char,
    ) -> *mut ::std::os::raw::c_void;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_supported_extensions() -> *mut ::std::os::raw::c_char;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_shader_parameter_d(
        shader: ::std::os::raw::c_int,
        param: ::std::os::raw::c_int,
    ) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_shader_info_log_utf8(
        shader: ::std::os::raw::c_int,
    ) -> *mut ::std::os::raw::c_char;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_shader_source_utf8(
        shader: ::std::os::raw::c_int,
    ) -> *mut ::std::os::raw::c_char;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_program_parameter_d(
        program: ::std::os::raw::c_int,
        param: ::std::os::raw::c_int,
    ) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_program_info_log_utf8(
        program: ::std::os::raw::c_int,
    ) -> *mut ::std::os::raw::c_char;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_vertex_attrib_d(
        index: ::std::os::raw::c_int,
        param: ::std::os::raw::c_int,
    ) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_vertex_attrib_o(
        index: ::std::os::raw::c_int,
        param: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_vertex_attrib_v(
        index: ::std::os::raw::c_int,
        param: ::std::os::raw::c_int,
        dst: *mut ::std::os::raw::c_void,
        dstLength: ::std::os::raw::c_int,
        dstType: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_uniform_d(
        program: ::std::os::raw::c_int,
        location: ::std::os::raw::c_int,
    ) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_uniform_v(
        program: ::std::os::raw::c_int,
        location: ::std::os::raw::c_int,
        dst: *mut ::std::os::raw::c_void,
        dstLength: ::std::os::raw::c_int,
        dstType: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_parameter_v(
        param: ::std::os::raw::c_int,
        dst: *mut ::std::os::raw::c_void,
        dstLength: ::std::os::raw::c_int,
        dstType: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_parameter_d(param: ::std::os::raw::c_int) -> f64;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_parameter_o(param: ::std::os::raw::c_int) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_parameter_utf8(
        param: ::std::os::raw::c_int,
    ) -> *mut ::std::os::raw::c_char;
}
unsafe extern "C" {
    pub fn emscripten_webgl_get_parameter_i64v(
        param: ::std::os::raw::c_int,
        dst: *mut ::std::os::raw::c_longlong,
    );
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct EmscriptenKeyboardEvent {
    pub timestamp: f64,
    pub location: ::std::os::raw::c_uint,
    pub ctrlKey: bool,
    pub shiftKey: bool,
    pub altKey: bool,
    pub metaKey: bool,
    pub repeat: bool,
    pub charCode: ::std::os::raw::c_uint,
    pub keyCode: ::std::os::raw::c_uint,
    pub which: ::std::os::raw::c_uint,
    pub key: [::std::os::raw::c_char; 32usize],
    pub code: [::std::os::raw::c_char; 32usize],
    pub charValue: [::std::os::raw::c_char; 32usize],
    pub locale: [::std::os::raw::c_char; 32usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenKeyboardEvent"]
        [::std::mem::size_of::<EmscriptenKeyboardEvent>() - 160usize];
    ["Alignment of EmscriptenKeyboardEvent"]
        [::std::mem::align_of::<EmscriptenKeyboardEvent>() - 8usize];
    ["Offset of field: EmscriptenKeyboardEvent::timestamp"]
        [::std::mem::offset_of!(EmscriptenKeyboardEvent, timestamp) - 0usize];
    ["Offset of field: EmscriptenKeyboardEvent::location"]
        [::std::mem::offset_of!(EmscriptenKeyboardEvent, location) - 8usize];
    ["Offset of field: EmscriptenKeyboardEvent::ctrlKey"]
        [::std::mem::offset_of!(EmscriptenKeyboardEvent, ctrlKey) - 12usize];
    ["Offset of field: EmscriptenKeyboardEvent::shiftKey"]
        [::std::mem::offset_of!(EmscriptenKeyboardEvent, shiftKey) - 13usize];
    ["Offset of field: EmscriptenKeyboardEvent::altKey"]
        [::std::mem::offset_of!(EmscriptenKeyboardEvent, altKey) - 14usize];
    ["Offset of field: EmscriptenKeyboardEvent::metaKey"]
        [::std::mem::offset_of!(EmscriptenKeyboardEvent, metaKey) - 15usize];
    ["Offset of field: EmscriptenKeyboardEvent::repeat"]
        [::std::mem::offset_of!(EmscriptenKeyboardEvent, repeat) - 16usize];
    ["Offset of field: EmscriptenKeyboardEvent::charCode"]
        [::std::mem::offset_of!(EmscriptenKeyboardEvent, charCode) - 20usize];
    ["Offset of field: EmscriptenKeyboardEvent::keyCode"]
        [::std::mem::offset_of!(EmscriptenKeyboardEvent, keyCode) - 24usize];
    ["Offset of field: EmscriptenKeyboardEvent::which"]
        [::std::mem::offset_of!(EmscriptenKeyboardEvent, which) - 28usize];
    ["Offset of field: EmscriptenKeyboardEvent::key"]
        [::std::mem::offset_of!(EmscriptenKeyboardEvent, key) - 32usize];
    ["Offset of field: EmscriptenKeyboardEvent::code"]
        [::std::mem::offset_of!(EmscriptenKeyboardEvent, code) - 64usize];
    ["Offset of field: EmscriptenKeyboardEvent::charValue"]
        [::std::mem::offset_of!(EmscriptenKeyboardEvent, charValue) - 96usize];
    ["Offset of field: EmscriptenKeyboardEvent::locale"]
        [::std::mem::offset_of!(EmscriptenKeyboardEvent, locale) - 128usize];
};
pub type em_key_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        keyEvent: *const EmscriptenKeyboardEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_keypress_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_key_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_keydown_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_key_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_keyup_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_key_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct EmscriptenMouseEvent {
    pub timestamp: f64,
    pub screenX: ::std::os::raw::c_int,
    pub screenY: ::std::os::raw::c_int,
    pub clientX: ::std::os::raw::c_int,
    pub clientY: ::std::os::raw::c_int,
    pub ctrlKey: bool,
    pub shiftKey: bool,
    pub altKey: bool,
    pub metaKey: bool,
    pub button: ::std::os::raw::c_ushort,
    pub buttons: ::std::os::raw::c_ushort,
    pub movementX: ::std::os::raw::c_int,
    pub movementY: ::std::os::raw::c_int,
    pub targetX: ::std::os::raw::c_int,
    pub targetY: ::std::os::raw::c_int,
    pub canvasX: ::std::os::raw::c_int,
    pub canvasY: ::std::os::raw::c_int,
    pub padding: ::std::os::raw::c_int,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenMouseEvent"][::std::mem::size_of::<EmscriptenMouseEvent>() - 64usize];
    ["Alignment of EmscriptenMouseEvent"][::std::mem::align_of::<EmscriptenMouseEvent>() - 8usize];
    ["Offset of field: EmscriptenMouseEvent::timestamp"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, timestamp) - 0usize];
    ["Offset of field: EmscriptenMouseEvent::screenX"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, screenX) - 8usize];
    ["Offset of field: EmscriptenMouseEvent::screenY"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, screenY) - 12usize];
    ["Offset of field: EmscriptenMouseEvent::clientX"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, clientX) - 16usize];
    ["Offset of field: EmscriptenMouseEvent::clientY"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, clientY) - 20usize];
    ["Offset of field: EmscriptenMouseEvent::ctrlKey"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, ctrlKey) - 24usize];
    ["Offset of field: EmscriptenMouseEvent::shiftKey"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, shiftKey) - 25usize];
    ["Offset of field: EmscriptenMouseEvent::altKey"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, altKey) - 26usize];
    ["Offset of field: EmscriptenMouseEvent::metaKey"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, metaKey) - 27usize];
    ["Offset of field: EmscriptenMouseEvent::button"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, button) - 28usize];
    ["Offset of field: EmscriptenMouseEvent::buttons"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, buttons) - 30usize];
    ["Offset of field: EmscriptenMouseEvent::movementX"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, movementX) - 32usize];
    ["Offset of field: EmscriptenMouseEvent::movementY"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, movementY) - 36usize];
    ["Offset of field: EmscriptenMouseEvent::targetX"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, targetX) - 40usize];
    ["Offset of field: EmscriptenMouseEvent::targetY"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, targetY) - 44usize];
    ["Offset of field: EmscriptenMouseEvent::canvasX"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, canvasX) - 48usize];
    ["Offset of field: EmscriptenMouseEvent::canvasY"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, canvasY) - 52usize];
    ["Offset of field: EmscriptenMouseEvent::padding"]
        [::std::mem::offset_of!(EmscriptenMouseEvent, padding) - 56usize];
};
pub type em_mouse_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        mouseEvent: *const EmscriptenMouseEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_click_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_mouse_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_mousedown_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_mouse_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_mouseup_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_mouse_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_dblclick_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_mouse_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_mousemove_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_mouse_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_mouseenter_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_mouse_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_mouseleave_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_mouse_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_mouseover_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_mouse_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_mouseout_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_mouse_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_get_mouse_status(
        mouseState: *mut EmscriptenMouseEvent,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct EmscriptenWheelEvent {
    pub mouse: EmscriptenMouseEvent,
    pub deltaX: f64,
    pub deltaY: f64,
    pub deltaZ: f64,
    pub deltaMode: ::std::os::raw::c_uint,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenWheelEvent"][::std::mem::size_of::<EmscriptenWheelEvent>() - 96usize];
    ["Alignment of EmscriptenWheelEvent"][::std::mem::align_of::<EmscriptenWheelEvent>() - 8usize];
    ["Offset of field: EmscriptenWheelEvent::mouse"]
        [::std::mem::offset_of!(EmscriptenWheelEvent, mouse) - 0usize];
    ["Offset of field: EmscriptenWheelEvent::deltaX"]
        [::std::mem::offset_of!(EmscriptenWheelEvent, deltaX) - 64usize];
    ["Offset of field: EmscriptenWheelEvent::deltaY"]
        [::std::mem::offset_of!(EmscriptenWheelEvent, deltaY) - 72usize];
    ["Offset of field: EmscriptenWheelEvent::deltaZ"]
        [::std::mem::offset_of!(EmscriptenWheelEvent, deltaZ) - 80usize];
    ["Offset of field: EmscriptenWheelEvent::deltaMode"]
        [::std::mem::offset_of!(EmscriptenWheelEvent, deltaMode) - 88usize];
};
pub type em_wheel_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        wheelEvent: *const EmscriptenWheelEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_wheel_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_wheel_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct EmscriptenUiEvent {
    pub detail: ::std::os::raw::c_int,
    pub documentBodyClientWidth: ::std::os::raw::c_int,
    pub documentBodyClientHeight: ::std::os::raw::c_int,
    pub windowInnerWidth: ::std::os::raw::c_int,
    pub windowInnerHeight: ::std::os::raw::c_int,
    pub windowOuterWidth: ::std::os::raw::c_int,
    pub windowOuterHeight: ::std::os::raw::c_int,
    pub scrollTop: ::std::os::raw::c_int,
    pub scrollLeft: ::std::os::raw::c_int,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenUiEvent"][::std::mem::size_of::<EmscriptenUiEvent>() - 36usize];
    ["Alignment of EmscriptenUiEvent"][::std::mem::align_of::<EmscriptenUiEvent>() - 4usize];
    ["Offset of field: EmscriptenUiEvent::detail"]
        [::std::mem::offset_of!(EmscriptenUiEvent, detail) - 0usize];
    ["Offset of field: EmscriptenUiEvent::documentBodyClientWidth"]
        [::std::mem::offset_of!(EmscriptenUiEvent, documentBodyClientWidth) - 4usize];
    ["Offset of field: EmscriptenUiEvent::documentBodyClientHeight"]
        [::std::mem::offset_of!(EmscriptenUiEvent, documentBodyClientHeight) - 8usize];
    ["Offset of field: EmscriptenUiEvent::windowInnerWidth"]
        [::std::mem::offset_of!(EmscriptenUiEvent, windowInnerWidth) - 12usize];
    ["Offset of field: EmscriptenUiEvent::windowInnerHeight"]
        [::std::mem::offset_of!(EmscriptenUiEvent, windowInnerHeight) - 16usize];
    ["Offset of field: EmscriptenUiEvent::windowOuterWidth"]
        [::std::mem::offset_of!(EmscriptenUiEvent, windowOuterWidth) - 20usize];
    ["Offset of field: EmscriptenUiEvent::windowOuterHeight"]
        [::std::mem::offset_of!(EmscriptenUiEvent, windowOuterHeight) - 24usize];
    ["Offset of field: EmscriptenUiEvent::scrollTop"]
        [::std::mem::offset_of!(EmscriptenUiEvent, scrollTop) - 28usize];
    ["Offset of field: EmscriptenUiEvent::scrollLeft"]
        [::std::mem::offset_of!(EmscriptenUiEvent, scrollLeft) - 32usize];
};
pub type em_ui_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        uiEvent: *const EmscriptenUiEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_resize_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_ui_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_scroll_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_ui_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct EmscriptenFocusEvent {
    pub nodeName: [::std::os::raw::c_char; 128usize],
    pub id: [::std::os::raw::c_char; 128usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenFocusEvent"][::std::mem::size_of::<EmscriptenFocusEvent>() - 256usize];
    ["Alignment of EmscriptenFocusEvent"][::std::mem::align_of::<EmscriptenFocusEvent>() - 1usize];
    ["Offset of field: EmscriptenFocusEvent::nodeName"]
        [::std::mem::offset_of!(EmscriptenFocusEvent, nodeName) - 0usize];
    ["Offset of field: EmscriptenFocusEvent::id"]
        [::std::mem::offset_of!(EmscriptenFocusEvent, id) - 128usize];
};
impl Default for EmscriptenFocusEvent {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
pub type em_focus_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        focusEvent: *const EmscriptenFocusEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_blur_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_focus_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_focus_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_focus_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_focusin_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_focus_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_focusout_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_focus_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct EmscriptenDeviceOrientationEvent {
    pub alpha: f64,
    pub beta: f64,
    pub gamma: f64,
    pub absolute: bool,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenDeviceOrientationEvent"]
        [::std::mem::size_of::<EmscriptenDeviceOrientationEvent>() - 32usize];
    ["Alignment of EmscriptenDeviceOrientationEvent"]
        [::std::mem::align_of::<EmscriptenDeviceOrientationEvent>() - 8usize];
    ["Offset of field: EmscriptenDeviceOrientationEvent::alpha"]
        [::std::mem::offset_of!(EmscriptenDeviceOrientationEvent, alpha) - 0usize];
    ["Offset of field: EmscriptenDeviceOrientationEvent::beta"]
        [::std::mem::offset_of!(EmscriptenDeviceOrientationEvent, beta) - 8usize];
    ["Offset of field: EmscriptenDeviceOrientationEvent::gamma"]
        [::std::mem::offset_of!(EmscriptenDeviceOrientationEvent, gamma) - 16usize];
    ["Offset of field: EmscriptenDeviceOrientationEvent::absolute"]
        [::std::mem::offset_of!(EmscriptenDeviceOrientationEvent, absolute) - 24usize];
};
pub type em_deviceorientation_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        deviceOrientationEvent: *const EmscriptenDeviceOrientationEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_deviceorientation_callback_on_thread(
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_deviceorientation_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_get_deviceorientation_status(
        orientationState: *mut EmscriptenDeviceOrientationEvent,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct EmscriptenDeviceMotionEvent {
    pub accelerationX: f64,
    pub accelerationY: f64,
    pub accelerationZ: f64,
    pub accelerationIncludingGravityX: f64,
    pub accelerationIncludingGravityY: f64,
    pub accelerationIncludingGravityZ: f64,
    pub rotationRateAlpha: f64,
    pub rotationRateBeta: f64,
    pub rotationRateGamma: f64,
    pub supportedFields: ::std::os::raw::c_int,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenDeviceMotionEvent"]
        [::std::mem::size_of::<EmscriptenDeviceMotionEvent>() - 80usize];
    ["Alignment of EmscriptenDeviceMotionEvent"]
        [::std::mem::align_of::<EmscriptenDeviceMotionEvent>() - 8usize];
    ["Offset of field: EmscriptenDeviceMotionEvent::accelerationX"]
        [::std::mem::offset_of!(EmscriptenDeviceMotionEvent, accelerationX) - 0usize];
    ["Offset of field: EmscriptenDeviceMotionEvent::accelerationY"]
        [::std::mem::offset_of!(EmscriptenDeviceMotionEvent, accelerationY) - 8usize];
    ["Offset of field: EmscriptenDeviceMotionEvent::accelerationZ"]
        [::std::mem::offset_of!(EmscriptenDeviceMotionEvent, accelerationZ) - 16usize];
    ["Offset of field: EmscriptenDeviceMotionEvent::accelerationIncludingGravityX"][::std::mem::offset_of!(
        EmscriptenDeviceMotionEvent,
        accelerationIncludingGravityX
    ) - 24usize];
    ["Offset of field: EmscriptenDeviceMotionEvent::accelerationIncludingGravityY"][::std::mem::offset_of!(
        EmscriptenDeviceMotionEvent,
        accelerationIncludingGravityY
    ) - 32usize];
    ["Offset of field: EmscriptenDeviceMotionEvent::accelerationIncludingGravityZ"][::std::mem::offset_of!(
        EmscriptenDeviceMotionEvent,
        accelerationIncludingGravityZ
    ) - 40usize];
    ["Offset of field: EmscriptenDeviceMotionEvent::rotationRateAlpha"]
        [::std::mem::offset_of!(EmscriptenDeviceMotionEvent, rotationRateAlpha) - 48usize];
    ["Offset of field: EmscriptenDeviceMotionEvent::rotationRateBeta"]
        [::std::mem::offset_of!(EmscriptenDeviceMotionEvent, rotationRateBeta) - 56usize];
    ["Offset of field: EmscriptenDeviceMotionEvent::rotationRateGamma"]
        [::std::mem::offset_of!(EmscriptenDeviceMotionEvent, rotationRateGamma) - 64usize];
    ["Offset of field: EmscriptenDeviceMotionEvent::supportedFields"]
        [::std::mem::offset_of!(EmscriptenDeviceMotionEvent, supportedFields) - 72usize];
};
pub type em_devicemotion_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        deviceMotionEvent: *const EmscriptenDeviceMotionEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_devicemotion_callback_on_thread(
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_devicemotion_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_get_devicemotion_status(
        motionState: *mut EmscriptenDeviceMotionEvent,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct EmscriptenOrientationChangeEvent {
    pub orientationIndex: ::std::os::raw::c_int,
    pub orientationAngle: ::std::os::raw::c_int,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenOrientationChangeEvent"]
        [::std::mem::size_of::<EmscriptenOrientationChangeEvent>() - 8usize];
    ["Alignment of EmscriptenOrientationChangeEvent"]
        [::std::mem::align_of::<EmscriptenOrientationChangeEvent>() - 4usize];
    ["Offset of field: EmscriptenOrientationChangeEvent::orientationIndex"]
        [::std::mem::offset_of!(EmscriptenOrientationChangeEvent, orientationIndex) - 0usize];
    ["Offset of field: EmscriptenOrientationChangeEvent::orientationAngle"]
        [::std::mem::offset_of!(EmscriptenOrientationChangeEvent, orientationAngle) - 4usize];
};
pub type em_orientationchange_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        orientationChangeEvent: *const EmscriptenOrientationChangeEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_orientationchange_callback_on_thread(
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_orientationchange_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_get_orientation_status(
        orientationStatus: *mut EmscriptenOrientationChangeEvent,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_lock_orientation(
        allowedOrientations: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_unlock_orientation() -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct EmscriptenFullscreenChangeEvent {
    pub isFullscreen: bool,
    pub fullscreenEnabled: bool,
    pub nodeName: [::std::os::raw::c_char; 128usize],
    pub id: [::std::os::raw::c_char; 128usize],
    pub elementWidth: ::std::os::raw::c_int,
    pub elementHeight: ::std::os::raw::c_int,
    pub screenWidth: ::std::os::raw::c_int,
    pub screenHeight: ::std::os::raw::c_int,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenFullscreenChangeEvent"]
        [::std::mem::size_of::<EmscriptenFullscreenChangeEvent>() - 276usize];
    ["Alignment of EmscriptenFullscreenChangeEvent"]
        [::std::mem::align_of::<EmscriptenFullscreenChangeEvent>() - 4usize];
    ["Offset of field: EmscriptenFullscreenChangeEvent::isFullscreen"]
        [::std::mem::offset_of!(EmscriptenFullscreenChangeEvent, isFullscreen) - 0usize];
    ["Offset of field: EmscriptenFullscreenChangeEvent::fullscreenEnabled"]
        [::std::mem::offset_of!(EmscriptenFullscreenChangeEvent, fullscreenEnabled) - 1usize];
    ["Offset of field: EmscriptenFullscreenChangeEvent::nodeName"]
        [::std::mem::offset_of!(EmscriptenFullscreenChangeEvent, nodeName) - 2usize];
    ["Offset of field: EmscriptenFullscreenChangeEvent::id"]
        [::std::mem::offset_of!(EmscriptenFullscreenChangeEvent, id) - 130usize];
    ["Offset of field: EmscriptenFullscreenChangeEvent::elementWidth"]
        [::std::mem::offset_of!(EmscriptenFullscreenChangeEvent, elementWidth) - 260usize];
    ["Offset of field: EmscriptenFullscreenChangeEvent::elementHeight"]
        [::std::mem::offset_of!(EmscriptenFullscreenChangeEvent, elementHeight) - 264usize];
    ["Offset of field: EmscriptenFullscreenChangeEvent::screenWidth"]
        [::std::mem::offset_of!(EmscriptenFullscreenChangeEvent, screenWidth) - 268usize];
    ["Offset of field: EmscriptenFullscreenChangeEvent::screenHeight"]
        [::std::mem::offset_of!(EmscriptenFullscreenChangeEvent, screenHeight) - 272usize];
};
impl Default for EmscriptenFullscreenChangeEvent {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
pub type em_fullscreenchange_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        fullscreenChangeEvent: *const EmscriptenFullscreenChangeEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_fullscreenchange_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_fullscreenchange_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_get_fullscreen_status(
        fullscreenStatus: *mut EmscriptenFullscreenChangeEvent,
    ) -> ::std::os::raw::c_int;
}
pub type em_canvasresized_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        reserved: *const ::std::os::raw::c_void,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct EmscriptenFullscreenStrategy {
    pub scaleMode: ::std::os::raw::c_int,
    pub canvasResolutionScaleMode: ::std::os::raw::c_int,
    pub filteringMode: ::std::os::raw::c_int,
    pub canvasResizedCallback: em_canvasresized_callback_func,
    pub canvasResizedCallbackUserData: *mut ::std::os::raw::c_void,
    pub canvasResizedCallbackTargetThread: pthread_t,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenFullscreenStrategy"]
        [::std::mem::size_of::<EmscriptenFullscreenStrategy>() - 24usize];
    ["Alignment of EmscriptenFullscreenStrategy"]
        [::std::mem::align_of::<EmscriptenFullscreenStrategy>() - 4usize];
    ["Offset of field: EmscriptenFullscreenStrategy::scaleMode"]
        [::std::mem::offset_of!(EmscriptenFullscreenStrategy, scaleMode) - 0usize];
    ["Offset of field: EmscriptenFullscreenStrategy::canvasResolutionScaleMode"]
        [::std::mem::offset_of!(EmscriptenFullscreenStrategy, canvasResolutionScaleMode) - 4usize];
    ["Offset of field: EmscriptenFullscreenStrategy::filteringMode"]
        [::std::mem::offset_of!(EmscriptenFullscreenStrategy, filteringMode) - 8usize];
    ["Offset of field: EmscriptenFullscreenStrategy::canvasResizedCallback"]
        [::std::mem::offset_of!(EmscriptenFullscreenStrategy, canvasResizedCallback) - 12usize];
    ["Offset of field: EmscriptenFullscreenStrategy::canvasResizedCallbackUserData"][::std::mem::offset_of!(
        EmscriptenFullscreenStrategy,
        canvasResizedCallbackUserData
    ) - 16usize];
    ["Offset of field: EmscriptenFullscreenStrategy::canvasResizedCallbackTargetThread"][::std::mem::offset_of!(
        EmscriptenFullscreenStrategy,
        canvasResizedCallbackTargetThread
    )
        - 20usize];
};
impl Default for EmscriptenFullscreenStrategy {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
unsafe extern "C" {
    pub fn emscripten_request_fullscreen(
        target: *const ::std::os::raw::c_char,
        deferUntilInEventHandler: bool,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_request_fullscreen_strategy(
        target: *const ::std::os::raw::c_char,
        deferUntilInEventHandler: bool,
        fullscreenStrategy: *const EmscriptenFullscreenStrategy,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_exit_fullscreen() -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_enter_soft_fullscreen(
        target: *const ::std::os::raw::c_char,
        fullscreenStrategy: *const EmscriptenFullscreenStrategy,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_exit_soft_fullscreen() -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct EmscriptenPointerlockChangeEvent {
    pub isActive: bool,
    pub nodeName: [::std::os::raw::c_char; 128usize],
    pub id: [::std::os::raw::c_char; 128usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenPointerlockChangeEvent"]
        [::std::mem::size_of::<EmscriptenPointerlockChangeEvent>() - 257usize];
    ["Alignment of EmscriptenPointerlockChangeEvent"]
        [::std::mem::align_of::<EmscriptenPointerlockChangeEvent>() - 1usize];
    ["Offset of field: EmscriptenPointerlockChangeEvent::isActive"]
        [::std::mem::offset_of!(EmscriptenPointerlockChangeEvent, isActive) - 0usize];
    ["Offset of field: EmscriptenPointerlockChangeEvent::nodeName"]
        [::std::mem::offset_of!(EmscriptenPointerlockChangeEvent, nodeName) - 1usize];
    ["Offset of field: EmscriptenPointerlockChangeEvent::id"]
        [::std::mem::offset_of!(EmscriptenPointerlockChangeEvent, id) - 129usize];
};
impl Default for EmscriptenPointerlockChangeEvent {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
pub type em_pointerlockchange_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        pointerlockChangeEvent: *const EmscriptenPointerlockChangeEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_pointerlockchange_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_pointerlockchange_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
pub type em_pointerlockerror_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        reserved: *const ::std::os::raw::c_void,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_pointerlockerror_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_pointerlockerror_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_get_pointerlock_status(
        pointerlockStatus: *mut EmscriptenPointerlockChangeEvent,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_request_pointerlock(
        target: *const ::std::os::raw::c_char,
        deferUntilInEventHandler: bool,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_exit_pointerlock() -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct EmscriptenVisibilityChangeEvent {
    pub hidden: bool,
    pub visibilityState: ::std::os::raw::c_int,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenVisibilityChangeEvent"]
        [::std::mem::size_of::<EmscriptenVisibilityChangeEvent>() - 8usize];
    ["Alignment of EmscriptenVisibilityChangeEvent"]
        [::std::mem::align_of::<EmscriptenVisibilityChangeEvent>() - 4usize];
    ["Offset of field: EmscriptenVisibilityChangeEvent::hidden"]
        [::std::mem::offset_of!(EmscriptenVisibilityChangeEvent, hidden) - 0usize];
    ["Offset of field: EmscriptenVisibilityChangeEvent::visibilityState"]
        [::std::mem::offset_of!(EmscriptenVisibilityChangeEvent, visibilityState) - 4usize];
};
pub type em_visibilitychange_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        visibilityChangeEvent: *const EmscriptenVisibilityChangeEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_visibilitychange_callback_on_thread(
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_visibilitychange_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_get_visibility_status(
        visibilityStatus: *mut EmscriptenVisibilityChangeEvent,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct EmscriptenTouchPoint {
    pub identifier: ::std::os::raw::c_int,
    pub screenX: ::std::os::raw::c_int,
    pub screenY: ::std::os::raw::c_int,
    pub clientX: ::std::os::raw::c_int,
    pub clientY: ::std::os::raw::c_int,
    pub pageX: ::std::os::raw::c_int,
    pub pageY: ::std::os::raw::c_int,
    pub isChanged: bool,
    pub onTarget: bool,
    pub targetX: ::std::os::raw::c_int,
    pub targetY: ::std::os::raw::c_int,
    pub canvasX: ::std::os::raw::c_int,
    pub canvasY: ::std::os::raw::c_int,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenTouchPoint"][::std::mem::size_of::<EmscriptenTouchPoint>() - 48usize];
    ["Alignment of EmscriptenTouchPoint"][::std::mem::align_of::<EmscriptenTouchPoint>() - 4usize];
    ["Offset of field: EmscriptenTouchPoint::identifier"]
        [::std::mem::offset_of!(EmscriptenTouchPoint, identifier) - 0usize];
    ["Offset of field: EmscriptenTouchPoint::screenX"]
        [::std::mem::offset_of!(EmscriptenTouchPoint, screenX) - 4usize];
    ["Offset of field: EmscriptenTouchPoint::screenY"]
        [::std::mem::offset_of!(EmscriptenTouchPoint, screenY) - 8usize];
    ["Offset of field: EmscriptenTouchPoint::clientX"]
        [::std::mem::offset_of!(EmscriptenTouchPoint, clientX) - 12usize];
    ["Offset of field: EmscriptenTouchPoint::clientY"]
        [::std::mem::offset_of!(EmscriptenTouchPoint, clientY) - 16usize];
    ["Offset of field: EmscriptenTouchPoint::pageX"]
        [::std::mem::offset_of!(EmscriptenTouchPoint, pageX) - 20usize];
    ["Offset of field: EmscriptenTouchPoint::pageY"]
        [::std::mem::offset_of!(EmscriptenTouchPoint, pageY) - 24usize];
    ["Offset of field: EmscriptenTouchPoint::isChanged"]
        [::std::mem::offset_of!(EmscriptenTouchPoint, isChanged) - 28usize];
    ["Offset of field: EmscriptenTouchPoint::onTarget"]
        [::std::mem::offset_of!(EmscriptenTouchPoint, onTarget) - 29usize];
    ["Offset of field: EmscriptenTouchPoint::targetX"]
        [::std::mem::offset_of!(EmscriptenTouchPoint, targetX) - 32usize];
    ["Offset of field: EmscriptenTouchPoint::targetY"]
        [::std::mem::offset_of!(EmscriptenTouchPoint, targetY) - 36usize];
    ["Offset of field: EmscriptenTouchPoint::canvasX"]
        [::std::mem::offset_of!(EmscriptenTouchPoint, canvasX) - 40usize];
    ["Offset of field: EmscriptenTouchPoint::canvasY"]
        [::std::mem::offset_of!(EmscriptenTouchPoint, canvasY) - 44usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct EmscriptenTouchEvent {
    pub timestamp: f64,
    pub numTouches: ::std::os::raw::c_int,
    pub ctrlKey: bool,
    pub shiftKey: bool,
    pub altKey: bool,
    pub metaKey: bool,
    pub touches: [EmscriptenTouchPoint; 32usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenTouchEvent"][::std::mem::size_of::<EmscriptenTouchEvent>() - 1552usize];
    ["Alignment of EmscriptenTouchEvent"][::std::mem::align_of::<EmscriptenTouchEvent>() - 8usize];
    ["Offset of field: EmscriptenTouchEvent::timestamp"]
        [::std::mem::offset_of!(EmscriptenTouchEvent, timestamp) - 0usize];
    ["Offset of field: EmscriptenTouchEvent::numTouches"]
        [::std::mem::offset_of!(EmscriptenTouchEvent, numTouches) - 8usize];
    ["Offset of field: EmscriptenTouchEvent::ctrlKey"]
        [::std::mem::offset_of!(EmscriptenTouchEvent, ctrlKey) - 12usize];
    ["Offset of field: EmscriptenTouchEvent::shiftKey"]
        [::std::mem::offset_of!(EmscriptenTouchEvent, shiftKey) - 13usize];
    ["Offset of field: EmscriptenTouchEvent::altKey"]
        [::std::mem::offset_of!(EmscriptenTouchEvent, altKey) - 14usize];
    ["Offset of field: EmscriptenTouchEvent::metaKey"]
        [::std::mem::offset_of!(EmscriptenTouchEvent, metaKey) - 15usize];
    ["Offset of field: EmscriptenTouchEvent::touches"]
        [::std::mem::offset_of!(EmscriptenTouchEvent, touches) - 16usize];
};
pub type em_touch_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        touchEvent: *const EmscriptenTouchEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_touchstart_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_touch_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_touchend_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_touch_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_touchmove_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_touch_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_touchcancel_callback_on_thread(
        target: *const ::std::os::raw::c_char,
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_touch_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct EmscriptenGamepadEvent {
    pub timestamp: f64,
    pub numAxes: ::std::os::raw::c_int,
    pub numButtons: ::std::os::raw::c_int,
    pub axis: [f64; 64usize],
    pub analogButton: [f64; 64usize],
    pub digitalButton: [bool; 64usize],
    pub connected: bool,
    pub index: ::std::os::raw::c_int,
    pub id: [::std::os::raw::c_char; 64usize],
    pub mapping: [::std::os::raw::c_char; 64usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenGamepadEvent"][::std::mem::size_of::<EmscriptenGamepadEvent>() - 1240usize];
    ["Alignment of EmscriptenGamepadEvent"]
        [::std::mem::align_of::<EmscriptenGamepadEvent>() - 8usize];
    ["Offset of field: EmscriptenGamepadEvent::timestamp"]
        [::std::mem::offset_of!(EmscriptenGamepadEvent, timestamp) - 0usize];
    ["Offset of field: EmscriptenGamepadEvent::numAxes"]
        [::std::mem::offset_of!(EmscriptenGamepadEvent, numAxes) - 8usize];
    ["Offset of field: EmscriptenGamepadEvent::numButtons"]
        [::std::mem::offset_of!(EmscriptenGamepadEvent, numButtons) - 12usize];
    ["Offset of field: EmscriptenGamepadEvent::axis"]
        [::std::mem::offset_of!(EmscriptenGamepadEvent, axis) - 16usize];
    ["Offset of field: EmscriptenGamepadEvent::analogButton"]
        [::std::mem::offset_of!(EmscriptenGamepadEvent, analogButton) - 528usize];
    ["Offset of field: EmscriptenGamepadEvent::digitalButton"]
        [::std::mem::offset_of!(EmscriptenGamepadEvent, digitalButton) - 1040usize];
    ["Offset of field: EmscriptenGamepadEvent::connected"]
        [::std::mem::offset_of!(EmscriptenGamepadEvent, connected) - 1104usize];
    ["Offset of field: EmscriptenGamepadEvent::index"]
        [::std::mem::offset_of!(EmscriptenGamepadEvent, index) - 1108usize];
    ["Offset of field: EmscriptenGamepadEvent::id"]
        [::std::mem::offset_of!(EmscriptenGamepadEvent, id) - 1112usize];
    ["Offset of field: EmscriptenGamepadEvent::mapping"]
        [::std::mem::offset_of!(EmscriptenGamepadEvent, mapping) - 1176usize];
};
impl Default for EmscriptenGamepadEvent {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
pub type em_gamepad_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        gamepadEvent: *const EmscriptenGamepadEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_gamepadconnected_callback_on_thread(
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_gamepad_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_gamepaddisconnected_callback_on_thread(
        userData: *mut ::std::os::raw::c_void,
        useCapture: bool,
        callback: em_gamepad_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_sample_gamepad_data() -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_get_num_gamepads() -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_get_gamepad_status(
        index: ::std::os::raw::c_int,
        gamepadState: *mut EmscriptenGamepadEvent,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct EmscriptenBatteryEvent {
    pub chargingTime: f64,
    pub dischargingTime: f64,
    pub level: f64,
    pub charging: bool,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenBatteryEvent"][::std::mem::size_of::<EmscriptenBatteryEvent>() - 32usize];
    ["Alignment of EmscriptenBatteryEvent"]
        [::std::mem::align_of::<EmscriptenBatteryEvent>() - 8usize];
    ["Offset of field: EmscriptenBatteryEvent::chargingTime"]
        [::std::mem::offset_of!(EmscriptenBatteryEvent, chargingTime) - 0usize];
    ["Offset of field: EmscriptenBatteryEvent::dischargingTime"]
        [::std::mem::offset_of!(EmscriptenBatteryEvent, dischargingTime) - 8usize];
    ["Offset of field: EmscriptenBatteryEvent::level"]
        [::std::mem::offset_of!(EmscriptenBatteryEvent, level) - 16usize];
    ["Offset of field: EmscriptenBatteryEvent::charging"]
        [::std::mem::offset_of!(EmscriptenBatteryEvent, charging) - 24usize];
};
pub type em_battery_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        batteryEvent: *const EmscriptenBatteryEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_set_batterychargingchange_callback_on_thread(
        userData: *mut ::std::os::raw::c_void,
        callback: em_battery_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_batterylevelchange_callback_on_thread(
        userData: *mut ::std::os::raw::c_void,
        callback: em_battery_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_get_battery_status(
        batteryState: *mut EmscriptenBatteryEvent,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_vibrate(msecs: ::std::os::raw::c_int) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_vibrate_pattern(
        msecsArray: *mut ::std::os::raw::c_int,
        numEntries: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
pub type em_beforeunload_callback = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        reserved: *const ::std::os::raw::c_void,
        userData: *mut ::std::os::raw::c_void,
    ) -> *const ::std::os::raw::c_char,
>;
unsafe extern "C" {
    pub fn emscripten_set_beforeunload_callback_on_thread(
        userData: *mut ::std::os::raw::c_void,
        callback: em_beforeunload_callback,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_canvas_element_size(
        target: *const ::std::os::raw::c_char,
        width: ::std::os::raw::c_int,
        height: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_get_canvas_element_size(
        target: *const ::std::os::raw::c_char,
        width: *mut ::std::os::raw::c_int,
        height: *mut ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_set_element_css_size(
        target: *const ::std::os::raw::c_char,
        width: f64,
        height: f64,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_get_element_css_size(
        target: *const ::std::os::raw::c_char,
        width: *mut f64,
        height: *mut f64,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_html5_remove_all_event_listeners();
}
unsafe extern "C" {
    pub fn emscripten_request_animation_frame(
        cb: ::std::option::Option<
            unsafe extern "C" fn(time: f64, userData: *mut ::std::os::raw::c_void) -> bool,
        >,
        userData: *mut ::std::os::raw::c_void,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_cancel_animation_frame(requestAnimationFrameId: ::std::os::raw::c_int);
}
unsafe extern "C" {
    pub fn emscripten_request_animation_frame_loop(
        cb: ::std::option::Option<
            unsafe extern "C" fn(time: f64, userData: *mut ::std::os::raw::c_void) -> bool,
        >,
        userData: *mut ::std::os::raw::c_void,
    );
}
unsafe extern "C" {
    pub fn emscripten_date_now() -> f64;
}
unsafe extern "C" {
    pub fn emscripten_performance_now() -> f64;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUBindGroupImpl {
    _unused: [u8; 0],
}
pub type WGPUBindGroup = *mut WGPUBindGroupImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUBindGroupLayoutImpl {
    _unused: [u8; 0],
}
pub type WGPUBindGroupLayout = *mut WGPUBindGroupLayoutImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUBufferImpl {
    _unused: [u8; 0],
}
pub type WGPUBuffer = *mut WGPUBufferImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUCommandBufferImpl {
    _unused: [u8; 0],
}
pub type WGPUCommandBuffer = *mut WGPUCommandBufferImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUCommandEncoderImpl {
    _unused: [u8; 0],
}
pub type WGPUCommandEncoder = *mut WGPUCommandEncoderImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUComputePassEncoderImpl {
    _unused: [u8; 0],
}
pub type WGPUComputePassEncoder = *mut WGPUComputePassEncoderImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUComputePipelineImpl {
    _unused: [u8; 0],
}
pub type WGPUComputePipeline = *mut WGPUComputePipelineImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUDeviceImpl {
    _unused: [u8; 0],
}
pub type WGPUDevice = *mut WGPUDeviceImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUPipelineLayoutImpl {
    _unused: [u8; 0],
}
pub type WGPUPipelineLayout = *mut WGPUPipelineLayoutImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUQuerySetImpl {
    _unused: [u8; 0],
}
pub type WGPUQuerySet = *mut WGPUQuerySetImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUQueueImpl {
    _unused: [u8; 0],
}
pub type WGPUQueue = *mut WGPUQueueImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPURenderBundleImpl {
    _unused: [u8; 0],
}
pub type WGPURenderBundle = *mut WGPURenderBundleImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPURenderBundleEncoderImpl {
    _unused: [u8; 0],
}
pub type WGPURenderBundleEncoder = *mut WGPURenderBundleEncoderImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPURenderPassEncoderImpl {
    _unused: [u8; 0],
}
pub type WGPURenderPassEncoder = *mut WGPURenderPassEncoderImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPURenderPipelineImpl {
    _unused: [u8; 0],
}
pub type WGPURenderPipeline = *mut WGPURenderPipelineImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUSamplerImpl {
    _unused: [u8; 0],
}
pub type WGPUSampler = *mut WGPUSamplerImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUShaderModuleImpl {
    _unused: [u8; 0],
}
pub type WGPUShaderModule = *mut WGPUShaderModuleImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUSurfaceImpl {
    _unused: [u8; 0],
}
pub type WGPUSurface = *mut WGPUSurfaceImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUSwapChainImpl {
    _unused: [u8; 0],
}
pub type WGPUSwapChain = *mut WGPUSwapChainImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUTextureImpl {
    _unused: [u8; 0],
}
pub type WGPUTexture = *mut WGPUTextureImpl;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WGPUTextureViewImpl {
    _unused: [u8; 0],
}
pub type WGPUTextureView = *mut WGPUTextureViewImpl;
unsafe extern "C" {
    pub fn emscripten_webgpu_get_device() -> WGPUDevice;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_release_js_handle(js_handle: ::std::os::raw::c_int);
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_surface(arg1: ::std::os::raw::c_int) -> WGPUSurface;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_surface(arg1: WGPUSurface) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_swap_chain(arg1: ::std::os::raw::c_int) -> WGPUSwapChain;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_swap_chain(arg1: WGPUSwapChain) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_device(arg1: ::std::os::raw::c_int) -> WGPUDevice;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_device(arg1: WGPUDevice) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_queue(arg1: ::std::os::raw::c_int) -> WGPUQueue;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_queue(arg1: WGPUQueue) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_command_buffer(
        arg1: ::std::os::raw::c_int,
    ) -> WGPUCommandBuffer;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_command_buffer(
        arg1: WGPUCommandBuffer,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_command_encoder(
        arg1: ::std::os::raw::c_int,
    ) -> WGPUCommandEncoder;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_command_encoder(
        arg1: WGPUCommandEncoder,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_render_pass_encoder(
        arg1: ::std::os::raw::c_int,
    ) -> WGPURenderPassEncoder;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_render_pass_encoder(
        arg1: WGPURenderPassEncoder,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_compute_pass_encoder(
        arg1: ::std::os::raw::c_int,
    ) -> WGPUComputePassEncoder;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_compute_pass_encoder(
        arg1: WGPUComputePassEncoder,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_bind_group(arg1: ::std::os::raw::c_int) -> WGPUBindGroup;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_bind_group(arg1: WGPUBindGroup) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_buffer(arg1: ::std::os::raw::c_int) -> WGPUBuffer;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_buffer(arg1: WGPUBuffer) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_sampler(arg1: ::std::os::raw::c_int) -> WGPUSampler;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_sampler(arg1: WGPUSampler) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_texture(arg1: ::std::os::raw::c_int) -> WGPUTexture;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_texture(arg1: WGPUTexture) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_texture_view(arg1: ::std::os::raw::c_int) -> WGPUTextureView;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_texture_view(arg1: WGPUTextureView) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_query_set(arg1: ::std::os::raw::c_int) -> WGPUQuerySet;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_query_set(arg1: WGPUQuerySet) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_bind_group_layout(
        arg1: ::std::os::raw::c_int,
    ) -> WGPUBindGroupLayout;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_bind_group_layout(
        arg1: WGPUBindGroupLayout,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_pipeline_layout(
        arg1: ::std::os::raw::c_int,
    ) -> WGPUPipelineLayout;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_pipeline_layout(
        arg1: WGPUPipelineLayout,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_render_pipeline(
        arg1: ::std::os::raw::c_int,
    ) -> WGPURenderPipeline;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_render_pipeline(
        arg1: WGPURenderPipeline,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_compute_pipeline(
        arg1: ::std::os::raw::c_int,
    ) -> WGPUComputePipeline;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_compute_pipeline(
        arg1: WGPUComputePipeline,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_shader_module(arg1: ::std::os::raw::c_int) -> WGPUShaderModule;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_shader_module(arg1: WGPUShaderModule) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_render_bundle_encoder(
        arg1: ::std::os::raw::c_int,
    ) -> WGPURenderBundleEncoder;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_render_bundle_encoder(
        arg1: WGPURenderBundleEncoder,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_import_render_bundle(arg1: ::std::os::raw::c_int) -> WGPURenderBundle;
}
unsafe extern "C" {
    pub fn emscripten_webgpu_export_render_bundle(arg1: WGPURenderBundle) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_dom_vk_to_string(
        dom_vk_code: ::std::os::raw::c_int,
    ) -> *const ::std::os::raw::c_char;
}
unsafe extern "C" {
    pub fn emscripten_websocket_get_ready_state(
        socket: ::std::os::raw::c_int,
        readyState: *mut ::std::os::raw::c_ushort,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_websocket_get_buffered_amount(
        socket: ::std::os::raw::c_int,
        bufferedAmount: *mut usize,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_websocket_get_url(
        socket: ::std::os::raw::c_int,
        url: *mut ::std::os::raw::c_char,
        urlLength: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_websocket_get_url_length(
        socket: ::std::os::raw::c_int,
        urlLength: *mut ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_websocket_get_extensions(
        socket: ::std::os::raw::c_int,
        extensions: *mut ::std::os::raw::c_char,
        extensionsLength: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_websocket_get_extensions_length(
        socket: ::std::os::raw::c_int,
        extensionsLength: *mut ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_websocket_get_protocol(
        socket: ::std::os::raw::c_int,
        protocol: *mut ::std::os::raw::c_char,
        protocolLength: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_websocket_get_protocol_length(
        socket: ::std::os::raw::c_int,
        protocolLength: *mut ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct EmscriptenWebSocketOpenEvent {
    pub socket: ::std::os::raw::c_int,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenWebSocketOpenEvent"]
        [::std::mem::size_of::<EmscriptenWebSocketOpenEvent>() - 4usize];
    ["Alignment of EmscriptenWebSocketOpenEvent"]
        [::std::mem::align_of::<EmscriptenWebSocketOpenEvent>() - 4usize];
    ["Offset of field: EmscriptenWebSocketOpenEvent::socket"]
        [::std::mem::offset_of!(EmscriptenWebSocketOpenEvent, socket) - 0usize];
};
pub type em_websocket_open_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        websocketEvent: *const EmscriptenWebSocketOpenEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_websocket_set_onopen_callback_on_thread(
        socket: ::std::os::raw::c_int,
        userData: *mut ::std::os::raw::c_void,
        callback: em_websocket_open_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct EmscriptenWebSocketMessageEvent {
    pub socket: ::std::os::raw::c_int,
    pub data: *mut u8,
    pub numBytes: u32,
    pub isText: bool,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenWebSocketMessageEvent"]
        [::std::mem::size_of::<EmscriptenWebSocketMessageEvent>() - 16usize];
    ["Alignment of EmscriptenWebSocketMessageEvent"]
        [::std::mem::align_of::<EmscriptenWebSocketMessageEvent>() - 4usize];
    ["Offset of field: EmscriptenWebSocketMessageEvent::socket"]
        [::std::mem::offset_of!(EmscriptenWebSocketMessageEvent, socket) - 0usize];
    ["Offset of field: EmscriptenWebSocketMessageEvent::data"]
        [::std::mem::offset_of!(EmscriptenWebSocketMessageEvent, data) - 4usize];
    ["Offset of field: EmscriptenWebSocketMessageEvent::numBytes"]
        [::std::mem::offset_of!(EmscriptenWebSocketMessageEvent, numBytes) - 8usize];
    ["Offset of field: EmscriptenWebSocketMessageEvent::isText"]
        [::std::mem::offset_of!(EmscriptenWebSocketMessageEvent, isText) - 12usize];
};
impl Default for EmscriptenWebSocketMessageEvent {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
pub type em_websocket_message_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        websocketEvent: *const EmscriptenWebSocketMessageEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_websocket_set_onmessage_callback_on_thread(
        socket: ::std::os::raw::c_int,
        userData: *mut ::std::os::raw::c_void,
        callback: em_websocket_message_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct EmscriptenWebSocketErrorEvent {
    pub socket: ::std::os::raw::c_int,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenWebSocketErrorEvent"]
        [::std::mem::size_of::<EmscriptenWebSocketErrorEvent>() - 4usize];
    ["Alignment of EmscriptenWebSocketErrorEvent"]
        [::std::mem::align_of::<EmscriptenWebSocketErrorEvent>() - 4usize];
    ["Offset of field: EmscriptenWebSocketErrorEvent::socket"]
        [::std::mem::offset_of!(EmscriptenWebSocketErrorEvent, socket) - 0usize];
};
pub type em_websocket_error_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        websocketEvent: *const EmscriptenWebSocketErrorEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_websocket_set_onerror_callback_on_thread(
        socket: ::std::os::raw::c_int,
        userData: *mut ::std::os::raw::c_void,
        callback: em_websocket_error_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct EmscriptenWebSocketCloseEvent {
    pub socket: ::std::os::raw::c_int,
    pub wasClean: bool,
    pub code: ::std::os::raw::c_ushort,
    pub reason: [::std::os::raw::c_char; 512usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenWebSocketCloseEvent"]
        [::std::mem::size_of::<EmscriptenWebSocketCloseEvent>() - 520usize];
    ["Alignment of EmscriptenWebSocketCloseEvent"]
        [::std::mem::align_of::<EmscriptenWebSocketCloseEvent>() - 4usize];
    ["Offset of field: EmscriptenWebSocketCloseEvent::socket"]
        [::std::mem::offset_of!(EmscriptenWebSocketCloseEvent, socket) - 0usize];
    ["Offset of field: EmscriptenWebSocketCloseEvent::wasClean"]
        [::std::mem::offset_of!(EmscriptenWebSocketCloseEvent, wasClean) - 4usize];
    ["Offset of field: EmscriptenWebSocketCloseEvent::code"]
        [::std::mem::offset_of!(EmscriptenWebSocketCloseEvent, code) - 6usize];
    ["Offset of field: EmscriptenWebSocketCloseEvent::reason"]
        [::std::mem::offset_of!(EmscriptenWebSocketCloseEvent, reason) - 8usize];
};
impl Default for EmscriptenWebSocketCloseEvent {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
pub type em_websocket_close_callback_func = ::std::option::Option<
    unsafe extern "C" fn(
        eventType: ::std::os::raw::c_int,
        websocketEvent: *const EmscriptenWebSocketCloseEvent,
        userData: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
unsafe extern "C" {
    pub fn emscripten_websocket_set_onclose_callback_on_thread(
        socket: ::std::os::raw::c_int,
        userData: *mut ::std::os::raw::c_void,
        callback: em_websocket_close_callback_func,
        targetThread: pthread_t,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct EmscriptenWebSocketCreateAttributes {
    pub url: *const ::std::os::raw::c_char,
    pub protocols: *const ::std::os::raw::c_char,
    pub createOnMainThread: bool,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenWebSocketCreateAttributes"]
        [::std::mem::size_of::<EmscriptenWebSocketCreateAttributes>() - 12usize];
    ["Alignment of EmscriptenWebSocketCreateAttributes"]
        [::std::mem::align_of::<EmscriptenWebSocketCreateAttributes>() - 4usize];
    ["Offset of field: EmscriptenWebSocketCreateAttributes::url"]
        [::std::mem::offset_of!(EmscriptenWebSocketCreateAttributes, url) - 0usize];
    ["Offset of field: EmscriptenWebSocketCreateAttributes::protocols"]
        [::std::mem::offset_of!(EmscriptenWebSocketCreateAttributes, protocols) - 4usize];
    ["Offset of field: EmscriptenWebSocketCreateAttributes::createOnMainThread"]
        [::std::mem::offset_of!(EmscriptenWebSocketCreateAttributes, createOnMainThread) - 8usize];
};
impl Default for EmscriptenWebSocketCreateAttributes {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
unsafe extern "C" {
    pub fn emscripten_websocket_is_supported() -> bool;
}
unsafe extern "C" {
    pub fn emscripten_websocket_new(
        createAttributes: *mut EmscriptenWebSocketCreateAttributes,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_websocket_send_utf8_text(
        socket: ::std::os::raw::c_int,
        textData: *const ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_websocket_send_binary(
        socket: ::std::os::raw::c_int,
        binaryData: *mut ::std::os::raw::c_void,
        dataLength: u32,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_websocket_close(
        socket: ::std::os::raw::c_int,
        code: ::std::os::raw::c_ushort,
        reason: *const ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_websocket_delete(socket: ::std::os::raw::c_int) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_websocket_deinitialize();
}
unsafe extern "C" {
    pub fn emscripten_init_websocket_to_posix_socket_bridge(
        bridgeUrl: *const ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct em_proxying_queue {
    _unused: [u8; 0],
}
unsafe extern "C" {
    pub fn em_proxying_queue_create() -> *mut em_proxying_queue;
}
unsafe extern "C" {
    pub fn em_proxying_queue_destroy(q: *mut em_proxying_queue);
}
unsafe extern "C" {
    pub fn emscripten_proxy_get_system_queue() -> *mut em_proxying_queue;
}
unsafe extern "C" {
    pub fn emscripten_proxy_execute_queue(q: *mut em_proxying_queue);
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct em_proxying_ctx {
    _unused: [u8; 0],
}
unsafe extern "C" {
    pub fn emscripten_proxy_finish(ctx: *mut em_proxying_ctx);
}
unsafe extern "C" {
    pub fn emscripten_proxy_async(
        q: *mut em_proxying_queue,
        target_thread: pthread_t,
        func: ::std::option::Option<unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void)>,
        arg: *mut ::std::os::raw::c_void,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_proxy_sync(
        q: *mut em_proxying_queue,
        target_thread: pthread_t,
        func: ::std::option::Option<unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void)>,
        arg: *mut ::std::os::raw::c_void,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_proxy_sync_with_ctx(
        q: *mut em_proxying_queue,
        target_thread: pthread_t,
        func: ::std::option::Option<
            unsafe extern "C" fn(arg1: *mut em_proxying_ctx, arg2: *mut ::std::os::raw::c_void),
        >,
        arg: *mut ::std::os::raw::c_void,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_proxy_callback(
        q: *mut em_proxying_queue,
        target_thread: pthread_t,
        func: ::std::option::Option<unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void)>,
        callback: ::std::option::Option<unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void)>,
        cancel: ::std::option::Option<unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void)>,
        arg: *mut ::std::os::raw::c_void,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_proxy_callback_with_ctx(
        q: *mut em_proxying_queue,
        target_thread: pthread_t,
        func: ::std::option::Option<
            unsafe extern "C" fn(arg1: *mut em_proxying_ctx, arg2: *mut ::std::os::raw::c_void),
        >,
        callback: ::std::option::Option<unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void)>,
        cancel: ::std::option::Option<unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void)>,
        arg: *mut ::std::os::raw::c_void,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_proxy_promise(
        q: *mut em_proxying_queue,
        target_thread: pthread_t,
        func: ::std::option::Option<unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void)>,
        arg: *mut ::std::os::raw::c_void,
    ) -> em_promise_t;
}
unsafe extern "C" {
    pub fn emscripten_proxy_promise_with_ctx(
        q: *mut em_proxying_queue,
        target_thread: pthread_t,
        func: ::std::option::Option<
            unsafe extern "C" fn(arg1: *mut em_proxying_ctx, arg2: *mut ::std::os::raw::c_void),
        >,
        arg: *mut ::std::os::raw::c_void,
    ) -> em_promise_t;
}
unsafe extern "C" {
    pub fn emscripten_stack_get_base() -> usize;
}
unsafe extern "C" {
    pub fn emscripten_stack_get_end() -> usize;
}
unsafe extern "C" {
    pub fn emscripten_stack_init();
}
unsafe extern "C" {
    pub fn emscripten_stack_set_limits(
        base: *mut ::std::os::raw::c_void,
        end: *mut ::std::os::raw::c_void,
    );
}
unsafe extern "C" {
    pub fn emscripten_stack_get_current() -> usize;
}
unsafe extern "C" {
    pub fn emscripten_stack_get_free() -> usize;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct em_queued_call {
    _unused: [u8; 0],
}
unsafe extern "C" {
    pub fn emscripten_sync_run_in_main_runtime_thread_(
        sig: ::std::os::raw::c_uint,
        func_ptr: *mut ::std::os::raw::c_void,
        ...
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_async_run_in_main_runtime_thread_(
        sig: ::std::os::raw::c_uint,
        func_ptr: *mut ::std::os::raw::c_void,
        ...
    );
}
unsafe extern "C" {
    pub fn emscripten_async_waitable_run_in_main_runtime_thread_(
        sig: ::std::os::raw::c_uint,
        func_ptr: *mut ::std::os::raw::c_void,
        ...
    ) -> *mut em_queued_call;
}
unsafe extern "C" {
    pub fn emscripten_wait_for_call_v(
        call: *mut em_queued_call,
        timeoutMSecs: f64,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_wait_for_call_i(
        call: *mut em_queued_call,
        timeoutMSecs: f64,
        outResult: *mut ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_async_waitable_close(call: *mut em_queued_call);
}
unsafe extern "C" {
    pub fn emscripten_dispatch_to_thread_args(
        target_thread: pthread_t,
        sig: ::std::os::raw::c_uint,
        func_ptr: *mut ::std::os::raw::c_void,
        satellite: *mut ::std::os::raw::c_void,
        args: va_list,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_dispatch_to_thread_(
        target_thread: pthread_t,
        sig: ::std::os::raw::c_uint,
        func_ptr: *mut ::std::os::raw::c_void,
        satellite: *mut ::std::os::raw::c_void,
        ...
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_dispatch_to_thread_async_args(
        target_thread: pthread_t,
        sig: ::std::os::raw::c_uint,
        func_ptr: *mut ::std::os::raw::c_void,
        satellite: *mut ::std::os::raw::c_void,
        args: va_list,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_dispatch_to_thread_async_(
        target_thread: pthread_t,
        sig: ::std::os::raw::c_uint,
        func_ptr: *mut ::std::os::raw::c_void,
        satellite: *mut ::std::os::raw::c_void,
        ...
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_has_threading_support() -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_num_logical_cores() -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_futex_wait(
        addr: *mut ::std::os::raw::c_void,
        val: u32,
        maxWaitMilliseconds: f64,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_futex_wake(
        addr: *mut ::std::os::raw::c_void,
        count: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_is_main_runtime_thread() -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_is_main_browser_thread() -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_main_thread_process_queued_calls();
}
unsafe extern "C" {
    pub fn emscripten_current_thread_process_queued_calls();
}
unsafe extern "C" {
    pub fn emscripten_main_runtime_thread_id() -> pthread_t;
}
unsafe extern "C" {
    pub fn emscripten_thread_sleep(msecs: f64);
}
unsafe extern "C" {
    pub fn emscripten_set_thread_name(threadId: pthread_t, name: *const ::std::os::raw::c_char);
}
unsafe extern "C" {
    pub fn emscripten_pthread_attr_gettransferredcanvases(
        a: *const pthread_attr_t,
        str_: *mut *const ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_pthread_attr_settransferredcanvases(
        a: *mut pthread_attr_t,
        str_: *const ::std::os::raw::c_char,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_check_blocking_allowed();
}
pub type emscripten_async_wait_volatile_callback_t = ::std::option::Option<
    unsafe extern "C" fn(
        address: *mut ::std::os::raw::c_void,
        value: u32,
        waitResult: ::std::os::raw::c_int,
        userData: *mut ::std::os::raw::c_void,
    ),
>;
unsafe extern "C" {
    pub fn emscripten_malloc_wasm_worker(stackSize: usize) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_create_wasm_worker(
        stackPlusTLSAddress: *mut ::std::os::raw::c_void,
        stackPlusTLSSize: usize,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_terminate_wasm_worker(id: ::std::os::raw::c_int);
}
unsafe extern "C" {
    pub fn emscripten_terminate_all_wasm_workers();
}
unsafe extern "C" {
    pub fn emscripten_current_thread_is_wasm_worker() -> bool;
}
unsafe extern "C" {
    pub fn emscripten_wasm_worker_self_id() -> u32;
}
unsafe extern "C" {
    pub fn emscripten_wasm_worker_post_function_v(
        id: ::std::os::raw::c_int,
        funcPtr: ::std::option::Option<unsafe extern "C" fn()>,
    );
}
unsafe extern "C" {
    pub fn emscripten_wasm_worker_post_function_vi(
        id: ::std::os::raw::c_int,
        funcPtr: ::std::option::Option<unsafe extern "C" fn(arg1: ::std::os::raw::c_int)>,
        arg0: ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_wasm_worker_post_function_vii(
        id: ::std::os::raw::c_int,
        funcPtr: ::std::option::Option<
            unsafe extern "C" fn(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int),
        >,
        arg0: ::std::os::raw::c_int,
        arg1: ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_wasm_worker_post_function_viii(
        id: ::std::os::raw::c_int,
        funcPtr: ::std::option::Option<
            unsafe extern "C" fn(
                arg1: ::std::os::raw::c_int,
                arg2: ::std::os::raw::c_int,
                arg3: ::std::os::raw::c_int,
            ),
        >,
        arg0: ::std::os::raw::c_int,
        arg1: ::std::os::raw::c_int,
        arg2: ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_wasm_worker_post_function_vd(
        id: ::std::os::raw::c_int,
        funcPtr: ::std::option::Option<unsafe extern "C" fn(arg1: f64)>,
        arg0: f64,
    );
}
unsafe extern "C" {
    pub fn emscripten_wasm_worker_post_function_vdd(
        id: ::std::os::raw::c_int,
        funcPtr: ::std::option::Option<unsafe extern "C" fn(arg1: f64, arg2: f64)>,
        arg0: f64,
        arg1: f64,
    );
}
unsafe extern "C" {
    pub fn emscripten_wasm_worker_post_function_vddd(
        id: ::std::os::raw::c_int,
        funcPtr: ::std::option::Option<unsafe extern "C" fn(arg1: f64, arg2: f64, arg3: f64)>,
        arg0: f64,
        arg1: f64,
        arg2: f64,
    );
}
unsafe extern "C" {
    pub fn emscripten_wasm_worker_post_function_sig(
        id: ::std::os::raw::c_int,
        funcPtr: *mut ::std::os::raw::c_void,
        sig: *const ::std::os::raw::c_char,
        ...
    );
}
unsafe extern "C" {
    pub fn emscripten_wasm_worker_sleep(nanoseconds: i64);
}
unsafe extern "C" {
    pub fn emscripten_navigator_hardware_concurrency() -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_atomics_is_lock_free(
        byteWidth: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_lock_init(lock: *mut u32);
}
unsafe extern "C" {
    pub fn emscripten_lock_wait_acquire(lock: *mut u32, maxWaitNanoseconds: i64) -> bool;
}
unsafe extern "C" {
    pub fn emscripten_lock_waitinf_acquire(lock: *mut u32);
}
unsafe extern "C" {
    pub fn emscripten_lock_busyspin_wait_acquire(lock: *mut u32, maxWaitMilliseconds: f64) -> bool;
}
unsafe extern "C" {
    pub fn emscripten_lock_busyspin_waitinf_acquire(lock: *mut u32);
}
unsafe extern "C" {
    pub fn emscripten_lock_async_acquire(
        lock: *mut u32,
        asyncWaitFinished: emscripten_async_wait_volatile_callback_t,
        userData: *mut ::std::os::raw::c_void,
        maxWaitMilliseconds: f64,
    );
}
unsafe extern "C" {
    pub fn emscripten_lock_try_acquire(lock: *mut u32) -> bool;
}
unsafe extern "C" {
    pub fn emscripten_lock_release(lock: *mut u32);
}
unsafe extern "C" {
    pub fn emscripten_semaphore_init(sem: *mut u32, num: ::std::os::raw::c_int);
}
unsafe extern "C" {
    pub fn emscripten_semaphore_try_acquire(
        sem: *mut u32,
        num: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_semaphore_async_acquire(
        sem: *mut u32,
        num: ::std::os::raw::c_int,
        asyncWaitFinished: emscripten_async_wait_volatile_callback_t,
        userData: *mut ::std::os::raw::c_void,
        maxWaitMilliseconds: f64,
    );
}
unsafe extern "C" {
    pub fn emscripten_semaphore_wait_acquire(
        sem: *mut u32,
        num: ::std::os::raw::c_int,
        maxWaitNanoseconds: i64,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_semaphore_waitinf_acquire(
        sem: *mut u32,
        num: ::std::os::raw::c_int,
    ) -> ::std::os::raw::c_int;
}
unsafe extern "C" {
    pub fn emscripten_semaphore_release(sem: *mut u32, num: ::std::os::raw::c_int) -> u32;
}
unsafe extern "C" {
    pub fn emscripten_condvar_init(condvar: *mut u32);
}
unsafe extern "C" {
    pub fn emscripten_condvar_waitinf(condvar: *mut u32, lock: *mut u32);
}
unsafe extern "C" {
    pub fn emscripten_condvar_wait(
        condvar: *mut u32,
        lock: *mut u32,
        maxWaitNanoseconds: i64,
    ) -> bool;
}
unsafe extern "C" {
    pub fn emscripten_condvar_wait_async(
        condvar: *mut u32,
        lock: *mut u32,
        asyncWaitFinished: emscripten_async_wait_callback_t,
        userData: *mut ::std::os::raw::c_void,
        maxWaitMilliseconds: f64,
    ) -> i32;
}
unsafe extern "C" {
    pub fn emscripten_condvar_signal(condvar: *mut u32, numWaitersToSignal: i64);
}
pub type EMSCRIPTEN_WEBAUDIO_T = ::std::os::raw::c_int;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct EmscriptenWebAudioCreateAttributes {
    pub latencyHint: *const ::std::os::raw::c_char,
    pub sampleRate: u32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenWebAudioCreateAttributes"]
        [::std::mem::size_of::<EmscriptenWebAudioCreateAttributes>() - 8usize];
    ["Alignment of EmscriptenWebAudioCreateAttributes"]
        [::std::mem::align_of::<EmscriptenWebAudioCreateAttributes>() - 4usize];
    ["Offset of field: EmscriptenWebAudioCreateAttributes::latencyHint"]
        [::std::mem::offset_of!(EmscriptenWebAudioCreateAttributes, latencyHint) - 0usize];
    ["Offset of field: EmscriptenWebAudioCreateAttributes::sampleRate"]
        [::std::mem::offset_of!(EmscriptenWebAudioCreateAttributes, sampleRate) - 4usize];
};
impl Default for EmscriptenWebAudioCreateAttributes {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
unsafe extern "C" {
    pub fn emscripten_create_audio_context(
        options: *const EmscriptenWebAudioCreateAttributes,
    ) -> EMSCRIPTEN_WEBAUDIO_T;
}
pub type AUDIO_CONTEXT_STATE = ::std::os::raw::c_int;
pub type EmscriptenResumeAudioContextCallback = ::std::option::Option<
    unsafe extern "C" fn(
        audioContext: EMSCRIPTEN_WEBAUDIO_T,
        state: AUDIO_CONTEXT_STATE,
        userData1: *mut ::std::os::raw::c_void,
    ),
>;
unsafe extern "C" {
    pub fn emscripten_resume_audio_context_async(
        audioContext: EMSCRIPTEN_WEBAUDIO_T,
        callback: EmscriptenResumeAudioContextCallback,
        userData1: *mut ::std::os::raw::c_void,
    );
}
unsafe extern "C" {
    pub fn emscripten_resume_audio_context_sync(audioContext: EMSCRIPTEN_WEBAUDIO_T);
}
unsafe extern "C" {
    pub fn emscripten_audio_context_state(
        audioContext: EMSCRIPTEN_WEBAUDIO_T,
    ) -> AUDIO_CONTEXT_STATE;
}
pub type EmscriptenStartWebAudioWorkletCallback = ::std::option::Option<
    unsafe extern "C" fn(
        audioContext: EMSCRIPTEN_WEBAUDIO_T,
        success: bool,
        userData2: *mut ::std::os::raw::c_void,
    ),
>;
unsafe extern "C" {
    pub fn emscripten_destroy_audio_context(audioContext: EMSCRIPTEN_WEBAUDIO_T);
}
unsafe extern "C" {
    pub fn emscripten_destroy_web_audio_node(objectHandle: EMSCRIPTEN_WEBAUDIO_T);
}
unsafe extern "C" {
    pub fn emscripten_start_wasm_audio_worklet_thread_async(
        audioContext: EMSCRIPTEN_WEBAUDIO_T,
        stackLowestAddress: *mut ::std::os::raw::c_void,
        stackSize: u32,
        callback: EmscriptenStartWebAudioWorkletCallback,
        userData2: *mut ::std::os::raw::c_void,
    );
}
pub type WEBAUDIO_PARAM_AUTOMATION_RATE = ::std::os::raw::c_int;
#[repr(C)]
#[derive(Debug, Default, Copy, Clone)]
pub struct WebAudioParamDescriptor {
    pub defaultValue: f32,
    pub minValue: f32,
    pub maxValue: f32,
    pub automationRate: WEBAUDIO_PARAM_AUTOMATION_RATE,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of WebAudioParamDescriptor"][::std::mem::size_of::<WebAudioParamDescriptor>() - 16usize];
    ["Alignment of WebAudioParamDescriptor"]
        [::std::mem::align_of::<WebAudioParamDescriptor>() - 4usize];
    ["Offset of field: WebAudioParamDescriptor::defaultValue"]
        [::std::mem::offset_of!(WebAudioParamDescriptor, defaultValue) - 0usize];
    ["Offset of field: WebAudioParamDescriptor::minValue"]
        [::std::mem::offset_of!(WebAudioParamDescriptor, minValue) - 4usize];
    ["Offset of field: WebAudioParamDescriptor::maxValue"]
        [::std::mem::offset_of!(WebAudioParamDescriptor, maxValue) - 8usize];
    ["Offset of field: WebAudioParamDescriptor::automationRate"]
        [::std::mem::offset_of!(WebAudioParamDescriptor, automationRate) - 12usize];
};
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct WebAudioWorkletProcessorCreateOptions {
    pub name: *const ::std::os::raw::c_char,
    pub numAudioParams: ::std::os::raw::c_int,
    pub audioParamDescriptors: *const WebAudioParamDescriptor,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of WebAudioWorkletProcessorCreateOptions"]
        [::std::mem::size_of::<WebAudioWorkletProcessorCreateOptions>() - 12usize];
    ["Alignment of WebAudioWorkletProcessorCreateOptions"]
        [::std::mem::align_of::<WebAudioWorkletProcessorCreateOptions>() - 4usize];
    ["Offset of field: WebAudioWorkletProcessorCreateOptions::name"]
        [::std::mem::offset_of!(WebAudioWorkletProcessorCreateOptions, name) - 0usize];
    ["Offset of field: WebAudioWorkletProcessorCreateOptions::numAudioParams"]
        [::std::mem::offset_of!(WebAudioWorkletProcessorCreateOptions, numAudioParams) - 4usize];
    ["Offset of field: WebAudioWorkletProcessorCreateOptions::audioParamDescriptors"][::std::mem::offset_of!(
        WebAudioWorkletProcessorCreateOptions,
        audioParamDescriptors
    ) - 8usize];
};
impl Default for WebAudioWorkletProcessorCreateOptions {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
pub type EmscriptenWorkletProcessorCreatedCallback = ::std::option::Option<
    unsafe extern "C" fn(
        audioContext: EMSCRIPTEN_WEBAUDIO_T,
        success: bool,
        userData3: *mut ::std::os::raw::c_void,
    ),
>;
unsafe extern "C" {
    pub fn emscripten_create_wasm_audio_worklet_processor_async(
        audioContext: EMSCRIPTEN_WEBAUDIO_T,
        options: *const WebAudioWorkletProcessorCreateOptions,
        callback: EmscriptenWorkletProcessorCreatedCallback,
        userData3: *mut ::std::os::raw::c_void,
    );
}
unsafe extern "C" {
    pub fn emscripten_audio_context_quantum_size(
        audioContext: EMSCRIPTEN_WEBAUDIO_T,
    ) -> ::std::os::raw::c_int;
}
pub type EMSCRIPTEN_AUDIO_WORKLET_NODE_T = ::std::os::raw::c_int;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct AudioSampleFrame {
    pub numberOfChannels: ::std::os::raw::c_int,
    pub samplesPerChannel: ::std::os::raw::c_int,
    pub data: *mut f32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of AudioSampleFrame"][::std::mem::size_of::<AudioSampleFrame>() - 12usize];
    ["Alignment of AudioSampleFrame"][::std::mem::align_of::<AudioSampleFrame>() - 4usize];
    ["Offset of field: AudioSampleFrame::numberOfChannels"]
        [::std::mem::offset_of!(AudioSampleFrame, numberOfChannels) - 0usize];
    ["Offset of field: AudioSampleFrame::samplesPerChannel"]
        [::std::mem::offset_of!(AudioSampleFrame, samplesPerChannel) - 4usize];
    ["Offset of field: AudioSampleFrame::data"]
        [::std::mem::offset_of!(AudioSampleFrame, data) - 8usize];
};
impl Default for AudioSampleFrame {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct AudioParamFrame {
    pub length: ::std::os::raw::c_int,
    pub data: *mut f32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of AudioParamFrame"][::std::mem::size_of::<AudioParamFrame>() - 8usize];
    ["Alignment of AudioParamFrame"][::std::mem::align_of::<AudioParamFrame>() - 4usize];
    ["Offset of field: AudioParamFrame::length"]
        [::std::mem::offset_of!(AudioParamFrame, length) - 0usize];
    ["Offset of field: AudioParamFrame::data"]
        [::std::mem::offset_of!(AudioParamFrame, data) - 4usize];
};
impl Default for AudioParamFrame {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
pub type EmscriptenWorkletNodeProcessCallback = ::std::option::Option<
    unsafe extern "C" fn(
        numInputs: ::std::os::raw::c_int,
        inputs: *const AudioSampleFrame,
        numOutputs: ::std::os::raw::c_int,
        outputs: *mut AudioSampleFrame,
        numParams: ::std::os::raw::c_int,
        params: *const AudioParamFrame,
        userData4: *mut ::std::os::raw::c_void,
    ) -> bool,
>;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct EmscriptenAudioWorkletNodeCreateOptions {
    pub numberOfInputs: ::std::os::raw::c_int,
    pub numberOfOutputs: ::std::os::raw::c_int,
    pub outputChannelCounts: *mut ::std::os::raw::c_int,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of EmscriptenAudioWorkletNodeCreateOptions"]
        [::std::mem::size_of::<EmscriptenAudioWorkletNodeCreateOptions>() - 12usize];
    ["Alignment of EmscriptenAudioWorkletNodeCreateOptions"]
        [::std::mem::align_of::<EmscriptenAudioWorkletNodeCreateOptions>() - 4usize];
    ["Offset of field: EmscriptenAudioWorkletNodeCreateOptions::numberOfInputs"]
        [::std::mem::offset_of!(EmscriptenAudioWorkletNodeCreateOptions, numberOfInputs) - 0usize];
    ["Offset of field: EmscriptenAudioWorkletNodeCreateOptions::numberOfOutputs"]
        [::std::mem::offset_of!(EmscriptenAudioWorkletNodeCreateOptions, numberOfOutputs) - 4usize];
    ["Offset of field: EmscriptenAudioWorkletNodeCreateOptions::outputChannelCounts"][::std::mem::offset_of!(
        EmscriptenAudioWorkletNodeCreateOptions,
        outputChannelCounts
    ) - 8usize];
};
impl Default for EmscriptenAudioWorkletNodeCreateOptions {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
unsafe extern "C" {
    pub fn emscripten_create_wasm_audio_worklet_node(
        audioContext: EMSCRIPTEN_WEBAUDIO_T,
        name: *const ::std::os::raw::c_char,
        options: *const EmscriptenAudioWorkletNodeCreateOptions,
        processCallback: EmscriptenWorkletNodeProcessCallback,
        userData4: *mut ::std::os::raw::c_void,
    ) -> EMSCRIPTEN_AUDIO_WORKLET_NODE_T;
}
unsafe extern "C" {
    pub fn emscripten_audio_node_connect(
        source: EMSCRIPTEN_WEBAUDIO_T,
        destination: EMSCRIPTEN_WEBAUDIO_T,
        outputIndex: ::std::os::raw::c_int,
        inputIndex: ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_current_thread_is_audio_worklet() -> bool;
}
unsafe extern "C" {
    pub fn emscripten_audio_worklet_post_function_v(
        id: EMSCRIPTEN_WEBAUDIO_T,
        funcPtr: ::std::option::Option<unsafe extern "C" fn()>,
    );
}
unsafe extern "C" {
    pub fn emscripten_audio_worklet_post_function_vi(
        id: EMSCRIPTEN_WEBAUDIO_T,
        funcPtr: ::std::option::Option<unsafe extern "C" fn(arg1: ::std::os::raw::c_int)>,
        arg0: ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_audio_worklet_post_function_vii(
        id: EMSCRIPTEN_WEBAUDIO_T,
        funcPtr: ::std::option::Option<
            unsafe extern "C" fn(arg1: ::std::os::raw::c_int, arg2: ::std::os::raw::c_int),
        >,
        arg0: ::std::os::raw::c_int,
        arg1: ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_audio_worklet_post_function_viii(
        id: EMSCRIPTEN_WEBAUDIO_T,
        funcPtr: ::std::option::Option<
            unsafe extern "C" fn(
                arg1: ::std::os::raw::c_int,
                arg2: ::std::os::raw::c_int,
                arg3: ::std::os::raw::c_int,
            ),
        >,
        arg0: ::std::os::raw::c_int,
        arg1: ::std::os::raw::c_int,
        arg2: ::std::os::raw::c_int,
    );
}
unsafe extern "C" {
    pub fn emscripten_audio_worklet_post_function_vd(
        id: EMSCRIPTEN_WEBAUDIO_T,
        funcPtr: ::std::option::Option<unsafe extern "C" fn(arg1: f64)>,
        arg0: f64,
    );
}
unsafe extern "C" {
    pub fn emscripten_audio_worklet_post_function_vdd(
        id: EMSCRIPTEN_WEBAUDIO_T,
        funcPtr: ::std::option::Option<unsafe extern "C" fn(arg1: f64, arg2: f64)>,
        arg0: f64,
        arg1: f64,
    );
}
unsafe extern "C" {
    pub fn emscripten_audio_worklet_post_function_vddd(
        id: EMSCRIPTEN_WEBAUDIO_T,
        funcPtr: ::std::option::Option<unsafe extern "C" fn(arg1: f64, arg2: f64, arg3: f64)>,
        arg0: f64,
        arg1: f64,
        arg2: f64,
    );
}
unsafe extern "C" {
    pub fn emscripten_audio_worklet_post_function_sig(
        id: EMSCRIPTEN_WEBAUDIO_T,
        funcPtr: *mut ::std::os::raw::c_void,
        sig: *const ::std::os::raw::c_char,
        ...
    );
}
pub type __builtin_va_list = *mut ::std::os::raw::c_void;
pub type rep = ::std::os::raw::c_longlong;
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of template specialization: __em_asm_sig_open0_int_void_close0"]
        [::std::mem::size_of::<__em_asm_sig>() - 1usize];
    ["Align of template specialization: __em_asm_sig_open0_int_void_close0"]
        [::std::mem::align_of::<__em_asm_sig>() - 1usize];
};
