Class: FFruby::AudioStream
- Defined in:
- ext/ffruby/ffrubystream.c,
ext/ffruby/ffrubystream.c
Overview
An interface to FFmpeg on audio streams. Provides access to audio metadata.
Instance Method Summary collapse
-
#channels ⇒ Object
Returns the number of audio channels.
-
#sample_rate ⇒ Object
Returns the sample rate.
Methods inherited from Stream
#bit_rate, #codec, #initialize, #tag
Constructor Details
This class inherits a constructor from FFruby::Stream
Instance Method Details
#channels ⇒ Object
Returns the number of audio channels.
163 164 165 166 167 |
# File 'ext/ffruby/ffrubystream.c', line 163
static VALUE ffras_channels(VALUE self)
{
AVStream *stream = ffrs_get_stream(self);
return INT2FIX(stream->codec->channels);
}
|
#sample_rate ⇒ Object
Returns the sample rate.
170 171 172 173 174 |
# File 'ext/ffruby/ffrubystream.c', line 170
static VALUE ffras_sample_rate(VALUE self)
{
AVStream *stream = ffrs_get_stream(self);
return INT2NUM(stream->codec->sample_rate);
}
|