You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, I am using this library to load GIFs to pass frames to SFML. As the title says, if the alpha value exists in gif->canvas, then I can just directly make SFML use the data within gif->canvas and avoid this intermediate step:
auto color = gif->canvas;
auto buf = frame_buf;
for (int i = 0; i < gif->height; ++i) {
for (int j = 0; j < gif->width; ++j, color += 3, buf += 4) {
buf[0] = color[0];
buf[1] = color[1];
buf[2] = color[2];
buf[3] = 255 * !gd_is_bgcolor(gif, color);
}
}
The text was updated successfully, but these errors were encountered:
Hello, I am using this library to load GIFs to pass frames to SFML. As the title says, if the alpha value exists in
gif->canvas
, then I can just directly make SFML use the data withingif->canvas
and avoid this intermediate step:The text was updated successfully, but these errors were encountered: