Skip to main content

On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines
(+1)

Hey Ray, I have been using Raylib for a small library for drawing pixels one at a time and slowly drawing lines to make cool animations.

Here is an example:

However, I want to create a flood fill algorithm which means getting the pixels on the screen and checking their color. Is there a function which can get the screen pixels or do I have to try something else entirely?

Hi! Nice application! You can use LoadImageFromScreen() to get screen data as an Image and LoadTextureFromImage() to get a Texture2D to draw on screen again but this can be very slow...

thanks that may actually work for my purposes since it’s not performance critical and just meant to do something good looking very slowly!

Nice! Feel free to share your creation on raylib Discord community, there is a #madewithraylib channel for that. Also, you can share your creations in raylib GitHub Discussion: https://github.com/raysan5/raylib/discussions/1326

will do if I manage to finish it!