14 #ifndef FFMPEGAUDIOCURSOR_H
15 #define FFMPEGAUDIOCURSOR_H
26 #include <libavcodec/avcodec.h>
30 struct AVFormatContext;
31 struct AVCodecContext;
45 virtual void seek(
double offset);
58 unsigned char *_packet_data;
59 AVFormatContext *_format_ctx;
60 AVCodecContext *_audio_ctx;
63 double _audio_timebase;
68 int16_t *_buffer_alloc;
72 SwrContext *_resample_ctx;
78 static void init_type() {
79 MovieAudioCursor::init_type();
81 MovieAudioCursor::get_class_type());
84 return get_class_type();
86 virtual TypeHandle force_init_type() {init_type();
return get_class_type();}
A stream that generates a sequence of audio samples.
A stream that generates a sequence of audio samples.
Enables ffmpeg to access panda's VFS.
The name of a file, such as a texture file or an Egg file.
A MovieAudio is actually any source that provides a sequence of audio samples.
virtual void seek(double offset)
Skips to the specified offset within the file.
void read_samples(int n, Datagram *dg)
Read audio samples from the stream into a Datagram.
TypeHandle is the identifier used to differentiate C++ class types.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
void register_type(TypeHandle &type_handle, const std::string &name)
This inline function is just a convenient way to call TypeRegistry::register_type(),...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.