diff options
Diffstat (limited to 'rotord/src/libavwrapper.h')
| -rw-r--r-- | rotord/src/libavwrapper.h | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/rotord/src/libavwrapper.h b/rotord/src/libavwrapper.h index 7822323..162a77e 100644 --- a/rotord/src/libavwrapper.h +++ b/rotord/src/libavwrapper.h @@ -55,9 +55,9 @@ namespace libav { } void cleanup(); bool open(const std::string& filename); - float get_framerate(){ - if (loaded) return (((float)props->FPSNumerator)/((float)props->FPSDenominator)); - else return -1.0f; + double get_framerate(){ + if (loaded) return (((double)props->FPSNumerator)/((double)props->FPSDenominator)); + else return -1.0; } int get_number_frames(){ if (loaded) return props->NumFrames; @@ -138,8 +138,8 @@ namespace libav { if (props) return props->ChannelLayout; else return 0; } - float get_duration(){ - if (props) return ((float)props->NumSamples)/props->SampleRate; + double get_duration(){ + if (props) return ((double)props->NumSamples)/props->SampleRate; else return 0; } bool get_samples(void *buf,int64_t start, int64_t count){ @@ -181,7 +181,7 @@ namespace libav { bool encodeFrame(uint16_t *samples); void finishRecord(); int get_audio_framesize(){return audioframesize;}; - float get_audio_step(){return audiostep;}; + double get_audio_step(){return audiostep;}; AVStream *add_stream(AVFormatContext *oc, AVCodec **codec,enum AVCodecID codec_id); //AVCodecID bool open_video(AVFormatContext *oc, AVCodec *codec, AVStream *st); @@ -204,7 +204,7 @@ namespace libav { struct SwsContext *sws_ctx; int audioframesize; - float audiostep; + double audiostep; int w; int h; int bitRate; @@ -226,7 +226,7 @@ namespace libav { //************************************************************// // audio output // - float t, tincr, tincr2; + double t, tincr, tincr2; int audio_input_frame_size; |
