mirror of https://github.com/ppy/SDL3-CS.git
Update SDL bindings
This brings in the removal of SDL_bool, making it C# `byte`
This commit is contained in:
parent
fb08ccb2ce
commit
fa7121a2c4
|
|
@ -1 +1 @@
|
|||
Subproject commit 93bf53426840fd052da2aeb6d5a5a6f380f4c21a
|
||||
Subproject commit 97d1056e16d44f67df3b19e1fac8378399ae5f3d
|
||||
|
|
@ -33,10 +33,17 @@ namespace SDL
|
|||
public int value;
|
||||
}
|
||||
|
||||
public partial struct SDL_AtomicU32
|
||||
{
|
||||
[NativeTypeName("Uint32")]
|
||||
public uint value;
|
||||
}
|
||||
|
||||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_TryLockSpinlock([NativeTypeName("SDL_SpinLock *")] int* @lock);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_TryLockSpinlock([NativeTypeName("SDL_SpinLock *")] int* @lock);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_LockSpinlock([NativeTypeName("SDL_SpinLock *")] int* @lock);
|
||||
|
|
@ -51,26 +58,40 @@ namespace SDL
|
|||
public static extern void SDL_MemoryBarrierAcquireFunction();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_AtomicCompareAndSwap(SDL_AtomicInt* a, int oldval, int newval);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_CompareAndSwapAtomicInt(SDL_AtomicInt* a, int oldval, int newval);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_AtomicSet(SDL_AtomicInt* a, int v);
|
||||
public static extern int SDL_SetAtomicInt(SDL_AtomicInt* a, int v);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_AtomicGet(SDL_AtomicInt* a);
|
||||
public static extern int SDL_GetAtomicInt(SDL_AtomicInt* a);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_AtomicAdd(SDL_AtomicInt* a, int v);
|
||||
public static extern int SDL_AddAtomicInt(SDL_AtomicInt* a, int v);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_AtomicCompareAndSwapPointer([NativeTypeName("void **")] IntPtr* a, [NativeTypeName("void*")] IntPtr oldval, [NativeTypeName("void*")] IntPtr newval);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_CompareAndSwapAtomicU32(SDL_AtomicU32* a, [NativeTypeName("Uint32")] uint oldval, [NativeTypeName("Uint32")] uint newval);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Uint32")]
|
||||
public static extern uint SDL_SetAtomicU32(SDL_AtomicU32* a, [NativeTypeName("Uint32")] uint v);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Uint32")]
|
||||
public static extern uint SDL_GetAtomicU32(SDL_AtomicU32* a);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_CompareAndSwapAtomicPointer([NativeTypeName("void **")] IntPtr* a, [NativeTypeName("void*")] IntPtr oldval, [NativeTypeName("void*")] IntPtr newval);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("void*")]
|
||||
public static extern IntPtr SDL_AtomicSetPointer([NativeTypeName("void **")] IntPtr* a, [NativeTypeName("void*")] IntPtr v);
|
||||
public static extern IntPtr SDL_SetAtomicPointer([NativeTypeName("void **")] IntPtr* a, [NativeTypeName("void*")] IntPtr v);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("void*")]
|
||||
public static extern IntPtr SDL_AtomicGetPointer([NativeTypeName("void **")] IntPtr* a);
|
||||
public static extern IntPtr SDL_GetAtomicPointer([NativeTypeName("void **")] IntPtr* a);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -79,7 +79,8 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetAudioDeviceName(SDL_AudioDeviceID devid);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetAudioDeviceFormat(SDL_AudioDeviceID devid, SDL_AudioSpec* spec, int* sample_frames);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetAudioDeviceFormat(SDL_AudioDeviceID devid, SDL_AudioSpec* spec, int* sample_frames);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int* SDL_GetAudioDeviceChannelMap(SDL_AudioDeviceID devid, int* count);
|
||||
|
|
@ -88,28 +89,34 @@ namespace SDL
|
|||
public static extern SDL_AudioDeviceID SDL_OpenAudioDevice(SDL_AudioDeviceID devid, [NativeTypeName("const SDL_AudioSpec *")] SDL_AudioSpec* spec);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_PauseAudioDevice(SDL_AudioDeviceID dev);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_PauseAudioDevice(SDL_AudioDeviceID dev);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ResumeAudioDevice(SDL_AudioDeviceID dev);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ResumeAudioDevice(SDL_AudioDeviceID dev);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_AudioDevicePaused(SDL_AudioDeviceID dev);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_AudioDevicePaused(SDL_AudioDeviceID dev);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern float SDL_GetAudioDeviceGain(SDL_AudioDeviceID devid);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetAudioDeviceGain(SDL_AudioDeviceID devid, float gain);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetAudioDeviceGain(SDL_AudioDeviceID devid, float gain);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_CloseAudioDevice(SDL_AudioDeviceID devid);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_BindAudioStreams(SDL_AudioDeviceID devid, SDL_AudioStream** streams, int num_streams);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_BindAudioStreams(SDL_AudioDeviceID devid, SDL_AudioStream** streams, int num_streams);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_BindAudioStream(SDL_AudioDeviceID devid, SDL_AudioStream* stream);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_BindAudioStream(SDL_AudioDeviceID devid, SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_UnbindAudioStreams(SDL_AudioStream** streams, int num_streams);
|
||||
|
|
@ -127,22 +134,26 @@ namespace SDL
|
|||
public static extern SDL_PropertiesID SDL_GetAudioStreamProperties(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetAudioStreamFormat(SDL_AudioStream* stream, SDL_AudioSpec* src_spec, SDL_AudioSpec* dst_spec);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetAudioStreamFormat(SDL_AudioStream* stream, SDL_AudioSpec* src_spec, SDL_AudioSpec* dst_spec);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetAudioStreamFormat(SDL_AudioStream* stream, [NativeTypeName("const SDL_AudioSpec *")] SDL_AudioSpec* src_spec, [NativeTypeName("const SDL_AudioSpec *")] SDL_AudioSpec* dst_spec);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetAudioStreamFormat(SDL_AudioStream* stream, [NativeTypeName("const SDL_AudioSpec *")] SDL_AudioSpec* src_spec, [NativeTypeName("const SDL_AudioSpec *")] SDL_AudioSpec* dst_spec);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern float SDL_GetAudioStreamFrequencyRatio(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetAudioStreamFrequencyRatio(SDL_AudioStream* stream, float ratio);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetAudioStreamFrequencyRatio(SDL_AudioStream* stream, float ratio);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern float SDL_GetAudioStreamGain(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetAudioStreamGain(SDL_AudioStream* stream, float gain);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetAudioStreamGain(SDL_AudioStream* stream, float gain);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int* SDL_GetAudioStreamInputChannelMap(SDL_AudioStream* stream, int* count);
|
||||
|
|
@ -151,13 +162,16 @@ namespace SDL
|
|||
public static extern int* SDL_GetAudioStreamOutputChannelMap(SDL_AudioStream* stream, int* count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetAudioStreamInputChannelMap(SDL_AudioStream* stream, [NativeTypeName("const int *")] int* chmap, int count);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetAudioStreamInputChannelMap(SDL_AudioStream* stream, [NativeTypeName("const int *")] int* chmap, int count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetAudioStreamOutputChannelMap(SDL_AudioStream* stream, [NativeTypeName("const int *")] int* chmap, int count);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetAudioStreamOutputChannelMap(SDL_AudioStream* stream, [NativeTypeName("const int *")] int* chmap, int count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_PutAudioStreamData(SDL_AudioStream* stream, [NativeTypeName("const void *")] IntPtr buf, int len);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_PutAudioStreamData(SDL_AudioStream* stream, [NativeTypeName("const void *")] IntPtr buf, int len);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetAudioStreamData(SDL_AudioStream* stream, [NativeTypeName("void*")] IntPtr buf, int len);
|
||||
|
|
@ -169,28 +183,36 @@ namespace SDL
|
|||
public static extern int SDL_GetAudioStreamQueued(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_FlushAudioStream(SDL_AudioStream* stream);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_FlushAudioStream(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ClearAudioStream(SDL_AudioStream* stream);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ClearAudioStream(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_PauseAudioStreamDevice(SDL_AudioStream* stream);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_PauseAudioStreamDevice(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ResumeAudioStreamDevice(SDL_AudioStream* stream);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ResumeAudioStreamDevice(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_LockAudioStream(SDL_AudioStream* stream);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_LockAudioStream(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_UnlockAudioStream(SDL_AudioStream* stream);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_UnlockAudioStream(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetAudioStreamGetCallback(SDL_AudioStream* stream, [NativeTypeName("SDL_AudioStreamCallback")] delegate* unmanaged[Cdecl]<IntPtr, SDL_AudioStream*, int, int, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetAudioStreamGetCallback(SDL_AudioStream* stream, [NativeTypeName("SDL_AudioStreamCallback")] delegate* unmanaged[Cdecl]<IntPtr, SDL_AudioStream*, int, int, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetAudioStreamPutCallback(SDL_AudioStream* stream, [NativeTypeName("SDL_AudioStreamCallback")] delegate* unmanaged[Cdecl]<IntPtr, SDL_AudioStream*, int, int, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetAudioStreamPutCallback(SDL_AudioStream* stream, [NativeTypeName("SDL_AudioStreamCallback")] delegate* unmanaged[Cdecl]<IntPtr, SDL_AudioStream*, int, int, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DestroyAudioStream(SDL_AudioStream* stream);
|
||||
|
|
@ -199,19 +221,24 @@ namespace SDL
|
|||
public static extern SDL_AudioStream* SDL_OpenAudioDeviceStream(SDL_AudioDeviceID devid, [NativeTypeName("const SDL_AudioSpec *")] SDL_AudioSpec* spec, [NativeTypeName("SDL_AudioStreamCallback")] delegate* unmanaged[Cdecl]<IntPtr, SDL_AudioStream*, int, int, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetAudioPostmixCallback(SDL_AudioDeviceID devid, [NativeTypeName("SDL_AudioPostmixCallback")] delegate* unmanaged[Cdecl]<IntPtr, SDL_AudioSpec*, float*, int, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetAudioPostmixCallback(SDL_AudioDeviceID devid, [NativeTypeName("SDL_AudioPostmixCallback")] delegate* unmanaged[Cdecl]<IntPtr, SDL_AudioSpec*, float*, int, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_LoadWAV_IO(SDL_IOStream* src, SDL_bool closeio, SDL_AudioSpec* spec, [NativeTypeName("Uint8 **")] byte** audio_buf, [NativeTypeName("Uint32 *")] uint* audio_len);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_LoadWAV_IO(SDL_IOStream* src, [NativeTypeName("bool")] byte closeio, SDL_AudioSpec* spec, [NativeTypeName("Uint8 **")] byte** audio_buf, [NativeTypeName("Uint32 *")] uint* audio_len);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_LoadWAV([NativeTypeName("const char *")] byte* path, SDL_AudioSpec* spec, [NativeTypeName("Uint8 **")] byte** audio_buf, [NativeTypeName("Uint32 *")] uint* audio_len);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_LoadWAV([NativeTypeName("const char *")] byte* path, SDL_AudioSpec* spec, [NativeTypeName("Uint8 **")] byte** audio_buf, [NativeTypeName("Uint32 *")] uint* audio_len);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_MixAudio([NativeTypeName("Uint8 *")] byte* dst, [NativeTypeName("const Uint8 *")] byte* src, SDL_AudioFormat format, [NativeTypeName("Uint32")] uint len, float volume);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_MixAudio([NativeTypeName("Uint8 *")] byte* dst, [NativeTypeName("const Uint8 *")] byte* src, SDL_AudioFormat format, [NativeTypeName("Uint32")] uint len, float volume);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ConvertAudioSamples([NativeTypeName("const SDL_AudioSpec *")] SDL_AudioSpec* src_spec, [NativeTypeName("const Uint8 *")] byte* src_data, int src_len, [NativeTypeName("const SDL_AudioSpec *")] SDL_AudioSpec* dst_spec, [NativeTypeName("Uint8 **")] byte** dst_data, int* dst_len);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ConvertAudioSamples([NativeTypeName("const SDL_AudioSpec *")] SDL_AudioSpec* src_spec, [NativeTypeName("const Uint8 *")] byte* src_data, int src_len, [NativeTypeName("const SDL_AudioSpec *")] SDL_AudioSpec* dst_spec, [NativeTypeName("Uint8 **")] byte** dst_data, int* dst_len);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_GetAudioFormatName", ExactSpelling = true)]
|
||||
[return: NativeTypeName("const char *")]
|
||||
|
|
|
|||
|
|
@ -92,7 +92,8 @@ namespace SDL
|
|||
public static extern SDL_PropertiesID SDL_GetCameraProperties(SDL_Camera* camera);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetCameraFormat(SDL_Camera* camera, SDL_CameraSpec* spec);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetCameraFormat(SDL_Camera* camera, SDL_CameraSpec* spec);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Surface* SDL_AcquireCameraFrame(SDL_Camera* camera, [NativeTypeName("Uint64 *")] ulong* timestampNS);
|
||||
|
|
|
|||
|
|
@ -31,36 +31,43 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetClipboardText([NativeTypeName("const char *")] byte* text);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetClipboardText([NativeTypeName("const char *")] byte* text);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_GetClipboardText", ExactSpelling = true)]
|
||||
[return: NativeTypeName("char *")]
|
||||
public static extern byte* Unsafe_SDL_GetClipboardText();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasClipboardText();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasClipboardText();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetPrimarySelectionText([NativeTypeName("const char *")] byte* text);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetPrimarySelectionText([NativeTypeName("const char *")] byte* text);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_GetPrimarySelectionText", ExactSpelling = true)]
|
||||
[return: NativeTypeName("char *")]
|
||||
public static extern byte* Unsafe_SDL_GetPrimarySelectionText();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasPrimarySelectionText();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasPrimarySelectionText();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetClipboardData([NativeTypeName("SDL_ClipboardDataCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte*, nuint*, IntPtr> callback, [NativeTypeName("SDL_ClipboardCleanupCallback")] delegate* unmanaged[Cdecl]<IntPtr, void> cleanup, [NativeTypeName("void*")] IntPtr userdata, [NativeTypeName("const char **")] byte** mime_types, [NativeTypeName("size_t")] nuint num_mime_types);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetClipboardData([NativeTypeName("SDL_ClipboardDataCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte*, nuint*, IntPtr> callback, [NativeTypeName("SDL_ClipboardCleanupCallback")] delegate* unmanaged[Cdecl]<IntPtr, void> cleanup, [NativeTypeName("void*")] IntPtr userdata, [NativeTypeName("const char **")] byte** mime_types, [NativeTypeName("size_t")] nuint num_mime_types);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ClearClipboardData();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ClearClipboardData();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("void*")]
|
||||
public static extern IntPtr SDL_GetClipboardData([NativeTypeName("const char *")] byte* mime_type, [NativeTypeName("size_t *")] nuint* size);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasClipboardData([NativeTypeName("const char *")] byte* mime_type);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasClipboardData([NativeTypeName("const char *")] byte* mime_type);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -30,52 +30,66 @@ namespace SDL
|
|||
public static partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetCPUCount();
|
||||
public static extern int SDL_GetNumLogicalCPUCores();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetCPUCacheLineSize();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasAltiVec();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasAltiVec();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasMMX();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasMMX();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasSSE();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasSSE();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasSSE2();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasSSE2();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasSSE3();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasSSE3();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasSSE41();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasSSE41();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasSSE42();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasSSE42();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasAVX();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasAVX();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasAVX2();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasAVX2();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasAVX512F();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasAVX512F();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasARMSIMD();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasARMSIMD();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasNEON();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasNEON();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasLSX();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasLSX();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasLASX();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasLASX();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetSystemRAM();
|
||||
|
|
|
|||
|
|
@ -40,12 +40,12 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_ShowOpenFileDialog([NativeTypeName("SDL_DialogFileCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte**, int, void> callback, [NativeTypeName("void*")] IntPtr userdata, SDL_Window* window, [NativeTypeName("const SDL_DialogFileFilter *")] SDL_DialogFileFilter* filters, int nfilters, [NativeTypeName("const char *")] byte* default_location, SDL_bool allow_many);
|
||||
public static extern void SDL_ShowOpenFileDialog([NativeTypeName("SDL_DialogFileCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte**, int, void> callback, [NativeTypeName("void*")] IntPtr userdata, SDL_Window* window, [NativeTypeName("const SDL_DialogFileFilter *")] SDL_DialogFileFilter* filters, int nfilters, [NativeTypeName("const char *")] byte* default_location, [NativeTypeName("bool")] byte allow_many);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_ShowSaveFileDialog([NativeTypeName("SDL_DialogFileCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte**, int, void> callback, [NativeTypeName("void*")] IntPtr userdata, SDL_Window* window, [NativeTypeName("const SDL_DialogFileFilter *")] SDL_DialogFileFilter* filters, int nfilters, [NativeTypeName("const char *")] byte* default_location);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_ShowOpenFolderDialog([NativeTypeName("SDL_DialogFileCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte**, int, void> callback, [NativeTypeName("void*")] IntPtr userdata, SDL_Window* window, [NativeTypeName("const char *")] byte* default_location, SDL_bool allow_many);
|
||||
public static extern void SDL_ShowOpenFolderDialog([NativeTypeName("SDL_DialogFileCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte**, int, void> callback, [NativeTypeName("void*")] IntPtr userdata, SDL_Window* window, [NativeTypeName("const char *")] byte* default_location, [NativeTypeName("bool")] byte allow_many);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -30,16 +30,19 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetError([NativeTypeName("const char *")] byte* fmt, __arglist);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetError([NativeTypeName("const char *")] byte* fmt, __arglist);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_OutOfMemory();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_OutOfMemory();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_GetError", ExactSpelling = true)]
|
||||
[return: NativeTypeName("const char *")]
|
||||
public static extern byte* Unsafe_SDL_GetError();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ClearError();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ClearError();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -231,9 +231,11 @@ namespace SDL
|
|||
[NativeTypeName("Uint16")]
|
||||
public ushort raw;
|
||||
|
||||
public SDL_bool down;
|
||||
[NativeTypeName("bool")]
|
||||
public byte down;
|
||||
|
||||
public SDL_bool repeat;
|
||||
[NativeTypeName("bool")]
|
||||
public byte repeat;
|
||||
}
|
||||
|
||||
public unsafe partial struct SDL_TextEditingEvent
|
||||
|
|
@ -279,7 +281,8 @@ namespace SDL
|
|||
[NativeTypeName("Sint32")]
|
||||
public int selected_candidate;
|
||||
|
||||
public SDL_bool horizontal;
|
||||
[NativeTypeName("bool")]
|
||||
public byte horizontal;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
|
@ -362,7 +365,8 @@ namespace SDL
|
|||
[NativeTypeName("Uint8")]
|
||||
public byte button;
|
||||
|
||||
public SDL_bool down;
|
||||
[NativeTypeName("bool")]
|
||||
public byte down;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte clicks;
|
||||
|
|
@ -502,7 +506,8 @@ namespace SDL
|
|||
[NativeTypeName("Uint8")]
|
||||
public byte button;
|
||||
|
||||
public SDL_bool down;
|
||||
[NativeTypeName("bool")]
|
||||
public byte down;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
|
@ -587,7 +592,8 @@ namespace SDL
|
|||
[NativeTypeName("Uint8")]
|
||||
public byte button;
|
||||
|
||||
public SDL_bool down;
|
||||
[NativeTypeName("bool")]
|
||||
public byte down;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
|
@ -674,7 +680,8 @@ namespace SDL
|
|||
|
||||
public SDL_AudioDeviceID which;
|
||||
|
||||
public SDL_bool recording;
|
||||
[NativeTypeName("bool")]
|
||||
public byte recording;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
|
@ -782,9 +789,11 @@ namespace SDL
|
|||
|
||||
public float y;
|
||||
|
||||
public SDL_bool eraser;
|
||||
[NativeTypeName("bool")]
|
||||
public byte eraser;
|
||||
|
||||
public SDL_bool down;
|
||||
[NativeTypeName("bool")]
|
||||
public byte down;
|
||||
}
|
||||
|
||||
public partial struct SDL_PenButtonEvent
|
||||
|
|
@ -810,7 +819,8 @@ namespace SDL
|
|||
[NativeTypeName("Uint8")]
|
||||
public byte button;
|
||||
|
||||
public SDL_bool down;
|
||||
[NativeTypeName("bool")]
|
||||
public byte down;
|
||||
}
|
||||
|
||||
public partial struct SDL_PenAxisEvent
|
||||
|
|
@ -1073,10 +1083,12 @@ namespace SDL
|
|||
public static extern int SDL_PeepEvents(SDL_Event* events, int numevents, SDL_EventAction action, [NativeTypeName("Uint32")] uint minType, [NativeTypeName("Uint32")] uint maxType);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasEvent([NativeTypeName("Uint32")] uint type);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasEvent([NativeTypeName("Uint32")] uint type);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasEvents([NativeTypeName("Uint32")] uint minType, [NativeTypeName("Uint32")] uint maxType);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasEvents([NativeTypeName("Uint32")] uint minType, [NativeTypeName("Uint32")] uint maxType);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_FlushEvent([NativeTypeName("Uint32")] uint type);
|
||||
|
|
@ -1085,37 +1097,44 @@ namespace SDL
|
|||
public static extern void SDL_FlushEvents([NativeTypeName("Uint32")] uint minType, [NativeTypeName("Uint32")] uint maxType);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_PollEvent(SDL_Event* @event);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_PollEvent(SDL_Event* @event);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WaitEvent(SDL_Event* @event);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WaitEvent(SDL_Event* @event);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WaitEventTimeout(SDL_Event* @event, [NativeTypeName("Sint32")] int timeoutMS);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WaitEventTimeout(SDL_Event* @event, [NativeTypeName("Sint32")] int timeoutMS);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_PushEvent(SDL_Event* @event);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_PushEvent(SDL_Event* @event);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_SetEventFilter([NativeTypeName("SDL_EventFilter")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, SDL_bool> filter, [NativeTypeName("void*")] IntPtr userdata);
|
||||
public static extern void SDL_SetEventFilter([NativeTypeName("SDL_EventFilter")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, byte> filter, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetEventFilter([NativeTypeName("SDL_EventFilter *")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, SDL_bool>* filter, [NativeTypeName("void **")] IntPtr* userdata);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetEventFilter([NativeTypeName("SDL_EventFilter *")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, byte>* filter, [NativeTypeName("void **")] IntPtr* userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_AddEventWatch([NativeTypeName("SDL_EventFilter")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, SDL_bool> filter, [NativeTypeName("void*")] IntPtr userdata);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_AddEventWatch([NativeTypeName("SDL_EventFilter")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, byte> filter, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_RemoveEventWatch([NativeTypeName("SDL_EventFilter")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, SDL_bool> filter, [NativeTypeName("void*")] IntPtr userdata);
|
||||
public static extern void SDL_RemoveEventWatch([NativeTypeName("SDL_EventFilter")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, byte> filter, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_FilterEvents([NativeTypeName("SDL_EventFilter")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, SDL_bool> filter, [NativeTypeName("void*")] IntPtr userdata);
|
||||
public static extern void SDL_FilterEvents([NativeTypeName("SDL_EventFilter")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, byte> filter, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_SetEventEnabled([NativeTypeName("Uint32")] uint type, SDL_bool enabled);
|
||||
public static extern void SDL_SetEventEnabled([NativeTypeName("Uint32")] uint type, [NativeTypeName("bool")] byte enabled);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_EventEnabled([NativeTypeName("Uint32")] uint type);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_EventEnabled([NativeTypeName("Uint32")] uint type);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Uint32")]
|
||||
|
|
|
|||
|
|
@ -81,22 +81,28 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetUserFolder(SDL_Folder folder);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_CreateDirectory([NativeTypeName("const char *")] byte* path);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_CreateDirectory([NativeTypeName("const char *")] byte* path);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_EnumerateDirectory([NativeTypeName("const char *")] byte* path, [NativeTypeName("SDL_EnumerateDirectoryCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, int> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_EnumerateDirectory([NativeTypeName("const char *")] byte* path, [NativeTypeName("SDL_EnumerateDirectoryCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, int> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RemovePath([NativeTypeName("const char *")] byte* path);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RemovePath([NativeTypeName("const char *")] byte* path);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenamePath([NativeTypeName("const char *")] byte* oldpath, [NativeTypeName("const char *")] byte* newpath);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenamePath([NativeTypeName("const char *")] byte* oldpath, [NativeTypeName("const char *")] byte* newpath);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_CopyFile([NativeTypeName("const char *")] byte* oldpath, [NativeTypeName("const char *")] byte* newpath);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_CopyFile([NativeTypeName("const char *")] byte* oldpath, [NativeTypeName("const char *")] byte* newpath);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetPathInfo([NativeTypeName("const char *")] byte* path, SDL_PathInfo* info);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetPathInfo([NativeTypeName("const char *")] byte* path, SDL_PathInfo* info);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("char **")]
|
||||
|
|
|
|||
|
|
@ -183,13 +183,14 @@ namespace SDL
|
|||
public static extern int SDL_AddGamepadMapping([NativeTypeName("const char *")] byte* mapping);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_AddGamepadMappingsFromIO(SDL_IOStream* src, SDL_bool closeio);
|
||||
public static extern int SDL_AddGamepadMappingsFromIO(SDL_IOStream* src, [NativeTypeName("bool")] byte closeio);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_AddGamepadMappingsFromFile([NativeTypeName("const char *")] byte* file);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReloadGamepadMappings();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReloadGamepadMappings();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("char **")]
|
||||
|
|
@ -204,16 +205,19 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetGamepadMapping(SDL_Gamepad* gamepad);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetGamepadMapping(SDL_JoystickID instance_id, [NativeTypeName("const char *")] byte* mapping);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetGamepadMapping(SDL_JoystickID instance_id, [NativeTypeName("const char *")] byte* mapping);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasGamepad();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasGamepad();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_JoystickID* SDL_GetGamepads(int* count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_IsGamepad(SDL_JoystickID instance_id);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_IsGamepad(SDL_JoystickID instance_id);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_GetGamepadNameForID", ExactSpelling = true)]
|
||||
[return: NativeTypeName("const char *")]
|
||||
|
|
@ -284,7 +288,8 @@ namespace SDL
|
|||
public static extern int SDL_GetGamepadPlayerIndex(SDL_Gamepad* gamepad);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetGamepadPlayerIndex(SDL_Gamepad* gamepad, int player_index);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetGamepadPlayerIndex(SDL_Gamepad* gamepad, int player_index);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Uint16")]
|
||||
|
|
@ -317,16 +322,18 @@ namespace SDL
|
|||
public static extern SDL_PowerState SDL_GetGamepadPowerInfo(SDL_Gamepad* gamepad, int* percent);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GamepadConnected(SDL_Gamepad* gamepad);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GamepadConnected(SDL_Gamepad* gamepad);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Joystick* SDL_GetGamepadJoystick(SDL_Gamepad* gamepad);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_SetGamepadEventsEnabled(SDL_bool enabled);
|
||||
public static extern void SDL_SetGamepadEventsEnabled([NativeTypeName("bool")] byte enabled);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GamepadEventsEnabled();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GamepadEventsEnabled();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_GamepadBinding** SDL_GetGamepadBindings(SDL_Gamepad* gamepad, int* count);
|
||||
|
|
@ -349,7 +356,8 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetGamepadStringForAxis(SDL_GamepadAxis axis);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GamepadHasAxis(SDL_Gamepad* gamepad, SDL_GamepadAxis axis);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GamepadHasAxis(SDL_Gamepad* gamepad, SDL_GamepadAxis axis);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Sint16")]
|
||||
|
|
@ -363,10 +371,12 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetGamepadStringForButton(SDL_GamepadButton button);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GamepadHasButton(SDL_Gamepad* gamepad, SDL_GamepadButton button);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GamepadHasButton(SDL_Gamepad* gamepad, SDL_GamepadButton button);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetGamepadButton(SDL_Gamepad* gamepad, SDL_GamepadButton button);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetGamepadButton(SDL_Gamepad* gamepad, SDL_GamepadButton button);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_GamepadButtonLabel SDL_GetGamepadButtonLabelForType(SDL_GamepadType type, SDL_GamepadButton button);
|
||||
|
|
@ -381,34 +391,43 @@ namespace SDL
|
|||
public static extern int SDL_GetNumGamepadTouchpadFingers(SDL_Gamepad* gamepad, int touchpad);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetGamepadTouchpadFinger(SDL_Gamepad* gamepad, int touchpad, int finger, SDL_bool* down, float* x, float* y, float* pressure);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetGamepadTouchpadFinger(SDL_Gamepad* gamepad, int touchpad, int finger, bool* down, float* x, float* y, float* pressure);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GamepadHasSensor(SDL_Gamepad* gamepad, SDL_SensorType type);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GamepadHasSensor(SDL_Gamepad* gamepad, SDL_SensorType type);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetGamepadSensorEnabled(SDL_Gamepad* gamepad, SDL_SensorType type, SDL_bool enabled);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetGamepadSensorEnabled(SDL_Gamepad* gamepad, SDL_SensorType type, [NativeTypeName("bool")] byte enabled);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GamepadSensorEnabled(SDL_Gamepad* gamepad, SDL_SensorType type);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GamepadSensorEnabled(SDL_Gamepad* gamepad, SDL_SensorType type);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern float SDL_GetGamepadSensorDataRate(SDL_Gamepad* gamepad, SDL_SensorType type);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetGamepadSensorData(SDL_Gamepad* gamepad, SDL_SensorType type, float* data, int num_values);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetGamepadSensorData(SDL_Gamepad* gamepad, SDL_SensorType type, float* data, int num_values);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RumbleGamepad(SDL_Gamepad* gamepad, [NativeTypeName("Uint16")] ushort low_frequency_rumble, [NativeTypeName("Uint16")] ushort high_frequency_rumble, [NativeTypeName("Uint32")] uint duration_ms);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RumbleGamepad(SDL_Gamepad* gamepad, [NativeTypeName("Uint16")] ushort low_frequency_rumble, [NativeTypeName("Uint16")] ushort high_frequency_rumble, [NativeTypeName("Uint32")] uint duration_ms);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RumbleGamepadTriggers(SDL_Gamepad* gamepad, [NativeTypeName("Uint16")] ushort left_rumble, [NativeTypeName("Uint16")] ushort right_rumble, [NativeTypeName("Uint32")] uint duration_ms);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RumbleGamepadTriggers(SDL_Gamepad* gamepad, [NativeTypeName("Uint16")] ushort left_rumble, [NativeTypeName("Uint16")] ushort right_rumble, [NativeTypeName("Uint32")] uint duration_ms);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetGamepadLED(SDL_Gamepad* gamepad, [NativeTypeName("Uint8")] byte red, [NativeTypeName("Uint8")] byte green, [NativeTypeName("Uint8")] byte blue);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetGamepadLED(SDL_Gamepad* gamepad, [NativeTypeName("Uint8")] byte red, [NativeTypeName("Uint8")] byte green, [NativeTypeName("Uint8")] byte blue);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SendGamepadEffect(SDL_Gamepad* gamepad, [NativeTypeName("const void *")] IntPtr data, int size);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SendGamepadEffect(SDL_Gamepad* gamepad, [NativeTypeName("const void *")] IntPtr data, int size);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_CloseGamepad(SDL_Gamepad* gamepad);
|
||||
|
|
|
|||
|
|
@ -100,6 +100,8 @@ namespace SDL
|
|||
{
|
||||
SDL_GPU_STOREOP_STORE,
|
||||
SDL_GPU_STOREOP_DONT_CARE,
|
||||
SDL_GPU_STOREOP_RESOLVE,
|
||||
SDL_GPU_STOREOP_RESOLVE_AND_STORE,
|
||||
}
|
||||
|
||||
public enum SDL_GPUIndexElementSize
|
||||
|
|
@ -553,9 +555,11 @@ namespace SDL
|
|||
|
||||
public float max_lod;
|
||||
|
||||
public SDL_bool enable_anisotropy;
|
||||
[NativeTypeName("bool")]
|
||||
public byte enable_anisotropy;
|
||||
|
||||
public SDL_bool enable_compare;
|
||||
[NativeTypeName("bool")]
|
||||
public byte enable_compare;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
|
@ -636,9 +640,11 @@ namespace SDL
|
|||
|
||||
public SDL_GPUColorComponentFlags color_write_mask;
|
||||
|
||||
public SDL_bool enable_blend;
|
||||
[NativeTypeName("bool")]
|
||||
public byte enable_blend;
|
||||
|
||||
public SDL_bool enable_color_write_mask;
|
||||
[NativeTypeName("bool")]
|
||||
public byte enable_color_write_mask;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding2;
|
||||
|
|
@ -736,7 +742,8 @@ namespace SDL
|
|||
|
||||
public float depth_bias_slope_factor;
|
||||
|
||||
public SDL_bool enable_depth_bias;
|
||||
[NativeTypeName("bool")]
|
||||
public byte enable_depth_bias;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
|
@ -755,7 +762,8 @@ namespace SDL
|
|||
[NativeTypeName("Uint32")]
|
||||
public uint sample_mask;
|
||||
|
||||
public SDL_bool enable_mask;
|
||||
[NativeTypeName("bool")]
|
||||
public byte enable_mask;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
|
@ -781,11 +789,14 @@ namespace SDL
|
|||
[NativeTypeName("Uint8")]
|
||||
public byte write_mask;
|
||||
|
||||
public SDL_bool enable_depth_test;
|
||||
[NativeTypeName("bool")]
|
||||
public byte enable_depth_test;
|
||||
|
||||
public SDL_bool enable_depth_write;
|
||||
[NativeTypeName("bool")]
|
||||
public byte enable_depth_write;
|
||||
|
||||
public SDL_bool enable_stencil_test;
|
||||
[NativeTypeName("bool")]
|
||||
public byte enable_stencil_test;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
|
@ -804,7 +815,7 @@ namespace SDL
|
|||
public SDL_GPUColorTargetBlendState blend_state;
|
||||
}
|
||||
|
||||
public unsafe partial struct SDL_GpuGraphicsPipelineTargetInfo
|
||||
public unsafe partial struct SDL_GPUGraphicsPipelineTargetInfo
|
||||
{
|
||||
[NativeTypeName("const SDL_GPUColorTargetDescription *")]
|
||||
public SDL_GPUColorTargetDescription* color_target_descriptions;
|
||||
|
|
@ -814,7 +825,8 @@ namespace SDL
|
|||
|
||||
public SDL_GPUTextureFormat depth_stencil_format;
|
||||
|
||||
public SDL_bool has_depth_stencil_target;
|
||||
[NativeTypeName("bool")]
|
||||
public byte has_depth_stencil_target;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
|
@ -842,7 +854,7 @@ namespace SDL
|
|||
|
||||
public SDL_GPUDepthStencilState depth_stencil_state;
|
||||
|
||||
public SDL_GpuGraphicsPipelineTargetInfo target_info;
|
||||
public SDL_GPUGraphicsPipelineTargetInfo target_info;
|
||||
|
||||
public SDL_PropertiesID props;
|
||||
}
|
||||
|
|
@ -906,16 +918,25 @@ namespace SDL
|
|||
|
||||
public SDL_GPUStoreOp store_op;
|
||||
|
||||
public SDL_bool cycle;
|
||||
public SDL_GPUTexture* resolve_texture;
|
||||
|
||||
[NativeTypeName("Uint32")]
|
||||
public uint resolve_mip_level;
|
||||
|
||||
[NativeTypeName("Uint32")]
|
||||
public uint resolve_layer;
|
||||
|
||||
[NativeTypeName("bool")]
|
||||
public byte cycle;
|
||||
|
||||
[NativeTypeName("bool")]
|
||||
public byte cycle_resolve_texture;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding2;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding3;
|
||||
}
|
||||
|
||||
public unsafe partial struct SDL_GPUDepthStencilTargetInfo
|
||||
|
|
@ -932,7 +953,8 @@ namespace SDL
|
|||
|
||||
public SDL_GPUStoreOp stencil_store_op;
|
||||
|
||||
public SDL_bool cycle;
|
||||
[NativeTypeName("bool")]
|
||||
public byte cycle;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte clear_stencil;
|
||||
|
|
@ -958,7 +980,8 @@ namespace SDL
|
|||
|
||||
public SDL_GPUFilter filter;
|
||||
|
||||
public SDL_bool cycle;
|
||||
[NativeTypeName("bool")]
|
||||
public byte cycle;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
|
@ -989,7 +1012,8 @@ namespace SDL
|
|||
{
|
||||
public SDL_GPUBuffer* buffer;
|
||||
|
||||
public SDL_bool cycle;
|
||||
[NativeTypeName("bool")]
|
||||
public byte cycle;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
|
@ -1011,7 +1035,8 @@ namespace SDL
|
|||
[NativeTypeName("Uint32")]
|
||||
public uint layer;
|
||||
|
||||
public SDL_bool cycle;
|
||||
[NativeTypeName("bool")]
|
||||
public byte cycle;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
|
@ -1026,13 +1051,15 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GPUSupportsShaderFormats(SDL_GPUShaderFormat format_flags, [NativeTypeName("const char *")] byte* name);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GPUSupportsShaderFormats(SDL_GPUShaderFormat format_flags, [NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GPUSupportsProperties(SDL_PropertiesID props);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GPUSupportsProperties(SDL_PropertiesID props);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_GPUDevice* SDL_CreateGPUDevice(SDL_GPUShaderFormat format_flags, SDL_bool debug_mode, [NativeTypeName("const char *")] byte* name);
|
||||
public static extern SDL_GPUDevice* SDL_CreateGPUDevice(SDL_GPUShaderFormat format_flags, [NativeTypeName("bool")] byte debug_mode, [NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_GPUDevice* SDL_CreateGPUDeviceWithProperties(SDL_PropertiesID props);
|
||||
|
|
@ -1206,7 +1233,7 @@ namespace SDL
|
|||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("void*")]
|
||||
public static extern IntPtr SDL_MapGPUTransferBuffer(SDL_GPUDevice* device, SDL_GPUTransferBuffer* transfer_buffer, SDL_bool cycle);
|
||||
public static extern IntPtr SDL_MapGPUTransferBuffer(SDL_GPUDevice* device, SDL_GPUTransferBuffer* transfer_buffer, [NativeTypeName("bool")] byte cycle);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_UnmapGPUTransferBuffer(SDL_GPUDevice* device, SDL_GPUTransferBuffer* transfer_buffer);
|
||||
|
|
@ -1215,16 +1242,16 @@ namespace SDL
|
|||
public static extern SDL_GPUCopyPass* SDL_BeginGPUCopyPass(SDL_GPUCommandBuffer* command_buffer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_UploadToGPUTexture(SDL_GPUCopyPass* copy_pass, [NativeTypeName("const SDL_GPUTextureTransferInfo *")] SDL_GPUTextureTransferInfo* source, [NativeTypeName("const SDL_GPUTextureRegion *")] SDL_GPUTextureRegion* destination, SDL_bool cycle);
|
||||
public static extern void SDL_UploadToGPUTexture(SDL_GPUCopyPass* copy_pass, [NativeTypeName("const SDL_GPUTextureTransferInfo *")] SDL_GPUTextureTransferInfo* source, [NativeTypeName("const SDL_GPUTextureRegion *")] SDL_GPUTextureRegion* destination, [NativeTypeName("bool")] byte cycle);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_UploadToGPUBuffer(SDL_GPUCopyPass* copy_pass, [NativeTypeName("const SDL_GPUTransferBufferLocation *")] SDL_GPUTransferBufferLocation* source, [NativeTypeName("const SDL_GPUBufferRegion *")] SDL_GPUBufferRegion* destination, SDL_bool cycle);
|
||||
public static extern void SDL_UploadToGPUBuffer(SDL_GPUCopyPass* copy_pass, [NativeTypeName("const SDL_GPUTransferBufferLocation *")] SDL_GPUTransferBufferLocation* source, [NativeTypeName("const SDL_GPUBufferRegion *")] SDL_GPUBufferRegion* destination, [NativeTypeName("bool")] byte cycle);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_CopyGPUTextureToTexture(SDL_GPUCopyPass* copy_pass, [NativeTypeName("const SDL_GPUTextureLocation *")] SDL_GPUTextureLocation* source, [NativeTypeName("const SDL_GPUTextureLocation *")] SDL_GPUTextureLocation* destination, [NativeTypeName("Uint32")] uint w, [NativeTypeName("Uint32")] uint h, [NativeTypeName("Uint32")] uint d, SDL_bool cycle);
|
||||
public static extern void SDL_CopyGPUTextureToTexture(SDL_GPUCopyPass* copy_pass, [NativeTypeName("const SDL_GPUTextureLocation *")] SDL_GPUTextureLocation* source, [NativeTypeName("const SDL_GPUTextureLocation *")] SDL_GPUTextureLocation* destination, [NativeTypeName("Uint32")] uint w, [NativeTypeName("Uint32")] uint h, [NativeTypeName("Uint32")] uint d, [NativeTypeName("bool")] byte cycle);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_CopyGPUBufferToBuffer(SDL_GPUCopyPass* copy_pass, [NativeTypeName("const SDL_GPUBufferLocation *")] SDL_GPUBufferLocation* source, [NativeTypeName("const SDL_GPUBufferLocation *")] SDL_GPUBufferLocation* destination, [NativeTypeName("Uint32")] uint size, SDL_bool cycle);
|
||||
public static extern void SDL_CopyGPUBufferToBuffer(SDL_GPUCopyPass* copy_pass, [NativeTypeName("const SDL_GPUBufferLocation *")] SDL_GPUBufferLocation* source, [NativeTypeName("const SDL_GPUBufferLocation *")] SDL_GPUBufferLocation* destination, [NativeTypeName("Uint32")] uint size, [NativeTypeName("bool")] byte cycle);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DownloadFromGPUTexture(SDL_GPUCopyPass* copy_pass, [NativeTypeName("const SDL_GPUTextureRegion *")] SDL_GPUTextureRegion* source, [NativeTypeName("const SDL_GPUTextureTransferInfo *")] SDL_GPUTextureTransferInfo* destination);
|
||||
|
|
@ -1242,19 +1269,23 @@ namespace SDL
|
|||
public static extern void SDL_BlitGPUTexture(SDL_GPUCommandBuffer* command_buffer, [NativeTypeName("const SDL_GPUBlitInfo *")] SDL_GPUBlitInfo* info);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WindowSupportsGPUSwapchainComposition(SDL_GPUDevice* device, SDL_Window* window, SDL_GPUSwapchainComposition swapchain_composition);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WindowSupportsGPUSwapchainComposition(SDL_GPUDevice* device, SDL_Window* window, SDL_GPUSwapchainComposition swapchain_composition);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WindowSupportsGPUPresentMode(SDL_GPUDevice* device, SDL_Window* window, SDL_GPUPresentMode present_mode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WindowSupportsGPUPresentMode(SDL_GPUDevice* device, SDL_Window* window, SDL_GPUPresentMode present_mode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ClaimWindowForGPUDevice(SDL_GPUDevice* device, SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ClaimWindowForGPUDevice(SDL_GPUDevice* device, SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_ReleaseWindowFromGPUDevice(SDL_GPUDevice* device, SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetGPUSwapchainParameters(SDL_GPUDevice* device, SDL_Window* window, SDL_GPUSwapchainComposition swapchain_composition, SDL_GPUPresentMode present_mode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetGPUSwapchainParameters(SDL_GPUDevice* device, SDL_Window* window, SDL_GPUSwapchainComposition swapchain_composition, SDL_GPUPresentMode present_mode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_GPUTextureFormat SDL_GetGPUSwapchainTextureFormat(SDL_GPUDevice* device, SDL_Window* window);
|
||||
|
|
@ -1272,10 +1303,11 @@ namespace SDL
|
|||
public static extern void SDL_WaitForGPUIdle(SDL_GPUDevice* device);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_WaitForGPUFences(SDL_GPUDevice* device, SDL_bool wait_all, [NativeTypeName("SDL_GPUFence *const *")] SDL_GPUFence** fences, [NativeTypeName("Uint32")] uint num_fences);
|
||||
public static extern void SDL_WaitForGPUFences(SDL_GPUDevice* device, [NativeTypeName("bool")] byte wait_all, [NativeTypeName("SDL_GPUFence *const *")] SDL_GPUFence** fences, [NativeTypeName("Uint32")] uint num_fences);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_QueryGPUFence(SDL_GPUDevice* device, SDL_GPUFence* fence);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_QueryGPUFence(SDL_GPUDevice* device, SDL_GPUFence* fence);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_ReleaseGPUFence(SDL_GPUDevice* device, SDL_GPUFence* fence);
|
||||
|
|
@ -1285,10 +1317,12 @@ namespace SDL
|
|||
public static extern uint SDL_GPUTextureFormatTexelBlockSize(SDL_GPUTextureFormat format);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GPUTextureSupportsFormat(SDL_GPUDevice* device, SDL_GPUTextureFormat format, SDL_GPUTextureType type, SDL_GPUTextureUsageFlags usage);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GPUTextureSupportsFormat(SDL_GPUDevice* device, SDL_GPUTextureFormat format, SDL_GPUTextureType type, SDL_GPUTextureUsageFlags usage);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GPUTextureSupportsSampleCount(SDL_GPUDevice* device, SDL_GPUTextureFormat format, SDL_GPUSampleCount sample_count);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GPUTextureSupportsSampleCount(SDL_GPUDevice* device, SDL_GPUTextureFormat format, SDL_GPUSampleCount sample_count);
|
||||
|
||||
[NativeTypeName("#define SDL_GPU_TEXTUREUSAGE_SAMPLER (1u << 0)")]
|
||||
public const uint SDL_GPU_TEXTUREUSAGE_SAMPLER = (1U << 0);
|
||||
|
|
|
|||
|
|
@ -346,13 +346,15 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetHapticName(SDL_Haptic* haptic);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_IsMouseHaptic();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_IsMouseHaptic();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Haptic* SDL_OpenHapticFromMouse();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_IsJoystickHaptic(SDL_Joystick* joystick);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_IsJoystickHaptic(SDL_Joystick* joystick);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Haptic* SDL_OpenHapticFromJoystick(SDL_Joystick* joystick);
|
||||
|
|
@ -374,52 +376,66 @@ namespace SDL
|
|||
public static extern int SDL_GetNumHapticAxes(SDL_Haptic* haptic);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HapticEffectSupported(SDL_Haptic* haptic, [NativeTypeName("const SDL_HapticEffect *")] SDL_HapticEffect* effect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HapticEffectSupported(SDL_Haptic* haptic, [NativeTypeName("const SDL_HapticEffect *")] SDL_HapticEffect* effect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_CreateHapticEffect(SDL_Haptic* haptic, [NativeTypeName("const SDL_HapticEffect *")] SDL_HapticEffect* effect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_UpdateHapticEffect(SDL_Haptic* haptic, int effect, [NativeTypeName("const SDL_HapticEffect *")] SDL_HapticEffect* data);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_UpdateHapticEffect(SDL_Haptic* haptic, int effect, [NativeTypeName("const SDL_HapticEffect *")] SDL_HapticEffect* data);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RunHapticEffect(SDL_Haptic* haptic, int effect, [NativeTypeName("Uint32")] uint iterations);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RunHapticEffect(SDL_Haptic* haptic, int effect, [NativeTypeName("Uint32")] uint iterations);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_StopHapticEffect(SDL_Haptic* haptic, int effect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_StopHapticEffect(SDL_Haptic* haptic, int effect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DestroyHapticEffect(SDL_Haptic* haptic, int effect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetHapticEffectStatus(SDL_Haptic* haptic, int effect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetHapticEffectStatus(SDL_Haptic* haptic, int effect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetHapticGain(SDL_Haptic* haptic, int gain);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetHapticGain(SDL_Haptic* haptic, int gain);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetHapticAutocenter(SDL_Haptic* haptic, int autocenter);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetHapticAutocenter(SDL_Haptic* haptic, int autocenter);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_PauseHaptic(SDL_Haptic* haptic);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_PauseHaptic(SDL_Haptic* haptic);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ResumeHaptic(SDL_Haptic* haptic);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ResumeHaptic(SDL_Haptic* haptic);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_StopHapticEffects(SDL_Haptic* haptic);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_StopHapticEffects(SDL_Haptic* haptic);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HapticRumbleSupported(SDL_Haptic* haptic);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HapticRumbleSupported(SDL_Haptic* haptic);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_InitHapticRumble(SDL_Haptic* haptic);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_InitHapticRumble(SDL_Haptic* haptic);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_PlayHapticRumble(SDL_Haptic* haptic, float strength, [NativeTypeName("Uint32")] uint length);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_PlayHapticRumble(SDL_Haptic* haptic, float strength, [NativeTypeName("Uint32")] uint length);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_StopHapticRumble(SDL_Haptic* haptic);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_StopHapticRumble(SDL_Haptic* haptic);
|
||||
|
||||
[NativeTypeName("#define SDL_HAPTIC_CONSTANT (1u<<0)")]
|
||||
public const uint SDL_HAPTIC_CONSTANT = (1U << 0);
|
||||
|
|
|
|||
|
|
@ -151,6 +151,6 @@ namespace SDL
|
|||
public static extern int SDL_hid_get_report_descriptor(SDL_hid_device* dev, [NativeTypeName("unsigned char *")] byte* buf, [NativeTypeName("size_t")] nuint buf_size);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_hid_ble_scan(SDL_bool active);
|
||||
public static extern void SDL_hid_ble_scan([NativeTypeName("bool")] byte active);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -38,13 +38,16 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetHintWithPriority([NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value, SDL_HintPriority priority);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetHintWithPriority([NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value, SDL_HintPriority priority);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetHint([NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetHint([NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ResetHint([NativeTypeName("const char *")] byte* name);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ResetHint([NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_ResetHints();
|
||||
|
|
@ -54,10 +57,12 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetHint([NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetHintBoolean([NativeTypeName("const char *")] byte* name, SDL_bool default_value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetHintBoolean([NativeTypeName("const char *")] byte* name, [NativeTypeName("bool")] byte default_value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_AddHintCallback([NativeTypeName("const char *")] byte* name, [NativeTypeName("SDL_HintCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, byte*, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_AddHintCallback([NativeTypeName("const char *")] byte* name, [NativeTypeName("SDL_HintCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, byte*, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_RemoveHintCallback([NativeTypeName("const char *")] byte* name, [NativeTypeName("SDL_HintCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, byte*, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
|
@ -329,6 +334,9 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_HINT_JOYSTICK_HIDAPI_STEAMDECK \"SDL_JOYSTICK_HIDAPI_STEAMDECK\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_JOYSTICK_HIDAPI_STEAMDECK => "SDL_JOYSTICK_HIDAPI_STEAMDECK"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_JOYSTICK_HIDAPI_STEAM_HORI \"SDL_JOYSTICK_HIDAPI_STEAM_HORI\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_JOYSTICK_HIDAPI_STEAM_HORI => "SDL_JOYSTICK_HIDAPI_STEAM_HORI"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_JOYSTICK_HIDAPI_SWITCH \"SDL_JOYSTICK_HIDAPI_SWITCH\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_JOYSTICK_HIDAPI_SWITCH => "SDL_JOYSTICK_HIDAPI_SWITCH"u8;
|
||||
|
||||
|
|
|
|||
|
|
@ -38,10 +38,12 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_Init(SDL_InitFlags flags);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_Init(SDL_InitFlags flags);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_InitSubSystem(SDL_InitFlags flags);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_InitSubSystem(SDL_InitFlags flags);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_QuitSubSystem(SDL_InitFlags flags);
|
||||
|
|
@ -53,18 +55,17 @@ namespace SDL
|
|||
public static extern void SDL_Quit();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetAppMetadata([NativeTypeName("const char *")] byte* appname, [NativeTypeName("const char *")] byte* appversion, [NativeTypeName("const char *")] byte* appidentifier);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetAppMetadata([NativeTypeName("const char *")] byte* appname, [NativeTypeName("const char *")] byte* appversion, [NativeTypeName("const char *")] byte* appidentifier);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetAppMetadataProperty([NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetAppMetadataProperty([NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_GetAppMetadataProperty", ExactSpelling = true)]
|
||||
[return: NativeTypeName("const char *")]
|
||||
public static extern byte* Unsafe_SDL_GetAppMetadataProperty([NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[NativeTypeName("#define SDL_INIT_TIMER 0x00000001u")]
|
||||
public const uint SDL_INIT_TIMER = 0x00000001U;
|
||||
|
||||
[NativeTypeName("#define SDL_INIT_AUDIO 0x00000010u")]
|
||||
public const uint SDL_INIT_AUDIO = 0x00000010U;
|
||||
|
||||
|
|
|
|||
|
|
@ -62,11 +62,11 @@ namespace SDL
|
|||
[NativeTypeName("size_t (*)(void *, const void *, size_t, SDL_IOStatus *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, IntPtr, nuint, SDL_IOStatus*, nuint> write;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *, SDL_IOStatus *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, SDL_IOStatus*, SDL_bool> flush;
|
||||
[NativeTypeName("bool (*)(void *, SDL_IOStatus *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, SDL_IOStatus*, byte> flush;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, SDL_bool> close;
|
||||
[NativeTypeName("bool (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte> close;
|
||||
}
|
||||
|
||||
public partial struct SDL_IOStream
|
||||
|
|
@ -91,7 +91,8 @@ namespace SDL
|
|||
public static extern SDL_IOStream* SDL_OpenIO([NativeTypeName("const SDL_IOStreamInterface *")] SDL_IOStreamInterface* iface, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_CloseIO(SDL_IOStream* context);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_CloseIO(SDL_IOStream* context);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_PropertiesID SDL_GetIOProperties(SDL_IOStream* context);
|
||||
|
|
@ -128,99 +129,128 @@ namespace SDL
|
|||
public static extern nuint SDL_IOvprintf(SDL_IOStream* context, [NativeTypeName("const char *")] byte* fmt, [NativeTypeName("va_list")] byte* ap);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_FlushIO(SDL_IOStream* context);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_FlushIO(SDL_IOStream* context);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("void*")]
|
||||
public static extern IntPtr SDL_LoadFile_IO(SDL_IOStream* src, [NativeTypeName("size_t *")] nuint* datasize, SDL_bool closeio);
|
||||
public static extern IntPtr SDL_LoadFile_IO(SDL_IOStream* src, [NativeTypeName("size_t *")] nuint* datasize, [NativeTypeName("bool")] byte closeio);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("void*")]
|
||||
public static extern IntPtr SDL_LoadFile([NativeTypeName("const char *")] byte* file, [NativeTypeName("size_t *")] nuint* datasize);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadU8(SDL_IOStream* src, [NativeTypeName("Uint8 *")] byte* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadU8(SDL_IOStream* src, [NativeTypeName("Uint8 *")] byte* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadS8(SDL_IOStream* src, [NativeTypeName("Sint8 *")] sbyte* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadS8(SDL_IOStream* src, [NativeTypeName("Sint8 *")] sbyte* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadU16LE(SDL_IOStream* src, [NativeTypeName("Uint16 *")] ushort* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadU16LE(SDL_IOStream* src, [NativeTypeName("Uint16 *")] ushort* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadS16LE(SDL_IOStream* src, [NativeTypeName("Sint16 *")] short* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadS16LE(SDL_IOStream* src, [NativeTypeName("Sint16 *")] short* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadU16BE(SDL_IOStream* src, [NativeTypeName("Uint16 *")] ushort* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadU16BE(SDL_IOStream* src, [NativeTypeName("Uint16 *")] ushort* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadS16BE(SDL_IOStream* src, [NativeTypeName("Sint16 *")] short* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadS16BE(SDL_IOStream* src, [NativeTypeName("Sint16 *")] short* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadU32LE(SDL_IOStream* src, [NativeTypeName("Uint32 *")] uint* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadU32LE(SDL_IOStream* src, [NativeTypeName("Uint32 *")] uint* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadS32LE(SDL_IOStream* src, [NativeTypeName("Sint32 *")] int* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadS32LE(SDL_IOStream* src, [NativeTypeName("Sint32 *")] int* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadU32BE(SDL_IOStream* src, [NativeTypeName("Uint32 *")] uint* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadU32BE(SDL_IOStream* src, [NativeTypeName("Uint32 *")] uint* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadS32BE(SDL_IOStream* src, [NativeTypeName("Sint32 *")] int* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadS32BE(SDL_IOStream* src, [NativeTypeName("Sint32 *")] int* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadU64LE(SDL_IOStream* src, [NativeTypeName("Uint64 *")] ulong* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadU64LE(SDL_IOStream* src, [NativeTypeName("Uint64 *")] ulong* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadS64LE(SDL_IOStream* src, [NativeTypeName("Sint64 *")] long* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadS64LE(SDL_IOStream* src, [NativeTypeName("Sint64 *")] long* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadU64BE(SDL_IOStream* src, [NativeTypeName("Uint64 *")] ulong* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadU64BE(SDL_IOStream* src, [NativeTypeName("Uint64 *")] ulong* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadS64BE(SDL_IOStream* src, [NativeTypeName("Sint64 *")] long* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadS64BE(SDL_IOStream* src, [NativeTypeName("Sint64 *")] long* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteU8(SDL_IOStream* dst, [NativeTypeName("Uint8")] byte value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteU8(SDL_IOStream* dst, [NativeTypeName("Uint8")] byte value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteS8(SDL_IOStream* dst, [NativeTypeName("Sint8")] sbyte value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteS8(SDL_IOStream* dst, [NativeTypeName("Sint8")] sbyte value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteU16LE(SDL_IOStream* dst, [NativeTypeName("Uint16")] ushort value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteU16LE(SDL_IOStream* dst, [NativeTypeName("Uint16")] ushort value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteS16LE(SDL_IOStream* dst, [NativeTypeName("Sint16")] short value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteS16LE(SDL_IOStream* dst, [NativeTypeName("Sint16")] short value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteU16BE(SDL_IOStream* dst, [NativeTypeName("Uint16")] ushort value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteU16BE(SDL_IOStream* dst, [NativeTypeName("Uint16")] ushort value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteS16BE(SDL_IOStream* dst, [NativeTypeName("Sint16")] short value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteS16BE(SDL_IOStream* dst, [NativeTypeName("Sint16")] short value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteU32LE(SDL_IOStream* dst, [NativeTypeName("Uint32")] uint value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteU32LE(SDL_IOStream* dst, [NativeTypeName("Uint32")] uint value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteS32LE(SDL_IOStream* dst, [NativeTypeName("Sint32")] int value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteS32LE(SDL_IOStream* dst, [NativeTypeName("Sint32")] int value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteU32BE(SDL_IOStream* dst, [NativeTypeName("Uint32")] uint value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteU32BE(SDL_IOStream* dst, [NativeTypeName("Uint32")] uint value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteS32BE(SDL_IOStream* dst, [NativeTypeName("Sint32")] int value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteS32BE(SDL_IOStream* dst, [NativeTypeName("Sint32")] int value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteU64LE(SDL_IOStream* dst, [NativeTypeName("Uint64")] ulong value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteU64LE(SDL_IOStream* dst, [NativeTypeName("Uint64")] ulong value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteS64LE(SDL_IOStream* dst, [NativeTypeName("Sint64")] long value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteS64LE(SDL_IOStream* dst, [NativeTypeName("Sint64")] long value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteU64BE(SDL_IOStream* dst, [NativeTypeName("Uint64")] ulong value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteU64BE(SDL_IOStream* dst, [NativeTypeName("Uint64")] ulong value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteS64BE(SDL_IOStream* dst, [NativeTypeName("Sint64")] long value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteS64BE(SDL_IOStream* dst, [NativeTypeName("Sint64")] long value);
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_IOSTREAM_WINDOWS_HANDLE_POINTER \"SDL.iostream.windows.handle\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_IOSTREAM_WINDOWS_HANDLE_POINTER => "SDL.iostream.windows.handle"u8;
|
||||
|
|
|
|||
|
|
@ -140,20 +140,20 @@ namespace SDL
|
|||
[NativeTypeName("void (*)(void *, int)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, int, void> SetPlayerIndex;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *, Uint16, Uint16)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, ushort, ushort, SDL_bool> Rumble;
|
||||
[NativeTypeName("bool (*)(void *, Uint16, Uint16)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, ushort, ushort, byte> Rumble;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *, Uint16, Uint16)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, ushort, ushort, SDL_bool> RumbleTriggers;
|
||||
[NativeTypeName("bool (*)(void *, Uint16, Uint16)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, ushort, ushort, byte> RumbleTriggers;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *, Uint8, Uint8, Uint8)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte, byte, byte, SDL_bool> SetLED;
|
||||
[NativeTypeName("bool (*)(void *, Uint8, Uint8, Uint8)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte, byte, byte, byte> SetLED;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *, const void *, int)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, IntPtr, int, SDL_bool> SendEffect;
|
||||
[NativeTypeName("bool (*)(void *, const void *, int)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, IntPtr, int, byte> SendEffect;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *, SDL_bool)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, SDL_bool, SDL_bool> SetSensorsEnabled;
|
||||
[NativeTypeName("bool (*)(void *, bool)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte, byte> SetSensorsEnabled;
|
||||
|
||||
[NativeTypeName("void (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, void> Cleanup;
|
||||
|
|
@ -174,7 +174,8 @@ namespace SDL
|
|||
public static extern void SDL_UnlockJoysticks();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasJoystick();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasJoystick();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_JoystickID* SDL_GetJoysticks(int* count);
|
||||
|
|
@ -221,28 +222,36 @@ namespace SDL
|
|||
public static extern SDL_JoystickID SDL_AttachVirtualJoystick([NativeTypeName("const SDL_VirtualJoystickDesc *")] SDL_VirtualJoystickDesc* desc);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_DetachVirtualJoystick(SDL_JoystickID instance_id);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_DetachVirtualJoystick(SDL_JoystickID instance_id);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_IsJoystickVirtual(SDL_JoystickID instance_id);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_IsJoystickVirtual(SDL_JoystickID instance_id);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetJoystickVirtualAxis(SDL_Joystick* joystick, int axis, [NativeTypeName("Sint16")] short value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetJoystickVirtualAxis(SDL_Joystick* joystick, int axis, [NativeTypeName("Sint16")] short value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetJoystickVirtualBall(SDL_Joystick* joystick, int ball, [NativeTypeName("Sint16")] short xrel, [NativeTypeName("Sint16")] short yrel);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetJoystickVirtualBall(SDL_Joystick* joystick, int ball, [NativeTypeName("Sint16")] short xrel, [NativeTypeName("Sint16")] short yrel);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetJoystickVirtualButton(SDL_Joystick* joystick, int button, SDL_bool down);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetJoystickVirtualButton(SDL_Joystick* joystick, int button, [NativeTypeName("bool")] byte down);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetJoystickVirtualHat(SDL_Joystick* joystick, int hat, [NativeTypeName("Uint8")] byte value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetJoystickVirtualHat(SDL_Joystick* joystick, int hat, [NativeTypeName("Uint8")] byte value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetJoystickVirtualTouchpad(SDL_Joystick* joystick, int touchpad, int finger, SDL_bool down, float x, float y, float pressure);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetJoystickVirtualTouchpad(SDL_Joystick* joystick, int touchpad, int finger, [NativeTypeName("bool")] byte down, float x, float y, float pressure);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SendJoystickVirtualSensorData(SDL_Joystick* joystick, SDL_SensorType type, [NativeTypeName("Uint64")] ulong sensor_timestamp, [NativeTypeName("const float *")] float* data, int num_values);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SendJoystickVirtualSensorData(SDL_Joystick* joystick, SDL_SensorType type, [NativeTypeName("Uint64")] ulong sensor_timestamp, [NativeTypeName("const float *")] float* data, int num_values);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_PropertiesID SDL_GetJoystickProperties(SDL_Joystick* joystick);
|
||||
|
|
@ -259,7 +268,8 @@ namespace SDL
|
|||
public static extern int SDL_GetJoystickPlayerIndex(SDL_Joystick* joystick);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetJoystickPlayerIndex(SDL_Joystick* joystick, int player_index);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetJoystickPlayerIndex(SDL_Joystick* joystick, int player_index);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_GUID SDL_GetJoystickGUID(SDL_Joystick* joystick);
|
||||
|
|
@ -291,7 +301,8 @@ namespace SDL
|
|||
public static extern void SDL_GetJoystickGUIDInfo(SDL_GUID guid, [NativeTypeName("Uint16 *")] ushort* vendor, [NativeTypeName("Uint16 *")] ushort* product, [NativeTypeName("Uint16 *")] ushort* version, [NativeTypeName("Uint16 *")] ushort* crc16);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_JoystickConnected(SDL_Joystick* joystick);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_JoystickConnected(SDL_Joystick* joystick);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_JoystickID SDL_GetJoystickID(SDL_Joystick* joystick);
|
||||
|
|
@ -309,10 +320,11 @@ namespace SDL
|
|||
public static extern int SDL_GetNumJoystickButtons(SDL_Joystick* joystick);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_SetJoystickEventsEnabled(SDL_bool enabled);
|
||||
public static extern void SDL_SetJoystickEventsEnabled([NativeTypeName("bool")] byte enabled);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_JoystickEventsEnabled();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_JoystickEventsEnabled();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_UpdateJoysticks();
|
||||
|
|
@ -322,29 +334,36 @@ namespace SDL
|
|||
public static extern short SDL_GetJoystickAxis(SDL_Joystick* joystick, int axis);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetJoystickAxisInitialState(SDL_Joystick* joystick, int axis, [NativeTypeName("Sint16 *")] short* state);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetJoystickAxisInitialState(SDL_Joystick* joystick, int axis, [NativeTypeName("Sint16 *")] short* state);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetJoystickBall(SDL_Joystick* joystick, int ball, int* dx, int* dy);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetJoystickBall(SDL_Joystick* joystick, int ball, int* dx, int* dy);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Uint8")]
|
||||
public static extern byte SDL_GetJoystickHat(SDL_Joystick* joystick, int hat);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetJoystickButton(SDL_Joystick* joystick, int button);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetJoystickButton(SDL_Joystick* joystick, int button);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RumbleJoystick(SDL_Joystick* joystick, [NativeTypeName("Uint16")] ushort low_frequency_rumble, [NativeTypeName("Uint16")] ushort high_frequency_rumble, [NativeTypeName("Uint32")] uint duration_ms);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RumbleJoystick(SDL_Joystick* joystick, [NativeTypeName("Uint16")] ushort low_frequency_rumble, [NativeTypeName("Uint16")] ushort high_frequency_rumble, [NativeTypeName("Uint32")] uint duration_ms);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RumbleJoystickTriggers(SDL_Joystick* joystick, [NativeTypeName("Uint16")] ushort left_rumble, [NativeTypeName("Uint16")] ushort right_rumble, [NativeTypeName("Uint32")] uint duration_ms);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RumbleJoystickTriggers(SDL_Joystick* joystick, [NativeTypeName("Uint16")] ushort left_rumble, [NativeTypeName("Uint16")] ushort right_rumble, [NativeTypeName("Uint32")] uint duration_ms);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetJoystickLED(SDL_Joystick* joystick, [NativeTypeName("Uint8")] byte red, [NativeTypeName("Uint8")] byte green, [NativeTypeName("Uint8")] byte blue);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetJoystickLED(SDL_Joystick* joystick, [NativeTypeName("Uint8")] byte red, [NativeTypeName("Uint8")] byte green, [NativeTypeName("Uint8")] byte blue);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SendJoystickEffect(SDL_Joystick* joystick, [NativeTypeName("const void *")] IntPtr data, int size);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SendJoystickEffect(SDL_Joystick* joystick, [NativeTypeName("const void *")] IntPtr data, int size);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_CloseJoystick(SDL_Joystick* joystick);
|
||||
|
|
|
|||
|
|
@ -52,7 +52,8 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasKeyboard();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasKeyboard();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_KeyboardID* SDL_GetKeyboards(int* count);
|
||||
|
|
@ -65,8 +66,8 @@ namespace SDL
|
|||
public static extern SDL_Window* SDL_GetKeyboardFocus();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("const SDL_bool *")]
|
||||
public static extern SDL_bool* SDL_GetKeyboardState(int* numkeys);
|
||||
[return: NativeTypeName("const bool *")]
|
||||
public static extern bool* SDL_GetKeyboardState(int* numkeys);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_ResetKeyboard();
|
||||
|
|
@ -78,13 +79,14 @@ namespace SDL
|
|||
public static extern void SDL_SetModState(SDL_Keymod modstate);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Keycode SDL_GetKeyFromScancode(SDL_Scancode scancode, SDL_Keymod modstate, SDL_bool key_event);
|
||||
public static extern SDL_Keycode SDL_GetKeyFromScancode(SDL_Scancode scancode, SDL_Keymod modstate, [NativeTypeName("bool")] byte key_event);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Scancode SDL_GetScancodeFromKey(SDL_Keycode key, SDL_Keymod* modstate);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetScancodeName(SDL_Scancode scancode, [NativeTypeName("const char *")] byte* name);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetScancodeName(SDL_Scancode scancode, [NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_GetScancodeName", ExactSpelling = true)]
|
||||
[return: NativeTypeName("const char *")]
|
||||
|
|
@ -101,31 +103,40 @@ namespace SDL
|
|||
public static extern SDL_Keycode SDL_GetKeyFromName([NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_StartTextInput(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_StartTextInput(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_StartTextInputWithProperties(SDL_Window* window, SDL_PropertiesID props);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_StartTextInputWithProperties(SDL_Window* window, SDL_PropertiesID props);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_TextInputActive(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_TextInputActive(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_StopTextInput(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_StopTextInput(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ClearComposition(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ClearComposition(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetTextInputArea(SDL_Window* window, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, int cursor);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetTextInputArea(SDL_Window* window, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, int cursor);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetTextInputArea(SDL_Window* window, SDL_Rect* rect, int* cursor);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetTextInputArea(SDL_Window* window, SDL_Rect* rect, int* cursor);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasScreenKeyboardSupport();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasScreenKeyboardSupport();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ScreenKeyboardShown(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ScreenKeyboardShown(SDL_Window* window);
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTINPUT_TYPE_NUMBER \"SDL.textinput.type\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTINPUT_TYPE_NUMBER => "SDL.textinput.type"u8;
|
||||
|
|
|
|||
|
|
@ -54,7 +54,9 @@ namespace SDL
|
|||
|
||||
public enum SDL_LogPriority
|
||||
{
|
||||
SDL_LOG_PRIORITY_VERBOSE = 1,
|
||||
SDL_LOG_PRIORITY_INVALID,
|
||||
SDL_LOG_PRIORITY_TRACE,
|
||||
SDL_LOG_PRIORITY_VERBOSE,
|
||||
SDL_LOG_PRIORITY_DEBUG,
|
||||
SDL_LOG_PRIORITY_INFO,
|
||||
SDL_LOG_PRIORITY_WARN,
|
||||
|
|
@ -78,11 +80,15 @@ namespace SDL
|
|||
public static extern void SDL_ResetLogPriorities();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetLogPriorityPrefix(SDL_LogPriority priority, [NativeTypeName("const char *")] byte* prefix);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetLogPriorityPrefix(SDL_LogPriority priority, [NativeTypeName("const char *")] byte* prefix);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_Log([NativeTypeName("const char *")] byte* fmt, __arglist);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_LogTrace(int category, [NativeTypeName("const char *")] byte* fmt, __arglist);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_LogVerbose(int category, [NativeTypeName("const char *")] byte* fmt, __arglist);
|
||||
|
||||
|
|
|
|||
|
|
@ -32,8 +32,9 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("bool")]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
public static extern SDL_bool SDL_RegisterApp([NativeTypeName("const char *")] byte* name, [NativeTypeName("Uint32")] uint style, [NativeTypeName("void*")] IntPtr hInst);
|
||||
public static extern byte SDL_RegisterApp([NativeTypeName("const char *")] byte* name, [NativeTypeName("Uint32")] uint style, [NativeTypeName("void*")] IntPtr hInst);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
|
|
|
|||
|
|
@ -96,10 +96,12 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ShowMessageBox([NativeTypeName("const SDL_MessageBoxData *")] SDL_MessageBoxData* messageboxdata, int* buttonid);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ShowMessageBox([NativeTypeName("const SDL_MessageBoxData *")] SDL_MessageBoxData* messageboxdata, int* buttonid);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ShowSimpleMessageBox(SDL_MessageBoxFlags flags, [NativeTypeName("const char *")] byte* title, [NativeTypeName("const char *")] byte* message, SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ShowSimpleMessageBox(SDL_MessageBoxFlags flags, [NativeTypeName("const char *")] byte* title, [NativeTypeName("const char *")] byte* message, SDL_Window* window);
|
||||
|
||||
[NativeTypeName("#define SDL_MESSAGEBOX_ERROR 0x00000010u")]
|
||||
public const uint SDL_MESSAGEBOX_ERROR = 0x00000010U;
|
||||
|
|
|
|||
|
|
@ -30,6 +30,7 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_OpenURL([NativeTypeName("const char *")] byte* url);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_OpenURL([NativeTypeName("const char *")] byte* url);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -65,7 +65,8 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasMouse();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasMouse();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_MouseID* SDL_GetMice(int* count);
|
||||
|
|
@ -90,16 +91,20 @@ namespace SDL
|
|||
public static extern void SDL_WarpMouseInWindow(SDL_Window* window, float x, float y);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WarpMouseGlobal(float x, float y);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WarpMouseGlobal(float x, float y);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowRelativeMouseMode(SDL_Window* window, SDL_bool enabled);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowRelativeMouseMode(SDL_Window* window, [NativeTypeName("bool")] byte enabled);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetWindowRelativeMouseMode(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetWindowRelativeMouseMode(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_CaptureMouse(SDL_bool enabled);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_CaptureMouse([NativeTypeName("bool")] byte enabled);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Cursor* SDL_CreateCursor([NativeTypeName("const Uint8 *")] byte* data, [NativeTypeName("const Uint8 *")] byte* mask, int w, int h, int hot_x, int hot_y);
|
||||
|
|
@ -111,7 +116,8 @@ namespace SDL
|
|||
public static extern SDL_Cursor* SDL_CreateSystemCursor(SDL_SystemCursor id);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetCursor(SDL_Cursor* cursor);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetCursor(SDL_Cursor* cursor);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Cursor* SDL_GetCursor();
|
||||
|
|
@ -123,13 +129,16 @@ namespace SDL
|
|||
public static extern void SDL_DestroyCursor(SDL_Cursor* cursor);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ShowCursor();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ShowCursor();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HideCursor();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HideCursor();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_CursorVisible();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_CursorVisible();
|
||||
|
||||
[NativeTypeName("#define SDL_BUTTON_LEFT 1")]
|
||||
public const int SDL_BUTTON_LEFT = 1;
|
||||
|
|
|
|||
|
|
@ -52,7 +52,8 @@ namespace SDL
|
|||
public static extern void SDL_LockMutex(SDL_Mutex* mutex);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_TryLockMutex(SDL_Mutex* mutex);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_TryLockMutex(SDL_Mutex* mutex);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_UnlockMutex(SDL_Mutex* mutex);
|
||||
|
|
@ -70,10 +71,12 @@ namespace SDL
|
|||
public static extern void SDL_LockRWLockForWriting(SDL_RWLock* rwlock);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_TryLockRWLockForReading(SDL_RWLock* rwlock);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_TryLockRWLockForReading(SDL_RWLock* rwlock);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_TryLockRWLockForWriting(SDL_RWLock* rwlock);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_TryLockRWLockForWriting(SDL_RWLock* rwlock);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_UnlockRWLock(SDL_RWLock* rwlock);
|
||||
|
|
@ -91,10 +94,12 @@ namespace SDL
|
|||
public static extern void SDL_WaitSemaphore(SDL_Semaphore* sem);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_TryWaitSemaphore(SDL_Semaphore* sem);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_TryWaitSemaphore(SDL_Semaphore* sem);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WaitSemaphoreTimeout(SDL_Semaphore* sem, [NativeTypeName("Sint32")] int timeoutMS);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WaitSemaphoreTimeout(SDL_Semaphore* sem, [NativeTypeName("Sint32")] int timeoutMS);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_SignalSemaphore(SDL_Semaphore* sem);
|
||||
|
|
@ -119,6 +124,7 @@ namespace SDL
|
|||
public static extern void SDL_WaitCondition(SDL_Condition* cond, SDL_Mutex* mutex);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WaitConditionTimeout(SDL_Condition* cond, SDL_Mutex* mutex, [NativeTypeName("Sint32")] int timeoutMS);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WaitConditionTimeout(SDL_Condition* cond, SDL_Mutex* mutex, [NativeTypeName("Sint32")] int timeoutMS);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -359,7 +359,8 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetPixelFormatName(SDL_PixelFormat format);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetMasksForPixelFormat(SDL_PixelFormat format, int* bpp, [NativeTypeName("Uint32 *")] uint* Rmask, [NativeTypeName("Uint32 *")] uint* Gmask, [NativeTypeName("Uint32 *")] uint* Bmask, [NativeTypeName("Uint32 *")] uint* Amask);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetMasksForPixelFormat(SDL_PixelFormat format, int* bpp, [NativeTypeName("Uint32 *")] uint* Rmask, [NativeTypeName("Uint32 *")] uint* Gmask, [NativeTypeName("Uint32 *")] uint* Bmask, [NativeTypeName("Uint32 *")] uint* Amask);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_PixelFormat SDL_GetPixelFormatForMasks(int bpp, [NativeTypeName("Uint32")] uint Rmask, [NativeTypeName("Uint32")] uint Gmask, [NativeTypeName("Uint32")] uint Bmask, [NativeTypeName("Uint32")] uint Amask);
|
||||
|
|
@ -372,7 +373,8 @@ namespace SDL
|
|||
public static extern SDL_Palette* SDL_CreatePalette(int ncolors);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetPaletteColors(SDL_Palette* palette, [NativeTypeName("const SDL_Color *")] SDL_Color* colors, int firstcolor, int ncolors);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetPaletteColors(SDL_Palette* palette, [NativeTypeName("const SDL_Color *")] SDL_Color* colors, int firstcolor, int ncolors);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DestroyPalette(SDL_Palette* palette);
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Process* SDL_CreateProcess([NativeTypeName("const char *const *")] byte** args, SDL_bool pipe_stdio);
|
||||
public static extern SDL_Process* SDL_CreateProcess([NativeTypeName("const char *const *")] byte** args, [NativeTypeName("bool")] byte pipe_stdio);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Process* SDL_CreateProcessWithProperties(SDL_PropertiesID props);
|
||||
|
|
@ -62,10 +62,12 @@ namespace SDL
|
|||
public static extern SDL_IOStream* SDL_GetProcessOutput(SDL_Process* process);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_KillProcess(SDL_Process* process, SDL_bool force);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_KillProcess(SDL_Process* process, [NativeTypeName("bool")] byte force);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WaitProcess(SDL_Process* process, SDL_bool block, int* exitcode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WaitProcess(SDL_Process* process, [NativeTypeName("bool")] byte block, int* exitcode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DestroyProcess(SDL_Process* process);
|
||||
|
|
|
|||
|
|
@ -47,34 +47,43 @@ namespace SDL
|
|||
public static extern SDL_PropertiesID SDL_CreateProperties();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_CopyProperties(SDL_PropertiesID src, SDL_PropertiesID dst);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_CopyProperties(SDL_PropertiesID src, SDL_PropertiesID dst);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_LockProperties(SDL_PropertiesID props);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_LockProperties(SDL_PropertiesID props);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_UnlockProperties(SDL_PropertiesID props);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetPointerPropertyWithCleanup(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, [NativeTypeName("void*")] IntPtr value, [NativeTypeName("SDL_CleanupPropertyCallback")] delegate* unmanaged[Cdecl]<IntPtr, IntPtr, void> cleanup, [NativeTypeName("void*")] IntPtr userdata);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetPointerPropertyWithCleanup(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, [NativeTypeName("void*")] IntPtr value, [NativeTypeName("SDL_CleanupPropertyCallback")] delegate* unmanaged[Cdecl]<IntPtr, IntPtr, void> cleanup, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetPointerProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, [NativeTypeName("void*")] IntPtr value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetPointerProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, [NativeTypeName("void*")] IntPtr value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetStringProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetStringProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetNumberProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, [NativeTypeName("Sint64")] long value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetNumberProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, [NativeTypeName("Sint64")] long value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetFloatProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, float value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetFloatProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, float value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetBooleanProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, SDL_bool value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetBooleanProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, [NativeTypeName("bool")] byte value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_PropertyType SDL_GetPropertyType(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name);
|
||||
|
|
@ -95,13 +104,16 @@ namespace SDL
|
|||
public static extern float SDL_GetFloatProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, float default_value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetBooleanProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, SDL_bool default_value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetBooleanProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, [NativeTypeName("bool")] byte default_value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ClearProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ClearProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_EnumerateProperties(SDL_PropertiesID props, [NativeTypeName("SDL_EnumeratePropertiesCallback")] delegate* unmanaged[Cdecl]<IntPtr, SDL_PropertiesID, byte*, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_EnumerateProperties(SDL_PropertiesID props, [NativeTypeName("SDL_EnumeratePropertiesCallback")] delegate* unmanaged[Cdecl]<IntPtr, SDL_PropertiesID, byte*, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DestroyProperties(SDL_PropertiesID props);
|
||||
|
|
|
|||
|
|
@ -73,69 +73,79 @@ namespace SDL
|
|||
frect->h = (float)(rect->h);
|
||||
}
|
||||
|
||||
public static SDL_bool SDL_PointInRect([NativeTypeName("const SDL_Point *")] SDL_Point* p, [NativeTypeName("const SDL_Rect *")] SDL_Rect* r)
|
||||
public static bool SDL_PointInRect([NativeTypeName("const SDL_Point *")] SDL_Point* p, [NativeTypeName("const SDL_Rect *")] SDL_Rect* r)
|
||||
{
|
||||
return ((p) != null && (r) != null && (p->x >= r->x) && (p->x < (r->x + r->w)) && (p->y >= r->y) && (p->y < (r->y + r->h))) ? true : false;
|
||||
}
|
||||
|
||||
public static SDL_bool SDL_RectEmpty([NativeTypeName("const SDL_Rect *")] SDL_Rect* r)
|
||||
public static bool SDL_RectEmpty([NativeTypeName("const SDL_Rect *")] SDL_Rect* r)
|
||||
{
|
||||
return ((r == null) || (r->w <= 0) || (r->h <= 0)) ? true : false;
|
||||
}
|
||||
|
||||
public static SDL_bool SDL_RectsEqual([NativeTypeName("const SDL_Rect *")] SDL_Rect* a, [NativeTypeName("const SDL_Rect *")] SDL_Rect* b)
|
||||
public static bool SDL_RectsEqual([NativeTypeName("const SDL_Rect *")] SDL_Rect* a, [NativeTypeName("const SDL_Rect *")] SDL_Rect* b)
|
||||
{
|
||||
return ((a) != null && (b) != null && (a->x == b->x) && (a->y == b->y) && (a->w == b->w) && (a->h == b->h)) ? true : false;
|
||||
}
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasRectIntersection([NativeTypeName("const SDL_Rect *")] SDL_Rect* A, [NativeTypeName("const SDL_Rect *")] SDL_Rect* B);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasRectIntersection([NativeTypeName("const SDL_Rect *")] SDL_Rect* A, [NativeTypeName("const SDL_Rect *")] SDL_Rect* B);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRectIntersection([NativeTypeName("const SDL_Rect *")] SDL_Rect* A, [NativeTypeName("const SDL_Rect *")] SDL_Rect* B, SDL_Rect* result);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRectIntersection([NativeTypeName("const SDL_Rect *")] SDL_Rect* A, [NativeTypeName("const SDL_Rect *")] SDL_Rect* B, SDL_Rect* result);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRectUnion([NativeTypeName("const SDL_Rect *")] SDL_Rect* A, [NativeTypeName("const SDL_Rect *")] SDL_Rect* B, SDL_Rect* result);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRectUnion([NativeTypeName("const SDL_Rect *")] SDL_Rect* A, [NativeTypeName("const SDL_Rect *")] SDL_Rect* B, SDL_Rect* result);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRectEnclosingPoints([NativeTypeName("const SDL_Point *")] SDL_Point* points, int count, [NativeTypeName("const SDL_Rect *")] SDL_Rect* clip, SDL_Rect* result);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRectEnclosingPoints([NativeTypeName("const SDL_Point *")] SDL_Point* points, int count, [NativeTypeName("const SDL_Rect *")] SDL_Rect* clip, SDL_Rect* result);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRectAndLineIntersection([NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, int* X1, int* Y1, int* X2, int* Y2);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRectAndLineIntersection([NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, int* X1, int* Y1, int* X2, int* Y2);
|
||||
|
||||
public static SDL_bool SDL_PointInRectFloat([NativeTypeName("const SDL_FPoint *")] SDL_FPoint* p, [NativeTypeName("const SDL_FRect *")] SDL_FRect* r)
|
||||
public static bool SDL_PointInRectFloat([NativeTypeName("const SDL_FPoint *")] SDL_FPoint* p, [NativeTypeName("const SDL_FRect *")] SDL_FRect* r)
|
||||
{
|
||||
return ((p) != null && (r) != null && (p->x >= r->x) && (p->x <= (r->x + r->w)) && (p->y >= r->y) && (p->y <= (r->y + r->h))) ? true : false;
|
||||
}
|
||||
|
||||
public static SDL_bool SDL_RectEmptyFloat([NativeTypeName("const SDL_FRect *")] SDL_FRect* r)
|
||||
public static bool SDL_RectEmptyFloat([NativeTypeName("const SDL_FRect *")] SDL_FRect* r)
|
||||
{
|
||||
return ((r == null) || (r->w < 0.0f) || (r->h < 0.0f)) ? true : false;
|
||||
}
|
||||
|
||||
public static SDL_bool SDL_RectsEqualEpsilon([NativeTypeName("const SDL_FRect *")] SDL_FRect* a, [NativeTypeName("const SDL_FRect *")] SDL_FRect* b, [NativeTypeName("const float")] float epsilon)
|
||||
public static bool SDL_RectsEqualEpsilon([NativeTypeName("const SDL_FRect *")] SDL_FRect* a, [NativeTypeName("const SDL_FRect *")] SDL_FRect* b, [NativeTypeName("const float")] float epsilon)
|
||||
{
|
||||
return ((a) != null && (b) != null && ((a == b) || ((SDL_fabsf(a->x - b->x) <= epsilon) && (SDL_fabsf(a->y - b->y) <= epsilon) && (SDL_fabsf(a->w - b->w) <= epsilon) && (SDL_fabsf(a->h - b->h) <= epsilon)))) ? true : false;
|
||||
}
|
||||
|
||||
public static SDL_bool SDL_RectsEqualFloat([NativeTypeName("const SDL_FRect *")] SDL_FRect* a, [NativeTypeName("const SDL_FRect *")] SDL_FRect* b)
|
||||
public static bool SDL_RectsEqualFloat([NativeTypeName("const SDL_FRect *")] SDL_FRect* a, [NativeTypeName("const SDL_FRect *")] SDL_FRect* b)
|
||||
{
|
||||
return SDL_RectsEqualEpsilon(a, b, 1.1920928955078125e-07F);
|
||||
}
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasRectIntersectionFloat([NativeTypeName("const SDL_FRect *")] SDL_FRect* A, [NativeTypeName("const SDL_FRect *")] SDL_FRect* B);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HasRectIntersectionFloat([NativeTypeName("const SDL_FRect *")] SDL_FRect* A, [NativeTypeName("const SDL_FRect *")] SDL_FRect* B);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRectIntersectionFloat([NativeTypeName("const SDL_FRect *")] SDL_FRect* A, [NativeTypeName("const SDL_FRect *")] SDL_FRect* B, SDL_FRect* result);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRectIntersectionFloat([NativeTypeName("const SDL_FRect *")] SDL_FRect* A, [NativeTypeName("const SDL_FRect *")] SDL_FRect* B, SDL_FRect* result);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRectUnionFloat([NativeTypeName("const SDL_FRect *")] SDL_FRect* A, [NativeTypeName("const SDL_FRect *")] SDL_FRect* B, SDL_FRect* result);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRectUnionFloat([NativeTypeName("const SDL_FRect *")] SDL_FRect* A, [NativeTypeName("const SDL_FRect *")] SDL_FRect* B, SDL_FRect* result);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRectEnclosingPointsFloat([NativeTypeName("const SDL_FPoint *")] SDL_FPoint* points, int count, [NativeTypeName("const SDL_FRect *")] SDL_FRect* clip, SDL_FRect* result);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRectEnclosingPointsFloat([NativeTypeName("const SDL_FPoint *")] SDL_FPoint* points, int count, [NativeTypeName("const SDL_FRect *")] SDL_FRect* clip, SDL_FRect* result);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRectAndLineIntersectionFloat([NativeTypeName("const SDL_FRect *")] SDL_FRect* rect, float* X1, float* Y1, float* X2, float* Y2);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRectAndLineIntersectionFloat([NativeTypeName("const SDL_FRect *")] SDL_FRect* rect, float* X1, float* Y1, float* X2, float* Y2);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -71,7 +71,8 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetRenderDriver(int index);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_CreateWindowAndRenderer([NativeTypeName("const char *")] byte* title, int width, int height, SDL_WindowFlags window_flags, SDL_Window** window, SDL_Renderer** renderer);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_CreateWindowAndRenderer([NativeTypeName("const char *")] byte* title, int width, int height, SDL_WindowFlags window_flags, SDL_Window** window, SDL_Renderer** renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Renderer* SDL_CreateRenderer(SDL_Window* window, [NativeTypeName("const char *")] byte* name);
|
||||
|
|
@ -96,10 +97,12 @@ namespace SDL
|
|||
public static extern SDL_PropertiesID SDL_GetRendererProperties(SDL_Renderer* renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRenderOutputSize(SDL_Renderer* renderer, int* w, int* h);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRenderOutputSize(SDL_Renderer* renderer, int* w, int* h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetCurrentRenderOutputSize(SDL_Renderer* renderer, int* w, int* h);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetCurrentRenderOutputSize(SDL_Renderer* renderer, int* w, int* h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Texture* SDL_CreateTexture(SDL_Renderer* renderer, SDL_PixelFormat format, SDL_TextureAccess access, int w, int h);
|
||||
|
|
@ -117,187 +120,245 @@ namespace SDL
|
|||
public static extern SDL_Renderer* SDL_GetRendererFromTexture(SDL_Texture* texture);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetTextureSize(SDL_Texture* texture, float* w, float* h);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetTextureSize(SDL_Texture* texture, float* w, float* h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetTextureColorMod(SDL_Texture* texture, [NativeTypeName("Uint8")] byte r, [NativeTypeName("Uint8")] byte g, [NativeTypeName("Uint8")] byte b);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetTextureColorMod(SDL_Texture* texture, [NativeTypeName("Uint8")] byte r, [NativeTypeName("Uint8")] byte g, [NativeTypeName("Uint8")] byte b);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetTextureColorModFloat(SDL_Texture* texture, float r, float g, float b);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetTextureColorModFloat(SDL_Texture* texture, float r, float g, float b);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetTextureColorMod(SDL_Texture* texture, [NativeTypeName("Uint8 *")] byte* r, [NativeTypeName("Uint8 *")] byte* g, [NativeTypeName("Uint8 *")] byte* b);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetTextureColorMod(SDL_Texture* texture, [NativeTypeName("Uint8 *")] byte* r, [NativeTypeName("Uint8 *")] byte* g, [NativeTypeName("Uint8 *")] byte* b);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetTextureColorModFloat(SDL_Texture* texture, float* r, float* g, float* b);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetTextureColorModFloat(SDL_Texture* texture, float* r, float* g, float* b);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetTextureAlphaMod(SDL_Texture* texture, [NativeTypeName("Uint8")] byte alpha);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetTextureAlphaMod(SDL_Texture* texture, [NativeTypeName("Uint8")] byte alpha);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetTextureAlphaModFloat(SDL_Texture* texture, float alpha);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetTextureAlphaModFloat(SDL_Texture* texture, float alpha);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetTextureAlphaMod(SDL_Texture* texture, [NativeTypeName("Uint8 *")] byte* alpha);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetTextureAlphaMod(SDL_Texture* texture, [NativeTypeName("Uint8 *")] byte* alpha);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetTextureAlphaModFloat(SDL_Texture* texture, float* alpha);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetTextureAlphaModFloat(SDL_Texture* texture, float* alpha);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetTextureBlendMode(SDL_Texture* texture, SDL_BlendMode blendMode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetTextureBlendMode(SDL_Texture* texture, SDL_BlendMode blendMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetTextureBlendMode(SDL_Texture* texture, SDL_BlendMode* blendMode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetTextureBlendMode(SDL_Texture* texture, SDL_BlendMode* blendMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetTextureScaleMode(SDL_Texture* texture, SDL_ScaleMode scaleMode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetTextureScaleMode(SDL_Texture* texture, SDL_ScaleMode scaleMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetTextureScaleMode(SDL_Texture* texture, SDL_ScaleMode* scaleMode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetTextureScaleMode(SDL_Texture* texture, SDL_ScaleMode* scaleMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_UpdateTexture(SDL_Texture* texture, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, [NativeTypeName("const void *")] IntPtr pixels, int pitch);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_UpdateTexture(SDL_Texture* texture, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, [NativeTypeName("const void *")] IntPtr pixels, int pitch);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_UpdateYUVTexture(SDL_Texture* texture, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, [NativeTypeName("const Uint8 *")] byte* Yplane, int Ypitch, [NativeTypeName("const Uint8 *")] byte* Uplane, int Upitch, [NativeTypeName("const Uint8 *")] byte* Vplane, int Vpitch);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_UpdateYUVTexture(SDL_Texture* texture, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, [NativeTypeName("const Uint8 *")] byte* Yplane, int Ypitch, [NativeTypeName("const Uint8 *")] byte* Uplane, int Upitch, [NativeTypeName("const Uint8 *")] byte* Vplane, int Vpitch);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_UpdateNVTexture(SDL_Texture* texture, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, [NativeTypeName("const Uint8 *")] byte* Yplane, int Ypitch, [NativeTypeName("const Uint8 *")] byte* UVplane, int UVpitch);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_UpdateNVTexture(SDL_Texture* texture, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, [NativeTypeName("const Uint8 *")] byte* Yplane, int Ypitch, [NativeTypeName("const Uint8 *")] byte* UVplane, int UVpitch);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_LockTexture(SDL_Texture* texture, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, [NativeTypeName("void **")] IntPtr* pixels, int* pitch);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_LockTexture(SDL_Texture* texture, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, [NativeTypeName("void **")] IntPtr* pixels, int* pitch);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_LockTextureToSurface(SDL_Texture* texture, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, SDL_Surface** surface);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_LockTextureToSurface(SDL_Texture* texture, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, SDL_Surface** surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_UnlockTexture(SDL_Texture* texture);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetRenderTarget(SDL_Renderer* renderer, SDL_Texture* texture);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetRenderTarget(SDL_Renderer* renderer, SDL_Texture* texture);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Texture* SDL_GetRenderTarget(SDL_Renderer* renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetRenderLogicalPresentation(SDL_Renderer* renderer, int w, int h, SDL_RendererLogicalPresentation mode, SDL_ScaleMode scale_mode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetRenderLogicalPresentation(SDL_Renderer* renderer, int w, int h, SDL_RendererLogicalPresentation mode, SDL_ScaleMode scale_mode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRenderLogicalPresentation(SDL_Renderer* renderer, int* w, int* h, SDL_RendererLogicalPresentation* mode, SDL_ScaleMode* scale_mode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRenderLogicalPresentation(SDL_Renderer* renderer, int* w, int* h, SDL_RendererLogicalPresentation* mode, SDL_ScaleMode* scale_mode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRenderLogicalPresentationRect(SDL_Renderer* renderer, SDL_FRect* rect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRenderLogicalPresentationRect(SDL_Renderer* renderer, SDL_FRect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderCoordinatesFromWindow(SDL_Renderer* renderer, float window_x, float window_y, float* x, float* y);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderCoordinatesFromWindow(SDL_Renderer* renderer, float window_x, float window_y, float* x, float* y);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderCoordinatesToWindow(SDL_Renderer* renderer, float x, float y, float* window_x, float* window_y);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderCoordinatesToWindow(SDL_Renderer* renderer, float x, float y, float* window_x, float* window_y);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ConvertEventToRenderCoordinates(SDL_Renderer* renderer, SDL_Event* @event);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ConvertEventToRenderCoordinates(SDL_Renderer* renderer, SDL_Event* @event);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetRenderViewport(SDL_Renderer* renderer, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetRenderViewport(SDL_Renderer* renderer, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRenderViewport(SDL_Renderer* renderer, SDL_Rect* rect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRenderViewport(SDL_Renderer* renderer, SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderViewportSet(SDL_Renderer* renderer);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderViewportSet(SDL_Renderer* renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRenderSafeArea(SDL_Renderer* renderer, SDL_Rect* rect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRenderSafeArea(SDL_Renderer* renderer, SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetRenderClipRect(SDL_Renderer* renderer, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetRenderClipRect(SDL_Renderer* renderer, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRenderClipRect(SDL_Renderer* renderer, SDL_Rect* rect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRenderClipRect(SDL_Renderer* renderer, SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderClipEnabled(SDL_Renderer* renderer);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderClipEnabled(SDL_Renderer* renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetRenderScale(SDL_Renderer* renderer, float scaleX, float scaleY);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetRenderScale(SDL_Renderer* renderer, float scaleX, float scaleY);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRenderScale(SDL_Renderer* renderer, float* scaleX, float* scaleY);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRenderScale(SDL_Renderer* renderer, float* scaleX, float* scaleY);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetRenderDrawColor(SDL_Renderer* renderer, [NativeTypeName("Uint8")] byte r, [NativeTypeName("Uint8")] byte g, [NativeTypeName("Uint8")] byte b, [NativeTypeName("Uint8")] byte a);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetRenderDrawColor(SDL_Renderer* renderer, [NativeTypeName("Uint8")] byte r, [NativeTypeName("Uint8")] byte g, [NativeTypeName("Uint8")] byte b, [NativeTypeName("Uint8")] byte a);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetRenderDrawColorFloat(SDL_Renderer* renderer, float r, float g, float b, float a);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetRenderDrawColorFloat(SDL_Renderer* renderer, float r, float g, float b, float a);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRenderDrawColor(SDL_Renderer* renderer, [NativeTypeName("Uint8 *")] byte* r, [NativeTypeName("Uint8 *")] byte* g, [NativeTypeName("Uint8 *")] byte* b, [NativeTypeName("Uint8 *")] byte* a);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRenderDrawColor(SDL_Renderer* renderer, [NativeTypeName("Uint8 *")] byte* r, [NativeTypeName("Uint8 *")] byte* g, [NativeTypeName("Uint8 *")] byte* b, [NativeTypeName("Uint8 *")] byte* a);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRenderDrawColorFloat(SDL_Renderer* renderer, float* r, float* g, float* b, float* a);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRenderDrawColorFloat(SDL_Renderer* renderer, float* r, float* g, float* b, float* a);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetRenderColorScale(SDL_Renderer* renderer, float scale);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetRenderColorScale(SDL_Renderer* renderer, float scale);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRenderColorScale(SDL_Renderer* renderer, float* scale);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRenderColorScale(SDL_Renderer* renderer, float* scale);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetRenderDrawBlendMode(SDL_Renderer* renderer, SDL_BlendMode blendMode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetRenderDrawBlendMode(SDL_Renderer* renderer, SDL_BlendMode blendMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRenderDrawBlendMode(SDL_Renderer* renderer, SDL_BlendMode* blendMode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRenderDrawBlendMode(SDL_Renderer* renderer, SDL_BlendMode* blendMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderClear(SDL_Renderer* renderer);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderClear(SDL_Renderer* renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderPoint(SDL_Renderer* renderer, float x, float y);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderPoint(SDL_Renderer* renderer, float x, float y);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderPoints(SDL_Renderer* renderer, [NativeTypeName("const SDL_FPoint *")] SDL_FPoint* points, int count);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderPoints(SDL_Renderer* renderer, [NativeTypeName("const SDL_FPoint *")] SDL_FPoint* points, int count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderLine(SDL_Renderer* renderer, float x1, float y1, float x2, float y2);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderLine(SDL_Renderer* renderer, float x1, float y1, float x2, float y2);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderLines(SDL_Renderer* renderer, [NativeTypeName("const SDL_FPoint *")] SDL_FPoint* points, int count);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderLines(SDL_Renderer* renderer, [NativeTypeName("const SDL_FPoint *")] SDL_FPoint* points, int count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderRect(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderRect(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderRects(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rects, int count);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderRects(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rects, int count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderFillRect(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderFillRect(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderFillRects(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rects, int count);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderFillRects(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rects, int count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderTexture(SDL_Renderer* renderer, SDL_Texture* texture, [NativeTypeName("const SDL_FRect *")] SDL_FRect* srcrect, [NativeTypeName("const SDL_FRect *")] SDL_FRect* dstrect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderTexture(SDL_Renderer* renderer, SDL_Texture* texture, [NativeTypeName("const SDL_FRect *")] SDL_FRect* srcrect, [NativeTypeName("const SDL_FRect *")] SDL_FRect* dstrect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderTextureRotated(SDL_Renderer* renderer, SDL_Texture* texture, [NativeTypeName("const SDL_FRect *")] SDL_FRect* srcrect, [NativeTypeName("const SDL_FRect *")] SDL_FRect* dstrect, [NativeTypeName("const double")] double angle, [NativeTypeName("const SDL_FPoint *")] SDL_FPoint* center, [NativeTypeName("const SDL_FlipMode")] SDL_FlipMode flip);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderTextureRotated(SDL_Renderer* renderer, SDL_Texture* texture, [NativeTypeName("const SDL_FRect *")] SDL_FRect* srcrect, [NativeTypeName("const SDL_FRect *")] SDL_FRect* dstrect, [NativeTypeName("const double")] double angle, [NativeTypeName("const SDL_FPoint *")] SDL_FPoint* center, [NativeTypeName("const SDL_FlipMode")] SDL_FlipMode flip);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderTextureTiled(SDL_Renderer* renderer, SDL_Texture* texture, [NativeTypeName("const SDL_FRect *")] SDL_FRect* srcrect, float scale, [NativeTypeName("const SDL_FRect *")] SDL_FRect* dstrect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderTextureTiled(SDL_Renderer* renderer, SDL_Texture* texture, [NativeTypeName("const SDL_FRect *")] SDL_FRect* srcrect, float scale, [NativeTypeName("const SDL_FRect *")] SDL_FRect* dstrect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderTexture9Grid(SDL_Renderer* renderer, SDL_Texture* texture, [NativeTypeName("const SDL_FRect *")] SDL_FRect* srcrect, float left_width, float right_width, float top_height, float bottom_height, float scale, [NativeTypeName("const SDL_FRect *")] SDL_FRect* dstrect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderTexture9Grid(SDL_Renderer* renderer, SDL_Texture* texture, [NativeTypeName("const SDL_FRect *")] SDL_FRect* srcrect, float left_width, float right_width, float top_height, float bottom_height, float scale, [NativeTypeName("const SDL_FRect *")] SDL_FRect* dstrect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderGeometry(SDL_Renderer* renderer, SDL_Texture* texture, [NativeTypeName("const SDL_Vertex *")] SDL_Vertex* vertices, int num_vertices, [NativeTypeName("const int *")] int* indices, int num_indices);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderGeometry(SDL_Renderer* renderer, SDL_Texture* texture, [NativeTypeName("const SDL_Vertex *")] SDL_Vertex* vertices, int num_vertices, [NativeTypeName("const int *")] int* indices, int num_indices);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderGeometryRaw(SDL_Renderer* renderer, SDL_Texture* texture, [NativeTypeName("const float *")] float* xy, int xy_stride, [NativeTypeName("const SDL_FColor *")] SDL_FColor* color, int color_stride, [NativeTypeName("const float *")] float* uv, int uv_stride, int num_vertices, [NativeTypeName("const void *")] IntPtr indices, int num_indices, int size_indices);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderGeometryRaw(SDL_Renderer* renderer, SDL_Texture* texture, [NativeTypeName("const float *")] float* xy, int xy_stride, [NativeTypeName("const SDL_FColor *")] SDL_FColor* color, int color_stride, [NativeTypeName("const float *")] float* uv, int uv_stride, int num_vertices, [NativeTypeName("const void *")] IntPtr indices, int num_indices, int size_indices);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Surface* SDL_RenderReadPixels(SDL_Renderer* renderer, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenderPresent(SDL_Renderer* renderer);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenderPresent(SDL_Renderer* renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DestroyTexture(SDL_Texture* texture);
|
||||
|
|
@ -306,7 +367,8 @@ namespace SDL
|
|||
public static extern void SDL_DestroyRenderer(SDL_Renderer* renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_FlushRenderer(SDL_Renderer* renderer);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_FlushRenderer(SDL_Renderer* renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("void*")]
|
||||
|
|
@ -317,13 +379,16 @@ namespace SDL
|
|||
public static extern IntPtr SDL_GetRenderMetalCommandEncoder(SDL_Renderer* renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_AddVulkanRenderSemaphores(SDL_Renderer* renderer, [NativeTypeName("Uint32")] uint wait_stage_mask, [NativeTypeName("Sint64")] long wait_semaphore, [NativeTypeName("Sint64")] long signal_semaphore);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_AddVulkanRenderSemaphores(SDL_Renderer* renderer, [NativeTypeName("Uint32")] uint wait_stage_mask, [NativeTypeName("Sint64")] long wait_semaphore, [NativeTypeName("Sint64")] long signal_semaphore);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetRenderVSync(SDL_Renderer* renderer, int vsync);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetRenderVSync(SDL_Renderer* renderer, int vsync);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRenderVSync(SDL_Renderer* renderer, int* vsync);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetRenderVSync(SDL_Renderer* renderer, int* vsync);
|
||||
|
||||
[NativeTypeName("#define SDL_SOFTWARE_RENDERER \"software\"")]
|
||||
public static ReadOnlySpan<byte> SDL_SOFTWARE_RENDERER => "software"u8;
|
||||
|
|
|
|||
|
|
@ -81,7 +81,8 @@ namespace SDL
|
|||
public static extern SDL_SensorID SDL_GetSensorID(SDL_Sensor* sensor);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetSensorData(SDL_Sensor* sensor, float* data, int num_values);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetSensorData(SDL_Sensor* sensor, float* data, int num_values);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_CloseSensor(SDL_Sensor* sensor);
|
||||
|
|
|
|||
|
|
@ -74,7 +74,8 @@ namespace SDL
|
|||
public static extern void SDL_GetMemoryFunctions([NativeTypeName("SDL_malloc_func *")] delegate* unmanaged[Cdecl]<nuint, IntPtr>* malloc_func, [NativeTypeName("SDL_calloc_func *")] delegate* unmanaged[Cdecl]<nuint, nuint, IntPtr>* calloc_func, [NativeTypeName("SDL_realloc_func *")] delegate* unmanaged[Cdecl]<IntPtr, nuint, IntPtr>* realloc_func, [NativeTypeName("SDL_free_func *")] delegate* unmanaged[Cdecl]<IntPtr, void>* free_func);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetMemoryFunctions([NativeTypeName("SDL_malloc_func")] delegate* unmanaged[Cdecl]<nuint, IntPtr> malloc_func, [NativeTypeName("SDL_calloc_func")] delegate* unmanaged[Cdecl]<nuint, nuint, IntPtr> calloc_func, [NativeTypeName("SDL_realloc_func")] delegate* unmanaged[Cdecl]<IntPtr, nuint, IntPtr> realloc_func, [NativeTypeName("SDL_free_func")] delegate* unmanaged[Cdecl]<IntPtr, void> free_func);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetMemoryFunctions([NativeTypeName("SDL_malloc_func")] delegate* unmanaged[Cdecl]<nuint, IntPtr> malloc_func, [NativeTypeName("SDL_calloc_func")] delegate* unmanaged[Cdecl]<nuint, nuint, IntPtr> calloc_func, [NativeTypeName("SDL_realloc_func")] delegate* unmanaged[Cdecl]<IntPtr, nuint, IntPtr> realloc_func, [NativeTypeName("SDL_free_func")] delegate* unmanaged[Cdecl]<IntPtr, void> free_func);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("void*")]
|
||||
|
|
@ -90,10 +91,7 @@ namespace SDL
|
|||
public static extern SDL_Environment* SDL_GetEnvironment();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_CleanupEnvironment();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Environment* SDL_CreateEnvironment(SDL_bool populated);
|
||||
public static extern SDL_Environment* SDL_CreateEnvironment([NativeTypeName("bool")] byte populated);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_GetEnvironmentVariable", ExactSpelling = true)]
|
||||
[return: NativeTypeName("const char *")]
|
||||
|
|
@ -104,14 +102,20 @@ namespace SDL
|
|||
public static extern byte** SDL_GetEnvironmentVariables(SDL_Environment* env);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetEnvironmentVariable(SDL_Environment* env, [NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value, SDL_bool overwrite);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetEnvironmentVariable(SDL_Environment* env, [NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value, [NativeTypeName("bool")] byte overwrite);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_UnsetEnvironmentVariable(SDL_Environment* env, [NativeTypeName("const char *")] byte* name);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_UnsetEnvironmentVariable(SDL_Environment* env, [NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DestroyEnvironment(SDL_Environment* env);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_getenv", ExactSpelling = true)]
|
||||
[return: NativeTypeName("const char *")]
|
||||
public static extern byte* Unsafe_SDL_getenv([NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_getenv_unsafe", ExactSpelling = true)]
|
||||
[return: NativeTypeName("const char *")]
|
||||
public static extern byte* Unsafe_SDL_getenv_unsafe([NativeTypeName("const char *")] byte* name);
|
||||
|
|
@ -607,7 +611,7 @@ namespace SDL
|
|||
[return: NativeTypeName("char *")]
|
||||
public static extern byte* Unsafe_SDL_iconv_string([NativeTypeName("const char *")] byte* tocode, [NativeTypeName("const char *")] byte* fromcode, [NativeTypeName("const char *")] byte* inbuf, [NativeTypeName("size_t")] nuint inbytesleft);
|
||||
|
||||
public static SDL_bool SDL_size_mul_check_overflow([NativeTypeName("size_t")] nuint a, [NativeTypeName("size_t")] nuint b, [NativeTypeName("size_t *")] nuint* ret)
|
||||
public static bool SDL_size_mul_check_overflow([NativeTypeName("size_t")] nuint a, [NativeTypeName("size_t")] nuint b, [NativeTypeName("size_t *")] nuint* ret)
|
||||
{
|
||||
if (a != 0 && b > 0xffffffffffffffffUL / a)
|
||||
{
|
||||
|
|
@ -618,7 +622,7 @@ namespace SDL
|
|||
return true;
|
||||
}
|
||||
|
||||
public static SDL_bool SDL_size_add_check_overflow([NativeTypeName("size_t")] nuint a, [NativeTypeName("size_t")] nuint b, [NativeTypeName("size_t *")] nuint* ret)
|
||||
public static bool SDL_size_add_check_overflow([NativeTypeName("size_t")] nuint a, [NativeTypeName("size_t")] nuint b, [NativeTypeName("size_t *")] nuint* ret)
|
||||
{
|
||||
if (b > 0xffffffffffffffffUL - a)
|
||||
{
|
||||
|
|
@ -632,12 +636,6 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_SIZE_MAX SIZE_MAX")]
|
||||
public const ulong SDL_SIZE_MAX = 0xffffffffffffffffUL;
|
||||
|
||||
[NativeTypeName("#define SDL_FALSE false")]
|
||||
public const bool SDL_FALSE = false;
|
||||
|
||||
[NativeTypeName("#define SDL_TRUE true")]
|
||||
public const bool SDL_TRUE = true;
|
||||
|
||||
[NativeTypeName("#define SDL_MAX_SINT8 ((Sint8)0x7F)")]
|
||||
public const sbyte SDL_MAX_SINT8 = ((sbyte)(0x7F));
|
||||
|
||||
|
|
@ -719,6 +717,21 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_PRIX32 \"X\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PRIX32 => "X"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PRILL_PREFIX \"ll\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PRILL_PREFIX => "ll"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PRILLd SDL_PRILL_PREFIX \"d\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PRILLd => "lld"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PRILLu SDL_PRILL_PREFIX \"u\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PRILLu => "llu"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PRILLx SDL_PRILL_PREFIX \"x\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PRILLx => "llx"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PRILLX SDL_PRILL_PREFIX \"X\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PRILLX => "llX"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_INVALID_UNICODE_CODEPOINT 0xFFFD")]
|
||||
public const int SDL_INVALID_UNICODE_CODEPOINT = 0xFFFD;
|
||||
|
||||
|
|
|
|||
|
|
@ -33,35 +33,35 @@ namespace SDL
|
|||
[NativeTypeName("Uint32")]
|
||||
public uint version;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, SDL_bool> close;
|
||||
[NativeTypeName("bool (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte> close;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, SDL_bool> ready;
|
||||
[NativeTypeName("bool (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte> ready;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *, const char *, SDL_EnumerateDirectoryCallback, void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, int>, IntPtr, SDL_bool> enumerate;
|
||||
[NativeTypeName("bool (*)(void *, const char *, SDL_EnumerateDirectoryCallback, void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, int>, IntPtr, byte> enumerate;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *, const char *, SDL_PathInfo *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, SDL_PathInfo*, SDL_bool> info;
|
||||
[NativeTypeName("bool (*)(void *, const char *, SDL_PathInfo *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, SDL_PathInfo*, byte> info;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *, const char *, void *, Uint64)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, IntPtr, ulong, SDL_bool> read_file;
|
||||
[NativeTypeName("bool (*)(void *, const char *, void *, Uint64)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, IntPtr, ulong, byte> read_file;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *, const char *, const void *, Uint64)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, IntPtr, ulong, SDL_bool> write_file;
|
||||
[NativeTypeName("bool (*)(void *, const char *, const void *, Uint64)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, IntPtr, ulong, byte> write_file;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, SDL_bool> mkdir;
|
||||
[NativeTypeName("bool (*)(void *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, byte> mkdir;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, SDL_bool> remove;
|
||||
[NativeTypeName("bool (*)(void *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, byte> remove;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *, const char *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, SDL_bool> rename;
|
||||
[NativeTypeName("bool (*)(void *, const char *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, byte> rename;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *, const char *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, SDL_bool> copy;
|
||||
[NativeTypeName("bool (*)(void *, const char *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, byte> copy;
|
||||
|
||||
[NativeTypeName("Uint64 (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, ulong> space_remaining;
|
||||
|
|
@ -86,37 +86,48 @@ namespace SDL
|
|||
public static extern SDL_Storage* SDL_OpenStorage([NativeTypeName("const SDL_StorageInterface *")] SDL_StorageInterface* iface, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_CloseStorage(SDL_Storage* storage);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_CloseStorage(SDL_Storage* storage);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_StorageReady(SDL_Storage* storage);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_StorageReady(SDL_Storage* storage);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetStorageFileSize(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, [NativeTypeName("Uint64 *")] ulong* length);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetStorageFileSize(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, [NativeTypeName("Uint64 *")] ulong* length);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadStorageFile(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, [NativeTypeName("void*")] IntPtr destination, [NativeTypeName("Uint64")] ulong length);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadStorageFile(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, [NativeTypeName("void*")] IntPtr destination, [NativeTypeName("Uint64")] ulong length);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteStorageFile(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, [NativeTypeName("const void *")] IntPtr source, [NativeTypeName("Uint64")] ulong length);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteStorageFile(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, [NativeTypeName("const void *")] IntPtr source, [NativeTypeName("Uint64")] ulong length);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_CreateStorageDirectory(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_CreateStorageDirectory(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_EnumerateStorageDirectory(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, [NativeTypeName("SDL_EnumerateDirectoryCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, int> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_EnumerateStorageDirectory(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, [NativeTypeName("SDL_EnumerateDirectoryCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, int> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RemoveStoragePath(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RemoveStoragePath(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RenameStoragePath(SDL_Storage* storage, [NativeTypeName("const char *")] byte* oldpath, [NativeTypeName("const char *")] byte* newpath);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RenameStoragePath(SDL_Storage* storage, [NativeTypeName("const char *")] byte* oldpath, [NativeTypeName("const char *")] byte* newpath);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_CopyStorageFile(SDL_Storage* storage, [NativeTypeName("const char *")] byte* oldpath, [NativeTypeName("const char *")] byte* newpath);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_CopyStorageFile(SDL_Storage* storage, [NativeTypeName("const char *")] byte* oldpath, [NativeTypeName("const char *")] byte* newpath);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetStoragePathInfo(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, SDL_PathInfo* info);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetStoragePathInfo(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, SDL_PathInfo* info);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Uint64")]
|
||||
|
|
|
|||
|
|
@ -80,7 +80,8 @@ namespace SDL
|
|||
public static extern SDL_PropertiesID SDL_GetSurfaceProperties(SDL_Surface* surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetSurfaceColorspace(SDL_Surface* surface, SDL_Colorspace colorspace);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetSurfaceColorspace(SDL_Surface* surface, SDL_Colorspace colorspace);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Colorspace SDL_GetSurfaceColorspace(SDL_Surface* surface);
|
||||
|
|
@ -89,16 +90,19 @@ namespace SDL
|
|||
public static extern SDL_Palette* SDL_CreateSurfacePalette(SDL_Surface* surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetSurfacePalette(SDL_Surface* surface, SDL_Palette* palette);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetSurfacePalette(SDL_Surface* surface, SDL_Palette* palette);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Palette* SDL_GetSurfacePalette(SDL_Surface* surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_AddSurfaceAlternateImage(SDL_Surface* surface, SDL_Surface* image);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_AddSurfaceAlternateImage(SDL_Surface* surface, SDL_Surface* image);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SurfaceHasAlternateImages(SDL_Surface* surface);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SurfaceHasAlternateImages(SDL_Surface* surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Surface** SDL_GetSurfaceImages(SDL_Surface* surface, int* count);
|
||||
|
|
@ -107,64 +111,81 @@ namespace SDL
|
|||
public static extern void SDL_RemoveSurfaceAlternateImages(SDL_Surface* surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_LockSurface(SDL_Surface* surface);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_LockSurface(SDL_Surface* surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_UnlockSurface(SDL_Surface* surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Surface* SDL_LoadBMP_IO(SDL_IOStream* src, SDL_bool closeio);
|
||||
public static extern SDL_Surface* SDL_LoadBMP_IO(SDL_IOStream* src, [NativeTypeName("bool")] byte closeio);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Surface* SDL_LoadBMP([NativeTypeName("const char *")] byte* file);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SaveBMP_IO(SDL_Surface* surface, SDL_IOStream* dst, SDL_bool closeio);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SaveBMP_IO(SDL_Surface* surface, SDL_IOStream* dst, [NativeTypeName("bool")] byte closeio);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SaveBMP(SDL_Surface* surface, [NativeTypeName("const char *")] byte* file);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SaveBMP(SDL_Surface* surface, [NativeTypeName("const char *")] byte* file);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetSurfaceRLE(SDL_Surface* surface, SDL_bool enabled);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetSurfaceRLE(SDL_Surface* surface, [NativeTypeName("bool")] byte enabled);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SurfaceHasRLE(SDL_Surface* surface);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SurfaceHasRLE(SDL_Surface* surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetSurfaceColorKey(SDL_Surface* surface, SDL_bool enabled, [NativeTypeName("Uint32")] uint key);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetSurfaceColorKey(SDL_Surface* surface, [NativeTypeName("bool")] byte enabled, [NativeTypeName("Uint32")] uint key);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SurfaceHasColorKey(SDL_Surface* surface);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SurfaceHasColorKey(SDL_Surface* surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetSurfaceColorKey(SDL_Surface* surface, [NativeTypeName("Uint32 *")] uint* key);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetSurfaceColorKey(SDL_Surface* surface, [NativeTypeName("Uint32 *")] uint* key);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetSurfaceColorMod(SDL_Surface* surface, [NativeTypeName("Uint8")] byte r, [NativeTypeName("Uint8")] byte g, [NativeTypeName("Uint8")] byte b);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetSurfaceColorMod(SDL_Surface* surface, [NativeTypeName("Uint8")] byte r, [NativeTypeName("Uint8")] byte g, [NativeTypeName("Uint8")] byte b);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetSurfaceColorMod(SDL_Surface* surface, [NativeTypeName("Uint8 *")] byte* r, [NativeTypeName("Uint8 *")] byte* g, [NativeTypeName("Uint8 *")] byte* b);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetSurfaceColorMod(SDL_Surface* surface, [NativeTypeName("Uint8 *")] byte* r, [NativeTypeName("Uint8 *")] byte* g, [NativeTypeName("Uint8 *")] byte* b);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetSurfaceAlphaMod(SDL_Surface* surface, [NativeTypeName("Uint8")] byte alpha);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetSurfaceAlphaMod(SDL_Surface* surface, [NativeTypeName("Uint8")] byte alpha);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetSurfaceAlphaMod(SDL_Surface* surface, [NativeTypeName("Uint8 *")] byte* alpha);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetSurfaceAlphaMod(SDL_Surface* surface, [NativeTypeName("Uint8 *")] byte* alpha);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetSurfaceBlendMode(SDL_Surface* surface, SDL_BlendMode blendMode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetSurfaceBlendMode(SDL_Surface* surface, SDL_BlendMode blendMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetSurfaceBlendMode(SDL_Surface* surface, SDL_BlendMode* blendMode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetSurfaceBlendMode(SDL_Surface* surface, SDL_BlendMode* blendMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetSurfaceClipRect(SDL_Surface* surface, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetSurfaceClipRect(SDL_Surface* surface, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetSurfaceClipRect(SDL_Surface* surface, SDL_Rect* rect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetSurfaceClipRect(SDL_Surface* surface, SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_FlipSurface(SDL_Surface* surface, SDL_FlipMode flip);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_FlipSurface(SDL_Surface* surface, SDL_FlipMode flip);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Surface* SDL_DuplicateSurface(SDL_Surface* surface);
|
||||
|
|
@ -179,46 +200,60 @@ namespace SDL
|
|||
public static extern SDL_Surface* SDL_ConvertSurfaceAndColorspace(SDL_Surface* surface, SDL_PixelFormat format, SDL_Palette* palette, SDL_Colorspace colorspace, SDL_PropertiesID props);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ConvertPixels(int width, int height, SDL_PixelFormat src_format, [NativeTypeName("const void *")] IntPtr src, int src_pitch, SDL_PixelFormat dst_format, [NativeTypeName("void*")] IntPtr dst, int dst_pitch);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ConvertPixels(int width, int height, SDL_PixelFormat src_format, [NativeTypeName("const void *")] IntPtr src, int src_pitch, SDL_PixelFormat dst_format, [NativeTypeName("void*")] IntPtr dst, int dst_pitch);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ConvertPixelsAndColorspace(int width, int height, SDL_PixelFormat src_format, SDL_Colorspace src_colorspace, SDL_PropertiesID src_properties, [NativeTypeName("const void *")] IntPtr src, int src_pitch, SDL_PixelFormat dst_format, SDL_Colorspace dst_colorspace, SDL_PropertiesID dst_properties, [NativeTypeName("void*")] IntPtr dst, int dst_pitch);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ConvertPixelsAndColorspace(int width, int height, SDL_PixelFormat src_format, SDL_Colorspace src_colorspace, SDL_PropertiesID src_properties, [NativeTypeName("const void *")] IntPtr src, int src_pitch, SDL_PixelFormat dst_format, SDL_Colorspace dst_colorspace, SDL_PropertiesID dst_properties, [NativeTypeName("void*")] IntPtr dst, int dst_pitch);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_PremultiplyAlpha(int width, int height, SDL_PixelFormat src_format, [NativeTypeName("const void *")] IntPtr src, int src_pitch, SDL_PixelFormat dst_format, [NativeTypeName("void*")] IntPtr dst, int dst_pitch, SDL_bool linear);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_PremultiplyAlpha(int width, int height, SDL_PixelFormat src_format, [NativeTypeName("const void *")] IntPtr src, int src_pitch, SDL_PixelFormat dst_format, [NativeTypeName("void*")] IntPtr dst, int dst_pitch, [NativeTypeName("bool")] byte linear);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_PremultiplySurfaceAlpha(SDL_Surface* surface, SDL_bool linear);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_PremultiplySurfaceAlpha(SDL_Surface* surface, [NativeTypeName("bool")] byte linear);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ClearSurface(SDL_Surface* surface, float r, float g, float b, float a);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ClearSurface(SDL_Surface* surface, float r, float g, float b, float a);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_FillSurfaceRect(SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, [NativeTypeName("Uint32")] uint color);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_FillSurfaceRect(SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, [NativeTypeName("Uint32")] uint color);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_FillSurfaceRects(SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rects, int count, [NativeTypeName("Uint32")] uint color);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_FillSurfaceRects(SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rects, int count, [NativeTypeName("Uint32")] uint color);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_BlitSurface(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_BlitSurface(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_BlitSurfaceUnchecked(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_BlitSurfaceUnchecked(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_BlitSurfaceScaled(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect, SDL_ScaleMode scaleMode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_BlitSurfaceScaled(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect, SDL_ScaleMode scaleMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_BlitSurfaceUncheckedScaled(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect, SDL_ScaleMode scaleMode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_BlitSurfaceUncheckedScaled(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect, SDL_ScaleMode scaleMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_BlitSurfaceTiled(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_BlitSurfaceTiled(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_BlitSurfaceTiledWithScale(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, float scale, SDL_ScaleMode scaleMode, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_BlitSurfaceTiledWithScale(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, float scale, SDL_ScaleMode scaleMode, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_BlitSurface9Grid(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, int left_width, int right_width, int top_height, int bottom_height, float scale, SDL_ScaleMode scaleMode, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_BlitSurface9Grid(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, int left_width, int right_width, int top_height, int bottom_height, float scale, SDL_ScaleMode scaleMode, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Uint32")]
|
||||
|
|
@ -229,16 +264,20 @@ namespace SDL
|
|||
public static extern uint SDL_MapSurfaceRGBA(SDL_Surface* surface, [NativeTypeName("Uint8")] byte r, [NativeTypeName("Uint8")] byte g, [NativeTypeName("Uint8")] byte b, [NativeTypeName("Uint8")] byte a);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadSurfacePixel(SDL_Surface* surface, int x, int y, [NativeTypeName("Uint8 *")] byte* r, [NativeTypeName("Uint8 *")] byte* g, [NativeTypeName("Uint8 *")] byte* b, [NativeTypeName("Uint8 *")] byte* a);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadSurfacePixel(SDL_Surface* surface, int x, int y, [NativeTypeName("Uint8 *")] byte* r, [NativeTypeName("Uint8 *")] byte* g, [NativeTypeName("Uint8 *")] byte* b, [NativeTypeName("Uint8 *")] byte* a);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ReadSurfacePixelFloat(SDL_Surface* surface, int x, int y, float* r, float* g, float* b, float* a);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ReadSurfacePixelFloat(SDL_Surface* surface, int x, int y, float* r, float* g, float* b, float* a);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteSurfacePixel(SDL_Surface* surface, int x, int y, [NativeTypeName("Uint8")] byte r, [NativeTypeName("Uint8")] byte g, [NativeTypeName("Uint8")] byte b, [NativeTypeName("Uint8")] byte a);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteSurfacePixel(SDL_Surface* surface, int x, int y, [NativeTypeName("Uint8")] byte r, [NativeTypeName("Uint8")] byte g, [NativeTypeName("Uint8")] byte b, [NativeTypeName("Uint8")] byte a);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WriteSurfacePixelFloat(SDL_Surface* surface, int x, int y, float r, float g, float b, float a);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WriteSurfacePixelFloat(SDL_Surface* surface, int x, int y, float r, float g, float b, float a);
|
||||
|
||||
[NativeTypeName("#define SDL_SURFACE_PREALLOCATED 0x00000001u")]
|
||||
public const uint SDL_SURFACE_PREALLOCATED = 0x00000001U;
|
||||
|
|
|
|||
|
|
@ -46,16 +46,19 @@ namespace SDL
|
|||
public static extern int SDL_GetAndroidSDKVersion();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("bool")]
|
||||
[SupportedOSPlatform("Android")]
|
||||
public static extern SDL_bool SDL_IsAndroidTV();
|
||||
public static extern byte SDL_IsAndroidTV();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("bool")]
|
||||
[SupportedOSPlatform("Android")]
|
||||
public static extern SDL_bool SDL_IsChromebook();
|
||||
public static extern byte SDL_IsChromebook();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("bool")]
|
||||
[SupportedOSPlatform("Android")]
|
||||
public static extern SDL_bool SDL_IsDeXMode();
|
||||
public static extern byte SDL_IsDeXMode();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Android")]
|
||||
|
|
@ -82,16 +85,19 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetAndroidCachePath();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("bool")]
|
||||
[SupportedOSPlatform("Android")]
|
||||
public static extern SDL_bool SDL_RequestAndroidPermission([NativeTypeName("const char *")] byte* permission, [NativeTypeName("SDL_RequestAndroidPermissionCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte*, SDL_bool, void> cb, [NativeTypeName("void*")] IntPtr userdata);
|
||||
public static extern byte SDL_RequestAndroidPermission([NativeTypeName("const char *")] byte* permission, [NativeTypeName("SDL_RequestAndroidPermissionCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte*, byte, void> cb, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("bool")]
|
||||
[SupportedOSPlatform("Android")]
|
||||
public static extern SDL_bool SDL_ShowAndroidToast([NativeTypeName("const char *")] byte* message, int duration, int gravity, int xoffset, int yoffset);
|
||||
public static extern byte SDL_ShowAndroidToast([NativeTypeName("const char *")] byte* message, int duration, int gravity, int xoffset, int yoffset);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("bool")]
|
||||
[SupportedOSPlatform("Android")]
|
||||
public static extern SDL_bool SDL_SendAndroidMessage([NativeTypeName("Uint32")] uint command, int param1);
|
||||
public static extern byte SDL_SendAndroidMessage([NativeTypeName("Uint32")] uint command, int param1);
|
||||
|
||||
[NativeTypeName("#define SDL_ANDROID_EXTERNAL_STORAGE_READ 0x01")]
|
||||
public const int SDL_ANDROID_EXTERNAL_STORAGE_READ = 0x01;
|
||||
|
|
|
|||
|
|
@ -39,11 +39,13 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("bool")]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
public static extern SDL_bool SDL_GetGDKTaskQueue([NativeTypeName("XTaskQueueHandle *")] XTaskQueueObject** outTaskQueue);
|
||||
public static extern byte SDL_GetGDKTaskQueue([NativeTypeName("XTaskQueueHandle *")] XTaskQueueObject** outTaskQueue);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("bool")]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
public static extern SDL_bool SDL_GetGDKDefaultUser([NativeTypeName("XUserHandle *")] XUser** outUserHandle);
|
||||
public static extern byte SDL_GetGDKDefaultUser([NativeTypeName("XUserHandle *")] XUser** outUserHandle);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -31,11 +31,13 @@ namespace SDL
|
|||
public static partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("bool")]
|
||||
[SupportedOSPlatform("Linux")]
|
||||
public static extern SDL_bool SDL_SetLinuxThreadPriority([NativeTypeName("Sint64")] long threadID, int priority);
|
||||
public static extern byte SDL_SetLinuxThreadPriority([NativeTypeName("Sint64")] long threadID, int priority);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("bool")]
|
||||
[SupportedOSPlatform("Linux")]
|
||||
public static extern SDL_bool SDL_SetLinuxThreadPriorityAndPolicy([NativeTypeName("Sint64")] long threadID, int sdlPriority, int schedPolicy);
|
||||
public static extern byte SDL_SetLinuxThreadPriorityAndPolicy([NativeTypeName("Sint64")] long threadID, int sdlPriority, int schedPolicy);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -33,14 +33,15 @@ namespace SDL
|
|||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
public static extern void SDL_SetWindowsMessageHook([NativeTypeName("SDL_WindowsMessageHook")] delegate* unmanaged[Cdecl]<IntPtr, MSG*, SDL_bool> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
public static extern void SDL_SetWindowsMessageHook([NativeTypeName("SDL_WindowsMessageHook")] delegate* unmanaged[Cdecl]<IntPtr, MSG*, byte> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
public static extern int SDL_GetDirect3D9AdapterIndex(SDL_DisplayID displayID);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("bool")]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
public static extern SDL_bool SDL_GetDXGIOutputInfo(SDL_DisplayID displayID, int* adapterIndex, int* outputIndex);
|
||||
public static extern byte SDL_GetDXGIOutputInfo(SDL_DisplayID displayID, int* adapterIndex, int* outputIndex);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -31,10 +31,11 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_SetX11EventHook([NativeTypeName("SDL_X11EventHook")] delegate* unmanaged[Cdecl]<IntPtr, IntPtr, SDL_bool> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
public static extern void SDL_SetX11EventHook([NativeTypeName("SDL_X11EventHook")] delegate* unmanaged[Cdecl]<IntPtr, IntPtr, byte> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_IsTablet();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_IsTablet();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_OnApplicationWillTerminate();
|
||||
|
|
|
|||
|
|
@ -32,12 +32,13 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("bool")]
|
||||
[SupportedOSPlatform("iOS")]
|
||||
public static extern SDL_bool SDL_SetiOSAnimationCallback(SDL_Window* window, int interval, [NativeTypeName("SDL_iOSAnimationCallback")] delegate* unmanaged[Cdecl]<IntPtr, void> callback, [NativeTypeName("void*")] IntPtr callbackParam);
|
||||
public static extern byte SDL_SetiOSAnimationCallback(SDL_Window* window, int interval, [NativeTypeName("SDL_iOSAnimationCallback")] delegate* unmanaged[Cdecl]<IntPtr, void> callback, [NativeTypeName("void*")] IntPtr callbackParam);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("iOS")]
|
||||
public static extern void SDL_SetiOSEventPump(SDL_bool enabled);
|
||||
public static extern void SDL_SetiOSEventPump([NativeTypeName("bool")] byte enabled);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("iOS")]
|
||||
|
|
|
|||
|
|
@ -59,7 +59,8 @@ namespace SDL
|
|||
public static extern SDL_ThreadID SDL_GetThreadID(SDL_Thread* thread);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetThreadPriority(SDL_ThreadPriority priority);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetThreadPriority(SDL_ThreadPriority priority);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_WaitThread(SDL_Thread* thread, int* status);
|
||||
|
|
@ -72,7 +73,8 @@ namespace SDL
|
|||
public static extern IntPtr SDL_GetTLS(SDL_TLSID* id);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetTLS(SDL_TLSID* id, [NativeTypeName("const void *")] IntPtr value, [NativeTypeName("SDL_TLSDestructorCallback")] delegate* unmanaged[Cdecl]<IntPtr, void> destructor);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetTLS(SDL_TLSID* id, [NativeTypeName("const void *")] IntPtr value, [NativeTypeName("SDL_TLSDestructorCallback")] delegate* unmanaged[Cdecl]<IntPtr, void> destructor);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_CleanupTLS();
|
||||
|
|
|
|||
|
|
@ -64,16 +64,20 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetDateTimeLocalePreferences(SDL_DateFormat* dateFormat, SDL_TimeFormat* timeFormat);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetDateTimeLocalePreferences(SDL_DateFormat* dateFormat, SDL_TimeFormat* timeFormat);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetCurrentTime(SDL_Time* ticks);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetCurrentTime(SDL_Time* ticks);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_TimeToDateTime(SDL_Time ticks, SDL_DateTime* dt, SDL_bool localTime);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_TimeToDateTime(SDL_Time ticks, SDL_DateTime* dt, [NativeTypeName("bool")] byte localTime);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_DateTimeToTime([NativeTypeName("const SDL_DateTime *")] SDL_DateTime* dt, SDL_Time* ticks);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_DateTimeToTime([NativeTypeName("const SDL_DateTime *")] SDL_DateTime* dt, SDL_Time* ticks);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_TimeToWindows(SDL_Time ticks, [NativeTypeName("Uint32 *")] uint* dwLowDateTime, [NativeTypeName("Uint32 *")] uint* dwHighDateTime);
|
||||
|
|
|
|||
|
|
@ -59,7 +59,8 @@ namespace SDL
|
|||
public static extern SDL_TimerID SDL_AddTimerNS([NativeTypeName("Uint64")] ulong interval, [NativeTypeName("SDL_NSTimerCallback")] delegate* unmanaged[Cdecl]<IntPtr, SDL_TimerID, ulong, ulong> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RemoveTimer(SDL_TimerID id);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RemoveTimer(SDL_TimerID id);
|
||||
|
||||
[NativeTypeName("#define SDL_MS_PER_SECOND 1000")]
|
||||
public const int SDL_MS_PER_SECOND = 1000;
|
||||
|
|
|
|||
|
|
@ -187,10 +187,12 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetDisplayName(SDL_DisplayID displayID);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetDisplayBounds(SDL_DisplayID displayID, SDL_Rect* rect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetDisplayBounds(SDL_DisplayID displayID, SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetDisplayUsableBounds(SDL_DisplayID displayID, SDL_Rect* rect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetDisplayUsableBounds(SDL_DisplayID displayID, SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_DisplayOrientation SDL_GetNaturalDisplayOrientation(SDL_DisplayID displayID);
|
||||
|
|
@ -205,7 +207,8 @@ namespace SDL
|
|||
public static extern SDL_DisplayMode** SDL_GetFullscreenDisplayModes(SDL_DisplayID displayID, int* count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetClosestFullscreenDisplayMode(SDL_DisplayID displayID, int w, int h, float refresh_rate, SDL_bool include_high_density_modes, SDL_DisplayMode* mode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetClosestFullscreenDisplayMode(SDL_DisplayID displayID, int w, int h, float refresh_rate, [NativeTypeName("bool")] byte include_high_density_modes, SDL_DisplayMode* mode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("const SDL_DisplayMode *")]
|
||||
|
|
@ -231,7 +234,8 @@ namespace SDL
|
|||
public static extern float SDL_GetWindowDisplayScale(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowFullscreenMode(SDL_Window* window, [NativeTypeName("const SDL_DisplayMode *")] SDL_DisplayMode* mode);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowFullscreenMode(SDL_Window* window, [NativeTypeName("const SDL_DisplayMode *")] SDL_DisplayMode* mode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("const SDL_DisplayMode *")]
|
||||
|
|
@ -272,171 +276,220 @@ namespace SDL
|
|||
public static extern SDL_WindowFlags SDL_GetWindowFlags(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowTitle(SDL_Window* window, [NativeTypeName("const char *")] byte* title);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowTitle(SDL_Window* window, [NativeTypeName("const char *")] byte* title);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_GetWindowTitle", ExactSpelling = true)]
|
||||
[return: NativeTypeName("const char *")]
|
||||
public static extern byte* Unsafe_SDL_GetWindowTitle(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowIcon(SDL_Window* window, SDL_Surface* icon);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowIcon(SDL_Window* window, SDL_Surface* icon);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowPosition(SDL_Window* window, int x, int y);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowPosition(SDL_Window* window, int x, int y);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetWindowPosition(SDL_Window* window, int* x, int* y);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetWindowPosition(SDL_Window* window, int* x, int* y);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowSize(SDL_Window* window, int w, int h);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowSize(SDL_Window* window, int w, int h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetWindowSize(SDL_Window* window, int* w, int* h);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetWindowSize(SDL_Window* window, int* w, int* h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetWindowSafeArea(SDL_Window* window, SDL_Rect* rect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetWindowSafeArea(SDL_Window* window, SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowAspectRatio(SDL_Window* window, float min_aspect, float max_aspect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowAspectRatio(SDL_Window* window, float min_aspect, float max_aspect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetWindowAspectRatio(SDL_Window* window, float* min_aspect, float* max_aspect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetWindowAspectRatio(SDL_Window* window, float* min_aspect, float* max_aspect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetWindowBordersSize(SDL_Window* window, int* top, int* left, int* bottom, int* right);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetWindowBordersSize(SDL_Window* window, int* top, int* left, int* bottom, int* right);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetWindowSizeInPixels(SDL_Window* window, int* w, int* h);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetWindowSizeInPixels(SDL_Window* window, int* w, int* h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowMinimumSize(SDL_Window* window, int min_w, int min_h);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowMinimumSize(SDL_Window* window, int min_w, int min_h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetWindowMinimumSize(SDL_Window* window, int* w, int* h);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetWindowMinimumSize(SDL_Window* window, int* w, int* h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowMaximumSize(SDL_Window* window, int max_w, int max_h);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowMaximumSize(SDL_Window* window, int max_w, int max_h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetWindowMaximumSize(SDL_Window* window, int* w, int* h);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetWindowMaximumSize(SDL_Window* window, int* w, int* h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowBordered(SDL_Window* window, SDL_bool bordered);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowBordered(SDL_Window* window, [NativeTypeName("bool")] byte bordered);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowResizable(SDL_Window* window, SDL_bool resizable);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowResizable(SDL_Window* window, [NativeTypeName("bool")] byte resizable);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowAlwaysOnTop(SDL_Window* window, SDL_bool on_top);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowAlwaysOnTop(SDL_Window* window, [NativeTypeName("bool")] byte on_top);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ShowWindow(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ShowWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HideWindow(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_HideWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RaiseWindow(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RaiseWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_MaximizeWindow(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_MaximizeWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_MinimizeWindow(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_MinimizeWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_RestoreWindow(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_RestoreWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowFullscreen(SDL_Window* window, SDL_bool fullscreen);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowFullscreen(SDL_Window* window, [NativeTypeName("bool")] byte fullscreen);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SyncWindow(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SyncWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WindowHasSurface(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_WindowHasSurface(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Surface* SDL_GetWindowSurface(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowSurfaceVSync(SDL_Window* window, int vsync);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowSurfaceVSync(SDL_Window* window, int vsync);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetWindowSurfaceVSync(SDL_Window* window, int* vsync);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetWindowSurfaceVSync(SDL_Window* window, int* vsync);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_UpdateWindowSurface(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_UpdateWindowSurface(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_UpdateWindowSurfaceRects(SDL_Window* window, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rects, int numrects);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_UpdateWindowSurfaceRects(SDL_Window* window, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rects, int numrects);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_DestroyWindowSurface(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_DestroyWindowSurface(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowKeyboardGrab(SDL_Window* window, SDL_bool grabbed);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowKeyboardGrab(SDL_Window* window, [NativeTypeName("bool")] byte grabbed);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowMouseGrab(SDL_Window* window, SDL_bool grabbed);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowMouseGrab(SDL_Window* window, [NativeTypeName("bool")] byte grabbed);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetWindowKeyboardGrab(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetWindowKeyboardGrab(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetWindowMouseGrab(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GetWindowMouseGrab(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Window* SDL_GetGrabbedWindow();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowMouseRect(SDL_Window* window, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowMouseRect(SDL_Window* window, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("const SDL_Rect *")]
|
||||
public static extern SDL_Rect* SDL_GetWindowMouseRect(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowOpacity(SDL_Window* window, float opacity);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowOpacity(SDL_Window* window, float opacity);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern float SDL_GetWindowOpacity(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowParent(SDL_Window* window, SDL_Window* parent);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowParent(SDL_Window* window, SDL_Window* parent);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowModal(SDL_Window* window, SDL_bool modal);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowModal(SDL_Window* window, [NativeTypeName("bool")] byte modal);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowFocusable(SDL_Window* window, SDL_bool focusable);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowFocusable(SDL_Window* window, [NativeTypeName("bool")] byte focusable);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ShowWindowSystemMenu(SDL_Window* window, int x, int y);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ShowWindowSystemMenu(SDL_Window* window, int x, int y);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowHitTest(SDL_Window* window, [NativeTypeName("SDL_HitTest")] delegate* unmanaged[Cdecl]<SDL_Window*, SDL_Point*, IntPtr, SDL_HitTestResult> callback, [NativeTypeName("void*")] IntPtr callback_data);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowHitTest(SDL_Window* window, [NativeTypeName("SDL_HitTest")] delegate* unmanaged[Cdecl]<SDL_Window*, SDL_Point*, IntPtr, SDL_HitTestResult> callback, [NativeTypeName("void*")] IntPtr callback_data);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SetWindowShape(SDL_Window* window, SDL_Surface* shape);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_SetWindowShape(SDL_Window* window, SDL_Surface* shape);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_FlashWindow(SDL_Window* window, SDL_FlashOperation operation);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_FlashWindow(SDL_Window* window, SDL_FlashOperation operation);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DestroyWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_ScreenSaverEnabled();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_ScreenSaverEnabled();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_EnableScreenSaver();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_EnableScreenSaver();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_DisableScreenSaver();
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_DisableScreenSaver();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GL_LoadLibrary([NativeTypeName("const char *")] byte* path);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GL_LoadLibrary([NativeTypeName("const char *")] byte* path);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("SDL_FunctionPointer")]
|
||||
|
|
@ -450,23 +503,27 @@ namespace SDL
|
|||
public static extern void SDL_GL_UnloadLibrary();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GL_ExtensionSupported([NativeTypeName("const char *")] byte* extension);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GL_ExtensionSupported([NativeTypeName("const char *")] byte* extension);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_GL_ResetAttributes();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GL_SetAttribute(SDL_GLattr attr, int value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GL_SetAttribute(SDL_GLattr attr, int value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GL_GetAttribute(SDL_GLattr attr, int* value);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GL_GetAttribute(SDL_GLattr attr, int* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("SDL_GLContext")]
|
||||
public static extern SDL_GLContextState* SDL_GL_CreateContext(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GL_MakeCurrent(SDL_Window* window, [NativeTypeName("SDL_GLContext")] SDL_GLContextState* context);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GL_MakeCurrent(SDL_Window* window, [NativeTypeName("SDL_GLContext")] SDL_GLContextState* context);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Window* SDL_GL_GetCurrentWindow();
|
||||
|
|
@ -491,16 +548,20 @@ namespace SDL
|
|||
public static extern void SDL_EGL_SetAttributeCallbacks([NativeTypeName("SDL_EGLAttribArrayCallback")] delegate* unmanaged[Cdecl]<nint*> platformAttribCallback, [NativeTypeName("SDL_EGLIntArrayCallback")] delegate* unmanaged[Cdecl]<int*> surfaceAttribCallback, [NativeTypeName("SDL_EGLIntArrayCallback")] delegate* unmanaged[Cdecl]<int*> contextAttribCallback);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GL_SetSwapInterval(int interval);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GL_SetSwapInterval(int interval);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GL_GetSwapInterval(int* interval);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GL_GetSwapInterval(int* interval);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GL_SwapWindow(SDL_Window* window);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GL_SwapWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GL_DestroyContext([NativeTypeName("SDL_GLContext")] SDL_GLContextState* context);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_GL_DestroyContext([NativeTypeName("SDL_GLContext")] SDL_GLContextState* context);
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_GLOBAL_VIDEO_WAYLAND_WL_DISPLAY_POINTER \"SDL.video.wayland.wl_display\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_GLOBAL_VIDEO_WAYLAND_WL_DISPLAY_POINTER => "SDL.video.wayland.wl_display"u8;
|
||||
|
|
|
|||
|
|
@ -47,7 +47,8 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_Vulkan_LoadLibrary([NativeTypeName("const char *")] byte* path);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_Vulkan_LoadLibrary([NativeTypeName("const char *")] byte* path);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("SDL_FunctionPointer")]
|
||||
|
|
@ -61,12 +62,14 @@ namespace SDL
|
|||
public static extern byte** SDL_Vulkan_GetInstanceExtensions([NativeTypeName("Uint32 *")] uint* count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_Vulkan_CreateSurface(SDL_Window* window, [NativeTypeName("VkInstance")] VkInstance_T* instance, [NativeTypeName("const struct VkAllocationCallbacks *")] VkAllocationCallbacks* allocator, [NativeTypeName("VkSurfaceKHR *")] VkSurfaceKHR_T** surface);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_Vulkan_CreateSurface(SDL_Window* window, [NativeTypeName("VkInstance")] VkInstance_T* instance, [NativeTypeName("const struct VkAllocationCallbacks *")] VkAllocationCallbacks* allocator, [NativeTypeName("VkSurfaceKHR *")] VkSurfaceKHR_T** surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_Vulkan_DestroySurface([NativeTypeName("VkInstance")] VkInstance_T* instance, [NativeTypeName("VkSurfaceKHR")] VkSurfaceKHR_T* surface, [NativeTypeName("const struct VkAllocationCallbacks *")] VkAllocationCallbacks* allocator);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_Vulkan_GetPresentationSupport([NativeTypeName("VkInstance")] VkInstance_T* instance, [NativeTypeName("VkPhysicalDevice")] VkPhysicalDevice_T* physicalDevice, [NativeTypeName("Uint32")] uint queueFamilyIndex);
|
||||
[return: NativeTypeName("bool")]
|
||||
public static extern byte SDL_Vulkan_GetPresentationSupport([NativeTypeName("VkInstance")] VkInstance_T* instance, [NativeTypeName("VkPhysicalDevice")] VkPhysicalDevice_T* physicalDevice, [NativeTypeName("Uint32")] uint queueFamilyIndex);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,9 +6,9 @@ namespace SDL
|
|||
public unsafe partial class SDL3
|
||||
{
|
||||
[Macro]
|
||||
public static int SDL_AtomicIncRef(SDL_AtomicInt* a) => SDL_AtomicAdd(a, 1);
|
||||
public static int SDL_AtomicIncRef(SDL_AtomicInt* a) => SDL_AddAtomicInt(a, 1);
|
||||
|
||||
[Macro]
|
||||
public static bool SDL_AtomicDecRef(SDL_AtomicInt* a) => SDL_AtomicAdd(a, -1) == 1;
|
||||
public static bool SDL_AtomicDecRef(SDL_AtomicInt* a) => SDL_AddAtomicInt(a, -1) == 1;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,7 +9,6 @@ namespace SDL
|
|||
[Typedef]
|
||||
public enum SDL_InitFlags : UInt32
|
||||
{
|
||||
SDL_INIT_TIMER = SDL3.SDL_INIT_TIMER,
|
||||
SDL_INIT_AUDIO = SDL3.SDL_INIT_AUDIO,
|
||||
SDL_INIT_VIDEO = SDL3.SDL_INIT_VIDEO,
|
||||
SDL_INIT_JOYSTICK = SDL3.SDL_INIT_JOYSTICK,
|
||||
|
|
|
|||
Loading…
Reference in New Issue