1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

gg: allow customisation of the image format in gg.new_streaming_image

This commit is contained in:
Delyan Angelov
2021-07-26 11:05:16 +03:00
parent 517260a1eb
commit 0d12d55295
2 changed files with 17 additions and 7 deletions

View File

@ -38,7 +38,7 @@ fn (mut state AppState) draw() {
// gg callbacks:
fn graphics_init(mut state AppState) {
state.istream_idx = state.gg.new_streaming_image(pwidth, pheight, pbytes)
state.istream_idx = state.gg.new_streaming_image(pwidth, pheight, pbytes, pixel_format: .rgba8)
}
fn graphics_frame(mut state AppState) {