FastLED 3.10.8
Loading...
Searching...
No Matches

◆ stb_vorbis_open_file()

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

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

4832{
4833 uint32_t len, start;
4834 start = (uint32_t) fl::ftell(file);
4835 fl::fseek(file, 0, fl::io::seek_end);
4836 len = (uint32_t) (fl::ftell(file) - start);
4837 fl::fseek(file, start, fl::io::seek_set);
4838 return stb_vorbis_open_file_section(file, close_on_free, error, alloc, len);
4839}
constexpr int seek_set
Definition file_io.h:43
constexpr int seek_end
Definition file_io.h:45
static int32_t error(vorb *f, enum STBVorbisError e) FL_NO_EXCEPT
stb_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)
int fseek(FILE *file, long offset, int origin) FL_NO_EXCEPT
Set file position.
Definition file_io.h:269
long ftell(FILE *file) FL_NO_EXCEPT
Get current file position.
Definition file_io.h:265
fl::u32 uint32_t
Definition stdint.h:218

References error(), fl::fseek(), fl::ftell(), fl::io::seek_end, fl::io::seek_set, and stb_vorbis_open_file_section().

Referenced by stb_vorbis_open_filename().

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