gstreamermm  0.10.11
Public Member Functions | Static Public Member Functions | Protected Member Functions | Related Functions
Gst::Tuner Class Reference

An interface for elements providing tuner operations. More...

Inheritance diagram for Gst::Tuner:
Inheritance graph
[legend]
Collaboration diagram for Gst::Tuner:
Collaboration graph
[legend]

List of all members.

Public Member Functions

virtual ~Tuner ()
GstTuner* gobj ()
 Provides access to the underlying C GObject.
const GstTuner* gobj () const
 Provides access to the underlying C GObject.
Glib::ListHandle< Glib::RefPtr
< Gst::TunerChannel > > 
list_channels ()
 Retrieve a List of Gst::TunerChannels available (e.g. 'composite', 's-video', ...) from the given tuner object.
Glib::ListHandle< Glib::RefPtr
< const Gst::TunerChannel > > 
list_channels () const
 Retrieve a List of Gst::TunerChannels available (e.g. 'composite', 's-video', ...) from the given tuner object.
Glib::RefPtr< Gst::TunerChannelget_channel ()
 Retrieve the current channel from the tuner.
Glib::RefPtr< const
Gst::TunerChannel
get_channel () const
 Retrieve the current channel from the tuner.
void set_channel (const Glib::RefPtr< Gst::TunerChannel >& channel)
 Tunes the object to the given channel, which should be one of the channels returned by list_channels().
Glib::ListHandle< Glib::RefPtr
< Gst::TunerNorm > > 
list_norms ()
 Retrieve a GList of available Gst::TunerNorm settings for the currently tuned channel on the given tuner object.
Glib::ListHandle< Glib::RefPtr
< const Gst::TunerNorm > > 
list_norms () const
 Retrieve a GList of available Gst::TunerNorm settings for the currently tuned channel on the given tuner object.
Glib::RefPtr< Gst::TunerNormget_norm ()
 Get the current video norm from the given tuner object for the currently selected channel.
Glib::RefPtr< const
Gst::TunerNorm
get_norm () const
 Get the current video norm from the given tuner object for the currently selected channel.
void set_norm (const Glib::RefPtr< Gst::TunerNorm >&norm)
 Changes the video norm on this tuner to the given norm, which should be one of the norms returned by list_norms().
gulong get_frequency (const Glib::RefPtr< const Gst::TunerChannel >& channel) const
 Retrieve the current frequency from the given channel.
void set_frequency (const Glib::RefPtr< Gst::TunerChannel >& channel, gulong frequency)
 Sets a tuning frequency on the given tuner/channel.
int get_signal_strength (const Glib::RefPtr< Gst::TunerChannel >& channel)
 Get the strength of the signal on this channel.
Glib::RefPtr< Gst::TunerNormfind_norm (const Glib::ustring&norm)
 Look up a Gst::TunerNorm by name.
Glib::RefPtr< const
Gst::TunerNorm
find_norm (const Glib::ustring&norm) const
 Look up a Gst::TunerNorm by name.
Glib::RefPtr< Gst::TunerChannelfind_channel (const Glib::ustring& channel)
 Look up a Gst::TunerChannel by name.
Glib::RefPtr< const
Gst::TunerChannel
find_channel (const Glib::ustring& channel) const
 Look up a Gst::TunerChannel by name.
void channel_changed (const Glib::RefPtr< Gst::TunerChannel >& channel)
 Called by elements implementing the Gst::Tuner interface when the current channel changes.
void norm_changed (const Glib::RefPtr< Gst::TunerNorm >&norm)
 Called by elements implementing the Gst::Tuner interface when the current norm changes.
void frequency_changed (const Glib::RefPtr< Gst::TunerChannel >& channel, gulong frequency)
 Called by elements implementing the Gst::Tuner interface when the configured frequency changes.
void signal_changed (const Glib::RefPtr< Gst::TunerChannel >& channel, int signal)
 Called by elements implementing the Gst::Tuner interface when the incoming signal strength changes.
Glib::SignalProxy1< void,
const Glib::RefPtr
< Gst::TunerChannel >& > 
signal_channel_changed ()
Glib::SignalProxy2< void,
const Glib::RefPtr
< Gst::TunerChannel >
&, gulong > 
signal_frequency_changed ()
Glib::SignalProxy1< void,
const Glib::RefPtr
< Gst::TunerNorm >& > 
signal_norm_changed ()
Glib::SignalProxy2< void,
const Glib::RefPtr
< Gst::TunerChannel >&, int > 
signal_signal_changed ()
virtual Glib::ListHandle
< Glib::RefPtr
< Gst::TunerChannel > > 
list_channels_vfunc () const
virtual void set_channel_vfunc (const Glib::RefPtr< Gst::TunerChannel >& channel)
virtual Glib::RefPtr
< Gst::TunerChannel
get_channel_vfunc () const
virtual Glib::ListHandle
< Glib::RefPtr< Gst::TunerNorm > > 
list_norms_vfunc () const
virtual void set_norm_vfunc (const Glib::RefPtr< Gst::TunerNorm >&norm)
virtual Glib::RefPtr
< Gst::TunerNorm
get_norm_vfunc () const
virtual void set_frequency_vfunc (const Glib::RefPtr< Gst::TunerChannel >& channel, gulong frequency)
virtual gulong get_frequency_vfunc (const Glib::RefPtr< Gst::TunerChannel >& channel) const
virtual int signal_strength_vfunc (const Glib::RefPtr< Gst::TunerChannel >& channel) const

Static Public Member Functions

static void add_interface (GType gtype_implementer)
static GType get_type ()
 Get the GType for this class, for use with the underlying GObject type system.

Protected Member Functions

 Tuner ()
 You should derive from this class to use it.
virtual void on_channel_changed (const Glib::RefPtr< Gst::TunerChannel >& channel)
 This is a default handler for the signal signal_channel_changed().
virtual void on_frequency_changed (const Glib::RefPtr< Gst::TunerChannel >& channel, gulong frequency)
 This is a default handler for the signal signal_frequency_changed().
virtual void on_norm_changed (const Glib::RefPtr< Gst::TunerNorm >&norm)
 This is a default handler for the signal signal_norm_changed().
virtual void on_signal_changed (const Glib::RefPtr< Gst::TunerChannel >& channel, int signal)
 This is a default handler for the signal signal_signal_changed().

Related Functions

(Note that these are not member functions.)

Glib::RefPtr< Gst::Tunerwrap (GstTuner* object, bool take_copy=false)
 A Glib::wrap() method for this object.

Detailed Description

An interface for elements providing tuner operations.


Constructor & Destructor Documentation

Gst::Tuner::Tuner ( ) [protected]

You should derive from this class to use it.

virtual Gst::Tuner::~Tuner ( ) [virtual]

Member Function Documentation

static void Gst::Tuner::add_interface ( GType  gtype_implementer) [static]

Called by elements implementing the Gst::Tuner interface when the current channel changes.

Fires the Gst::Tuner::signal_channel_changed() signal.

Parameters:
channelA Gst::TunerChannel instance.

Look up a Gst::TunerChannel by name.

Parameters:
channelA string containing the name of a Gst::TunerChannel.
Returns:
A Gst::TunerChannel, or 0 if no channel with the provided name is available.

Look up a Gst::TunerChannel by name.

Parameters:
channelA string containing the name of a Gst::TunerChannel.
Returns:
A Gst::TunerChannel, or 0 if no channel with the provided name is available.

Look up a Gst::TunerNorm by name.

Parameters:
normA string containing the name of a Gst::TunerNorm.
Returns:
A Gst::TunerNorm, or 0 if no norm with the provided name is available.

Look up a Gst::TunerNorm by name.

Parameters:
normA string containing the name of a Gst::TunerNorm.
Returns:
A Gst::TunerNorm, or 0 if no norm with the provided name is available.
void Gst::Tuner::frequency_changed ( const Glib::RefPtr< Gst::TunerChannel >&  channel,
gulong  frequency 
)

Called by elements implementing the Gst::Tuner interface when the configured frequency changes.

Fires the Gst::Tuner::signal_frequency_changed() signal on the tuner, and the Gst::TunerChannel::signal_frequency_changed() signal on the channel.

Parameters:
channelThe current Gst::TunerChannel.
frequencyThe new frequency setting.

Retrieve the current channel from the tuner.

Returns:
The current channel of the tuner object.

Retrieve the current channel from the tuner.

Returns:
The current channel of the tuner object.
gulong Gst::Tuner::get_frequency ( const Glib::RefPtr< const Gst::TunerChannel >&  channel) const

Retrieve the current frequency from the given channel.

As for set_frequency(), the Gst::TunerChannel must support frequency operations, as indicated by the GST_TUNER_CHANNEL_FREQUENCY flag.

Parameters:
channelThe Gst::TunerChannel to retrieve the frequency from.
Returns:
The current frequency, or 0 on error.
virtual gulong Gst::Tuner::get_frequency_vfunc ( const Glib::RefPtr< Gst::TunerChannel >&  channel) const [virtual]

Get the current video norm from the given tuner object for the currently selected channel.

Returns:
The current norm.

Get the current video norm from the given tuner object for the currently selected channel.

Returns:
The current norm.

Get the strength of the signal on this channel.

Note that this requires the current channel to be a "tuning" channel, i.e. a channel on which frequency can be set. This can be checked using GST_TUNER_CHANNEL_HAS_FLAG (), and the appropriate flag to check for is GST_TUNER_CHANNEL_FREQUENCY.

The valid range of the signal strength is indicated in the min_signal and max_signal properties of the Gst::TunerChannel.

Parameters:
channelThe Gst::TunerChannel to get the signal strength from.
Returns:
Signal strength, or 0 on error.
static GType Gst::Tuner::get_type ( ) [static]

Get the GType for this class, for use with the underlying GObject type system.

GstTuner* Gst::Tuner::gobj ( ) [inline]

Provides access to the underlying C GObject.

Reimplemented from Glib::Interface.

const GstTuner* Gst::Tuner::gobj ( ) const [inline]

Provides access to the underlying C GObject.

Reimplemented from Glib::Interface.

Retrieve a List of Gst::TunerChannels available (e.g. 'composite', 's-video', ...) from the given tuner object.

Returns:
A list of channels available on this tuner. The list is owned by the GstTuner and must not be freed.

Retrieve a List of Gst::TunerChannels available (e.g. 'composite', 's-video', ...) from the given tuner object.

Returns:
A list of channels available on this tuner. The list is owned by the GstTuner and must not be freed.

Retrieve a GList of available Gst::TunerNorm settings for the currently tuned channel on the given tuner object.

Returns:
A list of norms available on the current channel for this tuner object. The list is owned by the GstTuner and must not be freed.

Retrieve a GList of available Gst::TunerNorm settings for the currently tuned channel on the given tuner object.

Returns:
A list of norms available on the current channel for this tuner object. The list is owned by the GstTuner and must not be freed.

Called by elements implementing the Gst::Tuner interface when the current norm changes.

Fires the Gst::Tuner::signal_norm_changed() signal.

Parameters:
normA Gst::TunerNorm instance.
virtual void Gst::Tuner::on_channel_changed ( const Glib::RefPtr< Gst::TunerChannel >&  channel) [protected, virtual]

This is a default handler for the signal signal_channel_changed().

virtual void Gst::Tuner::on_frequency_changed ( const Glib::RefPtr< Gst::TunerChannel >&  channel,
gulong  frequency 
) [protected, virtual]

This is a default handler for the signal signal_frequency_changed().

virtual void Gst::Tuner::on_norm_changed ( const Glib::RefPtr< Gst::TunerNorm >&  norm) [protected, virtual]

This is a default handler for the signal signal_norm_changed().

virtual void Gst::Tuner::on_signal_changed ( const Glib::RefPtr< Gst::TunerChannel >&  channel,
int  signal 
) [protected, virtual]

This is a default handler for the signal signal_signal_changed().

Tunes the object to the given channel, which should be one of the channels returned by list_channels().

Parameters:
channelThe channel to tune to.
virtual void Gst::Tuner::set_channel_vfunc ( const Glib::RefPtr< Gst::TunerChannel >&  channel) [virtual]
void Gst::Tuner::set_frequency ( const Glib::RefPtr< Gst::TunerChannel >&  channel,
gulong  frequency 
)

Sets a tuning frequency on the given tuner/channel.

Note that this requires the given channel to be a "tuning" channel, which can be checked using GST_TUNER_CHANNEL_HAS_FLAG (), with the proper flag being GST_TUNER_CHANNEL_FREQUENCY.

The frequency is in Hz, with minimum steps indicated by the frequency_multiplicator provided in the Gst::TunerChannel. The valid range is provided in the min_frequency and max_frequency properties of the Gst::TunerChannel.

Parameters:
channelThe Gst::TunerChannel to set the frequency on.
frequencyThe frequency to tune in to.
virtual void Gst::Tuner::set_frequency_vfunc ( const Glib::RefPtr< Gst::TunerChannel >&  channel,
gulong  frequency 
) [virtual]

Changes the video norm on this tuner to the given norm, which should be one of the norms returned by list_norms().

Parameters:
normThe norm to use for the current channel.
virtual void Gst::Tuner::set_norm_vfunc ( const Glib::RefPtr< Gst::TunerNorm >&  norm) [virtual]
void Gst::Tuner::signal_changed ( const Glib::RefPtr< Gst::TunerChannel >&  channel,
int  signal 
)

Called by elements implementing the Gst::Tuner interface when the incoming signal strength changes.

Fires the Gst::Tuner::signal_signal_changed() signal on the tuner and the Gst::TunerChannel::signal_signal_changed() signal on the channel.

Parameters:
channelThe current Gst::TunerChannel.
signalThe new signal strength.
Slot Prototype:
void on_my_channel_changed(const Glib::RefPtr<Gst::TunerChannel>& channel)

Reports that the current Gst::TunerChannel has changed.

Parameters:
channelThe new configured channel.
Slot Prototype:
void on_my_frequency_changed(const Glib::RefPtr<Gst::TunerChannel>& channel, gulong frequency)

Reports that the current frequency has changed.

Parameters:
frequencyThe new frequency (an unsigned long).
Slot Prototype:
void on_my_norm_changed(const Glib::RefPtr<Gst::TunerNorm>& norm)

Reports that the current Gst::TunerNorm has changed.

Parameters:
normThe new configured norm.
Slot Prototype:
void on_my_signal_changed(const Glib::RefPtr<Gst::TunerChannel>& channel, int signal)

Reports that the signal strength has changed.

See Also: Gst::Tuner::signal_strength()

Parameters:
channelThe current Gst::TunerChannel.
signalThe new signal strength (an integer).
virtual int Gst::Tuner::signal_strength_vfunc ( const Glib::RefPtr< Gst::TunerChannel >&  channel) const [virtual]

Friends And Related Function Documentation

Glib::RefPtr< Gst::Tuner > wrap ( GstTuner *  object,
bool  take_copy = false 
) [related]

A Glib::wrap() method for this object.

Parameters:
objectThe C instance.
take_copyFalse if the result should take ownership of the C instance. True if it should take a new copy or ref.
Returns:
A C++ instance that wraps this C instance.

The documentation for this class was generated from the following file: