Class: Gst::Caps

Inherits:
Object
  • Object
show all
Defined in:
lib/gst/caps.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(*args) ⇒ Caps

Returns a new instance of Caps.



30
31
32
33
34
35
36
37
38
39
40
41
42
# File 'lib/gst/caps.rb', line 30

def initialize(*args)
  if args.size == 1
    case args[0]
    when :any
      initialize_new_any
      return
    when :empty
      initialize_new_empty
      return
    end
  end
  initialize_raw(*args)
end

Class Method Details

.anyObject



20
21
22
# File 'lib/gst/caps.rb', line 20

def any
  new(:any)
end

.emptyObject



24
25
26
# File 'lib/gst/caps.rb', line 24

def empty
  new(:empty)
end

Instance Method Details

#initialize_rawObject



29
# File 'lib/gst/caps.rb', line 29

alias_method :initialize_raw, :initialize

#structuresObject



44
45
46
47
48
# File 'lib/gst/caps.rb', line 44

def structures
  size.times.collect do |i|
    get_structure(i)
  end
end