Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Binding and API fixes #244

Merged
merged 1 commit into from May 16, 2024
Merged

Binding and API fixes #244

merged 1 commit into from May 16, 2024

Conversation

Marioalexsan
Copy link
Contributor

Fixed binding signatures (which were originally broken by yours truly):

CSFML_WINDOW_API sfBool sfContext_isExtensionAvailable(const char* name);
CSFML_WINDOW_API GlFunctionPointer sfContext_getFunction(const char* name);

Removed old bindings that don't exist anymore in CSFML:

private static extern bool sfRenderTexture_saveGLStates(IntPtr CPointer);
private static extern bool sfRenderTexture_restoreGLStates(IntPtr CPointer);
private static extern bool sfRenderWindow_saveGLStates(IntPtr CPointer);
private static extern bool sfRenderWindow_restoreGLStates(IntPtr CPointer);
private static extern uint sfRenderWindow_getFrameTime(IntPtr CPointer);
private static extern uint sfWindow_getFrameTime(IntPtr CPointer);
private static extern IntPtr sfShape_copy(IntPtr Shape);
private static extern FloatRect sfText_getRect(IntPtr CPointer);
private static extern FloatRect sfTexture_getTexCoords(IntPtr texture, IntRect rectangle);

Fixed missing userdata pointers in SoundRecorder callbacks.

Moved sfMouse_getPosition, sfMouse_setPosition, and sfTouch_getPosition back to Window, since those functions operate on sfWindow structs and not sfWindowBase. WindowBase will need its own CSFML functions that are not available at the moment, which is why I used NotImplementedException for the time being.

Also changed Mouse and Touch functions to use WindowBase instead of Window.

@eXpl0it3r eXpl0it3r added the Bug label Feb 25, 2024
@eXpl0it3r eXpl0it3r merged commit e191a5d into SFML:master May 16, 2024
15 checks passed
@eXpl0it3r
Copy link
Member

Took a while, but finally got around to it.

For SFML.Net 2.6.0, I guess we still have to release CSFML 2.6.1, so we can implement the WindowBase functions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants