2 # vi:si:et:sw=4:sts=4:ts=4
11 pipeline = " ".join(sys.argv[1:])
12 a = gst.element_factory_make(pipeline)
15 res = a.set_state(gst.STATE_PAUSED)
16 if res != gst.STATE_CHANGE_SUCCESS:
17 print "Could not set pipeline %s to PAUSED" % pipeline
20 for t in a.list_tracks():
21 if t.flags & gst.interfaces.MIXER_TRACK_INPUT:
22 sys.stdout.write(t.label)
23 sys.stdout.write(': %d - %d' % (t.min_volume, t.max_volume))
24 volumes = a.get_volume(t)
25 sys.stdout.write(': %r' % (volumes, ))
26 if t.props.num_channels > 0:
27 a.set_volume(t, volumes=volumes)
28 if t.flags & gst.interfaces.MIXER_TRACK_RECORD:
29 sys.stdout.write(' (selected)')
30 sys.stdout.write('\n')