[ruby-gnome2-doc-cvs] [Hiki] update - Gst::Element

アーカイブの一覧に戻る

ruby-****@sourc***** ruby-****@sourc*****
2004年 3月 2日 (火) 05:42:24 JST


-------------------------
REMOTE_ADDR = 217.117.55.140
REMOTE_HOST = 
        URL = http://ruby-gnome2.sourceforge.jp/?Gst%3A%3AElement
-------------------------
  = class Gst::Element
  Base class for all pipeline elements.
  
  == Object Hierarchy
- * ((<Gst::Object>))
+ * Object
+   * GLib::Instantiatable
+     * GLib::Object
+       * Gst::Object
+         * Gst::Element
  
- 
  == Instance Methods
- --- >>(anElement) 
+ --- >>(element)
      Synonym for Gst::Element#link.
+     * element: a Gst::Element object.  
+     * Returns: the destination element, or nil if the link failed.
  
- --- add_ghost_pad(aPad, aPadNameString=nil) 
+ --- add_ghost_pad(pad, pad_name=nil)
      Creates a ghost pad from the given pad, and adds it to the list of
      pads of the element.
-     
      The second parameter defines the ghost pad name.  
-     When ommited (or nil),  the ghost pad will receive the same name as
+     When ommited (or nil), the ghost pad will receive the same name as
      the given pad.
-     
-     Returns the ghost pad which was created, or nil.
+     * pad_name: a name which will be attributed to the ghost pad.  
+     * pad: a Gst::Pad. 
+     * Returns: the ghost pad which was created, or nil.
  
- --- clock 
-     Gets the clock of the element, as a Gst::Clock object.
-     Returns nil if this element does not provide a clock.
+ --- clock
+     This method returns the clock of the element (as a Gst::Clock object), or nil if this element does not provide a clock.
+     * Returns: the clock of the element (as a Gst::Clock object), or nil if this element does not provide a clock.
  
- --- complex? 
-     Checks if the Gst::Element::FLAG_COMPLEX flag is set on the object.
+ --- complex?
+     Checks if the Gst::Element::COMPLEX flag is set on the object.
+     * Returns: true if the flag is set, false otherwise.
  
- --- decoupled? 
-     Checks if the Gst::Element::FLAG_DECOUPLED flag is set on the object.
+ --- decoupled?
+     Checks if the Gst::Element::DECOUPLED flag is set on the object.
+     * Returns: true if the flag is set, false otherwise.
  
- --- each_pad { |aGstPad| block } 
+ --- each_pad { |pad| ... }
      Calls the block for each pad associated with the element, passing a 
      reference to the Gst::Pad as parameter.
-     
-     Always returns nil.
+     * Returns: always nil.
  
- --- each_property { |aStringName, aStringDescr, anObject| block } 
+ --- each_property { |name, descr, obj| ... }
      Calls the block for each property of the element, passing
-     name (aString), description (aStringDescr) and value (anObject) of the property 
-     as parameters.
-     
-     Always returns nil.
+     name, description and value of the property as parameters.
+     * Returns: always nil.
  
- --- eos 
-     Perform the actions needed to bring the element in the EOS 
+ --- eos
+     Performs the actions needed to bring the element in the EOS 
      (end of stream) state.
+     * Returns: self.
  
- --- event_aware? 
-     Checks if the Gst::Element::FLAG_EVENT_AWARE flag is set on the object.
+ --- event_aware?
+     Checks if the Gst::Element::EVENT_AWARE flag is set on the object.
+     * Returns: true if the flag is set, false otherwise.
  
- --- get_pad(aNameString) 
+ --- get_pad(name)
      Retrieves a Gst::Pad object from the element by name.
-     Returns nil if the pad cannot be found.
+     * name: the name of a pad.  
+     * Returns: a Gst::Pad object, or nil if the pad cannot be found.
  
- --- get_property(aString) 
-     Returns the value associated with the property named 
-     aString, or nil if the property has no value.
-     
+ --- get_property(name)
+     Returns the value associated with the named property,
+     or nil if the property has no value.
      Note that properties may be read through accessors methods, 
      which are generated on-the-fly according to the Gst::Element type.
-     
-     Example:
-     
-         e = Gst::ElementFactory.make("filesrc")
-         # ...
-         puts "Location is " + e.get_property("location")
-         # This does exactly the same
-         puts "Location is " + e.location
+     	e = Gst::ElementFactory.make("filesrc")
+     	# ...
+     	
+     	puts "Location is " + e.get_property("location")
+     	# This does exactly the same
+     	puts "Location is " + e.location
+     * name: a property name.  
+     * Returns: the object associated with the named property.
  
- --- has_infinite_loop? 
-     Checks if the Gst::Element::FLAG_INFINITE_LOOP flag is set on the object.
+ --- has_infinite_loop?
+     Checks if the Gst::Element::INFINITE_LOOP flag is set on the object.
+     * Returns: true if the flag is set, false otherwise.
  
- --- has_new_loopfunc? 
-     Checks if the Gst::Element::FLAG_NEW_LOOPFUNC flag is set on the object.
+ --- has_new_loopfunc?
+     Checks if the Gst::Element::NEW_LOOPFUNC flag is set on the object.
+     * Returns: true if the flag is set, false otherwise.
  
- --- indexable? 
-     Checks if the element can be indexed.
+ --- indexable?
+     This method returns true if the element can be indexed, false otherwise.
+     * Returns: true if the element can be indexed, false otherwise.
  
- --- link(anElement) 
-     Links this element (source) to anElement (destination). 
-     
-     The functions looks for existing pads and request pads that 
+ --- link(element)
+     Links this element (source) to the provided element (destination). 
+     The method looks for existing pads and request pads that 
      aren't linked yet. If multiple links are possible, only one 
      is established.
-     
-     Returns the destination element (anElement).
+     * element: a Gst::Element object.  
+     * Returns: the destination element, or nil if the link failed.
  
- --- link_pads(other_element) 
+ --- link_pads(element)
      Links the "src" named pad of the current element to the
      "sink" named pad of the destination element, returning
      true on success.
-     
      If you want to link specific named pads, you should use
-     the Gst::Pad#link method directly.
-     
-     Example:
-     
-         element1.link_pads(element2)
-         # This does the same
-         element1.get_pad("src").link(element2.get_pad("sink"))
+     the Gst::Pad#link method directly:
+     	element1.link_pads(element2)
+     	
+     	# This does the same
+     	element1.get_pad("src").link(element2.get_pad("sink"))
+     * element: a Gst::Element.  
+     * Returns: true on success, false on failure.
  
- --- pads 
+ --- pads
      Gets a list of the pads associated with the element, in an array
      of Gst::Pad objects.
+     * Returns: an Array of Gst::Pad objects.
  
