andelf / andelf/tinygif

[feature request] `from_iter` constructor

Aperta
#3 2 commenti 1 reazione 0 assegnatari Vedi su GitHub
Lingua principale
Rust
Stelle
29
Fork
5
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

Hi,

I'll probably take a look at this myself, creating an issue first incase you can point out it's impossible or any pitfalls.

What I'm after is a `from_iter`, similar to `from_slice` but it'd get given an iter which returns `u8`s instead of a u8 array.
(I'm reading GIF files off of an SD card & the GIFs can be too large for a full one to fit in memory).

It'd pull the headers etc from the input iter, store them same as what happens with the `from_slice`.
I think it it'd need to return `frames` as an iterator over `frame` & would only be able to do 1 loop (since the input iter will get consumed), but other than that I'm not seeing any major issues

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.