Module Generator.Generator


module Generator: sig .. end
The base module doesn't even know what kind of data it is buffering.

type 'a t 
All positions and lengths are in ticks.
val create : unit -> 'a t
val clear : 'a t -> unit
val length : 'a t -> int
val remove : 'a t -> int -> unit
Remove len ticks of data.
val put : 'a t -> 'a -> int -> int -> unit
Feed an item into a generator. The item is put as such, not copied.
val get : 'a t -> int -> ('a * int * int * int) list
Get size amount of data from g. Returns a list where each element will typically be passed to a blit: its elements are of the form b,o,o',l where o is the offset of data in the block b, o' is the position at which it should be written (the first position o' will always be 0), and l is the length of data to be taken from that block.