Skip to content

Latest commit

 

History

History
34 lines (27 loc) · 751 Bytes

api_reference.md

File metadata and controls

34 lines (27 loc) · 751 Bytes

GstContext

Purpose

Example

import time
from gstreamer import GstContext

with GstContext():
  ...
  
  # run pipeline 1
  ...
  # run pipeline N
  
  while any(pipeline):
    time.sleep(1)

GstPipeline

Purpose

  • Hides Gst.Pipeline creation and message handling in single class

Example

import time
from gstreamer import GstContext, GstPipeline

with GstContext():
  with GstPipeline("videotestsrc num-buffers=100 ! autovideosink") as p:
    while not p.is_done:
      time.sleep(1)