Closed ghost closed 4 years ago
Hello. That is because SDL_RWops deeply depends on the C language. Careless usage of SDL_RWopds from Ruby will make SEGV easily.
If your data is "raw" pixel data, SDL2::Surface.from_string method is available.
If your data is PNG or something, it is impossible to use the data now. If you have a use-case of loading such data from Ruby's string, I will add SDL2::Surface.load_from_string
method.
Okay, I get it. It's fine I can do without it.
I want to read a some pixel data from memory instead of from a file, but there doesn't seem to be an wrapper for SDL_RWops. Was there a technical limitation that cause this?