- --- pause 
-     Synonym for Gst::Element#set_state with Gst::Element::STATE_PAUSED.
+ --- pause
+     This method calls Gst::Element#set_state with Gst::Element::STATE_PAUSED.
+     * Returns: a code (see ((<GstElementState|Gst::Element#GstElementState>))Return).
  
- --- paused? 
-     Checks if the current state equals Gst::Element::STATE_PAUSED.
+ --- paused?
+     This method returns true if the current state equals Gst::Element::STATE_PAUSED, false otherwise.
+     * Returns: true if the current state equals Gst::Element::STATE_PAUSED, false otherwise.
  
- --- play 
-     Synonym for Gst::Element#set_state with Gst::Element::STATE_PLAYING.
+ --- play
+     This method calls Gst::Element#set_state with Gst::Element::STATE_PLAYING.
+     * Returns: a code (see ((<GstElementState|Gst::Element#GstElementState>))Return).
  
- --- playing? 
-     Checks if the current state equals Gst::Element::STATE_PLAYING.
+ --- playing?
+     This method returns true if the current state equals Gst::Element::STATE_PLAYING, false otherwise.
+     * Returns: true if the current state equals Gst::Element::STATE_PLAYING, false otherwise.
  
- --- provides_clock? 
-     Checks if the element provides a clock.
+ --- provides_clock?
+     This method returns true if the element provides a clock, false otherwise.
+     * Returns: true if the element provides a clock, false otherwise.
  
- --- query(aQueryType, aFormat = Gst::Format::DEFAULT) 
+ --- query(query_type, format=Gst::Format::DEFAULT)
      Performs a query on the element.
-     
-     Meaningful query types are:
-         * Gst::QueryType::TOTAL;
-         * Gst::QueryType::POSITION;
-         * Gst::QueryType::LATENCY;
-         * Gst::QueryType::JITTER;
-         * Gst::QueryType::START;
-         * Gst::QueryType::SEGMENT_END;
-         * Gst::QueryType::RATE.
-     
-     Meaningful formats are:
-         * Gst::Format::DEFAULT;
-         * Gst::Format::BYTES;
-         * Gst::Format::TIME;
-         * Gst::Format::BUFFERS;
-         * Gst::Format::PERCENT;
-         * Gst::Format::UNITS.
-     
-     Returns a Fixnum value, or nil if the query could not be performed.
+     * format: a format (see ((<GstFormat|Gst::Format#GstFormat>))s).  
+     * query_type: a query type (see ((<GstQueryType|Gst::QueryType#GstQueryType>))s). 
+     * Returns: a Fixnum value returned by the query, or nil if the query could not be performed.
  
- --- ready 
-     Synonym for Gst::Element#set_state with Gst::Element::STATE_READY.
+ --- ready
+     This method calls Gst::Element#set_state with Gst::Element::STATE_READY.
+     * Returns: a code (see ((<GstElementState|Gst::Element#GstElementState>))Return).
  
- --- ready? 
-     Checks if the current state equals Gst::Element::STATE_READY.
+ --- ready?
+     This method returns true if the current state equals Gst::Element::STATE_READY, false otherwise.
+     * Returns: true if the current state equals Gst::Element::STATE_READY, false otherwise.
  
- --- requires_clock? 
-     Checks if the element requires a clock.
+ --- requires_clock?
+     This method returns true if the element requires a clock, false otherwise.
+     * Returns: true if the element requires a clock, false otherwise.
  
- --- sched_interrupt 
+ --- sched_interrupt
      Requests the scheduler of this element to interrupt the 
      execution of this element and scheduler another one.
+     * Returns: self.
  
- --- sched_yield 
+ --- sched_yield
      Requests a yield operation for the element. The scheduler 
      will typically give control to another element.
+     * Returns: self.
  
- --- send_event(anEvent) 
+ --- send_event(event)
      Sends an event to an element, through a Gst::Event object. 
      If the element doesn't implement an event handler, the event will be 
      forwarded to a random sink pad.
-     
-     Returns true if the request event was successfully handled, false
-     otherwise.
+     * event: a Gst::Event object.  
+     * Returns: true if the request event was successfully handled, false otherwise.
  
- --- set_property(aString, anObject) 
-     Sets the value anObject for the property named aString.
-     
+ --- set_property(name, obj)
+     Sets the value anObject for a named property.
      If the element uses threadsafe properties, the property will 
      be put on the async queue.
-     
      Note that properties may be set through accessors methods, 
      which are generated on-the-fly according to the Gst::Element type.
-     
-     Example:
-     
-         e = Gst::ElementFactory.make("filesrc")
-         e.set_property("location", "a_file.ogg")
-         # This does exactly the same
-         e.location = "a_file.ogg"
+     	e = Gst::ElementFactory.make("filesrc")
+     	e.set_property("location", "a_file.ogg")
+     	
+     	# This does exactly the same
+     	e.location = "a_file.ogg"
+     * name: a property name. 
+     * obj: an object.  
+     * Returns: self.
  
- --- set_state(aFixnum) 
+ --- set_state(state)
      Sets the state of the element. 
-     
-     This function will try to set the requested state by going through all 
+     This method will try to set the requested state by going through all 
      the intermediary states and calling the class's state change function 
      for each.
-     
-     Returns a Fixnum code, according to the result of the operation:
-     
-       * Gst::Element::STATE_FAILURE;
-       * Gst::Element::STATE_SUCCESS;
-       * Gst::Element::STATE_ASYNC.
+     * state: the state you want to set (see ((<GstElementState|Gst::Element#GstElementState>))).  
+     * Returns: a code (see ((<GstElementState|Gst::Element#GstElementState>))Return).
  
- --- state 
-     Gets the state of the element:
-     
-       * Gst::Element::STATE_NULL;
-       * Gst::Element::STATE_READY;
-       * Gst::Element::STATE_PAUSED;
-       * Gst::Element::STATE_PLAYING.
+ --- state
+     This method returns the state of the element (see ((<GstElementState|Gst::Element#GstElementState>))).
+     * Returns: the state of the element (see ((<GstElementState|Gst::Element#GstElementState>))).
  
- --- state=(aFixnum) 
+ --- state=(state)
      Synonym for Gst::Element#set_state.
+     * state: the state you want to set (see ((<GstElementState|Gst::Element#GstElementState>))).  
+     * Returns: a code (see ((<GstElementState|Gst::Element#GstElementState>))Return).
  
- --- stop 
-     Synonym for Gst::Element#set_state with Gst::Element::STATE_NULL.
+ --- stop
+     This method calls Gst::Element#set_state with Gst::Element::STATE_NULL.
+     * Returns: a code (see ((<GstElementState|Gst::Element#GstElementState>))Return).
  
- --- stopped? 
-     Checks if the current state equals Gst::Element::STATE_NULL.
+ --- stopped?
+     This method returns true if the current state is set to Gst::Element::STATE_NULL, false otherwise.
+     * Returns: true if the current state is set to Gst::Element::STATE_NULL, false otherwise.
  
- --- thread_suggested? 
-     Checks if the Gst::Element::FLAG_THREAD_SUGGESTED flag is set on the 
+ --- thread_suggested?
+     Checks if the Gst::Element::THREAD_SUGGESTED flag is set on the 
      object.
+     * Returns: true if the flag is set, false otherwise.
  
- --- unlink_pads(other_element) 
+ --- unlink_pads(element)
      Unlinks the "src" named pad of the current element from the
      "sink" named pad of the destination element.
-     
      If you want to unlink specific named pads, you should use
-     the Gst::Pad#unlink method directly.
-     
-     Example:
-     
-         element1.unlink_pads(element2)
-         # This does the same
-         element1.get_pad("src").unlink(element2.get_pad("sink"))
+     the Gst::Pad#unlink method directly:
+     	element1.unlink_pads(element2)
+     	
+     	# This does the same
+     	element1.get_pad("src").unlink(element2.get_pad("sink"))
+     * element: a Gst::Element.  
+     * Returns: self.
  
  --- use_threadsafe_properties? 
-     Checks if the Gst::Element::FLAG_USE_THREADSAFE_PROPERTIES flag 
+     Checks if the Gst::Element::USE_THREADSAFE_PROPERTIES flag 
      is set on the object.
+     * Returns: true if the flag is set, false otherwise.
  
- --- wait_state_change 
+ --- wait_state_change
      Waits and blocks until the element changed its state.
+     * Returns: self.
  
- 
  == Constants
- --- FLAG_COMPLEX
-     This element is complex (for some def.) and generally requires a cothread.
+ === GstElementFlags
+ --- COMPLEX
+ --- DECOUPLED
+ --- EVENT_AWARE
+ --- FLAG_LAST
+ --- INFINITE_LOOP
+ --- NEW_LOOPFUNC
+ --- SCHEDULER_PRIVATE1
+ --- SCHEDULER_PRIVATE2
+ --- THREAD_SUGGESTED
+ --- USE_THREADSAFE_PROPERTIES
  
- --- FLAG_DECOUPLED
-     Input and output pads aren't directly coupled to each other 
-     (examples: queues, multi-output async readers, etc...).
+ === GstObjectFlags
+ --- DESTROYED
+ --- FLOATING
+ --- OBJECT_FLAG_LAST
  
- --- FLAG_EVENT_AWARE
-     The element can handle events.
- 
- --- FLAG_INFINITE_LOOP
-     This element, for some reason, has a loop function that performs
-     an infinite loop without calls to Gst::Element#sched_yield.
- 
- --- FLAG_NEW_LOOPFUNC
-     There is a new lookfunction ready for placement.
- 
- --- FLAG_THREAD_SUGGESTED
-     This element should be placed in a thread if at all possible.
- 
- --- FLAG_USE_THREADSAFE_PROPERTIES
-     Uses threadsafe property acessors (get/set).
- 
- --- STATE_ASYNC
-     The element will asynchronously change its state as soon as possible.
- 
- --- STATE_FAILURE
-     The element could not perform the state change.
- 
+ === GstElementState
  --- STATE_NULL
-     The state of the element is reseted.
- 
  --- STATE_PAUSED
-     Means there really is data flowing temporary stops the data flow.
- 
  --- STATE_PLAYING
-     Means there really is data flowing through the graph.
- 
  --- STATE_READY
-     The element is ready to start processing data. 
-     Some elements might have a non trivial way to initialize themselves.
+ --- STATE_VOID_PENDING
  
- --- STATE_SUCCESS
-     The element successfully changed its state.
- 
- 
  == Signals
  --- eos
+ 
  --- error
+ 
  --- new-pad
+ 
  --- pad-removed
+ 
  --- state-change
+ 
+ == See Also
+ ((<Gst::Bin>)), ((<Gst>)).
  
  - ((<lrz>))





ruby-gnome2-cvs メーリングリストの案内
アーカイブの一覧に戻る