Beispiel #1
0
 def __init__(self,
              duration=10 * gst.SECOND,
              media_duration=10 * gst.SECOND,
              *args,
              **kwargs):
     self.__duration = duration
     self.__media_duration = media_duration
     SourceFactory.__init__(self, "fakegnl://", *args, **kwargs)
Beispiel #2
0
    def __init__(self, timeline):
        SourceFactory.__init__(self, "timeline://", "timeline")
        self.bin = gst.Bin()
        self.max_bins = 1
        self.timeline = timeline
        self.pad_num = 0
        self.ghosts = {}
        self.seek_checkers = {}

        self.duration = timeline.duration

        for track in self.timeline.tracks:
            self._addTrack(track)

        self._connectTimeline()
Beispiel #3
0
    def __init__(self, timeline):
        SourceFactory.__init__(self, "timeline://", "timeline")
        self.bin = gst.Bin()
        self.max_bins = 1
        self.timeline = timeline
        self.pad_num = 0
        self.ghosts = {}
        self.seek_checkers = {}

        self.duration = timeline.duration

        for track in self.timeline.tracks:
            self._addTrack(track)

        self._connectTimeline()
Beispiel #4
0
    def _makeStreamBin(self, output_stream):
        video_bin = SourceFactory._makeStreamBin(self, output_stream)
        capsfilter = video_bin.get_by_name("videotestsrc-capsfilter")
        queue = video_bin.get_by_name("internal-queue")
        capsfilter.link(queue)

        capsfilter = video_bin.get_by_name("capsfilter-proj-settings")
        target = capsfilter.get_pad("src")
        ghost = gst.GhostPad('src', target)
        video_bin.add_pad(ghost)

        return video_bin
Beispiel #5
0
    def _makeStreamBin(self, output_stream):
        video_bin = SourceFactory._makeStreamBin(self, output_stream)
        capsfilter = video_bin.get_by_name("videotestsrc-capsfilter")
        queue = video_bin.get_by_name("internal-queue")
        capsfilter.link_pads_full("src", queue, "sink", gst.PAD_LINK_CHECK_NOTHING)

        capsfilter = video_bin.get_by_name("capsfilter-proj-settings")
        target = capsfilter.get_pad("src")
        ghost = gst.GhostPad('src', target)
        video_bin.add_pad(ghost)

        return video_bin
Beispiel #6
0
    def _makeStreamBin(self, output_stream):
        video_bin = SourceFactory._makeStreamBin(self, output_stream)
        capsfilter = video_bin.get_by_name("videotestsrc-capsfilter")
        queue = video_bin.get_by_name("internal-queue")
        capsfilter.link(queue)

        capsfilter = video_bin.get_by_name("capsfilter-proj-settings")
        target = capsfilter.get_pad("src")
        ghost = gst.GhostPad('src', target)
        video_bin.add_pad(ghost)

        return video_bin
Beispiel #7
0
    def _makeStreamBin(self, output_stream):
        video_bin = SourceFactory._makeStreamBin(self, output_stream)
        capsfilter = video_bin.get_by_name("videotestsrc-capsfilter")
        queue = video_bin.get_by_name("internal-queue")
        capsfilter.link_pads_full("src", queue, "sink",
                                  gst.PAD_LINK_CHECK_NOTHING)

        capsfilter = video_bin.get_by_name("capsfilter-proj-settings")
        target = capsfilter.get_pad("src")
        ghost = gst.GhostPad('src', target)
        video_bin.add_pad(ghost)

        return video_bin
Beispiel #8
0
 def getInterpolatedProperties(self, stream):
     props = SourceFactory.getInterpolatedProperties(self, stream)
     props.update({"volume": None})
     return props
Beispiel #9
0
    def __init__(self, wave=0):
        SourceFactory.__init__(self, "audiotestsrc://")
        self.wave = wave

        caps = gst.Caps('audio/x-raw-int; audio/x-raw-float')
        self.addOutputStream(AudioStream(caps))
Beispiel #10
0
    def __init__(self, pattern=0):
        SourceFactory.__init__(self, "videotestsrc://")
        self.pattern = pattern

        caps = gst.Caps('video/x-raw-yuv; video/x-raw-rgb')
        self.addOutputStream(VideoStream(caps))
Beispiel #11
0
 def __init__(self, factoryname="fakesrc", *args, **kwargs):
     SourceFactory.__init__(self, "fakesrc://", *args, **kwargs)
     self._factoryname = factoryname
Beispiel #12
0
 def __init__(self):
     SourceFactory.__init__(self, "stub://")
     self.duration = 42 * gst.SECOND
Beispiel #13
0
 def __init__(self, duration=10 * gst.SECOND, media_duration=10 * gst.SECOND,
              *args, **kwargs):
     self.__duration = duration
     self.__media_duration = media_duration
     SourceFactory.__init__(self, "fakegnl://", *args, **kwargs)
Beispiel #14
0
 def __init__(self):
     SourceFactory.__init__(self, "stub://")
     self.duration = 42 * gst.SECOND
Beispiel #15
0
    def __init__(self, wave=0):
        SourceFactory.__init__(self, "audiotestsrc://")
        self.wave = wave

        caps = gst.Caps('audio/x-raw-int; audio/x-raw-float')
        self.addOutputStream(AudioStream(caps))
Beispiel #16
0
 def __init__(self, factoryname="fakesrc", *args, **kwargs):
     SourceFactory.__init__(self, "fakesrc://", *args, **kwargs)
     self._factoryname = factoryname
Beispiel #17
0
    def __init__(self, pattern=0):
        SourceFactory.__init__(self, "videotestsrc://")
        self.pattern = pattern

        caps = gst.Caps('video/x-raw-yuv; video/x-raw-rgb')
        self.addOutputStream(VideoStream(caps))
Beispiel #18
0
 def getInterpolatedProperties(self, stream):
     props = SourceFactory.getInterpolatedProperties(self, stream)
     props.update({"volume": None})
     return props