FastLED 3.9.15
Loading...
Searching...
No Matches

◆ stb_vorbis_open_file_section()

stb_vorbis * fl::third_party::vorbis::stb_vorbis_open_file_section ( fl::FILE * file,
int32_t close_on_free,
int32_t * error,
const stb_vorbis_alloc * alloc,
uint32_t length )

Definition at line 4810 of file stb_vorbis.cpp.hpp.

4811{
4812 stb_vorbis *f, p;
4813 vorbis_init(&p, alloc);
4814 p.f = file;
4815 p.f_start = (uint32) fl::ftell(file);
4816 p.stream_len = length;
4817 p.close_on_free = close_on_free;
4818 if (start_decoder(&p)) {
4819 f = vorbis_alloc(&p);
4820 if (f) {
4821 *f = p;
4823 return f;
4824 }
4825 }
4826 if (error) *error = p.error;
4827 vorbis_deinit(&p);
4828 return nullptr;
4829}
fl::UISlider length("Length", 1.0f, 0.0f, 1.0f, 0.01f)
static int32_t error(vorb *f, enum STBVorbisError e) FL_NOEXCEPT
static int32_t vorbis_pump_first_frame(stb_vorbis *f) FL_NOEXCEPT
static void vorbis_deinit(stb_vorbis *p) FL_NOEXCEPT
static int32_t start_decoder(vorb *f) FL_NOEXCEPT
static void vorbis_init(stb_vorbis *p, const stb_vorbis_alloc *z) FL_NOEXCEPT
static stb_vorbis * vorbis_alloc(stb_vorbis *f) FL_NOEXCEPT
long ftell(FILE *file)
Get current file position.
Definition file_io.h:262

References fl::third_party::vorbis::stb_vorbis::close_on_free, error(), fl::third_party::vorbis::stb_vorbis::error, fl::third_party::vorbis::stb_vorbis::f, fl::third_party::vorbis::stb_vorbis::f_start, fl::ftell(), length(), start_decoder(), fl::third_party::vorbis::stb_vorbis::stream_len, vorbis_alloc(), vorbis_deinit(), vorbis_init(), and vorbis_pump_first_frame().

Referenced by stb_vorbis_open_file().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: