mirror of https://github.com/ppy/SDL3-CS.git
Merge pull request #129 from hwsmm/update
Update bindings 3 (no merging needed)
This commit is contained in:
commit
833814cf25
|
|
@ -22,24 +22,20 @@ namespace SDL.Tests
|
|||
SDL3.SDL_EnterAppMainCallbacks(0, (byte**)objectHandle.Handle, &AppInit, &AppIterate, &AppEvent, &AppQuit);
|
||||
}
|
||||
|
||||
protected virtual int Init()
|
||||
protected virtual SDL_AppResult Init()
|
||||
{
|
||||
SDL3.SDL_SetLogPriorities(SDL_LogPriority.SDL_LOG_PRIORITY_VERBOSE);
|
||||
SDL3.SDL_SetLogOutputFunction(&LogOutput, IntPtr.Zero);
|
||||
return CONTINUE;
|
||||
return SDL_AppResult.SDL_APP_CONTINUE;
|
||||
}
|
||||
|
||||
protected const int TERMINATE_ERROR = -1;
|
||||
protected const int CONTINUE = 0;
|
||||
protected const int TERMINATE_SUCCESS = 1;
|
||||
|
||||
protected virtual int Iterate()
|
||||
protected virtual SDL_AppResult Iterate()
|
||||
{
|
||||
Thread.Sleep(10);
|
||||
return CONTINUE;
|
||||
return SDL_AppResult.SDL_APP_CONTINUE;
|
||||
}
|
||||
|
||||
protected virtual int Event(SDL_Event e)
|
||||
protected virtual SDL_AppResult Event(SDL_Event e)
|
||||
{
|
||||
switch (e.Type)
|
||||
{
|
||||
|
|
@ -47,10 +43,10 @@ namespace SDL.Tests
|
|||
case SDL_EventType.SDL_EVENT_WINDOW_CLOSE_REQUESTED:
|
||||
case SDL_EventType.SDL_EVENT_TERMINATING:
|
||||
case SDL_EventType.SDL_EVENT_KEY_DOWN when e.key.key == SDL_Keycode.SDLK_ESCAPE:
|
||||
return TERMINATE_SUCCESS;
|
||||
return SDL_AppResult.SDL_APP_SUCCESS;
|
||||
}
|
||||
|
||||
return CONTINUE;
|
||||
return SDL_AppResult.SDL_APP_CONTINUE;
|
||||
}
|
||||
|
||||
protected virtual void Quit()
|
||||
|
|
@ -64,7 +60,7 @@ namespace SDL.Tests
|
|||
}
|
||||
|
||||
[UnmanagedCallersOnly(CallConvs = [typeof(CallConvCdecl)])]
|
||||
private static int AppInit(IntPtr* appState, int argc, byte** argv)
|
||||
private static SDL_AppResult AppInit(IntPtr* appState, int argc, byte** argv)
|
||||
{
|
||||
IntPtr handle = (IntPtr)argv;
|
||||
*appState = handle;
|
||||
|
|
@ -73,27 +69,27 @@ namespace SDL.Tests
|
|||
if (objectHandle.GetTarget(out var target))
|
||||
return target.Init();
|
||||
|
||||
return TERMINATE_ERROR;
|
||||
return SDL_AppResult.SDL_APP_FAILURE;
|
||||
}
|
||||
|
||||
[UnmanagedCallersOnly(CallConvs = [typeof(CallConvCdecl)])]
|
||||
private static int AppIterate(IntPtr appState)
|
||||
private static SDL_AppResult AppIterate(IntPtr appState)
|
||||
{
|
||||
var objectHandle = new ObjectHandle<MainCallbacksTest>(appState, true);
|
||||
if (objectHandle.GetTarget(out var target))
|
||||
return target.Iterate();
|
||||
|
||||
return TERMINATE_ERROR;
|
||||
return SDL_AppResult.SDL_APP_FAILURE;
|
||||
}
|
||||
|
||||
[UnmanagedCallersOnly(CallConvs = [typeof(CallConvCdecl)])]
|
||||
private static int AppEvent(IntPtr appState, SDL_Event* e)
|
||||
private static SDL_AppResult AppEvent(IntPtr appState, SDL_Event* e)
|
||||
{
|
||||
var objectHandle = new ObjectHandle<MainCallbacksTest>(appState, true);
|
||||
if (objectHandle.GetTarget(out var target))
|
||||
return target.Event(*e);
|
||||
|
||||
return TERMINATE_ERROR;
|
||||
return SDL_AppResult.SDL_APP_FAILURE;
|
||||
}
|
||||
|
||||
[UnmanagedCallersOnly(CallConvs = [typeof(CallConvCdecl)])]
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ namespace SDL.Tests
|
|||
|
||||
public MyWindow()
|
||||
{
|
||||
if (SDL_InitSubSystem(init_flags) < 0)
|
||||
if (SDL_InitSubSystem(init_flags) == SDL_bool.SDL_FALSE)
|
||||
throw new InvalidOperationException($"failed to initialise SDL. Error: {SDL_GetError()}");
|
||||
|
||||
initSuccess = true;
|
||||
|
|
@ -51,18 +51,18 @@ namespace SDL.Tests
|
|||
|
||||
// ReSharper disable once UseCollectionExpression
|
||||
[UnmanagedCallersOnly(CallConvs = new[] { typeof(CallConvCdecl) })]
|
||||
private static int nativeFilter(IntPtr userdata, SDL_Event* e)
|
||||
private static SDL_bool nativeFilter(IntPtr userdata, SDL_Event* e)
|
||||
{
|
||||
var handle = new ObjectHandle<MyWindow>(userdata);
|
||||
if (handle.GetTarget(out var window))
|
||||
return window.handleEventFromFilter(e);
|
||||
|
||||
return 1;
|
||||
return SDL_bool.SDL_TRUE;
|
||||
}
|
||||
|
||||
public Action<SDL_Event>? EventFilter;
|
||||
|
||||
private int handleEventFromFilter(SDL_Event* e)
|
||||
private SDL_bool handleEventFromFilter(SDL_Event* e)
|
||||
{
|
||||
switch (e->Type)
|
||||
{
|
||||
|
|
@ -76,7 +76,7 @@ namespace SDL.Tests
|
|||
break;
|
||||
}
|
||||
|
||||
return 1;
|
||||
return SDL_bool.SDL_TRUE;
|
||||
}
|
||||
|
||||
private void handleKeyFromFilter(SDL_KeyboardEvent e)
|
||||
|
|
@ -105,8 +105,8 @@ namespace SDL.Tests
|
|||
switch (e.key.key)
|
||||
{
|
||||
case SDL_Keycode.SDLK_R:
|
||||
bool old = SDL_GetRelativeMouseMode() == SDL_bool.SDL_TRUE;
|
||||
SDL_SetRelativeMouseMode(old ? SDL_bool.SDL_FALSE : SDL_bool.SDL_TRUE);
|
||||
bool old = SDL_GetWindowRelativeMouseMode(sdlWindowHandle) == SDL_bool.SDL_TRUE;
|
||||
SDL_SetWindowRelativeMouseMode(sdlWindowHandle, old ? SDL_bool.SDL_FALSE : SDL_bool.SDL_TRUE);
|
||||
break;
|
||||
|
||||
case SDL_Keycode.SDLK_V:
|
||||
|
|
@ -170,14 +170,8 @@ namespace SDL.Tests
|
|||
Console.WriteLine($"gamepad added: {e.gdevice.which}");
|
||||
break;
|
||||
|
||||
case SDL_EventType.SDL_EVENT_WINDOW_PEN_ENTER:
|
||||
SDL_PenCapabilityInfo info;
|
||||
var cap = SDL_GetPenCapabilities((SDL_PenID)e.window.data1, &info);
|
||||
|
||||
if (cap.HasFlag(SDL_PenCapabilityFlags.SDL_PEN_AXIS_XTILT_MASK))
|
||||
Console.WriteLine("has pen xtilt axis");
|
||||
|
||||
Console.WriteLine(info.max_tilt);
|
||||
case SDL_EventType.SDL_EVENT_PEN_PROXIMITY_IN:
|
||||
Console.WriteLine($"pen proximity in: {e.pproximity.which}");
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -14,6 +14,9 @@ namespace SDL.Tests
|
|||
if (OperatingSystem.IsWindows())
|
||||
Console.OutputEncoding = Encoding.UTF8;
|
||||
|
||||
Console.WriteLine($"SDL_FALSE is represented as 0x{SDL_OutOfMemory():X} (expected 0x{SDL_bool.SDL_FALSE:X})");
|
||||
Console.WriteLine($"SDL_TRUE is represented as 0x{SDL_ClearError():X} (expected 0x{SDL_bool.SDL_TRUE:X})");
|
||||
|
||||
SDL_SetHint(SDL_HINT_WINDOWS_CLOSE_ON_ALT_F4, "null byte \0 in string"u8);
|
||||
Debug.Assert(SDL_GetHint(SDL_HINT_WINDOWS_CLOSE_ON_ALT_F4) == "null byte ");
|
||||
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ namespace SDL.Tests
|
|||
[Test]
|
||||
public unsafe void TestClipboardData()
|
||||
{
|
||||
int ret = SDL3.SDL_SetClipboardData(&dataCallback, &cleanupCallback, IntPtr.Zero, "test/one", "test/two");
|
||||
var ret = SDL3.SDL_SetClipboardData(&dataCallback, &cleanupCallback, IntPtr.Zero, "test/one", "test/two");
|
||||
Assert.That(ret, Is.EqualTo(0), SDL3.SDL_GetError);
|
||||
|
||||
Assert.That(SDL3.SDL_HasClipboardData("test/one"), Is.EqualTo(SDL_bool.SDL_TRUE));
|
||||
|
|
@ -46,7 +46,7 @@ namespace SDL.Tests
|
|||
}
|
||||
|
||||
ret = SDL3.SDL_ClearClipboardData();
|
||||
Assert.That(ret, Is.EqualTo(0), SDL3.SDL_GetError);
|
||||
Assert.That(ret, Is.EqualTo(SDL_bool.SDL_TRUE), SDL3.SDL_GetError);
|
||||
|
||||
Assert.That(cleanups, Is.EqualTo(1));
|
||||
|
||||
|
|
|
|||
|
|
@ -11,12 +11,11 @@ namespace SDL.Tests
|
|||
private SDL_Window* window;
|
||||
private SDL_Renderer* renderer;
|
||||
|
||||
protected override int Init()
|
||||
protected override SDL_AppResult Init()
|
||||
{
|
||||
// decouple pen, mouse and touch events
|
||||
SDL_SetHint(SDL_HINT_MOUSE_TOUCH_EVENTS, "0");
|
||||
SDL_SetHint(SDL_HINT_TOUCH_MOUSE_EVENTS, "0");
|
||||
SDL_SetHint(SDL_HINT_PEN_NOT_MOUSE, "2");
|
||||
|
||||
SDL_Init(SDL_InitFlags.SDL_INIT_VIDEO);
|
||||
|
||||
|
|
@ -48,7 +47,7 @@ namespace SDL.Tests
|
|||
SDL_RenderFillRect(renderer, &r);
|
||||
}
|
||||
|
||||
protected override int Iterate()
|
||||
protected override SDL_AppResult Iterate()
|
||||
{
|
||||
const float gray = 0.1f;
|
||||
SDL_SetRenderDrawColorFloat(renderer, gray, gray, gray, 1.0f);
|
||||
|
|
@ -86,7 +85,7 @@ namespace SDL.Tests
|
|||
return base.Iterate();
|
||||
}
|
||||
|
||||
protected override int Event(SDL_Event e)
|
||||
protected override SDL_AppResult Event(SDL_Event e)
|
||||
{
|
||||
SDL_ConvertEventToRenderCoordinates(renderer, &e);
|
||||
|
||||
|
|
@ -117,7 +116,7 @@ namespace SDL.Tests
|
|||
switch (e.key.key)
|
||||
{
|
||||
case SDL_Keycode.SDLK_R:
|
||||
SDL_SetRelativeMouseMode(SDL_GetRelativeMouseMode() == SDL_bool.SDL_TRUE ? SDL_bool.SDL_FALSE : SDL_bool.SDL_TRUE);
|
||||
SDL_SetWindowRelativeMouseMode(window, SDL_GetWindowRelativeMouseMode(window) == SDL_bool.SDL_TRUE ? SDL_bool.SDL_FALSE : SDL_bool.SDL_TRUE);
|
||||
break;
|
||||
|
||||
case SDL_Keycode.SDLK_F:
|
||||
|
|
|
|||
|
|
@ -0,0 +1,39 @@
|
|||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||
// See the LICENCE file in the repository root for full licence text.
|
||||
|
||||
using NUnit.Framework;
|
||||
|
||||
namespace SDL.Tests
|
||||
{
|
||||
[TestFixture]
|
||||
public class TestSDLBool
|
||||
{
|
||||
private SDL_bool invert(SDL_bool value) => value == SDL_bool.SDL_TRUE ? SDL_bool.SDL_FALSE : SDL_bool.SDL_TRUE;
|
||||
|
||||
[Test]
|
||||
public void TestFalse()
|
||||
{
|
||||
Assert.That(SDL3.SDL_OutOfMemory(), Is.EqualTo(SDL_bool.SDL_FALSE));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void TestTrue()
|
||||
{
|
||||
Assert.That(SDL3.SDL_ClearError(), Is.EqualTo(SDL_bool.SDL_TRUE));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void TestStoreLoad([Values] SDL_bool value)
|
||||
{
|
||||
var props = SDL3.SDL_CreateProperties();
|
||||
Assume.That(props, Is.Not.EqualTo(0));
|
||||
|
||||
var ret = SDL3.SDL_SetBooleanProperty(props, "test", value);
|
||||
Assume.That(ret, Is.EqualTo(SDL_bool.SDL_TRUE));
|
||||
|
||||
Assert.That(SDL3.SDL_GetBooleanProperty(props, "test", invert(value)), Is.EqualTo(value));
|
||||
|
||||
SDL3.SDL_DestroyProperties(props);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -785,5 +785,6 @@ See the LICENCE file in the repository root for full licence text.
|
|||
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ECSharpKeepExistingMigration/@EntryIndexedValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ECSharpPlaceEmbeddedOnSameLineMigration/@EntryIndexedValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ECSharpUseContinuousIndentInsideBracesMigration/@EntryIndexedValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002EMemberReordering_002EMigrations_002ECSharpFileLayoutPatternRemoveIsAttributeUpgrade/@EntryIndexedValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ESettingsUpgrade_002EMigrateBlankLinesAroundFieldToBlankLinesAroundProperty/@EntryIndexedValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ESettingsUpgrade_002EPredefinedNamingRulesToUserRulesUpgrade/@EntryIndexedValue">True</s:Boolean></wpf:ResourceDictionary>
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
diff --git a/include/SDL3/SDL.h b/include/SDL3/SDL.h
|
||||
index 6cda579f7..bc2952a4e 100644
|
||||
index 4e18f6382..d737c7a9a 100644
|
||||
--- a/include/SDL3/SDL.h
|
||||
+++ b/include/SDL3/SDL.h
|
||||
@@ -28,6 +28,8 @@
|
||||
|
|
@ -12,10 +12,10 @@ index 6cda579f7..bc2952a4e 100644
|
|||
#include <SDL3/SDL_assert.h>
|
||||
#include <SDL3/SDL_atomic.h>
|
||||
diff --git a/include/SDL3/SDL_log.h b/include/SDL3/SDL_log.h
|
||||
index 3ded311ff..42760135f 100644
|
||||
index 3c0e80f38..44f58add3 100644
|
||||
--- a/include/SDL3/SDL_log.h
|
||||
+++ b/include/SDL3/SDL_log.h
|
||||
@@ -372,7 +372,7 @@ extern DECLSPEC void SDLCALL SDL_LogMessageV(int category,
|
||||
@@ -407,7 +407,7 @@ extern SDL_DECLSPEC void SDLCALL SDL_LogMessageV(int category,
|
||||
*
|
||||
* \since This datatype is available since SDL 3.0.0.
|
||||
*/
|
||||
|
|
@ -25,28 +25,24 @@ index 3ded311ff..42760135f 100644
|
|||
/**
|
||||
* Get the current log output function.
|
||||
diff --git a/include/SDL3/SDL_stdinc.h b/include/SDL3/SDL_stdinc.h
|
||||
index 00a54a139..847b50ecb 100644
|
||||
index 5539f2a81..3155f3f31 100644
|
||||
--- a/include/SDL3/SDL_stdinc.h
|
||||
+++ b/include/SDL3/SDL_stdinc.h
|
||||
@@ -146,7 +146,7 @@ void *alloca(size_t);
|
||||
@@ -194,7 +194,7 @@ void *alloca(size_t);
|
||||
*
|
||||
* \sa SDL_bool
|
||||
*/
|
||||
-#define SDL_FALSE 0
|
||||
-#define SDL_FALSE false
|
||||
+#define SDL_FALSE (SDL_bool)0
|
||||
|
||||
/**
|
||||
* A boolean true.
|
||||
@@ -155,7 +155,7 @@ void *alloca(size_t);
|
||||
@@ -203,7 +203,7 @@ void *alloca(size_t);
|
||||
*
|
||||
* \sa SDL_bool
|
||||
*/
|
||||
-#define SDL_TRUE 1
|
||||
-#define SDL_TRUE true
|
||||
+#define SDL_TRUE (SDL_bool)1
|
||||
|
||||
/**
|
||||
* A boolean type: true or false.
|
||||
|
||||
base-commit: 0429f5d6a36fc35b551bcc2acd4a40c2db6dab82
|
||||
--
|
||||
2.40.0.windows.1
|
||||
|
|
|
|||
|
|
@ -67,10 +67,10 @@ namespace SDL
|
|||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("void*")]
|
||||
public static extern IntPtr SDL_AtomicSetPtr([NativeTypeName("void **")] IntPtr* a, [NativeTypeName("void*")] IntPtr v);
|
||||
public static extern IntPtr SDL_AtomicSetPointer([NativeTypeName("void **")] IntPtr* a, [NativeTypeName("void*")] IntPtr v);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("void*")]
|
||||
public static extern IntPtr SDL_AtomicGetPtr([NativeTypeName("void **")] IntPtr* a);
|
||||
public static extern IntPtr SDL_AtomicGetPointer([NativeTypeName("void **")] IntPtr* a);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -31,6 +31,7 @@ namespace SDL
|
|||
[NativeTypeName("int")]
|
||||
public enum SDL_AudioFormat : uint
|
||||
{
|
||||
SDL_AUDIO_UNKNOWN = 0x0000U,
|
||||
SDL_AUDIO_U8 = 0x0008U,
|
||||
SDL_AUDIO_S8 = 0x8008U,
|
||||
SDL_AUDIO_S16LE = 0x8010U,
|
||||
|
|
@ -78,7 +79,7 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetAudioDeviceName(SDL_AudioDeviceID devid);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetAudioDeviceFormat(SDL_AudioDeviceID devid, SDL_AudioSpec* spec, int* sample_frames);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
@ -87,10 +88,10 @@ 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 int SDL_PauseAudioDevice(SDL_AudioDeviceID dev);
|
||||
public static extern SDL_bool SDL_PauseAudioDevice(SDL_AudioDeviceID dev);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ResumeAudioDevice(SDL_AudioDeviceID dev);
|
||||
public static extern SDL_bool SDL_ResumeAudioDevice(SDL_AudioDeviceID dev);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_AudioDevicePaused(SDL_AudioDeviceID dev);
|
||||
|
|
@ -99,16 +100,16 @@ namespace SDL
|
|||
public static extern float SDL_GetAudioDeviceGain(SDL_AudioDeviceID devid);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetAudioDeviceGain(SDL_AudioDeviceID devid, float gain);
|
||||
public static extern SDL_bool 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 int SDL_BindAudioStreams(SDL_AudioDeviceID devid, SDL_AudioStream** streams, int num_streams);
|
||||
public static extern SDL_bool SDL_BindAudioStreams(SDL_AudioDeviceID devid, SDL_AudioStream** streams, int num_streams);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_BindAudioStream(SDL_AudioDeviceID devid, SDL_AudioStream* stream);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
@ -126,22 +127,22 @@ namespace SDL
|
|||
public static extern SDL_PropertiesID SDL_GetAudioStreamProperties(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetAudioStreamFormat(SDL_AudioStream* stream, SDL_AudioSpec* src_spec, SDL_AudioSpec* dst_spec);
|
||||
public static extern SDL_bool SDL_GetAudioStreamFormat(SDL_AudioStream* stream, SDL_AudioSpec* src_spec, SDL_AudioSpec* dst_spec);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetAudioStreamFormat(SDL_AudioStream* stream, [NativeTypeName("const SDL_AudioSpec *")] SDL_AudioSpec* src_spec, [NativeTypeName("const SDL_AudioSpec *")] SDL_AudioSpec* dst_spec);
|
||||
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);
|
||||
|
||||
[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 int SDL_SetAudioStreamFrequencyRatio(SDL_AudioStream* stream, float ratio);
|
||||
public static extern SDL_bool 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 int SDL_SetAudioStreamGain(SDL_AudioStream* stream, float gain);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
@ -150,13 +151,13 @@ namespace SDL
|
|||
public static extern int* SDL_GetAudioStreamOutputChannelMap(SDL_AudioStream* stream, int* count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetAudioStreamInputChannelMap(SDL_AudioStream* stream, [NativeTypeName("const int *")] int* chmap, int count);
|
||||
public static extern SDL_bool SDL_SetAudioStreamInputChannelMap(SDL_AudioStream* stream, [NativeTypeName("const int *")] int* chmap, int count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetAudioStreamOutputChannelMap(SDL_AudioStream* stream, [NativeTypeName("const int *")] int* chmap, int count);
|
||||
public static extern SDL_bool SDL_SetAudioStreamOutputChannelMap(SDL_AudioStream* stream, [NativeTypeName("const int *")] int* chmap, int count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_PutAudioStreamData(SDL_AudioStream* stream, [NativeTypeName("const void *")] IntPtr buf, int len);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
@ -168,28 +169,28 @@ namespace SDL
|
|||
public static extern int SDL_GetAudioStreamQueued(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_FlushAudioStream(SDL_AudioStream* stream);
|
||||
public static extern SDL_bool SDL_FlushAudioStream(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ClearAudioStream(SDL_AudioStream* stream);
|
||||
public static extern SDL_bool SDL_ClearAudioStream(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_PauseAudioStreamDevice(SDL_AudioStream* stream);
|
||||
public static extern SDL_bool SDL_PauseAudioStreamDevice(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ResumeAudioStreamDevice(SDL_AudioStream* stream);
|
||||
public static extern SDL_bool SDL_ResumeAudioStreamDevice(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_LockAudioStream(SDL_AudioStream* stream);
|
||||
public static extern SDL_bool SDL_LockAudioStream(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_UnlockAudioStream(SDL_AudioStream* stream);
|
||||
public static extern SDL_bool SDL_UnlockAudioStream(SDL_AudioStream* stream);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetAudioStreamGetCallback(SDL_AudioStream* stream, [NativeTypeName("SDL_AudioStreamCallback")] delegate* unmanaged[Cdecl]<IntPtr, SDL_AudioStream*, int, int, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetAudioStreamPutCallback(SDL_AudioStream* stream, [NativeTypeName("SDL_AudioStreamCallback")] delegate* unmanaged[Cdecl]<IntPtr, SDL_AudioStream*, int, int, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DestroyAudioStream(SDL_AudioStream* stream);
|
||||
|
|
@ -198,19 +199,23 @@ 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 int SDL_SetAudioPostmixCallback(SDL_AudioDeviceID devid, [NativeTypeName("SDL_AudioPostmixCallback")] delegate* unmanaged[Cdecl]<IntPtr, SDL_AudioSpec*, float*, int, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_LoadWAV_IO(SDL_IOStream* src, SDL_bool closeio, SDL_AudioSpec* spec, [NativeTypeName("Uint8 **")] byte** audio_buf, [NativeTypeName("Uint32 *")] uint* audio_len);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_LoadWAV([NativeTypeName("const char *")] byte* path, SDL_AudioSpec* spec, [NativeTypeName("Uint8 **")] byte** audio_buf, [NativeTypeName("Uint32 *")] uint* audio_len);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_MixAudio([NativeTypeName("Uint8 *")] byte* dst, [NativeTypeName("const Uint8 *")] byte* src, SDL_AudioFormat format, [NativeTypeName("Uint32")] uint len, float volume);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_GetAudioFormatName", ExactSpelling = true)]
|
||||
[return: NativeTypeName("const char *")]
|
||||
public static extern byte* Unsafe_SDL_GetAudioFormatName(SDL_AudioFormat format);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetSilenceValueForFormat(SDL_AudioFormat format);
|
||||
|
|
|
|||
|
|
@ -92,13 +92,13 @@ namespace SDL
|
|||
public static extern SDL_PropertiesID SDL_GetCameraProperties(SDL_Camera* camera);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetCameraFormat(SDL_Camera* camera, SDL_CameraSpec* spec);
|
||||
public static extern SDL_bool 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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ReleaseCameraFrame(SDL_Camera* camera, SDL_Surface* frame);
|
||||
public static extern void SDL_ReleaseCameraFrame(SDL_Camera* camera, SDL_Surface* frame);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_CloseCamera(SDL_Camera* camera);
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetClipboardText([NativeTypeName("const char *")] byte* text);
|
||||
public static extern SDL_bool SDL_SetClipboardText([NativeTypeName("const char *")] byte* text);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_GetClipboardText", ExactSpelling = true)]
|
||||
[return: NativeTypeName("char *")]
|
||||
|
|
@ -41,7 +41,7 @@ namespace SDL
|
|||
public static extern SDL_bool SDL_HasClipboardText();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetPrimarySelectionText([NativeTypeName("const char *")] byte* text);
|
||||
public static extern SDL_bool SDL_SetPrimarySelectionText([NativeTypeName("const char *")] byte* text);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_GetPrimarySelectionText", ExactSpelling = true)]
|
||||
[return: NativeTypeName("char *")]
|
||||
|
|
@ -51,10 +51,10 @@ namespace SDL
|
|||
public static extern SDL_bool SDL_HasPrimarySelectionText();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ClearClipboardData();
|
||||
public static extern SDL_bool SDL_ClearClipboardData();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("void*")]
|
||||
|
|
|
|||
|
|
@ -30,16 +30,16 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetError([NativeTypeName("const char *")] byte* fmt, __arglist);
|
||||
public static extern SDL_bool SDL_SetError([NativeTypeName("const char *")] byte* fmt, __arglist);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_OutOfMemory();
|
||||
public static extern SDL_bool 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 int SDL_ClearError();
|
||||
public static extern SDL_bool SDL_ClearError();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -74,8 +74,6 @@ namespace SDL
|
|||
SDL_EVENT_WINDOW_ENTER_FULLSCREEN,
|
||||
SDL_EVENT_WINDOW_LEAVE_FULLSCREEN,
|
||||
SDL_EVENT_WINDOW_DESTROYED,
|
||||
SDL_EVENT_WINDOW_PEN_ENTER,
|
||||
SDL_EVENT_WINDOW_PEN_LEAVE,
|
||||
SDL_EVENT_WINDOW_HDR_STATE_CHANGED,
|
||||
SDL_EVENT_WINDOW_FIRST = SDL_EVENT_WINDOW_SHOWN,
|
||||
SDL_EVENT_WINDOW_LAST = SDL_EVENT_WINDOW_HDR_STATE_CHANGED,
|
||||
|
|
@ -127,11 +125,14 @@ namespace SDL
|
|||
SDL_EVENT_AUDIO_DEVICE_REMOVED,
|
||||
SDL_EVENT_AUDIO_DEVICE_FORMAT_CHANGED,
|
||||
SDL_EVENT_SENSOR_UPDATE = 0x1200,
|
||||
SDL_EVENT_PEN_DOWN = 0x1300,
|
||||
SDL_EVENT_PEN_PROXIMITY_IN = 0x1300,
|
||||
SDL_EVENT_PEN_PROXIMITY_OUT,
|
||||
SDL_EVENT_PEN_DOWN,
|
||||
SDL_EVENT_PEN_UP,
|
||||
SDL_EVENT_PEN_MOTION,
|
||||
SDL_EVENT_PEN_BUTTON_DOWN,
|
||||
SDL_EVENT_PEN_BUTTON_UP,
|
||||
SDL_EVENT_PEN_MOTION,
|
||||
SDL_EVENT_PEN_AXIS,
|
||||
SDL_EVENT_CAMERA_DEVICE_ADDED = 0x1400,
|
||||
SDL_EVENT_CAMERA_DEVICE_REMOVED,
|
||||
SDL_EVENT_CAMERA_DEVICE_APPROVED,
|
||||
|
|
@ -230,11 +231,9 @@ namespace SDL
|
|||
[NativeTypeName("Uint16")]
|
||||
public ushort raw;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte state;
|
||||
public SDL_bool down;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte repeat;
|
||||
public SDL_bool repeat;
|
||||
}
|
||||
|
||||
public unsafe partial struct SDL_TextEditingEvent
|
||||
|
|
@ -281,6 +280,15 @@ namespace SDL
|
|||
public int selected_candidate;
|
||||
|
||||
public SDL_bool horizontal;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding2;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding3;
|
||||
}
|
||||
|
||||
public unsafe partial struct SDL_TextInputEvent
|
||||
|
|
@ -354,8 +362,7 @@ namespace SDL
|
|||
[NativeTypeName("Uint8")]
|
||||
public byte button;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte state;
|
||||
public SDL_bool down;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte clicks;
|
||||
|
|
@ -495,8 +502,7 @@ namespace SDL
|
|||
[NativeTypeName("Uint8")]
|
||||
public byte button;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte state;
|
||||
public SDL_bool down;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
|
@ -581,8 +587,7 @@ namespace SDL
|
|||
[NativeTypeName("Uint8")]
|
||||
public byte button;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte state;
|
||||
public SDL_bool down;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
|
@ -669,8 +674,7 @@ namespace SDL
|
|||
|
||||
public SDL_AudioDeviceID which;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte recording;
|
||||
public SDL_bool recording;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
|
|
@ -722,7 +726,7 @@ namespace SDL
|
|||
public SDL_WindowID windowID;
|
||||
}
|
||||
|
||||
public partial struct SDL_PenTipEvent
|
||||
public partial struct SDL_PenProximityEvent
|
||||
{
|
||||
public SDL_EventType type;
|
||||
|
||||
|
|
@ -735,28 +739,6 @@ namespace SDL
|
|||
public SDL_WindowID windowID;
|
||||
|
||||
public SDL_PenID which;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte tip;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte state;
|
||||
|
||||
[NativeTypeName("Uint16")]
|
||||
public ushort pen_state;
|
||||
|
||||
public float x;
|
||||
|
||||
public float y;
|
||||
|
||||
[NativeTypeName("float[6]")]
|
||||
public _axes_e__FixedBuffer axes;
|
||||
|
||||
[InlineArray(6)]
|
||||
public partial struct _axes_e__FixedBuffer
|
||||
{
|
||||
public float e0;
|
||||
}
|
||||
}
|
||||
|
||||
public partial struct SDL_PenMotionEvent
|
||||
|
|
@ -773,27 +755,36 @@ namespace SDL
|
|||
|
||||
public SDL_PenID which;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding1;
|
||||
public SDL_PenInputFlags pen_state;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte padding2;
|
||||
public float x;
|
||||
|
||||
[NativeTypeName("Uint16")]
|
||||
public ushort pen_state;
|
||||
public float y;
|
||||
}
|
||||
|
||||
public partial struct SDL_PenTouchEvent
|
||||
{
|
||||
public SDL_EventType type;
|
||||
|
||||
[NativeTypeName("Uint32")]
|
||||
public uint reserved;
|
||||
|
||||
[NativeTypeName("Uint64")]
|
||||
public ulong timestamp;
|
||||
|
||||
public SDL_WindowID windowID;
|
||||
|
||||
public SDL_PenID which;
|
||||
|
||||
public SDL_PenInputFlags pen_state;
|
||||
|
||||
public float x;
|
||||
|
||||
public float y;
|
||||
|
||||
[NativeTypeName("float[6]")]
|
||||
public _axes_e__FixedBuffer axes;
|
||||
public SDL_bool eraser;
|
||||
|
||||
[InlineArray(6)]
|
||||
public partial struct _axes_e__FixedBuffer
|
||||
{
|
||||
public float e0;
|
||||
}
|
||||
public SDL_bool down;
|
||||
}
|
||||
|
||||
public partial struct SDL_PenButtonEvent
|
||||
|
|
@ -810,27 +801,41 @@ namespace SDL
|
|||
|
||||
public SDL_PenID which;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte button;
|
||||
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte state;
|
||||
|
||||
[NativeTypeName("Uint16")]
|
||||
public ushort pen_state;
|
||||
public SDL_PenInputFlags pen_state;
|
||||
|
||||
public float x;
|
||||
|
||||
public float y;
|
||||
|
||||
[NativeTypeName("float[6]")]
|
||||
public _axes_e__FixedBuffer axes;
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte button;
|
||||
|
||||
[InlineArray(6)]
|
||||
public partial struct _axes_e__FixedBuffer
|
||||
{
|
||||
public float e0;
|
||||
}
|
||||
public SDL_bool down;
|
||||
}
|
||||
|
||||
public partial struct SDL_PenAxisEvent
|
||||
{
|
||||
public SDL_EventType type;
|
||||
|
||||
[NativeTypeName("Uint32")]
|
||||
public uint reserved;
|
||||
|
||||
[NativeTypeName("Uint64")]
|
||||
public ulong timestamp;
|
||||
|
||||
public SDL_WindowID windowID;
|
||||
|
||||
public SDL_PenID which;
|
||||
|
||||
public SDL_PenInputFlags pen_state;
|
||||
|
||||
public float x;
|
||||
|
||||
public float y;
|
||||
|
||||
public SDL_PenAxis axis;
|
||||
|
||||
public float value;
|
||||
}
|
||||
|
||||
public unsafe partial struct SDL_DropEvent
|
||||
|
|
@ -1021,7 +1026,10 @@ namespace SDL
|
|||
public SDL_TouchFingerEvent tfinger;
|
||||
|
||||
[FieldOffset(0)]
|
||||
public SDL_PenTipEvent ptip;
|
||||
public SDL_PenProximityEvent pproximity;
|
||||
|
||||
[FieldOffset(0)]
|
||||
public SDL_PenTouchEvent ptouch;
|
||||
|
||||
[FieldOffset(0)]
|
||||
public SDL_PenMotionEvent pmotion;
|
||||
|
|
@ -1029,6 +1037,9 @@ namespace SDL
|
|||
[FieldOffset(0)]
|
||||
public SDL_PenButtonEvent pbutton;
|
||||
|
||||
[FieldOffset(0)]
|
||||
public SDL_PenAxisEvent paxis;
|
||||
|
||||
[FieldOffset(0)]
|
||||
public SDL_DropEvent drop;
|
||||
|
||||
|
|
@ -1083,22 +1094,22 @@ namespace SDL
|
|||
public static extern SDL_bool SDL_WaitEventTimeout(SDL_Event* @event, [NativeTypeName("Sint32")] int timeoutMS);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_PushEvent(SDL_Event* @event);
|
||||
public static extern SDL_bool 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*, int> filter, [NativeTypeName("void*")] IntPtr userdata);
|
||||
public static extern void SDL_SetEventFilter([NativeTypeName("SDL_EventFilter")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, SDL_bool> 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*, int>* filter, [NativeTypeName("void **")] IntPtr* userdata);
|
||||
public static extern SDL_bool SDL_GetEventFilter([NativeTypeName("SDL_EventFilter *")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, SDL_bool>* filter, [NativeTypeName("void **")] IntPtr* userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_AddEventWatch([NativeTypeName("SDL_EventFilter")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, int> filter, [NativeTypeName("void*")] IntPtr userdata);
|
||||
public static extern SDL_bool SDL_AddEventWatch([NativeTypeName("SDL_EventFilter")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, SDL_bool> filter, [NativeTypeName("void*")] IntPtr userdata);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DelEventWatch([NativeTypeName("SDL_EventFilter")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, int> filter, [NativeTypeName("void*")] IntPtr userdata);
|
||||
public static extern void SDL_RemoveEventWatch([NativeTypeName("SDL_EventFilter")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, SDL_bool> 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*, int> filter, [NativeTypeName("void*")] IntPtr userdata);
|
||||
public static extern void SDL_FilterEvents([NativeTypeName("SDL_EventFilter")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, SDL_bool> 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);
|
||||
|
|
@ -1112,11 +1123,5 @@ namespace SDL
|
|||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Window* SDL_GetWindowFromEvent([NativeTypeName("const SDL_Event *")] SDL_Event* @event);
|
||||
|
||||
[NativeTypeName("#define SDL_RELEASED 0")]
|
||||
public const int SDL_RELEASED = 0;
|
||||
|
||||
[NativeTypeName("#define SDL_PRESSED 1")]
|
||||
public const int SDL_PRESSED = 1;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ namespace SDL
|
|||
SDL_FOLDER_SCREENSHOTS,
|
||||
SDL_FOLDER_TEMPLATES,
|
||||
SDL_FOLDER_VIDEOS,
|
||||
SDL_FOLDER_TOTAL,
|
||||
SDL_FOLDER_COUNT,
|
||||
}
|
||||
|
||||
public enum SDL_PathType
|
||||
|
|
@ -81,22 +81,22 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetUserFolder(SDL_Folder folder);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_CreateDirectory([NativeTypeName("const char *")] byte* path);
|
||||
public static extern SDL_bool SDL_CreateDirectory([NativeTypeName("const char *")] byte* path);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_EnumerateDirectory([NativeTypeName("const char *")] byte* path, [NativeTypeName("SDL_EnumerateDirectoryCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, int> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RemovePath([NativeTypeName("const char *")] byte* path);
|
||||
public static extern SDL_bool SDL_RemovePath([NativeTypeName("const char *")] byte* path);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RenamePath([NativeTypeName("const char *")] byte* oldpath, [NativeTypeName("const char *")] byte* newpath);
|
||||
public static extern SDL_bool SDL_RenamePath([NativeTypeName("const char *")] byte* oldpath, [NativeTypeName("const char *")] byte* newpath);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_CopyFile([NativeTypeName("const char *")] byte* oldpath, [NativeTypeName("const char *")] byte* newpath);
|
||||
public static extern SDL_bool SDL_CopyFile([NativeTypeName("const char *")] byte* oldpath, [NativeTypeName("const char *")] byte* newpath);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetPathInfo([NativeTypeName("const char *")] byte* path, SDL_PathInfo* info);
|
||||
public static extern SDL_bool SDL_GetPathInfo([NativeTypeName("const char *")] byte* path, SDL_PathInfo* info);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("char **")]
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@ namespace SDL
|
|||
SDL_GAMEPAD_TYPE_NINTENDO_SWITCH_JOYCON_LEFT,
|
||||
SDL_GAMEPAD_TYPE_NINTENDO_SWITCH_JOYCON_RIGHT,
|
||||
SDL_GAMEPAD_TYPE_NINTENDO_SWITCH_JOYCON_PAIR,
|
||||
SDL_GAMEPAD_TYPE_MAX,
|
||||
SDL_GAMEPAD_TYPE_COUNT,
|
||||
}
|
||||
|
||||
public enum SDL_GamepadButton
|
||||
|
|
@ -77,7 +77,7 @@ namespace SDL
|
|||
SDL_GAMEPAD_BUTTON_MISC4,
|
||||
SDL_GAMEPAD_BUTTON_MISC5,
|
||||
SDL_GAMEPAD_BUTTON_MISC6,
|
||||
SDL_GAMEPAD_BUTTON_MAX,
|
||||
SDL_GAMEPAD_BUTTON_COUNT,
|
||||
}
|
||||
|
||||
public enum SDL_GamepadButtonLabel
|
||||
|
|
@ -102,7 +102,7 @@ namespace SDL
|
|||
SDL_GAMEPAD_AXIS_RIGHTY,
|
||||
SDL_GAMEPAD_AXIS_LEFT_TRIGGER,
|
||||
SDL_GAMEPAD_AXIS_RIGHT_TRIGGER,
|
||||
SDL_GAMEPAD_AXIS_MAX,
|
||||
SDL_GAMEPAD_AXIS_COUNT,
|
||||
}
|
||||
|
||||
public enum SDL_GamepadBindingType
|
||||
|
|
@ -117,12 +117,12 @@ namespace SDL
|
|||
{
|
||||
public SDL_GamepadBindingType input_type;
|
||||
|
||||
[NativeTypeName("__AnonymousRecord_SDL_gamepad_L245_C5")]
|
||||
[NativeTypeName("__AnonymousRecord_SDL_gamepad_L247_C5")]
|
||||
public _input_e__Union input;
|
||||
|
||||
public SDL_GamepadBindingType output_type;
|
||||
|
||||
[NativeTypeName("__AnonymousRecord_SDL_gamepad_L265_C5")]
|
||||
[NativeTypeName("__AnonymousRecord_SDL_gamepad_L267_C5")]
|
||||
public _output_e__Union output;
|
||||
|
||||
[StructLayout(LayoutKind.Explicit)]
|
||||
|
|
@ -132,11 +132,11 @@ namespace SDL
|
|||
public int button;
|
||||
|
||||
[FieldOffset(0)]
|
||||
[NativeTypeName("__AnonymousRecord_SDL_gamepad_L249_C9")]
|
||||
[NativeTypeName("__AnonymousRecord_SDL_gamepad_L251_C9")]
|
||||
public _axis_e__Struct axis;
|
||||
|
||||
[FieldOffset(0)]
|
||||
[NativeTypeName("__AnonymousRecord_SDL_gamepad_L256_C9")]
|
||||
[NativeTypeName("__AnonymousRecord_SDL_gamepad_L258_C9")]
|
||||
public _hat_e__Struct hat;
|
||||
|
||||
public partial struct _axis_e__Struct
|
||||
|
|
@ -163,7 +163,7 @@ namespace SDL
|
|||
public SDL_GamepadButton button;
|
||||
|
||||
[FieldOffset(0)]
|
||||
[NativeTypeName("__AnonymousRecord_SDL_gamepad_L269_C9")]
|
||||
[NativeTypeName("__AnonymousRecord_SDL_gamepad_L271_C9")]
|
||||
public _axis_e__Struct axis;
|
||||
|
||||
public partial struct _axis_e__Struct
|
||||
|
|
@ -189,7 +189,7 @@ namespace SDL
|
|||
public static extern int SDL_AddGamepadMappingsFromFile([NativeTypeName("const char *")] byte* file);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ReloadGamepadMappings();
|
||||
public static extern SDL_bool SDL_ReloadGamepadMappings();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("char **")]
|
||||
|
|
@ -204,7 +204,7 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetGamepadMapping(SDL_Gamepad* gamepad);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetGamepadMapping(SDL_JoystickID instance_id, [NativeTypeName("const char *")] byte* mapping);
|
||||
public static extern SDL_bool 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();
|
||||
|
|
@ -284,7 +284,7 @@ namespace SDL
|
|||
public static extern int SDL_GetGamepadPlayerIndex(SDL_Gamepad* gamepad);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetGamepadPlayerIndex(SDL_Gamepad* gamepad, int player_index);
|
||||
public static extern SDL_bool SDL_SetGamepadPlayerIndex(SDL_Gamepad* gamepad, int player_index);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Uint16")]
|
||||
|
|
@ -366,8 +366,7 @@ namespace SDL
|
|||
public static extern SDL_bool SDL_GamepadHasButton(SDL_Gamepad* gamepad, SDL_GamepadButton button);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Uint8")]
|
||||
public static extern byte SDL_GetGamepadButton(SDL_Gamepad* gamepad, SDL_GamepadButton button);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
@ -382,13 +381,13 @@ namespace SDL
|
|||
public static extern int SDL_GetNumGamepadTouchpadFingers(SDL_Gamepad* gamepad, int touchpad);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetGamepadTouchpadFinger(SDL_Gamepad* gamepad, int touchpad, int finger, [NativeTypeName("Uint8 *")] byte* state, float* x, float* y, float* pressure);
|
||||
public static extern SDL_bool SDL_GetGamepadTouchpadFinger(SDL_Gamepad* gamepad, int touchpad, int finger, SDL_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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetGamepadSensorEnabled(SDL_Gamepad* gamepad, SDL_SensorType type, SDL_bool enabled);
|
||||
public static extern SDL_bool SDL_SetGamepadSensorEnabled(SDL_Gamepad* gamepad, SDL_SensorType type, SDL_bool enabled);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GamepadSensorEnabled(SDL_Gamepad* gamepad, SDL_SensorType type);
|
||||
|
|
@ -397,19 +396,19 @@ namespace SDL
|
|||
public static extern float SDL_GetGamepadSensorDataRate(SDL_Gamepad* gamepad, SDL_SensorType type);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetGamepadSensorData(SDL_Gamepad* gamepad, SDL_SensorType type, float* data, int num_values);
|
||||
public static extern SDL_bool SDL_GetGamepadSensorData(SDL_Gamepad* gamepad, SDL_SensorType type, float* data, int num_values);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RumbleGamepad(SDL_Gamepad* gamepad, [NativeTypeName("Uint16")] ushort low_frequency_rumble, [NativeTypeName("Uint16")] ushort high_frequency_rumble, [NativeTypeName("Uint32")] uint duration_ms);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RumbleGamepadTriggers(SDL_Gamepad* gamepad, [NativeTypeName("Uint16")] ushort left_rumble, [NativeTypeName("Uint16")] ushort right_rumble, [NativeTypeName("Uint32")] uint duration_ms);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetGamepadLED(SDL_Gamepad* gamepad, [NativeTypeName("Uint8")] byte red, [NativeTypeName("Uint8")] byte green, [NativeTypeName("Uint8")] byte blue);
|
||||
public static extern SDL_bool 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 int SDL_SendGamepadEffect(SDL_Gamepad* gamepad, [NativeTypeName("const void *")] IntPtr data, int size);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -380,46 +380,46 @@ namespace SDL
|
|||
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 int SDL_UpdateHapticEffect(SDL_Haptic* haptic, int effect, [NativeTypeName("const SDL_HapticEffect *")] SDL_HapticEffect* data);
|
||||
public static extern SDL_bool SDL_UpdateHapticEffect(SDL_Haptic* haptic, int effect, [NativeTypeName("const SDL_HapticEffect *")] SDL_HapticEffect* data);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RunHapticEffect(SDL_Haptic* haptic, int effect, [NativeTypeName("Uint32")] uint iterations);
|
||||
public static extern SDL_bool SDL_RunHapticEffect(SDL_Haptic* haptic, int effect, [NativeTypeName("Uint32")] uint iterations);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_StopHapticEffect(SDL_Haptic* haptic, int effect);
|
||||
public static extern SDL_bool 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 int SDL_GetHapticEffectStatus(SDL_Haptic* haptic, int effect);
|
||||
public static extern SDL_bool SDL_GetHapticEffectStatus(SDL_Haptic* haptic, int effect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetHapticGain(SDL_Haptic* haptic, int gain);
|
||||
public static extern SDL_bool SDL_SetHapticGain(SDL_Haptic* haptic, int gain);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetHapticAutocenter(SDL_Haptic* haptic, int autocenter);
|
||||
public static extern SDL_bool SDL_SetHapticAutocenter(SDL_Haptic* haptic, int autocenter);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_PauseHaptic(SDL_Haptic* haptic);
|
||||
public static extern SDL_bool SDL_PauseHaptic(SDL_Haptic* haptic);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ResumeHaptic(SDL_Haptic* haptic);
|
||||
public static extern SDL_bool SDL_ResumeHaptic(SDL_Haptic* haptic);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_StopHapticEffects(SDL_Haptic* haptic);
|
||||
public static extern SDL_bool SDL_StopHapticEffects(SDL_Haptic* haptic);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HapticRumbleSupported(SDL_Haptic* haptic);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_InitHapticRumble(SDL_Haptic* haptic);
|
||||
public static extern SDL_bool SDL_InitHapticRumble(SDL_Haptic* haptic);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_PlayHapticRumble(SDL_Haptic* haptic, float strength, [NativeTypeName("Uint32")] uint length);
|
||||
public static extern SDL_bool SDL_PlayHapticRumble(SDL_Haptic* haptic, float strength, [NativeTypeName("Uint32")] uint length);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_StopHapticRumble(SDL_Haptic* haptic);
|
||||
public static extern SDL_bool SDL_StopHapticRumble(SDL_Haptic* haptic);
|
||||
|
||||
[NativeTypeName("#define SDL_HAPTIC_CONSTANT (1u<<0)")]
|
||||
public const uint SDL_HAPTIC_CONSTANT = (1U << 0);
|
||||
|
|
|
|||
|
|
@ -38,13 +38,13 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetHintWithPriority([NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value, SDL_HintPriority priority);
|
||||
public static extern SDL_bool 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 int SDL_SetHint([NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value);
|
||||
public static extern SDL_bool SDL_SetHint([NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ResetHint([NativeTypeName("const char *")] byte* name);
|
||||
public static extern SDL_bool SDL_ResetHint([NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_ResetHints();
|
||||
|
|
@ -57,10 +57,10 @@ namespace SDL
|
|||
public static extern SDL_bool SDL_GetHintBoolean([NativeTypeName("const char *")] byte* name, SDL_bool default_value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_AddHintCallback([NativeTypeName("const char *")] byte* name, [NativeTypeName("SDL_HintCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, byte*, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DelHintCallback([NativeTypeName("const char *")] byte* name, [NativeTypeName("SDL_HintCallback")] delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, byte*, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
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);
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_ALLOW_ALT_TAB_WHILE_GRABBED \"SDL_ALLOW_ALT_TAB_WHILE_GRABBED\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_ALLOW_ALT_TAB_WHILE_GRABBED => "SDL_ALLOW_ALT_TAB_WHILE_GRABBED"u8;
|
||||
|
|
@ -221,6 +221,9 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_HINT_HIDAPI_UDEV \"SDL_HIDAPI_UDEV\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_HIDAPI_UDEV => "SDL_HIDAPI_UDEV"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_GPU_DRIVER \"SDL_GPU_DRIVER\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_GPU_DRIVER => "SDL_GPU_DRIVER"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_HIDAPI_ENUMERATE_ONLY_CONTROLLERS \"SDL_HIDAPI_ENUMERATE_ONLY_CONTROLLERS\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_HIDAPI_ENUMERATE_ONLY_CONTROLLERS => "SDL_HIDAPI_ENUMERATE_ONLY_CONTROLLERS"u8;
|
||||
|
||||
|
|
@ -257,6 +260,9 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_HINT_JOYSTICK_FLIGHTSTICK_DEVICES_EXCLUDED \"SDL_JOYSTICK_FLIGHTSTICK_DEVICES_EXCLUDED\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_JOYSTICK_FLIGHTSTICK_DEVICES_EXCLUDED => "SDL_JOYSTICK_FLIGHTSTICK_DEVICES_EXCLUDED"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_JOYSTICK_GAMEINPUT \"SDL_JOYSTICK_GAMEINPUT\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_JOYSTICK_GAMEINPUT => "SDL_JOYSTICK_GAMEINPUT"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_JOYSTICK_GAMECUBE_DEVICES \"SDL_JOYSTICK_GAMECUBE_DEVICES\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_JOYSTICK_GAMECUBE_DEVICES => "SDL_JOYSTICK_GAMECUBE_DEVICES"u8;
|
||||
|
||||
|
|
@ -488,12 +494,6 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_HINT_ORIENTATIONS \"SDL_ORIENTATIONS\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_ORIENTATIONS => "SDL_ORIENTATIONS"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_PEN_DELAY_MOUSE_BUTTON \"SDL_PEN_DELAY_MOUSE_BUTTON\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_PEN_DELAY_MOUSE_BUTTON => "SDL_PEN_DELAY_MOUSE_BUTTON"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_PEN_NOT_MOUSE \"SDL_PEN_NOT_MOUSE\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_PEN_NOT_MOUSE => "SDL_PEN_NOT_MOUSE"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_POLL_SENTINEL \"SDL_POLL_SENTINEL\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_POLL_SENTINEL => "SDL_POLL_SENTINEL"u8;
|
||||
|
||||
|
|
@ -512,6 +512,12 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_HINT_RENDER_VULKAN_DEBUG \"SDL_RENDER_VULKAN_DEBUG\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_RENDER_VULKAN_DEBUG => "SDL_RENDER_VULKAN_DEBUG"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_RENDER_GPU_DEBUG \"SDL_RENDER_GPU_DEBUG\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_RENDER_GPU_DEBUG => "SDL_RENDER_GPU_DEBUG"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_RENDER_GPU_LOW_POWER \"SDL_RENDER_GPU_LOW_POWER\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_RENDER_GPU_LOW_POWER => "SDL_RENDER_GPU_LOW_POWER"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_RENDER_DRIVER \"SDL_RENDER_DRIVER\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_RENDER_DRIVER => "SDL_RENDER_DRIVER"u8;
|
||||
|
||||
|
|
@ -695,6 +701,9 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_HINT_WINDOWS_ENABLE_MESSAGELOOP \"SDL_WINDOWS_ENABLE_MESSAGELOOP\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_WINDOWS_ENABLE_MESSAGELOOP => "SDL_WINDOWS_ENABLE_MESSAGELOOP"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_WINDOWS_GAMEINPUT \"SDL_WINDOWS_GAMEINPUT\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_WINDOWS_GAMEINPUT => "SDL_WINDOWS_GAMEINPUT"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_WINDOWS_RAW_KEYBOARD \"SDL_WINDOWS_RAW_KEYBOARD\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_WINDOWS_RAW_KEYBOARD => "SDL_WINDOWS_RAW_KEYBOARD"u8;
|
||||
|
||||
|
|
@ -713,15 +722,6 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_HINT_WINDOWS_ERASE_BACKGROUND_MODE \"SDL_WINDOWS_ERASE_BACKGROUND_MODE\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_WINDOWS_ERASE_BACKGROUND_MODE => "SDL_WINDOWS_ERASE_BACKGROUND_MODE"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_WINRT_HANDLE_BACK_BUTTON \"SDL_WINRT_HANDLE_BACK_BUTTON\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_WINRT_HANDLE_BACK_BUTTON => "SDL_WINRT_HANDLE_BACK_BUTTON"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_WINRT_PRIVACY_POLICY_LABEL \"SDL_WINRT_PRIVACY_POLICY_LABEL\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_WINRT_PRIVACY_POLICY_LABEL => "SDL_WINRT_PRIVACY_POLICY_LABEL"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_WINRT_PRIVACY_POLICY_URL \"SDL_WINRT_PRIVACY_POLICY_URL\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_WINRT_PRIVACY_POLICY_URL => "SDL_WINRT_PRIVACY_POLICY_URL"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_X11_FORCE_OVERRIDE_REDIRECT \"SDL_X11_FORCE_OVERRIDE_REDIRECT\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_X11_FORCE_OVERRIDE_REDIRECT => "SDL_X11_FORCE_OVERRIDE_REDIRECT"u8;
|
||||
|
||||
|
|
@ -733,5 +733,8 @@ namespace SDL
|
|||
|
||||
[NativeTypeName("#define SDL_HINT_XINPUT_ENABLED \"SDL_XINPUT_ENABLED\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_XINPUT_ENABLED => "SDL_XINPUT_ENABLED"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_HINT_ASSERT \"SDL_ASSERT\"")]
|
||||
public static ReadOnlySpan<byte> SDL_HINT_ASSERT => "SDL_ASSERT"u8;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,13 +28,20 @@ using System.Runtime.InteropServices;
|
|||
|
||||
namespace SDL
|
||||
{
|
||||
public enum SDL_AppResult
|
||||
{
|
||||
SDL_APP_CONTINUE,
|
||||
SDL_APP_SUCCESS,
|
||||
SDL_APP_FAILURE,
|
||||
}
|
||||
|
||||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_Init(SDL_InitFlags flags);
|
||||
public static extern SDL_bool SDL_Init(SDL_InitFlags flags);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_InitSubSystem(SDL_InitFlags flags);
|
||||
public static extern SDL_bool SDL_InitSubSystem(SDL_InitFlags flags);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_QuitSubSystem(SDL_InitFlags flags);
|
||||
|
|
@ -46,10 +53,10 @@ namespace SDL
|
|||
public static extern void SDL_Quit();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetAppMetadata([NativeTypeName("const char *")] byte* appname, [NativeTypeName("const char *")] byte* appversion, [NativeTypeName("const char *")] byte* appidentifier);
|
||||
public static extern SDL_bool 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 int SDL_SetAppMetadataProperty([NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value);
|
||||
public static extern SDL_bool 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 *")]
|
||||
|
|
|
|||
|
|
@ -47,6 +47,9 @@ namespace SDL
|
|||
|
||||
public unsafe partial struct SDL_IOStreamInterface
|
||||
{
|
||||
[NativeTypeName("Uint32")]
|
||||
public uint version;
|
||||
|
||||
[NativeTypeName("Sint64 (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, long> size;
|
||||
|
||||
|
|
@ -59,8 +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("int (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, int> close;
|
||||
[NativeTypeName("SDL_bool (*)(void *, SDL_IOStatus *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, SDL_IOStatus*, SDL_bool> flush;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, SDL_bool> close;
|
||||
}
|
||||
|
||||
public partial struct SDL_IOStream
|
||||
|
|
@ -85,7 +91,7 @@ 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 int SDL_CloseIO(SDL_IOStream* context);
|
||||
public static extern SDL_bool SDL_CloseIO(SDL_IOStream* context);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_PropertiesID SDL_GetIOProperties(SDL_IOStream* context);
|
||||
|
|
@ -121,6 +127,9 @@ namespace SDL
|
|||
[return: NativeTypeName("size_t")]
|
||||
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);
|
||||
|
||||
[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);
|
||||
|
|
@ -219,6 +228,9 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_PROP_IOSTREAM_STDIO_FILE_POINTER \"SDL.iostream.stdio.file\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_IOSTREAM_STDIO_FILE_POINTER => "SDL.iostream.stdio.file"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_IOSTREAM_FILE_DESCRIPTOR_NUMBER \"SDL.iostream.file_descriptor\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_IOSTREAM_FILE_DESCRIPTOR_NUMBER => "SDL.iostream.file_descriptor"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_IOSTREAM_ANDROID_AASSET_POINTER \"SDL.iostream.android.aasset\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_IOSTREAM_ANDROID_AASSET_POINTER => "SDL.iostream.android.aasset"u8;
|
||||
|
||||
|
|
|
|||
|
|
@ -45,6 +45,7 @@ namespace SDL
|
|||
SDL_JOYSTICK_TYPE_DRUM_KIT,
|
||||
SDL_JOYSTICK_TYPE_ARCADE_PAD,
|
||||
SDL_JOYSTICK_TYPE_THROTTLE,
|
||||
SDL_JOYSTICK_TYPE_COUNT,
|
||||
}
|
||||
|
||||
public enum SDL_JoystickConnectionState
|
||||
|
|
@ -79,6 +80,9 @@ namespace SDL
|
|||
|
||||
public unsafe partial struct SDL_VirtualJoystickDesc
|
||||
{
|
||||
[NativeTypeName("Uint32")]
|
||||
public uint version;
|
||||
|
||||
[NativeTypeName("Uint16")]
|
||||
public ushort type;
|
||||
|
||||
|
|
@ -136,20 +140,23 @@ namespace SDL
|
|||
[NativeTypeName("void (*)(void *, int)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, int, void> SetPlayerIndex;
|
||||
|
||||
[NativeTypeName("int (*)(void *, Uint16, Uint16)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, ushort, ushort, int> Rumble;
|
||||
[NativeTypeName("SDL_bool (*)(void *, Uint16, Uint16)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, ushort, ushort, SDL_bool> Rumble;
|
||||
|
||||
[NativeTypeName("int (*)(void *, Uint16, Uint16)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, ushort, ushort, int> RumbleTriggers;
|
||||
[NativeTypeName("SDL_bool (*)(void *, Uint16, Uint16)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, ushort, ushort, SDL_bool> RumbleTriggers;
|
||||
|
||||
[NativeTypeName("int (*)(void *, Uint8, Uint8, Uint8)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte, byte, byte, int> SetLED;
|
||||
[NativeTypeName("SDL_bool (*)(void *, Uint8, Uint8, Uint8)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte, byte, byte, SDL_bool> SetLED;
|
||||
|
||||
[NativeTypeName("int (*)(void *, const void *, int)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, IntPtr, int, int> SendEffect;
|
||||
[NativeTypeName("SDL_bool (*)(void *, const void *, int)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, IntPtr, int, SDL_bool> SendEffect;
|
||||
|
||||
[NativeTypeName("int (*)(void *, SDL_bool)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, SDL_bool, int> SetSensorsEnabled;
|
||||
[NativeTypeName("SDL_bool (*)(void *, SDL_bool)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, SDL_bool, SDL_bool> SetSensorsEnabled;
|
||||
|
||||
[NativeTypeName("void (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, void> Cleanup;
|
||||
|
||||
[InlineArray(2)]
|
||||
public partial struct _padding2_e__FixedBuffer
|
||||
|
|
@ -214,28 +221,28 @@ 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 int SDL_DetachVirtualJoystick(SDL_JoystickID instance_id);
|
||||
public static extern SDL_bool SDL_DetachVirtualJoystick(SDL_JoystickID instance_id);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_IsJoystickVirtual(SDL_JoystickID instance_id);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetJoystickVirtualAxis(SDL_Joystick* joystick, int axis, [NativeTypeName("Sint16")] short value);
|
||||
public static extern SDL_bool SDL_SetJoystickVirtualAxis(SDL_Joystick* joystick, int axis, [NativeTypeName("Sint16")] short value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetJoystickVirtualBall(SDL_Joystick* joystick, int ball, [NativeTypeName("Sint16")] short xrel, [NativeTypeName("Sint16")] short yrel);
|
||||
public static extern SDL_bool 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 int SDL_SetJoystickVirtualButton(SDL_Joystick* joystick, int button, [NativeTypeName("Uint8")] byte value);
|
||||
public static extern SDL_bool SDL_SetJoystickVirtualButton(SDL_Joystick* joystick, int button, SDL_bool down);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetJoystickVirtualHat(SDL_Joystick* joystick, int hat, [NativeTypeName("Uint8")] byte value);
|
||||
public static extern SDL_bool SDL_SetJoystickVirtualHat(SDL_Joystick* joystick, int hat, [NativeTypeName("Uint8")] byte value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetJoystickVirtualTouchpad(SDL_Joystick* joystick, int touchpad, int finger, [NativeTypeName("Uint8")] byte state, float x, float y, float pressure);
|
||||
public static extern SDL_bool SDL_SetJoystickVirtualTouchpad(SDL_Joystick* joystick, int touchpad, int finger, SDL_bool down, float x, float y, float pressure);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SendJoystickVirtualSensorData(SDL_Joystick* joystick, SDL_SensorType type, [NativeTypeName("Uint64")] ulong sensor_timestamp, [NativeTypeName("const float *")] float* data, int num_values);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_PropertiesID SDL_GetJoystickProperties(SDL_Joystick* joystick);
|
||||
|
|
@ -252,7 +259,7 @@ namespace SDL
|
|||
public static extern int SDL_GetJoystickPlayerIndex(SDL_Joystick* joystick);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetJoystickPlayerIndex(SDL_Joystick* joystick, int player_index);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
@ -318,27 +325,26 @@ namespace SDL
|
|||
public static extern SDL_bool SDL_GetJoystickAxisInitialState(SDL_Joystick* joystick, int axis, [NativeTypeName("Sint16 *")] short* state);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetJoystickBall(SDL_Joystick* joystick, int ball, int* dx, int* dy);
|
||||
public static extern SDL_bool 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)]
|
||||
[return: NativeTypeName("Uint8")]
|
||||
public static extern byte SDL_GetJoystickButton(SDL_Joystick* joystick, int button);
|
||||
public static extern SDL_bool SDL_GetJoystickButton(SDL_Joystick* joystick, int button);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RumbleJoystick(SDL_Joystick* joystick, [NativeTypeName("Uint16")] ushort low_frequency_rumble, [NativeTypeName("Uint16")] ushort high_frequency_rumble, [NativeTypeName("Uint32")] uint duration_ms);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RumbleJoystickTriggers(SDL_Joystick* joystick, [NativeTypeName("Uint16")] ushort left_rumble, [NativeTypeName("Uint16")] ushort right_rumble, [NativeTypeName("Uint32")] uint duration_ms);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetJoystickLED(SDL_Joystick* joystick, [NativeTypeName("Uint8")] byte red, [NativeTypeName("Uint8")] byte green, [NativeTypeName("Uint8")] byte blue);
|
||||
public static extern SDL_bool 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 int SDL_SendJoystickEffect(SDL_Joystick* joystick, [NativeTypeName("const void *")] IntPtr data, int size);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
|
|||
|
|
@ -65,8 +65,8 @@ namespace SDL
|
|||
public static extern SDL_Window* SDL_GetKeyboardFocus();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("const Uint8 *")]
|
||||
public static extern byte* SDL_GetKeyboardState(int* numkeys);
|
||||
[return: NativeTypeName("const SDL_bool *")]
|
||||
public static extern SDL_bool* SDL_GetKeyboardState(int* numkeys);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_ResetKeyboard();
|
||||
|
|
@ -84,7 +84,7 @@ namespace SDL
|
|||
public static extern SDL_Scancode SDL_GetScancodeFromKey(SDL_Keycode key, SDL_Keymod* modstate);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetScancodeName(SDL_Scancode scancode, [NativeTypeName("const char *")] byte* name);
|
||||
public static extern SDL_bool 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,25 +101,25 @@ namespace SDL
|
|||
public static extern SDL_Keycode SDL_GetKeyFromName([NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_StartTextInput(SDL_Window* window);
|
||||
public static extern SDL_bool SDL_StartTextInput(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_StartTextInputWithProperties(SDL_Window* window, SDL_PropertiesID props);
|
||||
public static extern SDL_bool 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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_StopTextInput(SDL_Window* window);
|
||||
public static extern SDL_bool SDL_StopTextInput(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ClearComposition(SDL_Window* window);
|
||||
public static extern SDL_bool SDL_ClearComposition(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetTextInputArea(SDL_Window* window, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, int cursor);
|
||||
public static extern SDL_bool SDL_SetTextInputArea(SDL_Window* window, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, int cursor);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetTextInputArea(SDL_Window* window, SDL_Rect* rect, int* cursor);
|
||||
public static extern SDL_bool SDL_GetTextInputArea(SDL_Window* window, SDL_Rect* rect, int* cursor);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasScreenKeyboardSupport();
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ namespace SDL
|
|||
SDL_LOG_CATEGORY_RENDER,
|
||||
SDL_LOG_CATEGORY_INPUT,
|
||||
SDL_LOG_CATEGORY_TEST,
|
||||
SDL_LOG_CATEGORY_RESERVED1,
|
||||
SDL_LOG_CATEGORY_GPU,
|
||||
SDL_LOG_CATEGORY_RESERVED2,
|
||||
SDL_LOG_CATEGORY_RESERVED3,
|
||||
SDL_LOG_CATEGORY_RESERVED4,
|
||||
|
|
@ -60,7 +60,7 @@ namespace SDL
|
|||
SDL_LOG_PRIORITY_WARN,
|
||||
SDL_LOG_PRIORITY_ERROR,
|
||||
SDL_LOG_PRIORITY_CRITICAL,
|
||||
SDL_NUM_LOG_PRIORITIES,
|
||||
SDL_LOG_PRIORITY_COUNT,
|
||||
}
|
||||
|
||||
public static unsafe partial class SDL3
|
||||
|
|
@ -78,7 +78,7 @@ namespace SDL
|
|||
public static extern void SDL_ResetLogPriorities();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetLogPriorityPrefix(SDL_LogPriority priority, [NativeTypeName("const char *")] byte* prefix);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
|
|||
|
|
@ -0,0 +1,37 @@
|
|||
/*
|
||||
<auto-generated/>
|
||||
C# bindings for Simple DirectMedia Layer.
|
||||
Original copyright notice of input files:
|
||||
|
||||
Simple DirectMedia Layer
|
||||
Copyright (C) 1997-2024 Sam Lantinga <slouken@libsdl.org>
|
||||
|
||||
This software is provided 'as-is', without any express or implied
|
||||
warranty. In no event will the authors be held liable for any damages
|
||||
arising from the use of this software.
|
||||
|
||||
Permission is granted to anyone to use this software for any purpose,
|
||||
including commercial applications, and to alter it and redistribute it
|
||||
freely, subject to the following restrictions:
|
||||
|
||||
1. The origin of this software must not be misrepresented; you must not
|
||||
claim that you wrote the original software. If you use this software
|
||||
in a product, an acknowledgment in the product documentation would be
|
||||
appreciated but is not required.
|
||||
2. Altered source versions must be plainly marked as such, and must not be
|
||||
misrepresented as being the original software.
|
||||
3. This notice may not be removed or altered from any source distribution.
|
||||
*/
|
||||
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.Versioning;
|
||||
|
||||
namespace SDL
|
||||
{
|
||||
public static partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
public static extern void SDL_GDKSuspendComplete();
|
||||
}
|
||||
}
|
||||
|
|
@ -33,14 +33,10 @@ namespace SDL
|
|||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
public static extern int SDL_RegisterApp([NativeTypeName("const char *")] byte* name, [NativeTypeName("Uint32")] uint style, [NativeTypeName("void*")] IntPtr hInst);
|
||||
public static extern SDL_bool SDL_RegisterApp([NativeTypeName("const char *")] byte* name, [NativeTypeName("Uint32")] uint style, [NativeTypeName("void*")] IntPtr hInst);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
public static extern void SDL_UnregisterApp();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
public static extern void SDL_GDKSuspendComplete();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -37,6 +37,6 @@ namespace SDL
|
|||
public static extern int SDL_RunApp(int argc, [NativeTypeName("char *[]")] byte** argv, [NativeTypeName("SDL_main_func")] delegate* unmanaged[Cdecl]<int, byte**, int> mainFunction, [NativeTypeName("void*")] IntPtr reserved);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_EnterAppMainCallbacks(int argc, [NativeTypeName("char *[]")] byte** argv, [NativeTypeName("SDL_AppInit_func")] delegate* unmanaged[Cdecl]<IntPtr*, int, byte**, int> appinit, [NativeTypeName("SDL_AppIterate_func")] delegate* unmanaged[Cdecl]<IntPtr, int> appiter, [NativeTypeName("SDL_AppEvent_func")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, int> appevent, [NativeTypeName("SDL_AppQuit_func")] delegate* unmanaged[Cdecl]<IntPtr, void> appquit);
|
||||
public static extern int SDL_EnterAppMainCallbacks(int argc, [NativeTypeName("char *[]")] byte** argv, [NativeTypeName("SDL_AppInit_func")] delegate* unmanaged[Cdecl]<IntPtr*, int, byte**, SDL_AppResult> appinit, [NativeTypeName("SDL_AppIterate_func")] delegate* unmanaged[Cdecl]<IntPtr, SDL_AppResult> appiter, [NativeTypeName("SDL_AppEvent_func")] delegate* unmanaged[Cdecl]<IntPtr, SDL_Event*, SDL_AppResult> appevent, [NativeTypeName("SDL_AppQuit_func")] delegate* unmanaged[Cdecl]<IntPtr, void> appquit);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ namespace SDL
|
|||
SDL_MESSAGEBOX_COLOR_BUTTON_BORDER,
|
||||
SDL_MESSAGEBOX_COLOR_BUTTON_BACKGROUND,
|
||||
SDL_MESSAGEBOX_COLOR_BUTTON_SELECTED,
|
||||
SDL_MESSAGEBOX_COLOR_MAX,
|
||||
SDL_MESSAGEBOX_COLOR_COUNT,
|
||||
}
|
||||
|
||||
public partial struct SDL_MessageBoxColorScheme
|
||||
|
|
@ -96,10 +96,10 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ShowMessageBox([NativeTypeName("const SDL_MessageBoxData *")] SDL_MessageBoxData* messageboxdata, int* buttonid);
|
||||
public static extern SDL_bool SDL_ShowMessageBox([NativeTypeName("const SDL_MessageBoxData *")] SDL_MessageBoxData* messageboxdata, int* buttonid);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ShowSimpleMessageBox(SDL_MessageBoxFlags flags, [NativeTypeName("const char *")] byte* title, [NativeTypeName("const char *")] byte* message, SDL_Window* window);
|
||||
public static extern SDL_bool 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,6 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_OpenURL([NativeTypeName("const char *")] byte* url);
|
||||
public static extern SDL_bool SDL_OpenURL([NativeTypeName("const char *")] byte* url);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@ namespace SDL
|
|||
SDL_SYSTEM_CURSOR_S_RESIZE,
|
||||
SDL_SYSTEM_CURSOR_SW_RESIZE,
|
||||
SDL_SYSTEM_CURSOR_W_RESIZE,
|
||||
SDL_NUM_SYSTEM_CURSORS,
|
||||
SDL_SYSTEM_CURSOR_COUNT,
|
||||
}
|
||||
|
||||
public enum SDL_MouseWheelDirection
|
||||
|
|
@ -90,16 +90,16 @@ 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 int SDL_WarpMouseGlobal(float x, float y);
|
||||
public static extern SDL_bool SDL_WarpMouseGlobal(float x, float y);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetRelativeMouseMode(SDL_bool enabled);
|
||||
public static extern SDL_bool SDL_SetWindowRelativeMouseMode(SDL_Window* window, SDL_bool enabled);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_CaptureMouse(SDL_bool enabled);
|
||||
public static extern SDL_bool SDL_GetWindowRelativeMouseMode(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetRelativeMouseMode();
|
||||
public static extern SDL_bool SDL_CaptureMouse(SDL_bool 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 +111,7 @@ namespace SDL
|
|||
public static extern SDL_Cursor* SDL_CreateSystemCursor(SDL_SystemCursor id);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetCursor(SDL_Cursor* cursor);
|
||||
public static extern SDL_bool SDL_SetCursor(SDL_Cursor* cursor);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Cursor* SDL_GetCursor();
|
||||
|
|
@ -123,10 +123,10 @@ namespace SDL
|
|||
public static extern void SDL_DestroyCursor(SDL_Cursor* cursor);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ShowCursor();
|
||||
public static extern SDL_bool SDL_ShowCursor();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_HideCursor();
|
||||
public static extern SDL_bool SDL_HideCursor();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_CursorVisible();
|
||||
|
|
|
|||
|
|
@ -52,7 +52,7 @@ namespace SDL
|
|||
public static extern void SDL_LockMutex(SDL_Mutex* mutex);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_TryLockMutex(SDL_Mutex* mutex);
|
||||
public static extern SDL_bool SDL_TryLockMutex(SDL_Mutex* mutex);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_UnlockMutex(SDL_Mutex* mutex);
|
||||
|
|
@ -70,10 +70,10 @@ namespace SDL
|
|||
public static extern void SDL_LockRWLockForWriting(SDL_RWLock* rwlock);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_TryLockRWLockForReading(SDL_RWLock* rwlock);
|
||||
public static extern SDL_bool SDL_TryLockRWLockForReading(SDL_RWLock* rwlock);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_TryLockRWLockForWriting(SDL_RWLock* rwlock);
|
||||
public static extern SDL_bool SDL_TryLockRWLockForWriting(SDL_RWLock* rwlock);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_UnlockRWLock(SDL_RWLock* rwlock);
|
||||
|
|
@ -88,16 +88,16 @@ namespace SDL
|
|||
public static extern void SDL_DestroySemaphore(SDL_Semaphore* sem);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_WaitSemaphore(SDL_Semaphore* sem);
|
||||
public static extern void SDL_WaitSemaphore(SDL_Semaphore* sem);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_TryWaitSemaphore(SDL_Semaphore* sem);
|
||||
public static extern SDL_bool SDL_TryWaitSemaphore(SDL_Semaphore* sem);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_WaitSemaphoreTimeout(SDL_Semaphore* sem, [NativeTypeName("Sint32")] int timeoutMS);
|
||||
public static extern SDL_bool SDL_WaitSemaphoreTimeout(SDL_Semaphore* sem, [NativeTypeName("Sint32")] int timeoutMS);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SignalSemaphore(SDL_Semaphore* sem);
|
||||
public static extern void SDL_SignalSemaphore(SDL_Semaphore* sem);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Uint32")]
|
||||
|
|
@ -110,21 +110,15 @@ namespace SDL
|
|||
public static extern void SDL_DestroyCondition(SDL_Condition* cond);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SignalCondition(SDL_Condition* cond);
|
||||
public static extern void SDL_SignalCondition(SDL_Condition* cond);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_BroadcastCondition(SDL_Condition* cond);
|
||||
public static extern void SDL_BroadcastCondition(SDL_Condition* cond);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_WaitCondition(SDL_Condition* cond, SDL_Mutex* mutex);
|
||||
public static extern void SDL_WaitCondition(SDL_Condition* cond, SDL_Mutex* mutex);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_WaitConditionTimeout(SDL_Condition* cond, SDL_Mutex* mutex, [NativeTypeName("Sint32")] int timeoutMS);
|
||||
|
||||
[NativeTypeName("#define SDL_MUTEX_TIMEDOUT 1")]
|
||||
public const int SDL_MUTEX_TIMEDOUT = 1;
|
||||
|
||||
[NativeTypeName("#define SDL_RWLOCK_TIMEDOUT SDL_MUTEX_TIMEDOUT")]
|
||||
public const int SDL_RWLOCK_TIMEDOUT = 1;
|
||||
public static extern SDL_bool SDL_WaitConditionTimeout(SDL_Condition* cond, SDL_Mutex* mutex, [NativeTypeName("Sint32")] int timeoutMS);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -23,125 +23,41 @@
|
|||
3. This notice may not be removed or altered from any source distribution.
|
||||
*/
|
||||
|
||||
using System.Runtime.InteropServices;
|
||||
using static SDL.SDL_PenAxis;
|
||||
|
||||
namespace SDL
|
||||
{
|
||||
public enum SDL_PenAxis
|
||||
{
|
||||
SDL_PEN_AXIS_PRESSURE = 0,
|
||||
SDL_PEN_AXIS_PRESSURE,
|
||||
SDL_PEN_AXIS_XTILT,
|
||||
SDL_PEN_AXIS_YTILT,
|
||||
SDL_PEN_AXIS_DISTANCE,
|
||||
SDL_PEN_AXIS_ROTATION,
|
||||
SDL_PEN_AXIS_SLIDER,
|
||||
SDL_PEN_NUM_AXES,
|
||||
SDL_PEN_AXIS_LAST = SDL_PEN_NUM_AXES - 1,
|
||||
SDL_PEN_AXIS_TANGENTIAL_PRESSURE,
|
||||
SDL_PEN_AXIS_COUNT,
|
||||
}
|
||||
|
||||
public enum SDL_PenSubtype
|
||||
public static partial class SDL3
|
||||
{
|
||||
SDL_PEN_TYPE_UNKNOWN = 0,
|
||||
SDL_PEN_TYPE_ERASER = 1,
|
||||
SDL_PEN_TYPE_PEN,
|
||||
SDL_PEN_TYPE_PENCIL,
|
||||
SDL_PEN_TYPE_BRUSH,
|
||||
SDL_PEN_TYPE_AIRBRUSH,
|
||||
SDL_PEN_TYPE_LAST = SDL_PEN_TYPE_AIRBRUSH,
|
||||
}
|
||||
[NativeTypeName("#define SDL_PEN_INPUT_DOWN (1u << 0)")]
|
||||
public const uint SDL_PEN_INPUT_DOWN = (1U << 0);
|
||||
|
||||
public partial struct SDL_PenCapabilityInfo
|
||||
{
|
||||
public float max_tilt;
|
||||
[NativeTypeName("#define SDL_PEN_INPUT_BUTTON_1 (1u << 1)")]
|
||||
public const uint SDL_PEN_INPUT_BUTTON_1 = (1U << 1);
|
||||
|
||||
[NativeTypeName("Uint32")]
|
||||
public uint wacom_id;
|
||||
[NativeTypeName("#define SDL_PEN_INPUT_BUTTON_2 (1u << 2)")]
|
||||
public const uint SDL_PEN_INPUT_BUTTON_2 = (1U << 2);
|
||||
|
||||
[NativeTypeName("Sint8")]
|
||||
public sbyte num_buttons;
|
||||
}
|
||||
[NativeTypeName("#define SDL_PEN_INPUT_BUTTON_3 (1u << 3)")]
|
||||
public const uint SDL_PEN_INPUT_BUTTON_3 = (1U << 3);
|
||||
|
||||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_PenID* SDL_GetPens(int* count);
|
||||
[NativeTypeName("#define SDL_PEN_INPUT_BUTTON_4 (1u << 4)")]
|
||||
public const uint SDL_PEN_INPUT_BUTTON_4 = (1U << 4);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Uint32")]
|
||||
public static extern uint SDL_GetPenStatus(SDL_PenID instance_id, float* x, float* y, float* axes, [NativeTypeName("size_t")] nuint num_axes);
|
||||
[NativeTypeName("#define SDL_PEN_INPUT_BUTTON_5 (1u << 5)")]
|
||||
public const uint SDL_PEN_INPUT_BUTTON_5 = (1U << 5);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_PenID SDL_GetPenFromGUID(SDL_GUID guid);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_GUID SDL_GetPenGUID(SDL_PenID instance_id);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_PenConnected(SDL_PenID instance_id);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_GetPenName", ExactSpelling = true)]
|
||||
[return: NativeTypeName("const char *")]
|
||||
public static extern byte* Unsafe_SDL_GetPenName(SDL_PenID instance_id);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_PenCapabilityFlags SDL_GetPenCapabilities(SDL_PenID instance_id, SDL_PenCapabilityInfo* capabilities);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_PenSubtype SDL_GetPenType(SDL_PenID instance_id);
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_INVALID ((SDL_PenID)0)")]
|
||||
public const SDL_PenID SDL_PEN_INVALID = ((SDL_PenID)(0));
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_INFO_UNKNOWN (-1)")]
|
||||
public const int SDL_PEN_INFO_UNKNOWN = (-1);
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_FLAG_DOWN_BIT_INDEX 13")]
|
||||
public const int SDL_PEN_FLAG_DOWN_BIT_INDEX = 13;
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_FLAG_INK_BIT_INDEX 14")]
|
||||
public const int SDL_PEN_FLAG_INK_BIT_INDEX = 14;
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_FLAG_ERASER_BIT_INDEX 15")]
|
||||
public const int SDL_PEN_FLAG_ERASER_BIT_INDEX = 15;
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_FLAG_AXIS_BIT_OFFSET 16")]
|
||||
public const int SDL_PEN_FLAG_AXIS_BIT_OFFSET = 16;
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_TIP_INK SDL_PEN_FLAG_INK_BIT_INDEX")]
|
||||
public const int SDL_PEN_TIP_INK = 14;
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_TIP_ERASER SDL_PEN_FLAG_ERASER_BIT_INDEX")]
|
||||
public const int SDL_PEN_TIP_ERASER = 15;
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_DOWN_MASK SDL_PEN_CAPABILITY(SDL_PEN_FLAG_DOWN_BIT_INDEX)")]
|
||||
public const uint SDL_PEN_DOWN_MASK = (1U << (13));
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_INK_MASK SDL_PEN_CAPABILITY(SDL_PEN_FLAG_INK_BIT_INDEX)")]
|
||||
public const uint SDL_PEN_INK_MASK = (1U << (14));
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_ERASER_MASK SDL_PEN_CAPABILITY(SDL_PEN_FLAG_ERASER_BIT_INDEX)")]
|
||||
public const uint SDL_PEN_ERASER_MASK = (1U << (15));
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_AXIS_PRESSURE_MASK SDL_PEN_AXIS_CAPABILITY(SDL_PEN_AXIS_PRESSURE)")]
|
||||
public const uint SDL_PEN_AXIS_PRESSURE_MASK = (1U << ((int)(SDL_PEN_AXIS_PRESSURE) + 16));
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_AXIS_XTILT_MASK SDL_PEN_AXIS_CAPABILITY(SDL_PEN_AXIS_XTILT)")]
|
||||
public const uint SDL_PEN_AXIS_XTILT_MASK = (1U << ((int)(SDL_PEN_AXIS_XTILT) + 16));
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_AXIS_YTILT_MASK SDL_PEN_AXIS_CAPABILITY(SDL_PEN_AXIS_YTILT)")]
|
||||
public const uint SDL_PEN_AXIS_YTILT_MASK = (1U << ((int)(SDL_PEN_AXIS_YTILT) + 16));
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_AXIS_DISTANCE_MASK SDL_PEN_AXIS_CAPABILITY(SDL_PEN_AXIS_DISTANCE)")]
|
||||
public const uint SDL_PEN_AXIS_DISTANCE_MASK = (1U << ((int)(SDL_PEN_AXIS_DISTANCE) + 16));
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_AXIS_ROTATION_MASK SDL_PEN_AXIS_CAPABILITY(SDL_PEN_AXIS_ROTATION)")]
|
||||
public const uint SDL_PEN_AXIS_ROTATION_MASK = (1U << ((int)(SDL_PEN_AXIS_ROTATION) + 16));
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_AXIS_SLIDER_MASK SDL_PEN_AXIS_CAPABILITY(SDL_PEN_AXIS_SLIDER)")]
|
||||
public const uint SDL_PEN_AXIS_SLIDER_MASK = (1U << ((int)(SDL_PEN_AXIS_SLIDER) + 16));
|
||||
|
||||
[NativeTypeName("#define SDL_PEN_AXIS_BIDIRECTIONAL_MASKS (SDL_PEN_AXIS_XTILT_MASK | SDL_PEN_AXIS_YTILT_MASK)")]
|
||||
public const uint SDL_PEN_AXIS_BIDIRECTIONAL_MASKS = ((1U << ((int)(SDL_PEN_AXIS_XTILT) + 16)) | (1U << ((int)(SDL_PEN_AXIS_YTILT) + 16)));
|
||||
[NativeTypeName("#define SDL_PEN_INPUT_ERASER_TIP (1u << 30)")]
|
||||
public const uint SDL_PEN_INPUT_ERASER_TIP = (1U << 30);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -359,7 +359,7 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetPixelFormatName(SDL_PixelFormat format);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetMasksForPixelFormat(SDL_PixelFormat format, int* bpp, [NativeTypeName("Uint32 *")] uint* Rmask, [NativeTypeName("Uint32 *")] uint* Gmask, [NativeTypeName("Uint32 *")] uint* Bmask, [NativeTypeName("Uint32 *")] uint* Amask);
|
||||
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);
|
||||
|
||||
[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 +372,7 @@ namespace SDL
|
|||
public static extern SDL_Palette* SDL_CreatePalette(int ncolors);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetPaletteColors(SDL_Palette* palette, [NativeTypeName("const SDL_Color *")] SDL_Color* colors, int firstcolor, int ncolors);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
@ -394,9 +394,15 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_ALPHA_OPAQUE 255")]
|
||||
public const int SDL_ALPHA_OPAQUE = 255;
|
||||
|
||||
[NativeTypeName("#define SDL_ALPHA_OPAQUE_FLOAT 1.0f")]
|
||||
public const float SDL_ALPHA_OPAQUE_FLOAT = 1.0f;
|
||||
|
||||
[NativeTypeName("#define SDL_ALPHA_TRANSPARENT 0")]
|
||||
public const int SDL_ALPHA_TRANSPARENT = 0;
|
||||
|
||||
[NativeTypeName("#define SDL_ALPHA_TRANSPARENT_FLOAT 0.0f")]
|
||||
public const float SDL_ALPHA_TRANSPARENT_FLOAT = 0.0f;
|
||||
|
||||
[NativeTypeName("#define SDL_PIXELFORMAT_RGBA32 SDL_PIXELFORMAT_ABGR8888")]
|
||||
public const SDL_PixelFormat SDL_PIXELFORMAT_RGBA32 = SDL_PIXELFORMAT_ABGR8888;
|
||||
|
||||
|
|
|
|||
|
|
@ -0,0 +1,118 @@
|
|||
/*
|
||||
<auto-generated/>
|
||||
C# bindings for Simple DirectMedia Layer.
|
||||
Original copyright notice of input files:
|
||||
|
||||
Simple DirectMedia Layer
|
||||
Copyright (C) 1997-2024 Sam Lantinga <slouken@libsdl.org>
|
||||
|
||||
This software is provided 'as-is', without any express or implied
|
||||
warranty. In no event will the authors be held liable for any damages
|
||||
arising from the use of this software.
|
||||
|
||||
Permission is granted to anyone to use this software for any purpose,
|
||||
including commercial applications, and to alter it and redistribute it
|
||||
freely, subject to the following restrictions:
|
||||
|
||||
1. The origin of this software must not be misrepresented; you must not
|
||||
claim that you wrote the original software. If you use this software
|
||||
in a product, an acknowledgment in the product documentation would be
|
||||
appreciated but is not required.
|
||||
2. Altered source versions must be plainly marked as such, and must not be
|
||||
misrepresented as being the original software.
|
||||
3. This notice may not be removed or altered from any source distribution.
|
||||
*/
|
||||
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace SDL
|
||||
{
|
||||
public partial struct SDL_Process
|
||||
{
|
||||
}
|
||||
|
||||
public enum SDL_ProcessIO
|
||||
{
|
||||
SDL_PROCESS_STDIO_INHERITED,
|
||||
SDL_PROCESS_STDIO_NULL,
|
||||
SDL_PROCESS_STDIO_APP,
|
||||
SDL_PROCESS_STDIO_REDIRECT,
|
||||
}
|
||||
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Process* SDL_CreateProcessWithProperties(SDL_PropertiesID props);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_PropertiesID SDL_GetProcessProperties(SDL_Process* process);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("void*")]
|
||||
public static extern IntPtr SDL_ReadProcess(SDL_Process* process, [NativeTypeName("size_t *")] nuint* datasize, int* exitcode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_IOStream* SDL_GetProcessInput(SDL_Process* process);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WaitProcess(SDL_Process* process, SDL_bool block, int* exitcode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DestroyProcess(SDL_Process* process);
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_PROCESS_CREATE_ARGS_POINTER \"SDL.process.create.args\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_PROCESS_CREATE_ARGS_POINTER => "SDL.process.create.args"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_PROCESS_CREATE_ENVIRONMENT_POINTER \"SDL.process.create.environment\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_PROCESS_CREATE_ENVIRONMENT_POINTER => "SDL.process.create.environment"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_PROCESS_CREATE_STDIN_NUMBER \"SDL.process.create.stdin_option\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_PROCESS_CREATE_STDIN_NUMBER => "SDL.process.create.stdin_option"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_PROCESS_CREATE_STDIN_POINTER \"SDL.process.create.stdin_source\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_PROCESS_CREATE_STDIN_POINTER => "SDL.process.create.stdin_source"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_PROCESS_CREATE_STDOUT_NUMBER \"SDL.process.create.stdout_option\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_PROCESS_CREATE_STDOUT_NUMBER => "SDL.process.create.stdout_option"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_PROCESS_CREATE_STDOUT_POINTER \"SDL.process.create.stdout_source\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_PROCESS_CREATE_STDOUT_POINTER => "SDL.process.create.stdout_source"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_PROCESS_CREATE_STDERR_NUMBER \"SDL.process.create.stderr_option\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_PROCESS_CREATE_STDERR_NUMBER => "SDL.process.create.stderr_option"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_PROCESS_CREATE_STDERR_POINTER \"SDL.process.create.stderr_source\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_PROCESS_CREATE_STDERR_POINTER => "SDL.process.create.stderr_source"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_PROCESS_CREATE_STDERR_TO_STDOUT_BOOLEAN \"SDL.process.create.stderr_to_stdout\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_PROCESS_CREATE_STDERR_TO_STDOUT_BOOLEAN => "SDL.process.create.stderr_to_stdout"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_PROCESS_CREATE_BACKGROUND_BOOLEAN \"SDL.process.create.background\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_PROCESS_CREATE_BACKGROUND_BOOLEAN => "SDL.process.create.background"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_PROCESS_PID_NUMBER \"SDL.process.pid\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_PROCESS_PID_NUMBER => "SDL.process.pid"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_PROCESS_STDIN_POINTER \"SDL.process.stdin\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_PROCESS_STDIN_POINTER => "SDL.process.stdin"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_PROCESS_STDOUT_POINTER \"SDL.process.stdout\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_PROCESS_STDOUT_POINTER => "SDL.process.stdout"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_PROCESS_STDERR_POINTER \"SDL.process.stderr\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_PROCESS_STDERR_POINTER => "SDL.process.stderr"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_PROCESS_BACKGROUND_BOOLEAN \"SDL.process.background\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_PROCESS_BACKGROUND_BOOLEAN => "SDL.process.background"u8;
|
||||
}
|
||||
}
|
||||
|
|
@ -47,31 +47,31 @@ namespace SDL
|
|||
public static extern SDL_PropertiesID SDL_CreateProperties();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_CopyProperties(SDL_PropertiesID src, SDL_PropertiesID dst);
|
||||
public static extern SDL_bool SDL_CopyProperties(SDL_PropertiesID src, SDL_PropertiesID dst);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_LockProperties(SDL_PropertiesID props);
|
||||
public static extern SDL_bool 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 int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetPointerProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, [NativeTypeName("void*")] IntPtr value);
|
||||
public static extern SDL_bool SDL_SetPointerProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, [NativeTypeName("void*")] IntPtr value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetStringProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value);
|
||||
public static extern SDL_bool 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 int SDL_SetNumberProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, [NativeTypeName("Sint64")] long value);
|
||||
public static extern SDL_bool SDL_SetNumberProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, [NativeTypeName("Sint64")] long value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetFloatProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, float value);
|
||||
public static extern SDL_bool SDL_SetFloatProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, float value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetBooleanProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, SDL_bool value);
|
||||
public static extern SDL_bool SDL_SetBooleanProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, SDL_bool value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_HasProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name);
|
||||
|
|
@ -98,10 +98,10 @@ namespace SDL
|
|||
public static extern SDL_bool SDL_GetBooleanProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name, SDL_bool default_value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ClearProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name);
|
||||
public static extern SDL_bool SDL_ClearProperty(SDL_PropertiesID props, [NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_EnumerateProperties(SDL_PropertiesID props, [NativeTypeName("SDL_EnumeratePropertiesCallback")] delegate* unmanaged[Cdecl]<IntPtr, SDL_PropertiesID, byte*, void> callback, [NativeTypeName("void*")] IntPtr userdata);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DestroyProperties(SDL_PropertiesID props);
|
||||
|
|
|
|||
|
|
@ -95,7 +95,7 @@ namespace SDL
|
|||
public static extern SDL_bool 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 int SDL_GetRectUnion([NativeTypeName("const SDL_Rect *")] SDL_Rect* A, [NativeTypeName("const SDL_Rect *")] SDL_Rect* B, SDL_Rect* result);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
@ -130,7 +130,7 @@ namespace SDL
|
|||
public static extern SDL_bool 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 int SDL_GetRectUnionFloat([NativeTypeName("const SDL_FRect *")] SDL_FRect* A, [NativeTypeName("const SDL_FRect *")] SDL_FRect* B, SDL_FRect* result);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
|
|||
|
|
@ -71,7 +71,7 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetRenderDriver(int index);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_CreateWindowAndRenderer([NativeTypeName("const char *")] byte* title, int width, int height, SDL_WindowFlags window_flags, SDL_Window** window, SDL_Renderer** renderer);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_Renderer* SDL_CreateRenderer(SDL_Window* window, [NativeTypeName("const char *")] byte* name);
|
||||
|
|
@ -96,10 +96,10 @@ namespace SDL
|
|||
public static extern SDL_PropertiesID SDL_GetRendererProperties(SDL_Renderer* renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetRenderOutputSize(SDL_Renderer* renderer, int* w, int* h);
|
||||
public static extern SDL_bool SDL_GetRenderOutputSize(SDL_Renderer* renderer, int* w, int* h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetCurrentRenderOutputSize(SDL_Renderer* renderer, int* w, int* h);
|
||||
public static extern SDL_bool 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 +117,187 @@ namespace SDL
|
|||
public static extern SDL_Renderer* SDL_GetRendererFromTexture(SDL_Texture* texture);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetTextureSize(SDL_Texture* texture, float* w, float* h);
|
||||
public static extern SDL_bool SDL_GetTextureSize(SDL_Texture* texture, float* w, float* h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetTextureColorMod(SDL_Texture* texture, [NativeTypeName("Uint8")] byte r, [NativeTypeName("Uint8")] byte g, [NativeTypeName("Uint8")] byte b);
|
||||
public static extern SDL_bool 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 int SDL_SetTextureColorModFloat(SDL_Texture* texture, float r, float g, float b);
|
||||
public static extern SDL_bool SDL_SetTextureColorModFloat(SDL_Texture* texture, float r, float g, float b);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetTextureColorMod(SDL_Texture* texture, [NativeTypeName("Uint8 *")] byte* r, [NativeTypeName("Uint8 *")] byte* g, [NativeTypeName("Uint8 *")] byte* b);
|
||||
public static extern SDL_bool 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 int SDL_GetTextureColorModFloat(SDL_Texture* texture, float* r, float* g, float* b);
|
||||
public static extern SDL_bool SDL_GetTextureColorModFloat(SDL_Texture* texture, float* r, float* g, float* b);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetTextureAlphaMod(SDL_Texture* texture, [NativeTypeName("Uint8")] byte alpha);
|
||||
public static extern SDL_bool SDL_SetTextureAlphaMod(SDL_Texture* texture, [NativeTypeName("Uint8")] byte alpha);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetTextureAlphaModFloat(SDL_Texture* texture, float alpha);
|
||||
public static extern SDL_bool SDL_SetTextureAlphaModFloat(SDL_Texture* texture, float alpha);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetTextureAlphaMod(SDL_Texture* texture, [NativeTypeName("Uint8 *")] byte* alpha);
|
||||
public static extern SDL_bool SDL_GetTextureAlphaMod(SDL_Texture* texture, [NativeTypeName("Uint8 *")] byte* alpha);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetTextureAlphaModFloat(SDL_Texture* texture, float* alpha);
|
||||
public static extern SDL_bool SDL_GetTextureAlphaModFloat(SDL_Texture* texture, float* alpha);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetTextureBlendMode(SDL_Texture* texture, SDL_BlendMode blendMode);
|
||||
public static extern SDL_bool SDL_SetTextureBlendMode(SDL_Texture* texture, SDL_BlendMode blendMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetTextureBlendMode(SDL_Texture* texture, SDL_BlendMode* blendMode);
|
||||
public static extern SDL_bool SDL_GetTextureBlendMode(SDL_Texture* texture, SDL_BlendMode* blendMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetTextureScaleMode(SDL_Texture* texture, SDL_ScaleMode scaleMode);
|
||||
public static extern SDL_bool SDL_SetTextureScaleMode(SDL_Texture* texture, SDL_ScaleMode scaleMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetTextureScaleMode(SDL_Texture* texture, SDL_ScaleMode* scaleMode);
|
||||
public static extern SDL_bool SDL_GetTextureScaleMode(SDL_Texture* texture, SDL_ScaleMode* scaleMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_UpdateTexture(SDL_Texture* texture, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, [NativeTypeName("const void *")] IntPtr pixels, int pitch);
|
||||
public static extern SDL_bool 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 int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_LockTexture(SDL_Texture* texture, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, [NativeTypeName("void **")] IntPtr* pixels, int* pitch);
|
||||
public static extern SDL_bool 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 int SDL_LockTextureToSurface(SDL_Texture* texture, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, SDL_Surface** surface);
|
||||
public static extern SDL_bool 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 int SDL_SetRenderTarget(SDL_Renderer* renderer, SDL_Texture* texture);
|
||||
public static extern SDL_bool 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 int SDL_SetRenderLogicalPresentation(SDL_Renderer* renderer, int w, int h, SDL_RendererLogicalPresentation mode, SDL_ScaleMode scale_mode);
|
||||
public static extern SDL_bool 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 int SDL_GetRenderLogicalPresentation(SDL_Renderer* renderer, int* w, int* h, SDL_RendererLogicalPresentation* mode, SDL_ScaleMode* scale_mode);
|
||||
public static extern SDL_bool 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 int SDL_GetRenderLogicalPresentationRect(SDL_Renderer* renderer, SDL_FRect* rect);
|
||||
public static extern SDL_bool SDL_GetRenderLogicalPresentationRect(SDL_Renderer* renderer, SDL_FRect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RenderCoordinatesFromWindow(SDL_Renderer* renderer, float window_x, float window_y, float* x, float* y);
|
||||
public static extern SDL_bool 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 int SDL_RenderCoordinatesToWindow(SDL_Renderer* renderer, float x, float y, float* window_x, float* window_y);
|
||||
public static extern SDL_bool 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 int SDL_ConvertEventToRenderCoordinates(SDL_Renderer* renderer, SDL_Event* @event);
|
||||
public static extern SDL_bool SDL_ConvertEventToRenderCoordinates(SDL_Renderer* renderer, SDL_Event* @event);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetRenderViewport(SDL_Renderer* renderer, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect);
|
||||
public static extern SDL_bool SDL_SetRenderViewport(SDL_Renderer* renderer, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetRenderViewport(SDL_Renderer* renderer, SDL_Rect* rect);
|
||||
public static extern SDL_bool 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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetRenderSafeArea(SDL_Renderer* renderer, SDL_Rect* rect);
|
||||
public static extern SDL_bool SDL_GetRenderSafeArea(SDL_Renderer* renderer, SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetRenderClipRect(SDL_Renderer* renderer, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect);
|
||||
public static extern SDL_bool SDL_SetRenderClipRect(SDL_Renderer* renderer, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetRenderClipRect(SDL_Renderer* renderer, SDL_Rect* rect);
|
||||
public static extern SDL_bool 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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetRenderScale(SDL_Renderer* renderer, float scaleX, float scaleY);
|
||||
public static extern SDL_bool SDL_SetRenderScale(SDL_Renderer* renderer, float scaleX, float scaleY);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetRenderScale(SDL_Renderer* renderer, float* scaleX, float* scaleY);
|
||||
public static extern SDL_bool SDL_GetRenderScale(SDL_Renderer* renderer, float* scaleX, float* scaleY);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetRenderDrawColor(SDL_Renderer* renderer, [NativeTypeName("Uint8")] byte r, [NativeTypeName("Uint8")] byte g, [NativeTypeName("Uint8")] byte b, [NativeTypeName("Uint8")] byte a);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetRenderDrawColorFloat(SDL_Renderer* renderer, float r, float g, float b, float a);
|
||||
public static extern SDL_bool SDL_SetRenderDrawColorFloat(SDL_Renderer* renderer, float r, float g, float b, float a);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetRenderDrawColor(SDL_Renderer* renderer, [NativeTypeName("Uint8 *")] byte* r, [NativeTypeName("Uint8 *")] byte* g, [NativeTypeName("Uint8 *")] byte* b, [NativeTypeName("Uint8 *")] byte* a);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetRenderDrawColorFloat(SDL_Renderer* renderer, float* r, float* g, float* b, float* a);
|
||||
public static extern SDL_bool SDL_GetRenderDrawColorFloat(SDL_Renderer* renderer, float* r, float* g, float* b, float* a);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetRenderColorScale(SDL_Renderer* renderer, float scale);
|
||||
public static extern SDL_bool SDL_SetRenderColorScale(SDL_Renderer* renderer, float scale);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetRenderColorScale(SDL_Renderer* renderer, float* scale);
|
||||
public static extern SDL_bool SDL_GetRenderColorScale(SDL_Renderer* renderer, float* scale);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetRenderDrawBlendMode(SDL_Renderer* renderer, SDL_BlendMode blendMode);
|
||||
public static extern SDL_bool SDL_SetRenderDrawBlendMode(SDL_Renderer* renderer, SDL_BlendMode blendMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetRenderDrawBlendMode(SDL_Renderer* renderer, SDL_BlendMode* blendMode);
|
||||
public static extern SDL_bool SDL_GetRenderDrawBlendMode(SDL_Renderer* renderer, SDL_BlendMode* blendMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RenderClear(SDL_Renderer* renderer);
|
||||
public static extern SDL_bool SDL_RenderClear(SDL_Renderer* renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RenderPoint(SDL_Renderer* renderer, float x, float y);
|
||||
public static extern SDL_bool SDL_RenderPoint(SDL_Renderer* renderer, float x, float y);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RenderPoints(SDL_Renderer* renderer, [NativeTypeName("const SDL_FPoint *")] SDL_FPoint* points, int count);
|
||||
public static extern SDL_bool SDL_RenderPoints(SDL_Renderer* renderer, [NativeTypeName("const SDL_FPoint *")] SDL_FPoint* points, int count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RenderLine(SDL_Renderer* renderer, float x1, float y1, float x2, float y2);
|
||||
public static extern SDL_bool SDL_RenderLine(SDL_Renderer* renderer, float x1, float y1, float x2, float y2);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RenderLines(SDL_Renderer* renderer, [NativeTypeName("const SDL_FPoint *")] SDL_FPoint* points, int count);
|
||||
public static extern SDL_bool SDL_RenderLines(SDL_Renderer* renderer, [NativeTypeName("const SDL_FPoint *")] SDL_FPoint* points, int count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RenderRect(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rect);
|
||||
public static extern SDL_bool SDL_RenderRect(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RenderRects(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rects, int count);
|
||||
public static extern SDL_bool SDL_RenderRects(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rects, int count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RenderFillRect(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rect);
|
||||
public static extern SDL_bool SDL_RenderFillRect(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RenderFillRects(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rects, int count);
|
||||
public static extern SDL_bool SDL_RenderFillRects(SDL_Renderer* renderer, [NativeTypeName("const SDL_FRect *")] SDL_FRect* rects, int count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RenderTexture(SDL_Renderer* renderer, SDL_Texture* texture, [NativeTypeName("const SDL_FRect *")] SDL_FRect* srcrect, [NativeTypeName("const SDL_FRect *")] SDL_FRect* dstrect);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RenderTextureTiled(SDL_Renderer* renderer, SDL_Texture* texture, [NativeTypeName("const SDL_FRect *")] SDL_FRect* srcrect, float scale, [NativeTypeName("const SDL_FRect *")] SDL_FRect* dstrect);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int 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);
|
||||
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);
|
||||
|
||||
[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 int SDL_RenderPresent(SDL_Renderer* renderer);
|
||||
public static extern SDL_bool SDL_RenderPresent(SDL_Renderer* renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DestroyTexture(SDL_Texture* texture);
|
||||
|
|
@ -306,7 +306,7 @@ namespace SDL
|
|||
public static extern void SDL_DestroyRenderer(SDL_Renderer* renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_FlushRenderer(SDL_Renderer* renderer);
|
||||
public static extern SDL_bool SDL_FlushRenderer(SDL_Renderer* renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("void*")]
|
||||
|
|
@ -317,49 +317,49 @@ namespace SDL
|
|||
public static extern IntPtr SDL_GetRenderMetalCommandEncoder(SDL_Renderer* renderer);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_AddVulkanRenderSemaphores(SDL_Renderer* renderer, [NativeTypeName("Uint32")] uint wait_stage_mask, [NativeTypeName("Sint64")] long wait_semaphore, [NativeTypeName("Sint64")] long signal_semaphore);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetRenderVSync(SDL_Renderer* renderer, int vsync);
|
||||
public static extern SDL_bool SDL_SetRenderVSync(SDL_Renderer* renderer, int vsync);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetRenderVSync(SDL_Renderer* renderer, int* vsync);
|
||||
public static extern SDL_bool SDL_GetRenderVSync(SDL_Renderer* renderer, int* vsync);
|
||||
|
||||
[NativeTypeName("#define SDL_SOFTWARE_RENDERER \"software\"")]
|
||||
public static ReadOnlySpan<byte> SDL_SOFTWARE_RENDERER => "software"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_NAME_STRING \"name\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_NAME_STRING => "name"u8;
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_NAME_STRING \"SDL.renderer.create.name\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_NAME_STRING => "SDL.renderer.create.name"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_WINDOW_POINTER \"window\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_WINDOW_POINTER => "window"u8;
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_WINDOW_POINTER \"SDL.renderer.create.window\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_WINDOW_POINTER => "SDL.renderer.create.window"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_SURFACE_POINTER \"surface\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_SURFACE_POINTER => "surface"u8;
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_SURFACE_POINTER \"SDL.renderer.create.surface\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_SURFACE_POINTER => "SDL.renderer.create.surface"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_OUTPUT_COLORSPACE_NUMBER \"output_colorspace\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_OUTPUT_COLORSPACE_NUMBER => "output_colorspace"u8;
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_OUTPUT_COLORSPACE_NUMBER \"SDL.renderer.create.output_colorspace\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_OUTPUT_COLORSPACE_NUMBER => "SDL.renderer.create.output_colorspace"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_PRESENT_VSYNC_NUMBER \"present_vsync\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_PRESENT_VSYNC_NUMBER => "present_vsync"u8;
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_PRESENT_VSYNC_NUMBER \"SDL.renderer.create.present_vsync\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_PRESENT_VSYNC_NUMBER => "SDL.renderer.create.present_vsync"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_VULKAN_INSTANCE_POINTER \"vulkan.instance\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_VULKAN_INSTANCE_POINTER => "vulkan.instance"u8;
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_VULKAN_INSTANCE_POINTER \"SDL.renderer.create.vulkan.instance\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_VULKAN_INSTANCE_POINTER => "SDL.renderer.create.vulkan.instance"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_VULKAN_SURFACE_NUMBER \"vulkan.surface\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_VULKAN_SURFACE_NUMBER => "vulkan.surface"u8;
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_VULKAN_SURFACE_NUMBER \"SDL.renderer.create.vulkan.surface\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_VULKAN_SURFACE_NUMBER => "SDL.renderer.create.vulkan.surface"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_VULKAN_PHYSICAL_DEVICE_POINTER \"vulkan.physical_device\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_VULKAN_PHYSICAL_DEVICE_POINTER => "vulkan.physical_device"u8;
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_VULKAN_PHYSICAL_DEVICE_POINTER \"SDL.renderer.create.vulkan.physical_device\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_VULKAN_PHYSICAL_DEVICE_POINTER => "SDL.renderer.create.vulkan.physical_device"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_VULKAN_DEVICE_POINTER \"vulkan.device\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_VULKAN_DEVICE_POINTER => "vulkan.device"u8;
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_VULKAN_DEVICE_POINTER \"SDL.renderer.create.vulkan.device\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_VULKAN_DEVICE_POINTER => "SDL.renderer.create.vulkan.device"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_VULKAN_GRAPHICS_QUEUE_FAMILY_INDEX_NUMBER \"vulkan.graphics_queue_family_index\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_VULKAN_GRAPHICS_QUEUE_FAMILY_INDEX_NUMBER => "vulkan.graphics_queue_family_index"u8;
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_VULKAN_GRAPHICS_QUEUE_FAMILY_INDEX_NUMBER \"SDL.renderer.create.vulkan.graphics_queue_family_index\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_VULKAN_GRAPHICS_QUEUE_FAMILY_INDEX_NUMBER => "SDL.renderer.create.vulkan.graphics_queue_family_index"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_VULKAN_PRESENT_QUEUE_FAMILY_INDEX_NUMBER \"vulkan.present_queue_family_index\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_VULKAN_PRESENT_QUEUE_FAMILY_INDEX_NUMBER => "vulkan.present_queue_family_index"u8;
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_CREATE_VULKAN_PRESENT_QUEUE_FAMILY_INDEX_NUMBER \"SDL.renderer.create.vulkan.present_queue_family_index\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_CREATE_VULKAN_PRESENT_QUEUE_FAMILY_INDEX_NUMBER => "SDL.renderer.create.vulkan.present_queue_family_index"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_RENDERER_NAME_STRING \"SDL.renderer.name\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_NAME_STRING => "SDL.renderer.name"u8;
|
||||
|
|
@ -430,74 +430,74 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_PROP_RENDERER_VULKAN_SWAPCHAIN_IMAGE_COUNT_NUMBER \"SDL.renderer.vulkan.swapchain_image_count\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_RENDERER_VULKAN_SWAPCHAIN_IMAGE_COUNT_NUMBER => "SDL.renderer.vulkan.swapchain_image_count"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_COLORSPACE_NUMBER \"colorspace\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_COLORSPACE_NUMBER => "colorspace"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_COLORSPACE_NUMBER \"SDL.texture.create.colorspace\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_COLORSPACE_NUMBER => "SDL.texture.create.colorspace"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_FORMAT_NUMBER \"format\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_FORMAT_NUMBER => "format"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_FORMAT_NUMBER \"SDL.texture.create.format\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_FORMAT_NUMBER => "SDL.texture.create.format"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_ACCESS_NUMBER \"access\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_ACCESS_NUMBER => "access"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_ACCESS_NUMBER \"SDL.texture.create.access\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_ACCESS_NUMBER => "SDL.texture.create.access"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_WIDTH_NUMBER \"width\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_WIDTH_NUMBER => "width"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_WIDTH_NUMBER \"SDL.texture.create.width\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_WIDTH_NUMBER => "SDL.texture.create.width"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_HEIGHT_NUMBER \"height\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_HEIGHT_NUMBER => "height"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_HEIGHT_NUMBER \"SDL.texture.create.height\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_HEIGHT_NUMBER => "SDL.texture.create.height"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_SDR_WHITE_POINT_FLOAT \"SDR_white_point\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_SDR_WHITE_POINT_FLOAT => "SDR_white_point"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_SDR_WHITE_POINT_FLOAT \"SDL.texture.create.SDR_white_point\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_SDR_WHITE_POINT_FLOAT => "SDL.texture.create.SDR_white_point"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_HDR_HEADROOM_FLOAT \"HDR_headroom\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_HDR_HEADROOM_FLOAT => "HDR_headroom"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_HDR_HEADROOM_FLOAT \"SDL.texture.create.HDR_headroom\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_HDR_HEADROOM_FLOAT => "SDL.texture.create.HDR_headroom"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_D3D11_TEXTURE_POINTER \"d3d11.texture\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_D3D11_TEXTURE_POINTER => "d3d11.texture"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_D3D11_TEXTURE_POINTER \"SDL.texture.create.d3d11.texture\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_D3D11_TEXTURE_POINTER => "SDL.texture.create.d3d11.texture"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_D3D11_TEXTURE_U_POINTER \"d3d11.texture_u\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_D3D11_TEXTURE_U_POINTER => "d3d11.texture_u"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_D3D11_TEXTURE_U_POINTER \"SDL.texture.create.d3d11.texture_u\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_D3D11_TEXTURE_U_POINTER => "SDL.texture.create.d3d11.texture_u"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_D3D11_TEXTURE_V_POINTER \"d3d11.texture_v\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_D3D11_TEXTURE_V_POINTER => "d3d11.texture_v"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_D3D11_TEXTURE_V_POINTER \"SDL.texture.create.d3d11.texture_v\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_D3D11_TEXTURE_V_POINTER => "SDL.texture.create.d3d11.texture_v"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_D3D12_TEXTURE_POINTER \"d3d12.texture\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_D3D12_TEXTURE_POINTER => "d3d12.texture"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_D3D12_TEXTURE_POINTER \"SDL.texture.create.d3d12.texture\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_D3D12_TEXTURE_POINTER => "SDL.texture.create.d3d12.texture"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_D3D12_TEXTURE_U_POINTER \"d3d12.texture_u\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_D3D12_TEXTURE_U_POINTER => "d3d12.texture_u"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_D3D12_TEXTURE_U_POINTER \"SDL.texture.create.d3d12.texture_u\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_D3D12_TEXTURE_U_POINTER => "SDL.texture.create.d3d12.texture_u"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_D3D12_TEXTURE_V_POINTER \"d3d12.texture_v\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_D3D12_TEXTURE_V_POINTER => "d3d12.texture_v"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_D3D12_TEXTURE_V_POINTER \"SDL.texture.create.d3d12.texture_v\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_D3D12_TEXTURE_V_POINTER => "SDL.texture.create.d3d12.texture_v"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_METAL_PIXELBUFFER_POINTER \"metal.pixelbuffer\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_METAL_PIXELBUFFER_POINTER => "metal.pixelbuffer"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_METAL_PIXELBUFFER_POINTER \"SDL.texture.create.metal.pixelbuffer\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_METAL_PIXELBUFFER_POINTER => "SDL.texture.create.metal.pixelbuffer"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_NUMBER \"opengl.texture\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_NUMBER => "opengl.texture"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_NUMBER \"SDL.texture.create.opengl.texture\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_NUMBER => "SDL.texture.create.opengl.texture"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_UV_NUMBER \"opengl.texture_uv\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_UV_NUMBER => "opengl.texture_uv"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_UV_NUMBER \"SDL.texture.create.opengl.texture_uv\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_UV_NUMBER => "SDL.texture.create.opengl.texture_uv"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_U_NUMBER \"opengl.texture_u\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_U_NUMBER => "opengl.texture_u"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_U_NUMBER \"SDL.texture.create.opengl.texture_u\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_U_NUMBER => "SDL.texture.create.opengl.texture_u"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_V_NUMBER \"opengl.texture_v\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_V_NUMBER => "opengl.texture_v"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_V_NUMBER \"SDL.texture.create.opengl.texture_v\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGL_TEXTURE_V_NUMBER => "SDL.texture.create.opengl.texture_v"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_NUMBER \"opengles2.texture\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_NUMBER => "opengles2.texture"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_NUMBER \"SDL.texture.create.opengles2.texture\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_NUMBER => "SDL.texture.create.opengles2.texture"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_UV_NUMBER \"opengles2.texture_uv\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_UV_NUMBER => "opengles2.texture_uv"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_UV_NUMBER \"SDL.texture.create.opengles2.texture_uv\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_UV_NUMBER => "SDL.texture.create.opengles2.texture_uv"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_U_NUMBER \"opengles2.texture_u\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_U_NUMBER => "opengles2.texture_u"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_U_NUMBER \"SDL.texture.create.opengles2.texture_u\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_U_NUMBER => "SDL.texture.create.opengles2.texture_u"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_V_NUMBER \"opengles2.texture_v\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_V_NUMBER => "opengles2.texture_v"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_V_NUMBER \"SDL.texture.create.opengles2.texture_v\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_OPENGLES2_TEXTURE_V_NUMBER => "SDL.texture.create.opengles2.texture_v"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_VULKAN_TEXTURE_NUMBER \"vulkan.texture\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_VULKAN_TEXTURE_NUMBER => "vulkan.texture"u8;
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_CREATE_VULKAN_TEXTURE_NUMBER \"SDL.texture.create.vulkan.texture\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_CREATE_VULKAN_TEXTURE_NUMBER => "SDL.texture.create.vulkan.texture"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_TEXTURE_COLORSPACE_NUMBER \"SDL.texture.colorspace\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_TEXTURE_COLORSPACE_NUMBER => "SDL.texture.colorspace"u8;
|
||||
|
|
|
|||
|
|
@ -275,6 +275,6 @@ namespace SDL
|
|||
SDL_SCANCODE_CALL = 289,
|
||||
SDL_SCANCODE_ENDCALL = 290,
|
||||
SDL_SCANCODE_RESERVED = 400,
|
||||
SDL_NUM_SCANCODES = 512,
|
||||
SDL_SCANCODE_COUNT = 512,
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -81,7 +81,7 @@ namespace SDL
|
|||
public static extern SDL_SensorID SDL_GetSensorID(SDL_Sensor* sensor);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetSensorData(SDL_Sensor* sensor, float* data, int num_values);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
|
|||
|
|
@ -28,11 +28,24 @@ using System.Runtime.InteropServices;
|
|||
|
||||
namespace SDL
|
||||
{
|
||||
public partial struct SDL_alignment_test
|
||||
{
|
||||
[NativeTypeName("Uint8")]
|
||||
public byte a;
|
||||
|
||||
[NativeTypeName("void*")]
|
||||
public IntPtr b;
|
||||
}
|
||||
|
||||
public enum SDL_DUMMY_ENUM
|
||||
{
|
||||
DUMMY_ENUM_VALUE,
|
||||
}
|
||||
|
||||
public partial struct SDL_Environment
|
||||
{
|
||||
}
|
||||
|
||||
public partial struct SDL_iconv_data_t
|
||||
{
|
||||
}
|
||||
|
|
@ -61,7 +74,7 @@ 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 int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("void*")]
|
||||
|
|
@ -73,15 +86,41 @@ namespace SDL
|
|||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetNumAllocations();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_getenv", ExactSpelling = true)]
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_GetEnvironmentVariable", ExactSpelling = true)]
|
||||
[return: NativeTypeName("const char *")]
|
||||
public static extern byte* Unsafe_SDL_getenv([NativeTypeName("const char *")] byte* name);
|
||||
public static extern byte* Unsafe_SDL_GetEnvironmentVariable(SDL_Environment* env, [NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_setenv([NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value, int overwrite);
|
||||
[return: NativeTypeName("char **")]
|
||||
public static extern byte** SDL_GetEnvironmentVariables(SDL_Environment* env);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_unsetenv([NativeTypeName("const char *")] byte* name);
|
||||
public static extern SDL_bool SDL_SetEnvironmentVariable(SDL_Environment* env, [NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value, SDL_bool overwrite);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool 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_unsafe", ExactSpelling = true)]
|
||||
[return: NativeTypeName("const char *")]
|
||||
public static extern byte* Unsafe_SDL_getenv_unsafe([NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_setenv_unsafe([NativeTypeName("const char *")] byte* name, [NativeTypeName("const char *")] byte* value, int overwrite);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_unsetenv_unsafe([NativeTypeName("const char *")] byte* name);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_qsort([NativeTypeName("void*")] IntPtr @base, [NativeTypeName("size_t")] nuint nmemb, [NativeTypeName("size_t")] nuint size, [NativeTypeName("SDL_CompareCallback")] delegate* unmanaged[Cdecl]<IntPtr, IntPtr, int> compare);
|
||||
|
|
@ -303,11 +342,11 @@ namespace SDL
|
|||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_lltoa", ExactSpelling = true)]
|
||||
[return: NativeTypeName("char *")]
|
||||
public static extern byte* Unsafe_SDL_lltoa([NativeTypeName("Sint64")] long value, [NativeTypeName("char *")] byte* str, int radix);
|
||||
public static extern byte* Unsafe_SDL_lltoa([NativeTypeName("long long")] long value, [NativeTypeName("char *")] byte* str, int radix);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_ulltoa", ExactSpelling = true)]
|
||||
[return: NativeTypeName("char *")]
|
||||
public static extern byte* Unsafe_SDL_ulltoa([NativeTypeName("Uint64")] ulong value, [NativeTypeName("char *")] byte* str, int radix);
|
||||
public static extern byte* Unsafe_SDL_ulltoa([NativeTypeName("unsigned long long")] ulong value, [NativeTypeName("char *")] byte* str, int radix);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_atoi([NativeTypeName("const char *")] byte* str);
|
||||
|
|
@ -324,11 +363,11 @@ namespace SDL
|
|||
public static extern uint SDL_strtoul([NativeTypeName("const char *")] byte* str, [NativeTypeName("char **")] byte** endp, int @base);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Sint64")]
|
||||
[return: NativeTypeName("long long")]
|
||||
public static extern long SDL_strtoll([NativeTypeName("const char *")] byte* str, [NativeTypeName("char **")] byte** endp, int @base);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Uint64")]
|
||||
[return: NativeTypeName("unsigned long long")]
|
||||
public static extern ulong SDL_strtoull([NativeTypeName("const char *")] byte* str, [NativeTypeName("char **")] byte** endp, int @base);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
|
|
@ -346,6 +385,10 @@ namespace SDL
|
|||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_strncasecmp([NativeTypeName("const char *")] byte* str1, [NativeTypeName("const char *")] byte* str2, [NativeTypeName("size_t")] nuint maxlen);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_strpbrk", ExactSpelling = true)]
|
||||
[return: NativeTypeName("char *")]
|
||||
public static extern byte* Unsafe_SDL_strpbrk([NativeTypeName("const char *")] byte* str, [NativeTypeName("const char *")] byte* breakset);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Uint32")]
|
||||
public static extern uint SDL_StepUTF8([NativeTypeName("const char **")] byte** pstr, [NativeTypeName("size_t *")] nuint* pslen);
|
||||
|
|
@ -564,26 +607,26 @@ 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 int SDL_size_mul_overflow([NativeTypeName("size_t")] nuint a, [NativeTypeName("size_t")] nuint b, [NativeTypeName("size_t *")] nuint* ret)
|
||||
public static SDL_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)
|
||||
{
|
||||
return -1;
|
||||
return (SDL_bool)(0);
|
||||
}
|
||||
|
||||
*ret = a * b;
|
||||
return 0;
|
||||
return (SDL_bool)(1);
|
||||
}
|
||||
|
||||
public static int SDL_size_add_overflow([NativeTypeName("size_t")] nuint a, [NativeTypeName("size_t")] nuint b, [NativeTypeName("size_t *")] nuint* ret)
|
||||
public static SDL_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)
|
||||
{
|
||||
return -1;
|
||||
return (SDL_bool)(0);
|
||||
}
|
||||
|
||||
*ret = a + b;
|
||||
return 0;
|
||||
return (SDL_bool)(1);
|
||||
}
|
||||
|
||||
[NativeTypeName("#define SDL_SIZE_MAX SIZE_MAX")]
|
||||
|
|
|
|||
|
|
@ -30,35 +30,38 @@ namespace SDL
|
|||
{
|
||||
public unsafe partial struct SDL_StorageInterface
|
||||
{
|
||||
[NativeTypeName("int (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, int> close;
|
||||
[NativeTypeName("Uint32")]
|
||||
public uint version;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, SDL_bool> close;
|
||||
|
||||
[NativeTypeName("SDL_bool (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, SDL_bool> ready;
|
||||
|
||||
[NativeTypeName("int (*)(void *, const char *, SDL_EnumerateDirectoryCallback, void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, int>, IntPtr, int> enumerate;
|
||||
[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("int (*)(void *, const char *, SDL_PathInfo *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, SDL_PathInfo*, int> info;
|
||||
[NativeTypeName("SDL_bool (*)(void *, const char *, SDL_PathInfo *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, SDL_PathInfo*, SDL_bool> info;
|
||||
|
||||
[NativeTypeName("int (*)(void *, const char *, void *, Uint64)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, IntPtr, ulong, int> read_file;
|
||||
[NativeTypeName("SDL_bool (*)(void *, const char *, void *, Uint64)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, IntPtr, ulong, SDL_bool> read_file;
|
||||
|
||||
[NativeTypeName("int (*)(void *, const char *, const void *, Uint64)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, IntPtr, ulong, int> write_file;
|
||||
[NativeTypeName("SDL_bool (*)(void *, const char *, const void *, Uint64)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, IntPtr, ulong, SDL_bool> write_file;
|
||||
|
||||
[NativeTypeName("int (*)(void *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, int> mkdir;
|
||||
[NativeTypeName("SDL_bool (*)(void *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, SDL_bool> mkdir;
|
||||
|
||||
[NativeTypeName("int (*)(void *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, int> remove;
|
||||
[NativeTypeName("SDL_bool (*)(void *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, SDL_bool> remove;
|
||||
|
||||
[NativeTypeName("int (*)(void *, const char *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, int> rename;
|
||||
[NativeTypeName("SDL_bool (*)(void *, const char *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, SDL_bool> rename;
|
||||
|
||||
[NativeTypeName("int (*)(void *, const char *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, int> copy;
|
||||
[NativeTypeName("SDL_bool (*)(void *, const char *, const char *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, byte*, byte*, SDL_bool> copy;
|
||||
|
||||
[NativeTypeName("Uint64 (*)(void *)")]
|
||||
public delegate* unmanaged[Cdecl]<IntPtr, ulong> space_remaining;
|
||||
|
|
@ -83,37 +86,37 @@ 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 int SDL_CloseStorage(SDL_Storage* storage);
|
||||
public static extern SDL_bool SDL_CloseStorage(SDL_Storage* storage);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_StorageReady(SDL_Storage* storage);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetStorageFileSize(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, [NativeTypeName("Uint64 *")] ulong* length);
|
||||
public static extern SDL_bool SDL_GetStorageFileSize(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, [NativeTypeName("Uint64 *")] ulong* length);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ReadStorageFile(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, [NativeTypeName("void*")] IntPtr destination, [NativeTypeName("Uint64")] ulong length);
|
||||
public static extern SDL_bool 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 int SDL_WriteStorageFile(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, [NativeTypeName("const void *")] IntPtr source, [NativeTypeName("Uint64")] ulong length);
|
||||
public static extern SDL_bool 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 int SDL_CreateStorageDirectory(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path);
|
||||
public static extern SDL_bool SDL_CreateStorageDirectory(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RemoveStoragePath(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path);
|
||||
public static extern SDL_bool SDL_RemoveStoragePath(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RenameStoragePath(SDL_Storage* storage, [NativeTypeName("const char *")] byte* oldpath, [NativeTypeName("const char *")] byte* newpath);
|
||||
public static extern SDL_bool 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 int SDL_CopyStorageFile(SDL_Storage* storage, [NativeTypeName("const char *")] byte* oldpath, [NativeTypeName("const char *")] byte* newpath);
|
||||
public static extern SDL_bool 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 int SDL_GetStoragePathInfo(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, SDL_PathInfo* info);
|
||||
public static extern SDL_bool SDL_GetStoragePathInfo(SDL_Storage* storage, [NativeTypeName("const char *")] byte* path, SDL_PathInfo* info);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Uint64")]
|
||||
|
|
|
|||
|
|
@ -32,7 +32,6 @@ namespace SDL
|
|||
{
|
||||
SDL_SCALEMODE_NEAREST,
|
||||
SDL_SCALEMODE_LINEAR,
|
||||
SDL_SCALEMODE_BEST,
|
||||
}
|
||||
|
||||
public enum SDL_FlipMode
|
||||
|
|
@ -81,7 +80,7 @@ namespace SDL
|
|||
public static extern SDL_PropertiesID SDL_GetSurfaceProperties(SDL_Surface* surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetSurfaceColorspace(SDL_Surface* surface, SDL_Colorspace colorspace);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
@ -90,13 +89,13 @@ namespace SDL
|
|||
public static extern SDL_Palette* SDL_CreateSurfacePalette(SDL_Surface* surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetSurfacePalette(SDL_Surface* surface, SDL_Palette* palette);
|
||||
public static extern SDL_bool 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 int SDL_AddSurfaceAlternateImage(SDL_Surface* surface, SDL_Surface* image);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
@ -108,7 +107,7 @@ namespace SDL
|
|||
public static extern void SDL_RemoveSurfaceAlternateImages(SDL_Surface* surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_LockSurface(SDL_Surface* surface);
|
||||
public static extern SDL_bool SDL_LockSurface(SDL_Surface* surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_UnlockSurface(SDL_Surface* surface);
|
||||
|
|
@ -120,52 +119,52 @@ namespace SDL
|
|||
public static extern SDL_Surface* SDL_LoadBMP([NativeTypeName("const char *")] byte* file);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SaveBMP_IO(SDL_Surface* surface, SDL_IOStream* dst, SDL_bool closeio);
|
||||
public static extern SDL_bool SDL_SaveBMP_IO(SDL_Surface* surface, SDL_IOStream* dst, SDL_bool closeio);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SaveBMP(SDL_Surface* surface, [NativeTypeName("const char *")] byte* file);
|
||||
public static extern SDL_bool SDL_SaveBMP(SDL_Surface* surface, [NativeTypeName("const char *")] byte* file);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetSurfaceRLE(SDL_Surface* surface, SDL_bool enabled);
|
||||
public static extern SDL_bool SDL_SetSurfaceRLE(SDL_Surface* surface, SDL_bool enabled);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SurfaceHasRLE(SDL_Surface* surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetSurfaceColorKey(SDL_Surface* surface, SDL_bool enabled, [NativeTypeName("Uint32")] uint key);
|
||||
public static extern SDL_bool SDL_SetSurfaceColorKey(SDL_Surface* surface, SDL_bool enabled, [NativeTypeName("Uint32")] uint key);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_SurfaceHasColorKey(SDL_Surface* surface);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetSurfaceColorKey(SDL_Surface* surface, [NativeTypeName("Uint32 *")] uint* key);
|
||||
public static extern SDL_bool SDL_GetSurfaceColorKey(SDL_Surface* surface, [NativeTypeName("Uint32 *")] uint* key);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetSurfaceColorMod(SDL_Surface* surface, [NativeTypeName("Uint8")] byte r, [NativeTypeName("Uint8")] byte g, [NativeTypeName("Uint8")] byte b);
|
||||
public static extern SDL_bool 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 int SDL_GetSurfaceColorMod(SDL_Surface* surface, [NativeTypeName("Uint8 *")] byte* r, [NativeTypeName("Uint8 *")] byte* g, [NativeTypeName("Uint8 *")] byte* b);
|
||||
public static extern SDL_bool 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 int SDL_SetSurfaceAlphaMod(SDL_Surface* surface, [NativeTypeName("Uint8")] byte alpha);
|
||||
public static extern SDL_bool SDL_SetSurfaceAlphaMod(SDL_Surface* surface, [NativeTypeName("Uint8")] byte alpha);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetSurfaceAlphaMod(SDL_Surface* surface, [NativeTypeName("Uint8 *")] byte* alpha);
|
||||
public static extern SDL_bool SDL_GetSurfaceAlphaMod(SDL_Surface* surface, [NativeTypeName("Uint8 *")] byte* alpha);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetSurfaceBlendMode(SDL_Surface* surface, SDL_BlendMode blendMode);
|
||||
public static extern SDL_bool SDL_SetSurfaceBlendMode(SDL_Surface* surface, SDL_BlendMode blendMode);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetSurfaceBlendMode(SDL_Surface* surface, SDL_BlendMode* blendMode);
|
||||
public static extern SDL_bool 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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetSurfaceClipRect(SDL_Surface* surface, SDL_Rect* rect);
|
||||
public static extern SDL_bool SDL_GetSurfaceClipRect(SDL_Surface* surface, SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_FlipSurface(SDL_Surface* surface, SDL_FlipMode flip);
|
||||
public static extern SDL_bool 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);
|
||||
|
|
@ -180,46 +179,46 @@ 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 int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_PremultiplySurfaceAlpha(SDL_Surface* surface, SDL_bool linear);
|
||||
public static extern SDL_bool SDL_PremultiplySurfaceAlpha(SDL_Surface* surface, SDL_bool linear);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ClearSurface(SDL_Surface* surface, float r, float g, float b, float a);
|
||||
public static extern SDL_bool SDL_ClearSurface(SDL_Surface* surface, float r, float g, float b, float a);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_FillSurfaceRect(SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect, [NativeTypeName("Uint32")] uint color);
|
||||
public static extern SDL_bool 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 int SDL_FillSurfaceRects(SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rects, int count, [NativeTypeName("Uint32")] uint color);
|
||||
public static extern SDL_bool 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 int SDL_BlitSurface(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_BlitSurfaceUnchecked(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_BlitSurfaceTiled(SDL_Surface* src, [NativeTypeName("const SDL_Rect *")] SDL_Rect* srcrect, SDL_Surface* dst, [NativeTypeName("const SDL_Rect *")] SDL_Rect* dstrect);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("Uint32")]
|
||||
|
|
@ -230,16 +229,16 @@ 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 int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ReadSurfacePixelFloat(SDL_Surface* surface, int x, int y, float* r, float* g, float* b, float* a);
|
||||
public static extern SDL_bool 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 int 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);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_WriteSurfacePixelFloat(SDL_Surface* surface, int x, int y, float r, float g, float b, float a);
|
||||
public static extern SDL_bool 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;
|
||||
|
|
|
|||
|
|
@ -83,15 +83,15 @@ namespace SDL
|
|||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Android")]
|
||||
public static extern int 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 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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Android")]
|
||||
public static extern int SDL_ShowAndroidToast([NativeTypeName("const char *")] byte* message, int duration, int gravity, int xoffset, int yoffset);
|
||||
public static extern SDL_bool SDL_ShowAndroidToast([NativeTypeName("const char *")] byte* message, int duration, int gravity, int xoffset, int yoffset);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Android")]
|
||||
public static extern int SDL_SendAndroidMessage([NativeTypeName("Uint32")] uint command, int param1);
|
||||
public static extern SDL_bool 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;
|
||||
|
|
|
|||
|
|
@ -28,31 +28,22 @@ using System.Runtime.Versioning;
|
|||
|
||||
namespace SDL
|
||||
{
|
||||
public enum SDL_WinRT_Path
|
||||
public partial struct XTaskQueueObject
|
||||
{
|
||||
SDL_WINRT_PATH_INSTALLED_LOCATION,
|
||||
SDL_WINRT_PATH_LOCAL_FOLDER,
|
||||
SDL_WINRT_PATH_ROAMING_FOLDER,
|
||||
SDL_WINRT_PATH_TEMP_FOLDER,
|
||||
}
|
||||
|
||||
public enum SDL_WinRT_DeviceFamily
|
||||
public partial struct XUser
|
||||
{
|
||||
SDL_WINRT_DEVICEFAMILY_UNKNOWN,
|
||||
SDL_WINRT_DEVICEFAMILY_DESKTOP,
|
||||
SDL_WINRT_DEVICEFAMILY_MOBILE,
|
||||
SDL_WINRT_DEVICEFAMILY_XBOX,
|
||||
}
|
||||
|
||||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, EntryPoint = "SDL_GetWinRTFSPath", ExactSpelling = true)]
|
||||
[return: NativeTypeName("const char *")]
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
public static extern byte* Unsafe_SDL_GetWinRTFSPath(SDL_WinRT_Path pathType);
|
||||
public static extern SDL_bool SDL_GetGDKTaskQueue([NativeTypeName("XTaskQueueHandle *")] XTaskQueueObject** outTaskQueue);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
public static extern SDL_WinRT_DeviceFamily SDL_GetWinRTDeviceFamily();
|
||||
public static extern SDL_bool SDL_GetGDKDefaultUser([NativeTypeName("XUserHandle *")] XUser** outUserHandle);
|
||||
}
|
||||
}
|
||||
|
|
@ -32,10 +32,10 @@ namespace SDL
|
|||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Linux")]
|
||||
public static extern int SDL_SetLinuxThreadPriority([NativeTypeName("Sint64")] long threadID, int priority);
|
||||
public static extern SDL_bool SDL_SetLinuxThreadPriority([NativeTypeName("Sint64")] long threadID, int priority);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Linux")]
|
||||
public static extern int SDL_SetLinuxThreadPriorityAndPolicy([NativeTypeName("Sint64")] long threadID, int sdlPriority, int schedPolicy);
|
||||
public static extern SDL_bool SDL_SetLinuxThreadPriorityAndPolicy([NativeTypeName("Sint64")] long threadID, int sdlPriority, int schedPolicy);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -29,14 +29,6 @@ using System.Runtime.Versioning;
|
|||
|
||||
namespace SDL
|
||||
{
|
||||
public partial struct XTaskQueueObject
|
||||
{
|
||||
}
|
||||
|
||||
public partial struct XUser
|
||||
{
|
||||
}
|
||||
|
||||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
|
|
@ -49,14 +41,6 @@ namespace SDL
|
|||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
public static extern int SDL_GetDXGIOutputInfo(SDL_DisplayID displayID, int* adapterIndex, int* outputIndex);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
public static extern int SDL_GetGDKTaskQueue([NativeTypeName("XTaskQueueHandle *")] XTaskQueueObject** outTaskQueue);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("Windows")]
|
||||
public static extern int SDL_GetGDKDefaultUser([NativeTypeName("XUserHandle *")] XUser** outUserHandle);
|
||||
public static extern SDL_bool SDL_GetDXGIOutputInfo(SDL_DisplayID displayID, int* adapterIndex, int* outputIndex);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ namespace SDL
|
|||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("iOS")]
|
||||
public static extern int SDL_SetiOSAnimationCallback(SDL_Window* window, int interval, [NativeTypeName("SDL_iOSAnimationCallback")] delegate* unmanaged[Cdecl]<IntPtr, void> callback, [NativeTypeName("void*")] IntPtr callbackParam);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[SupportedOSPlatform("iOS")]
|
||||
|
|
|
|||
|
|
@ -59,7 +59,7 @@ namespace SDL
|
|||
public static extern SDL_ThreadID SDL_GetThreadID(SDL_Thread* thread);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetThreadPriority(SDL_ThreadPriority priority);
|
||||
public static extern SDL_bool 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 +72,7 @@ namespace SDL
|
|||
public static extern IntPtr SDL_GetTLS(SDL_TLSID* id);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetTLS(SDL_TLSID* id, [NativeTypeName("const void *")] IntPtr value, [NativeTypeName("SDL_TLSDestructorCallback")] delegate* unmanaged[Cdecl]<IntPtr, void> destructor);
|
||||
public static extern SDL_bool 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();
|
||||
|
|
@ -83,16 +83,16 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_EndThreadFunction NULL")]
|
||||
public const int SDL_EndThreadFunction = 0;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_THREAD_CREATE_ENTRY_FUNCTION_POINTER \"entry_function\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_THREAD_CREATE_ENTRY_FUNCTION_POINTER => "entry_function"u8;
|
||||
[NativeTypeName("#define SDL_PROP_THREAD_CREATE_ENTRY_FUNCTION_POINTER \"SDL.thread.create.entry_function\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_THREAD_CREATE_ENTRY_FUNCTION_POINTER => "SDL.thread.create.entry_function"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_THREAD_CREATE_NAME_STRING \"name\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_THREAD_CREATE_NAME_STRING => "name"u8;
|
||||
[NativeTypeName("#define SDL_PROP_THREAD_CREATE_NAME_STRING \"SDL.thread.create.name\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_THREAD_CREATE_NAME_STRING => "SDL.thread.create.name"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_THREAD_CREATE_USERDATA_POINTER \"userdata\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_THREAD_CREATE_USERDATA_POINTER => "userdata"u8;
|
||||
[NativeTypeName("#define SDL_PROP_THREAD_CREATE_USERDATA_POINTER \"SDL.thread.create.userdata\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_THREAD_CREATE_USERDATA_POINTER => "SDL.thread.create.userdata"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_THREAD_CREATE_STACKSIZE_NUMBER \"stacksize\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_THREAD_CREATE_STACKSIZE_NUMBER => "stacksize"u8;
|
||||
[NativeTypeName("#define SDL_PROP_THREAD_CREATE_STACKSIZE_NUMBER \"SDL.thread.create.stacksize\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_THREAD_CREATE_STACKSIZE_NUMBER => "SDL.thread.create.stacksize"u8;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -64,16 +64,16 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetDateTimeLocalePreferences(SDL_DateFormat* dateFormat, SDL_TimeFormat* timeFormat);
|
||||
public static extern SDL_bool SDL_GetDateTimeLocalePreferences(SDL_DateFormat* dateFormat, SDL_TimeFormat* timeFormat);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetCurrentTime(SDL_Time* ticks);
|
||||
public static extern SDL_bool SDL_GetCurrentTime(SDL_Time* ticks);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_TimeToDateTime(SDL_Time ticks, SDL_DateTime* dt, SDL_bool localTime);
|
||||
public static extern SDL_bool SDL_TimeToDateTime(SDL_Time ticks, SDL_DateTime* dt, SDL_bool localTime);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_DateTimeToTime([NativeTypeName("const SDL_DateTime *")] SDL_DateTime* dt, SDL_Time* ticks);
|
||||
public static extern SDL_bool 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,7 @@ 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 int SDL_RemoveTimer(SDL_TimerID id);
|
||||
public static extern SDL_bool SDL_RemoveTimer(SDL_TimerID id);
|
||||
|
||||
[NativeTypeName("#define SDL_MS_PER_SECOND 1000")]
|
||||
public const int SDL_MS_PER_SECOND = 1000;
|
||||
|
|
|
|||
|
|
@ -187,10 +187,10 @@ namespace SDL
|
|||
public static extern byte* Unsafe_SDL_GetDisplayName(SDL_DisplayID displayID);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetDisplayBounds(SDL_DisplayID displayID, SDL_Rect* rect);
|
||||
public static extern SDL_bool SDL_GetDisplayBounds(SDL_DisplayID displayID, SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetDisplayUsableBounds(SDL_DisplayID displayID, SDL_Rect* rect);
|
||||
public static extern SDL_bool 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 +205,7 @@ namespace SDL
|
|||
public static extern SDL_DisplayMode** SDL_GetFullscreenDisplayModes(SDL_DisplayID displayID, int* count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetClosestFullscreenDisplayMode(SDL_DisplayID displayID, int w, int h, float refresh_rate, SDL_bool include_high_density_modes, SDL_DisplayMode* mode);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("const SDL_DisplayMode *")]
|
||||
|
|
@ -231,7 +231,7 @@ namespace SDL
|
|||
public static extern float SDL_GetWindowDisplayScale(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowFullscreenMode(SDL_Window* window, [NativeTypeName("const SDL_DisplayMode *")] SDL_DisplayMode* mode);
|
||||
public static extern SDL_bool 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,86 +272,86 @@ namespace SDL
|
|||
public static extern SDL_WindowFlags SDL_GetWindowFlags(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowTitle(SDL_Window* window, [NativeTypeName("const char *")] byte* title);
|
||||
public static extern SDL_bool 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 int SDL_SetWindowIcon(SDL_Window* window, SDL_Surface* icon);
|
||||
public static extern SDL_bool SDL_SetWindowIcon(SDL_Window* window, SDL_Surface* icon);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowPosition(SDL_Window* window, int x, int y);
|
||||
public static extern SDL_bool SDL_SetWindowPosition(SDL_Window* window, int x, int y);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetWindowPosition(SDL_Window* window, int* x, int* y);
|
||||
public static extern SDL_bool SDL_GetWindowPosition(SDL_Window* window, int* x, int* y);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowSize(SDL_Window* window, int w, int h);
|
||||
public static extern SDL_bool SDL_SetWindowSize(SDL_Window* window, int w, int h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetWindowSize(SDL_Window* window, int* w, int* h);
|
||||
public static extern SDL_bool SDL_GetWindowSize(SDL_Window* window, int* w, int* h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetWindowSafeArea(SDL_Window* window, SDL_Rect* rect);
|
||||
public static extern SDL_bool SDL_GetWindowSafeArea(SDL_Window* window, SDL_Rect* rect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowAspectRatio(SDL_Window* window, float min_aspect, float max_aspect);
|
||||
public static extern SDL_bool SDL_SetWindowAspectRatio(SDL_Window* window, float min_aspect, float max_aspect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetWindowAspectRatio(SDL_Window* window, float* min_aspect, float* max_aspect);
|
||||
public static extern SDL_bool SDL_GetWindowAspectRatio(SDL_Window* window, float* min_aspect, float* max_aspect);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetWindowBordersSize(SDL_Window* window, int* top, int* left, int* bottom, int* right);
|
||||
public static extern SDL_bool SDL_GetWindowBordersSize(SDL_Window* window, int* top, int* left, int* bottom, int* right);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetWindowSizeInPixels(SDL_Window* window, int* w, int* h);
|
||||
public static extern SDL_bool SDL_GetWindowSizeInPixels(SDL_Window* window, int* w, int* h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowMinimumSize(SDL_Window* window, int min_w, int min_h);
|
||||
public static extern SDL_bool SDL_SetWindowMinimumSize(SDL_Window* window, int min_w, int min_h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetWindowMinimumSize(SDL_Window* window, int* w, int* h);
|
||||
public static extern SDL_bool SDL_GetWindowMinimumSize(SDL_Window* window, int* w, int* h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowMaximumSize(SDL_Window* window, int max_w, int max_h);
|
||||
public static extern SDL_bool SDL_SetWindowMaximumSize(SDL_Window* window, int max_w, int max_h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetWindowMaximumSize(SDL_Window* window, int* w, int* h);
|
||||
public static extern SDL_bool SDL_GetWindowMaximumSize(SDL_Window* window, int* w, int* h);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowBordered(SDL_Window* window, SDL_bool bordered);
|
||||
public static extern SDL_bool SDL_SetWindowBordered(SDL_Window* window, SDL_bool bordered);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowResizable(SDL_Window* window, SDL_bool resizable);
|
||||
public static extern SDL_bool SDL_SetWindowResizable(SDL_Window* window, SDL_bool resizable);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowAlwaysOnTop(SDL_Window* window, SDL_bool on_top);
|
||||
public static extern SDL_bool SDL_SetWindowAlwaysOnTop(SDL_Window* window, SDL_bool on_top);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ShowWindow(SDL_Window* window);
|
||||
public static extern SDL_bool SDL_ShowWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_HideWindow(SDL_Window* window);
|
||||
public static extern SDL_bool SDL_HideWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RaiseWindow(SDL_Window* window);
|
||||
public static extern SDL_bool SDL_RaiseWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_MaximizeWindow(SDL_Window* window);
|
||||
public static extern SDL_bool SDL_MaximizeWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_MinimizeWindow(SDL_Window* window);
|
||||
public static extern SDL_bool SDL_MinimizeWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_RestoreWindow(SDL_Window* window);
|
||||
public static extern SDL_bool SDL_RestoreWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowFullscreen(SDL_Window* window, SDL_bool fullscreen);
|
||||
public static extern SDL_bool SDL_SetWindowFullscreen(SDL_Window* window, SDL_bool fullscreen);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SyncWindow(SDL_Window* window);
|
||||
public static extern SDL_bool SDL_SyncWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_WindowHasSurface(SDL_Window* window);
|
||||
|
|
@ -360,25 +360,25 @@ namespace SDL
|
|||
public static extern SDL_Surface* SDL_GetWindowSurface(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowSurfaceVSync(SDL_Window* window, int vsync);
|
||||
public static extern SDL_bool SDL_SetWindowSurfaceVSync(SDL_Window* window, int vsync);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GetWindowSurfaceVSync(SDL_Window* window, int* vsync);
|
||||
public static extern SDL_bool SDL_GetWindowSurfaceVSync(SDL_Window* window, int* vsync);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_UpdateWindowSurface(SDL_Window* window);
|
||||
public static extern SDL_bool SDL_UpdateWindowSurface(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_UpdateWindowSurfaceRects(SDL_Window* window, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rects, int numrects);
|
||||
public static extern SDL_bool SDL_UpdateWindowSurfaceRects(SDL_Window* window, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rects, int numrects);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_DestroyWindowSurface(SDL_Window* window);
|
||||
public static extern SDL_bool SDL_DestroyWindowSurface(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowKeyboardGrab(SDL_Window* window, SDL_bool grabbed);
|
||||
public static extern SDL_bool SDL_SetWindowKeyboardGrab(SDL_Window* window, SDL_bool grabbed);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowMouseGrab(SDL_Window* window, SDL_bool grabbed);
|
||||
public static extern SDL_bool SDL_SetWindowMouseGrab(SDL_Window* window, SDL_bool grabbed);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern SDL_bool SDL_GetWindowKeyboardGrab(SDL_Window* window);
|
||||
|
|
@ -390,35 +390,38 @@ namespace SDL
|
|||
public static extern SDL_Window* SDL_GetGrabbedWindow();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowMouseRect(SDL_Window* window, [NativeTypeName("const SDL_Rect *")] SDL_Rect* rect);
|
||||
public static extern SDL_bool 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 int SDL_SetWindowOpacity(SDL_Window* window, float opacity);
|
||||
public static extern SDL_bool 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 int SDL_SetWindowModalFor(SDL_Window* modal_window, SDL_Window* parent_window);
|
||||
public static extern SDL_bool SDL_SetWindowParent(SDL_Window* window, SDL_Window* parent);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowFocusable(SDL_Window* window, SDL_bool focusable);
|
||||
public static extern SDL_bool SDL_SetWindowModal(SDL_Window* window, SDL_bool modal);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_ShowWindowSystemMenu(SDL_Window* window, int x, int y);
|
||||
public static extern SDL_bool SDL_SetWindowFocusable(SDL_Window* window, SDL_bool focusable);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowHitTest(SDL_Window* window, [NativeTypeName("SDL_HitTest")] delegate* unmanaged[Cdecl]<SDL_Window*, SDL_Point*, IntPtr, SDL_HitTestResult> callback, [NativeTypeName("void*")] IntPtr callback_data);
|
||||
public static extern SDL_bool SDL_ShowWindowSystemMenu(SDL_Window* window, int x, int y);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_SetWindowShape(SDL_Window* window, SDL_Surface* shape);
|
||||
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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_FlashWindow(SDL_Window* window, SDL_FlashOperation operation);
|
||||
public static extern SDL_bool 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);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern void SDL_DestroyWindow(SDL_Window* window);
|
||||
|
|
@ -427,13 +430,13 @@ namespace SDL
|
|||
public static extern SDL_bool SDL_ScreenSaverEnabled();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_EnableScreenSaver();
|
||||
public static extern SDL_bool SDL_EnableScreenSaver();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_DisableScreenSaver();
|
||||
public static extern SDL_bool SDL_DisableScreenSaver();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GL_LoadLibrary([NativeTypeName("const char *")] byte* path);
|
||||
public static extern SDL_bool SDL_GL_LoadLibrary([NativeTypeName("const char *")] byte* path);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("SDL_FunctionPointer")]
|
||||
|
|
@ -453,17 +456,17 @@ namespace SDL
|
|||
public static extern void SDL_GL_ResetAttributes();
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GL_SetAttribute(SDL_GLattr attr, int value);
|
||||
public static extern SDL_bool SDL_GL_SetAttribute(SDL_GLattr attr, int value);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GL_GetAttribute(SDL_GLattr attr, int* value);
|
||||
public static extern SDL_bool 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 int SDL_GL_MakeCurrent(SDL_Window* window, [NativeTypeName("SDL_GLContext")] SDL_GLContextState* context);
|
||||
public static extern SDL_bool 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();
|
||||
|
|
@ -488,16 +491,16 @@ 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 int SDL_GL_SetSwapInterval(int interval);
|
||||
public static extern SDL_bool SDL_GL_SetSwapInterval(int interval);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GL_GetSwapInterval(int* interval);
|
||||
public static extern SDL_bool SDL_GL_GetSwapInterval(int* interval);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GL_SwapWindow(SDL_Window* window);
|
||||
public static extern SDL_bool SDL_GL_SwapWindow(SDL_Window* window);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_GL_DestroyContext([NativeTypeName("SDL_GLContext")] SDL_GLContextState* context);
|
||||
public static extern SDL_bool 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;
|
||||
|
|
@ -547,8 +550,11 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_WINDOW_MOUSE_CAPTURE SDL_UINT64_C(0x0000000000004000)")]
|
||||
public const ulong SDL_WINDOW_MOUSE_CAPTURE = (0x0000000000004000UL);
|
||||
|
||||
[NativeTypeName("#define SDL_WINDOW_ALWAYS_ON_TOP SDL_UINT64_C(0x0000000000008000)")]
|
||||
public const ulong SDL_WINDOW_ALWAYS_ON_TOP = (0x0000000000008000UL);
|
||||
[NativeTypeName("#define SDL_WINDOW_MOUSE_RELATIVE_MODE SDL_UINT64_C(0x0000000000008000)")]
|
||||
public const ulong SDL_WINDOW_MOUSE_RELATIVE_MODE = (0x0000000000008000UL);
|
||||
|
||||
[NativeTypeName("#define SDL_WINDOW_ALWAYS_ON_TOP SDL_UINT64_C(0x0000000000010000)")]
|
||||
public const ulong SDL_WINDOW_ALWAYS_ON_TOP = (0x0000000000010000UL);
|
||||
|
||||
[NativeTypeName("#define SDL_WINDOW_UTILITY SDL_UINT64_C(0x0000000000020000)")]
|
||||
public const ulong SDL_WINDOW_UTILITY = (0x0000000000020000UL);
|
||||
|
|
@ -592,104 +598,107 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_PROP_DISPLAY_KMSDRM_PANEL_ORIENTATION_NUMBER \"SDL.display.KMSDRM.panel_orientation\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_DISPLAY_KMSDRM_PANEL_ORIENTATION_NUMBER => "SDL.display.KMSDRM.panel_orientation"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_ALWAYS_ON_TOP_BOOLEAN \"always_on_top\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_ALWAYS_ON_TOP_BOOLEAN => "always_on_top"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_ALWAYS_ON_TOP_BOOLEAN \"SDL.window.create.always_on_top\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_ALWAYS_ON_TOP_BOOLEAN => "SDL.window.create.always_on_top"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_BORDERLESS_BOOLEAN \"borderless\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_BORDERLESS_BOOLEAN => "borderless"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_BORDERLESS_BOOLEAN \"SDL.window.create.borderless\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_BORDERLESS_BOOLEAN => "SDL.window.create.borderless"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_FOCUSABLE_BOOLEAN \"focusable\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_FOCUSABLE_BOOLEAN => "focusable"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_FOCUSABLE_BOOLEAN \"SDL.window.create.focusable\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_FOCUSABLE_BOOLEAN => "SDL.window.create.focusable"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_EXTERNAL_GRAPHICS_CONTEXT_BOOLEAN \"external_graphics_context\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_EXTERNAL_GRAPHICS_CONTEXT_BOOLEAN => "external_graphics_context"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_EXTERNAL_GRAPHICS_CONTEXT_BOOLEAN \"SDL.window.create.external_graphics_context\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_EXTERNAL_GRAPHICS_CONTEXT_BOOLEAN => "SDL.window.create.external_graphics_context"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_FULLSCREEN_BOOLEAN \"fullscreen\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_FULLSCREEN_BOOLEAN => "fullscreen"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_FLAGS_NUMBER \"SDL.window.create.flags\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_FLAGS_NUMBER => "SDL.window.create.flags"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_HEIGHT_NUMBER \"height\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_HEIGHT_NUMBER => "height"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_FULLSCREEN_BOOLEAN \"SDL.window.create.fullscreen\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_FULLSCREEN_BOOLEAN => "SDL.window.create.fullscreen"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_HIDDEN_BOOLEAN \"hidden\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_HIDDEN_BOOLEAN => "hidden"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_HEIGHT_NUMBER \"SDL.window.create.height\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_HEIGHT_NUMBER => "SDL.window.create.height"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_HIGH_PIXEL_DENSITY_BOOLEAN \"high_pixel_density\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_HIGH_PIXEL_DENSITY_BOOLEAN => "high_pixel_density"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_HIDDEN_BOOLEAN \"SDL.window.create.hidden\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_HIDDEN_BOOLEAN => "SDL.window.create.hidden"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_MAXIMIZED_BOOLEAN \"maximized\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_MAXIMIZED_BOOLEAN => "maximized"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_HIGH_PIXEL_DENSITY_BOOLEAN \"SDL.window.create.high_pixel_density\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_HIGH_PIXEL_DENSITY_BOOLEAN => "SDL.window.create.high_pixel_density"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_MENU_BOOLEAN \"menu\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_MENU_BOOLEAN => "menu"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_MAXIMIZED_BOOLEAN \"SDL.window.create.maximized\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_MAXIMIZED_BOOLEAN => "SDL.window.create.maximized"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_METAL_BOOLEAN \"metal\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_METAL_BOOLEAN => "metal"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_MENU_BOOLEAN \"SDL.window.create.menu\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_MENU_BOOLEAN => "SDL.window.create.menu"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_MINIMIZED_BOOLEAN \"minimized\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_MINIMIZED_BOOLEAN => "minimized"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_METAL_BOOLEAN \"SDL.window.create.metal\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_METAL_BOOLEAN => "SDL.window.create.metal"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_MODAL_BOOLEAN \"modal\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_MODAL_BOOLEAN => "modal"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_MINIMIZED_BOOLEAN \"SDL.window.create.minimized\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_MINIMIZED_BOOLEAN => "SDL.window.create.minimized"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_MOUSE_GRABBED_BOOLEAN \"mouse_grabbed\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_MOUSE_GRABBED_BOOLEAN => "mouse_grabbed"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_MODAL_BOOLEAN \"SDL.window.create.modal\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_MODAL_BOOLEAN => "SDL.window.create.modal"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_OPENGL_BOOLEAN \"opengl\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_OPENGL_BOOLEAN => "opengl"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_MOUSE_GRABBED_BOOLEAN \"SDL.window.create.mouse_grabbed\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_MOUSE_GRABBED_BOOLEAN => "SDL.window.create.mouse_grabbed"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_PARENT_POINTER \"parent\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_PARENT_POINTER => "parent"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_OPENGL_BOOLEAN \"SDL.window.create.opengl\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_OPENGL_BOOLEAN => "SDL.window.create.opengl"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_RESIZABLE_BOOLEAN \"resizable\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_RESIZABLE_BOOLEAN => "resizable"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_PARENT_POINTER \"SDL.window.create.parent\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_PARENT_POINTER => "SDL.window.create.parent"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_TITLE_STRING \"title\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_TITLE_STRING => "title"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_RESIZABLE_BOOLEAN \"SDL.window.create.resizable\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_RESIZABLE_BOOLEAN => "SDL.window.create.resizable"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_TRANSPARENT_BOOLEAN \"transparent\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_TRANSPARENT_BOOLEAN => "transparent"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_TITLE_STRING \"SDL.window.create.title\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_TITLE_STRING => "SDL.window.create.title"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_TOOLTIP_BOOLEAN \"tooltip\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_TOOLTIP_BOOLEAN => "tooltip"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_TRANSPARENT_BOOLEAN \"SDL.window.create.transparent\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_TRANSPARENT_BOOLEAN => "SDL.window.create.transparent"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_UTILITY_BOOLEAN \"utility\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_UTILITY_BOOLEAN => "utility"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_TOOLTIP_BOOLEAN \"SDL.window.create.tooltip\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_TOOLTIP_BOOLEAN => "SDL.window.create.tooltip"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_VULKAN_BOOLEAN \"vulkan\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_VULKAN_BOOLEAN => "vulkan"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_UTILITY_BOOLEAN \"SDL.window.create.utility\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_UTILITY_BOOLEAN => "SDL.window.create.utility"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_WIDTH_NUMBER \"width\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_WIDTH_NUMBER => "width"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_VULKAN_BOOLEAN \"SDL.window.create.vulkan\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_VULKAN_BOOLEAN => "SDL.window.create.vulkan"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_X_NUMBER \"x\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_X_NUMBER => "x"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_WIDTH_NUMBER \"SDL.window.create.width\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_WIDTH_NUMBER => "SDL.window.create.width"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_Y_NUMBER \"y\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_Y_NUMBER => "y"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_X_NUMBER \"SDL.window.create.x\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_X_NUMBER => "SDL.window.create.x"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_COCOA_WINDOW_POINTER \"cocoa.window\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_COCOA_WINDOW_POINTER => "cocoa.window"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_Y_NUMBER \"SDL.window.create.y\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_Y_NUMBER => "SDL.window.create.y"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_COCOA_VIEW_POINTER \"cocoa.view\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_COCOA_VIEW_POINTER => "cocoa.view"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_COCOA_WINDOW_POINTER \"SDL.window.create.cocoa.window\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_COCOA_WINDOW_POINTER => "SDL.window.create.cocoa.window"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_WAYLAND_SURFACE_ROLE_CUSTOM_BOOLEAN \"wayland.surface_role_custom\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_WAYLAND_SURFACE_ROLE_CUSTOM_BOOLEAN => "wayland.surface_role_custom"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_COCOA_VIEW_POINTER \"SDL.window.create.cocoa.view\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_COCOA_VIEW_POINTER => "SDL.window.create.cocoa.view"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_WAYLAND_CREATE_EGL_WINDOW_BOOLEAN \"wayland.create_egl_window\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_WAYLAND_CREATE_EGL_WINDOW_BOOLEAN => "wayland.create_egl_window"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_WAYLAND_SURFACE_ROLE_CUSTOM_BOOLEAN \"SDL.window.create.wayland.surface_role_custom\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_WAYLAND_SURFACE_ROLE_CUSTOM_BOOLEAN => "SDL.window.create.wayland.surface_role_custom"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_WAYLAND_WL_SURFACE_POINTER \"wayland.wl_surface\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_WAYLAND_WL_SURFACE_POINTER => "wayland.wl_surface"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_WAYLAND_CREATE_EGL_WINDOW_BOOLEAN \"SDL.window.create.wayland.create_egl_window\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_WAYLAND_CREATE_EGL_WINDOW_BOOLEAN => "SDL.window.create.wayland.create_egl_window"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_WIN32_HWND_POINTER \"win32.hwnd\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_WIN32_HWND_POINTER => "win32.hwnd"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_WAYLAND_WL_SURFACE_POINTER \"SDL.window.create.wayland.wl_surface\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_WAYLAND_WL_SURFACE_POINTER => "SDL.window.create.wayland.wl_surface"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_WIN32_PIXEL_FORMAT_HWND_POINTER \"win32.pixel_format_hwnd\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_WIN32_PIXEL_FORMAT_HWND_POINTER => "win32.pixel_format_hwnd"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_WIN32_HWND_POINTER \"SDL.window.create.win32.hwnd\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_WIN32_HWND_POINTER => "SDL.window.create.win32.hwnd"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_X11_WINDOW_NUMBER \"x11.window\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_X11_WINDOW_NUMBER => "x11.window"u8;
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_WIN32_PIXEL_FORMAT_HWND_POINTER \"SDL.window.create.win32.pixel_format_hwnd\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_WIN32_PIXEL_FORMAT_HWND_POINTER => "SDL.window.create.win32.pixel_format_hwnd"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_CREATE_X11_WINDOW_NUMBER \"SDL.window.create.x11.window\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_CREATE_X11_WINDOW_NUMBER => "SDL.window.create.x11.window"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_SHAPE_POINTER \"SDL.window.shape\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_SHAPE_POINTER => "SDL.window.shape"u8;
|
||||
|
|
@ -748,9 +757,6 @@ namespace SDL
|
|||
[NativeTypeName("#define SDL_PROP_WINDOW_VIVANTE_SURFACE_POINTER \"SDL.window.vivante.surface\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_VIVANTE_SURFACE_POINTER => "SDL.window.vivante.surface"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_WINRT_WINDOW_POINTER \"SDL.window.winrt.window\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_WINRT_WINDOW_POINTER => "SDL.window.winrt.window"u8;
|
||||
|
||||
[NativeTypeName("#define SDL_PROP_WINDOW_WIN32_HWND_POINTER \"SDL.window.win32.hwnd\"")]
|
||||
public static ReadOnlySpan<byte> SDL_PROP_WINDOW_WIN32_HWND_POINTER => "SDL.window.win32.hwnd"u8;
|
||||
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ namespace SDL
|
|||
public static unsafe partial class SDL3
|
||||
{
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_Vulkan_LoadLibrary([NativeTypeName("const char *")] byte* path);
|
||||
public static extern SDL_bool SDL_Vulkan_LoadLibrary([NativeTypeName("const char *")] byte* path);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
[return: NativeTypeName("SDL_FunctionPointer")]
|
||||
|
|
@ -61,7 +61,7 @@ namespace SDL
|
|||
public static extern byte** SDL_Vulkan_GetInstanceExtensions([NativeTypeName("Uint32 *")] uint* count);
|
||||
|
||||
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
|
||||
public static extern int SDL_Vulkan_CreateSurface(SDL_Window* window, [NativeTypeName("VkInstance")] VkInstance_T* instance, [NativeTypeName("const struct VkAllocationCallbacks *")] VkAllocationCallbacks* allocator, [NativeTypeName("VkSurfaceKHR *")] VkSurfaceKHR_T** surface);
|
||||
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);
|
||||
|
||||
[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);
|
||||
|
|
|
|||
|
|
@ -14,9 +14,9 @@ namespace SDL
|
|||
{
|
||||
[LibraryImport("SDL3", StringMarshalling = StringMarshalling.Utf8)]
|
||||
[UnmanagedCallConv(CallConvs = [typeof(CallConvCdecl)])]
|
||||
private static unsafe partial int SDL_SetClipboardData(SDL_ClipboardDataCallback callback, SDL_ClipboardCleanupCallback cleanup, IntPtr userdata, string[] mime_types, UIntPtr num_mime_types);
|
||||
private static unsafe partial SDL_bool SDL_SetClipboardData(SDL_ClipboardDataCallback callback, SDL_ClipboardCleanupCallback cleanup, IntPtr userdata, string[] mime_types, UIntPtr num_mime_types);
|
||||
|
||||
public static unsafe int SDL_SetClipboardData(SDL_ClipboardDataCallback callback, SDL_ClipboardCleanupCallback cleanup, IntPtr userdata, params string[] mime_types)
|
||||
public static unsafe SDL_bool SDL_SetClipboardData(SDL_ClipboardDataCallback callback, SDL_ClipboardCleanupCallback cleanup, IntPtr userdata, params string[] mime_types)
|
||||
=> SDL_SetClipboardData(callback, cleanup, userdata, mime_types, (UIntPtr)mime_types.Length);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,14 +6,14 @@ namespace SDL
|
|||
public static partial class SDL3
|
||||
{
|
||||
[Macro]
|
||||
public static unsafe int SDL_Unsupported()
|
||||
public static unsafe SDL_bool SDL_Unsupported()
|
||||
{
|
||||
fixed (byte* fmt = "That operation is not supported"u8)
|
||||
return SDL_SetError(fmt, __arglist());
|
||||
}
|
||||
|
||||
[Macro]
|
||||
public static unsafe int SDL_InvalidParamError([NativeTypeName("const char *")] byte* param)
|
||||
public static unsafe SDL_bool SDL_InvalidParamError([NativeTypeName("const char *")] byte* param)
|
||||
{
|
||||
fixed (byte* fmt = "Parameter '%s' is invalid"u8)
|
||||
return SDL_SetError(fmt, __arglist(param));
|
||||
|
|
|
|||
|
|
@ -0,0 +1,57 @@
|
|||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||
// See the LICENCE file in the repository root for full licence text.
|
||||
|
||||
using System;
|
||||
|
||||
namespace SDL
|
||||
{
|
||||
[Flags]
|
||||
[Typedef]
|
||||
public enum SDL_GPUTextureUsageFlags : uint
|
||||
{
|
||||
SDL_GPU_TEXTUREUSAGE_SAMPLER = SDL3.SDL_GPU_TEXTUREUSAGE_SAMPLER,
|
||||
SDL_GPU_TEXTUREUSAGE_COLOR_TARGET = SDL3.SDL_GPU_TEXTUREUSAGE_COLOR_TARGET,
|
||||
SDL_GPU_TEXTUREUSAGE_DEPTH_STENCIL_TARGET = SDL3.SDL_GPU_TEXTUREUSAGE_DEPTH_STENCIL_TARGET,
|
||||
SDL_GPU_TEXTUREUSAGE_GRAPHICS_STORAGE_READ = SDL3.SDL_GPU_TEXTUREUSAGE_GRAPHICS_STORAGE_READ,
|
||||
SDL_GPU_TEXTUREUSAGE_COMPUTE_STORAGE_READ = SDL3.SDL_GPU_TEXTUREUSAGE_COMPUTE_STORAGE_READ,
|
||||
SDL_GPU_TEXTUREUSAGE_COMPUTE_STORAGE_WRITE = SDL3.SDL_GPU_TEXTUREUSAGE_COMPUTE_STORAGE_WRITE,
|
||||
}
|
||||
|
||||
[Flags]
|
||||
[Typedef]
|
||||
public enum SDL_GPUBufferUsageFlags : uint
|
||||
{
|
||||
SDL_GPU_BUFFERUSAGE_VERTEX = SDL3.SDL_GPU_BUFFERUSAGE_VERTEX,
|
||||
SDL_GPU_BUFFERUSAGE_INDEX = SDL3.SDL_GPU_BUFFERUSAGE_INDEX,
|
||||
SDL_GPU_BUFFERUSAGE_INDIRECT = SDL3.SDL_GPU_BUFFERUSAGE_INDIRECT,
|
||||
SDL_GPU_BUFFERUSAGE_GRAPHICS_STORAGE_READ = SDL3.SDL_GPU_BUFFERUSAGE_GRAPHICS_STORAGE_READ,
|
||||
SDL_GPU_BUFFERUSAGE_COMPUTE_STORAGE_READ = SDL3.SDL_GPU_BUFFERUSAGE_COMPUTE_STORAGE_READ,
|
||||
SDL_GPU_BUFFERUSAGE_COMPUTE_STORAGE_WRITE = SDL3.SDL_GPU_BUFFERUSAGE_COMPUTE_STORAGE_WRITE,
|
||||
}
|
||||
|
||||
[Flags]
|
||||
[Typedef]
|
||||
public enum SDL_GPUShaderFormat : uint
|
||||
{
|
||||
SDL_GPU_SHADERFORMAT_PRIVATE = SDL3.SDL_GPU_SHADERFORMAT_PRIVATE,
|
||||
SDL_GPU_SHADERFORMAT_SPIRV = SDL3.SDL_GPU_SHADERFORMAT_SPIRV,
|
||||
SDL_GPU_SHADERFORMAT_DXBC = SDL3.SDL_GPU_SHADERFORMAT_DXBC,
|
||||
SDL_GPU_SHADERFORMAT_DXIL = SDL3.SDL_GPU_SHADERFORMAT_DXIL,
|
||||
SDL_GPU_SHADERFORMAT_MSL = SDL3.SDL_GPU_SHADERFORMAT_MSL,
|
||||
SDL_GPU_SHADERFORMAT_METALLIB = SDL3.SDL_GPU_SHADERFORMAT_METALLIB,
|
||||
}
|
||||
|
||||
[Flags]
|
||||
[Typedef]
|
||||
public enum SDL_GPUColorComponentFlags : byte
|
||||
{
|
||||
SDL_GPU_COLORCOMPONENT_R = (byte)SDL3.SDL_GPU_COLORCOMPONENT_R,
|
||||
SDL_GPU_COLORCOMPONENT_G = (byte)SDL3.SDL_GPU_COLORCOMPONENT_G,
|
||||
SDL_GPU_COLORCOMPONENT_B = (byte)SDL3.SDL_GPU_COLORCOMPONENT_B,
|
||||
SDL_GPU_COLORCOMPONENT_A = (byte)SDL3.SDL_GPU_COLORCOMPONENT_A,
|
||||
}
|
||||
|
||||
public static partial class SDL3
|
||||
{
|
||||
}
|
||||
}
|
||||
|
|
@ -2,7 +2,6 @@
|
|||
// See the LICENCE file in the repository root for full licence text.
|
||||
|
||||
using System;
|
||||
using JetBrains.Annotations;
|
||||
|
||||
namespace SDL
|
||||
{
|
||||
|
|
@ -11,37 +10,14 @@ namespace SDL
|
|||
|
||||
[Flags]
|
||||
[Typedef]
|
||||
public enum SDL_PenCapabilityFlags : uint
|
||||
public enum SDL_PenInputFlags : UInt32
|
||||
{
|
||||
SDL_PEN_DOWN_MASK = SDL3.SDL_PEN_DOWN_MASK,
|
||||
SDL_PEN_INK_MASK = SDL3.SDL_PEN_INK_MASK,
|
||||
SDL_PEN_ERASER_MASK = SDL3.SDL_PEN_ERASER_MASK,
|
||||
SDL_PEN_AXIS_PRESSURE_MASK = SDL3.SDL_PEN_AXIS_PRESSURE_MASK,
|
||||
SDL_PEN_AXIS_XTILT_MASK = SDL3.SDL_PEN_AXIS_XTILT_MASK,
|
||||
SDL_PEN_AXIS_YTILT_MASK = SDL3.SDL_PEN_AXIS_YTILT_MASK,
|
||||
SDL_PEN_AXIS_DISTANCE_MASK = SDL3.SDL_PEN_AXIS_DISTANCE_MASK,
|
||||
SDL_PEN_AXIS_ROTATION_MASK = SDL3.SDL_PEN_AXIS_ROTATION_MASK,
|
||||
SDL_PEN_AXIS_SLIDER_MASK = SDL3.SDL_PEN_AXIS_SLIDER_MASK,
|
||||
SDL_PEN_AXIS_BIDIRECTIONAL_MASKS = SDL3.SDL_PEN_AXIS_BIDIRECTIONAL_MASKS,
|
||||
}
|
||||
|
||||
public static partial class SDL3
|
||||
{
|
||||
[Constant]
|
||||
public const SDL_MouseID SDL_PEN_MOUSEID = unchecked((SDL_MouseID)(-2));
|
||||
|
||||
[Macro]
|
||||
public static SDL_PenCapabilityFlags SDL_PEN_CAPABILITY(int capbit) => (SDL_PenCapabilityFlags)(1ul << (capbit));
|
||||
|
||||
[Macro]
|
||||
public static SDL_PenCapabilityFlags SDL_PEN_AXIS_CAPABILITY(SDL_PenAxis axis) => SDL_PEN_CAPABILITY((int)axis + SDL_PEN_FLAG_AXIS_BIT_OFFSET);
|
||||
|
||||
[MustDisposeResource]
|
||||
public static unsafe SDLArray<SDL_PenID>? SDL_GetPens()
|
||||
{
|
||||
int count;
|
||||
var array = SDL_GetPens(&count);
|
||||
return SDLArray.Create(array, count);
|
||||
}
|
||||
SDL_PEN_INPUT_DOWN = SDL3.SDL_PEN_INPUT_DOWN,
|
||||
SDL_PEN_INPUT_BUTTON_1 = SDL3.SDL_PEN_INPUT_BUTTON_1,
|
||||
SDL_PEN_INPUT_BUTTON_2 = SDL3.SDL_PEN_INPUT_BUTTON_2,
|
||||
SDL_PEN_INPUT_BUTTON_3 = SDL3.SDL_PEN_INPUT_BUTTON_3,
|
||||
SDL_PEN_INPUT_BUTTON_4 = SDL3.SDL_PEN_INPUT_BUTTON_4,
|
||||
SDL_PEN_INPUT_BUTTON_5 = SDL3.SDL_PEN_INPUT_BUTTON_5,
|
||||
SDL_PEN_INPUT_ERASER_TIP = SDL3.SDL_PEN_INPUT_ERASER_TIP,
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ using System;
|
|||
namespace SDL
|
||||
{
|
||||
[Typedef]
|
||||
public enum SDL_bool
|
||||
public enum SDL_bool : byte
|
||||
{
|
||||
SDL_FALSE = SDL3.SDL_FALSE,
|
||||
SDL_TRUE = SDL3.SDL_TRUE
|
||||
|
|
|
|||
|
|
@ -90,6 +90,7 @@ headers = [
|
|||
add("SDL3/SDL_events.h"),
|
||||
add("SDL3/SDL_filesystem.h"),
|
||||
add("SDL3/SDL_gamepad.h"),
|
||||
add("SDL3/SDL_gpu.h"),
|
||||
add("SDL3/SDL_guid.h"),
|
||||
add("SDL3/SDL_haptic.h"),
|
||||
add("SDL3/SDL_hidapi.h"),
|
||||
|
|
@ -111,6 +112,7 @@ headers = [
|
|||
add("SDL3/SDL_pixels.h"),
|
||||
add("SDL3/SDL_platform.h"),
|
||||
add("SDL3/SDL_power.h"),
|
||||
add("SDL3/SDL_process.h"),
|
||||
add("SDL3/SDL_properties.h"),
|
||||
add("SDL3/SDL_rect.h"),
|
||||
add("SDL3/SDL_render.h"),
|
||||
|
|
@ -312,7 +314,8 @@ def main():
|
|||
check_generated_functions(sdl_api, header, [output_file])
|
||||
|
||||
generate_platform_specific_headers(sdl_api, add("SDL3/SDL_main.h"), [
|
||||
(["SDL_PLATFORM_WIN32", "SDL_PLATFORM_WINGDK"], "Windows", "Windows"),
|
||||
(["SDL_PLATFORM_WINDOWS"], "Windows", "Windows"),
|
||||
(["SDL_PLATFORM_GDK"], "GDK", "Windows"),
|
||||
])
|
||||
|
||||
generate_platform_specific_headers(sdl_api, add("SDL3/SDL_system.h"), [
|
||||
|
|
@ -320,8 +323,8 @@ def main():
|
|||
(["SDL_PLATFORM_ANDROID"], "Android", "Android"),
|
||||
(["SDL_PLATFORM_IOS"], "iOS", "iOS"),
|
||||
(["SDL_PLATFORM_LINUX"], "Linux", "Linux"),
|
||||
(["SDL_PLATFORM_WIN32", "SDL_PLATFORM_WINGDK"], "Windows", "Windows"),
|
||||
(["SDL_PLATFORM_WINRT"], "WinRT", "Windows"),
|
||||
(["SDL_PLATFORM_WINDOWS", "SDL_PLATFORM_WIN32"], "Windows", "Windows"),
|
||||
(["SDL_PLATFORM_GDK"], "GDK", "Windows"),
|
||||
])
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue