SFML community forums

General => General discussions => Topic started by: 6Peppered9 on November 29, 2018, 01:10:33 am

Title: Change mouse cursor image
Post by: 6Peppered9 on November 29, 2018, 01:10:33 am
Hello, i want to change my mouse cursor in my sfml window.

Using C++ SFML 2.5.0 on Linux.

This is the image that i want to set as cursor:
(https://i.imgur.com/OwL0ffg.png)
(Red Rectangle)

cursor.loadFromPixels(image.getPixelsPtr(), image.getSize(), {0,0});
window.setMouseCursor(cursor);

but if i run the application it looks strange:
(http://i.imgur.com/aComAJf.jpg)

what i need to do to fix it?

Thanks