Implement missing functions

This commit is contained in:
Miron Alexandru authored and Chris Thrasher committed 2024-03-09 20:29:30 -07:00
1 parent 16ae40d383
commit e0589c302b
11 files changed
+211

No files matched your search

+25
View File
@@ -94,5 +94,30 @@ CSFML_WINDOW_API sfVector2i sfMouse_getPosition(const sfWindow* relativeTo);
////////////////////////////////////////////////////////////
CSFML_WINDOW_API void sfMouse_setPosition(sfVector2i position, const sfWindow* relativeTo);
////////////////////////////////////////////////////////////
/// \brief Get the current position of the mouse relative to a window base
///
/// This function returns the current position of the mouse
/// cursor relative to the given window base, or desktop if NULL is passed.
///
/// \param relativeTo Reference window
///
/// \return Position of the mouse cursor, relative to the given window base
///
////////////////////////////////////////////////////////////
CSFML_WINDOW_API sfVector2i sfMouse_getPositionWindowBase(const sfWindowBase* relativeTo);
////////////////////////////////////////////////////////////
/// \brief Set the current position of the mouse relative to a window base
///
/// This function sets the current position of the mouse
/// cursor relative to the given window base, or desktop if NULL is passed.
///
/// \param position New position of the mouse
/// \param relativeTo Reference window
///
////////////////////////////////////////////////////////////
CSFML_WINDOW_API void sfMouse_setPositionWindowBase(sfVector2i position, const sfWindowBase* relativeTo);
#endif // SFML_MOUSE_H
+14
View File
@@ -57,5 +57,19 @@ CSFML_WINDOW_API sfBool sfTouch_isDown(unsigned int finger);
////////////////////////////////////////////////////////////
CSFML_WINDOW_API sfVector2i sfTouch_getPosition(unsigned int finger, const sfWindow* relativeTo);
////////////////////////////////////////////////////////////
/// \brief Get the current position of a touch in window coordinates
///
/// This function returns the current touch position
/// relative to the given window base, or desktop if NULL is passed.
///
/// \param finger Finger index
/// \param relativeTo Reference window
///
/// \return Current position of \a finger, or undefined if it's not down
///
////////////////////////////////////////////////////////////
CSFML_WINDOW_API sfVector2i sfTouch_getPositionWindowBase(unsigned int finger, const sfWindowBase* relativeTo);
#endif // SFML_TOUCH_H
+13
View File
@@ -474,5 +474,18 @@ CSFML_WINDOW_API void sfWindow_display(sfWindow* window);
////////////////////////////////////////////////////////////
CSFML_WINDOW_API sfWindowHandle sfWindow_getSystemHandle(const sfWindow* window);
////////////////////////////////////////////////////////////
/// \brief Create a Vulkan rendering surface
///
/// \param window Window object
/// \param instance Vulkan instance
/// \param surface Created surface
/// \param allocator Allocator to use
///
/// \return True if surface creation was successful, false otherwise
///
////////////////////////////////////////////////////////////
CSFML_WINDOW_API sfBool sfWindow_createVulkanSurface(sfWindow* window, const VkInstance* instance, VkSurfaceKHR* surface, const VkAllocationCallbacks* allocator);
#endif // SFML_WINDOW_H