index
This commit is contained in:
@@ -9,7 +9,7 @@
|
||||
@title{flac-decoder}
|
||||
@author[@author+email["Hans Dijkema" "hans@dijkewijk.nl"]]
|
||||
|
||||
@defmodule[racket-audio/flac-decoder]
|
||||
@defmodule[racket-audio/flac-decoder #:use-sources (racket-audio/flac-definitions)]
|
||||
|
||||
This module provides a small decoder interface on top of the FLAC
|
||||
FFI layer. It opens a decoder for a file, reads stream metadata,
|
||||
@@ -33,12 +33,12 @@ exist, the result is @racket[#f].
|
||||
|
||||
Otherwise a native decoder handler is created with
|
||||
@racket[flac-ffi-decoder-handler], initialized with the file, and
|
||||
wrapped in a @racket[flac-handle]. The given callbacks are stored
|
||||
wrapped in a @racket[flac-handle?]. The given callbacks are stored
|
||||
in the handle.
|
||||
|
||||
When metadata of type @racket['streaminfo] is processed and
|
||||
@racket[cb-stream-info] is a procedure, it is called with a
|
||||
@racket[flac-stream-info] value.
|
||||
@racket[flac-stream-info?] value.
|
||||
|
||||
When decoded audio data is processed and @racket[cb-audio] is a
|
||||
procedure, it is called as
|
||||
@@ -80,7 +80,7 @@ with @racket['stopped-reading] and @racket[reading] is reset to
|
||||
|
||||
Whenever pending metadata is available, it is processed with
|
||||
@racket[process-meta]. For metadata of type
|
||||
@racket['streaminfo], a @racket[flac-stream-info] value is
|
||||
@racket['streaminfo], a @racket[flac-stream-info?] value is
|
||||
constructed, stored in the handle, and passed to the
|
||||
stream-info callback.
|
||||
|
||||
@@ -110,7 +110,7 @@ metadata is processed and the stored stream info is returned.
|
||||
Otherwise the result is @racket[#f].
|
||||
|
||||
Only metadata of type @racket['streaminfo] is converted into a
|
||||
@racket[flac-stream-info] value by this module.
|
||||
@racket[flac-stream-info?] value by this module.
|
||||
}
|
||||
|
||||
@defproc[(flac-stop [handle flac-handle?]) void?]{
|
||||
@@ -125,6 +125,13 @@ The procedure prints timing information before and after the
|
||||
wait.
|
||||
}
|
||||
|
||||
@defproc[(flac-duration [handle flac-handle?])
|
||||
(or/c #f exact-nonnegative-integer?)]{
|
||||
|
||||
Returns the rounded duration in seconds, or @racket[#f] while no stream
|
||||
information is available.
|
||||
}
|
||||
|
||||
@section{Diagnostic bindings}
|
||||
|
||||
@defthing[kinds hash?]{
|
||||
|
||||
Reference in New Issue
Block a user