GstShark - Graphic tracer: Difference between revisions

From RidgeRun Developer Wiki
No edit summary
mNo edit summary
 
(6 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{GstShark Tracer
{{GstShark/Head |previous=CPU usage tracer|next=Bitrate tracer|metakeywords=}}
|prev=[[GstShark - CPU usage tracer|CPU usage tracer]]
 
|next=[[GstShark - Bitrate tracer|Bitrate tracer]]
The graphic tracer is an add-on to the GstShark tracer suit. It does not generate any output log providing any information about the performance of the pipeline neither it helps the user with the debugging process at the time of facing an unexpected issue on the behavior of a pipeline. However, this tracer is very useful since it shows to the user the pipeline graphically so the user can easily inspect it visually.
|name=graphic
|description=The graphic tracer is an add-on of the GstShark tracer suit. It does not generate any output log providing any information about the performance of the pipeline neither it helps the user with the debugging process at the time of facing an unexpected issue on the behavior of a pipeline. However, this tracer is very useful since it shows to the user the pipeline graphically so the user can easily inspect it visually.


In the examples of the previous tracers the pipelines used were very simple and small which makes them very easy to inspect. This is not the case with the applications usually developed in the actual market. There are scenarios in which an application uses a more complex pipeline with a lot of elements interconnected with several source elements, tees, muxers, encoders, decoders, among others. In those cases is very difficult to inspect and review every section of a pipeline manually and here is when the Graphic tracer becomes handy.  
In the examples of the previous tracers the pipelines used were very simple and small which makes them very easy to inspect. This is not the case with the applications usually developed in the actual market. There are scenarios in which an application uses a more complex pipeline with a lot of elements interconnected with several source elements, tees, muxers, encoders, decoders, among others. In those cases is very difficult to inspect and review every section of a pipeline manually and here is when the Graphic tracer becomes handy.  


The tracer provides a graphical representation of the pipeline without having to set any other environment variables and it shows the diagram instantaneously when the pipeline starts to run. The tracer also stores the diagram of the pipeline together with the output log generated by the others tracers in a DOT format file. It can be opened with the [[GstShark - Eclipse plugin|experimental Eclipse plugin]] or with any DOT file viewer at any time that the user might want after the pipeline has stopped its operation. For more information on the DOT format file, refer to the [[GstShark - Pipeline Diagram|pipeline diagram]] wiki page.
The tracer provides a graphical representation of the pipeline without having to set any other environment variables and it shows the diagram instantaneously when the pipeline starts to run. The tracer also stores the diagram of the pipeline together with the output log generated by the other tracers in a DOT format file. It can be opened with the [[GstShark - Eclipse plugin|experimental Eclipse plugin]] or with any DOT file viewer at any time that the user might want after the pipeline has stopped its operation. For more information on the DOT format file, refer to the [[GstShark - Pipeline Diagram|pipeline diagram]] wiki page.
 
The generated diagram is placed in a new folder called "graphic", inside the selected output directory. If the Graphic tracer is used alone on the pipeline, or if the other tracers have been disabled using the "GST_SHARK_CTF_DISABLE" environment variable, the diagram file will be stored in the "graphic" directory in the current path. When the Graphic tracer is running along with other enabled tracers, the diagram is stored in the "graphic" sub-directory inside the output folder (by default "gstshark_YY-MM-DD_hh:mm:ss").


It is important to mention that the generation of the graphic file cannot be disabled in the same way than the other tracers above. The other tracers can be disabled by defining the environment variable "GST_SHARK_CTF_DISABLE", but if the Graphic tracer is selected at the time of running a pipeline, the diagram will be generated and stored anyway.
The generated diagram is placed in a new folder called "graphic", inside the selected output directory. If the Graphic tracer is used alone on the pipeline, or if the other tracers have been disabled using the {{code|GST_SHARK_CTF_DISABLE}} environment variable, the diagram file will be stored in the "graphic" directory in the current path. When the Graphic tracer is running along with other enabled tracers, the diagram is stored in the "graphic" sub-directory inside the output folder (by default "gstshark_YY-MM-DD_hh:mm:ss").


It is important to mention that the generation of the graphic file cannot be disabled in the same way than the other tracers above. The other tracers can be disabled by defining the environment variable {{code|GST_SHARK_CTF_DISABLE}}, but if the Graphic tracer is selected at the time of running a pipeline, the diagram will be generated and stored anyway. 
<br><br>
<table>
<tr>
<td><div class="clear; float:right">__TOC__</div></td>
<td valign=top>
{{GStreamer debug}}
</td>
</table>


 
==Pipeline==
|pipeline=
All the simple pipeline diagrams shown on the others tracer pages on this wiki have been obtained using the Graphic tracer. The following pipeline has a more complicated layout that illustrates better the capabilities of the Graphic tracer.
All the pipeline diagrams shown on the others tracer pages on this wiki have been obtained using the Graphic tracer. The pipelines used above are straightforward to inspect. The following pipeline has a more complicated layout that illustrates better the capabilities of the Graphic tracer.
<syntaxhighlight lang="bash">
<syntaxhighlight lang="bash">
$ GST_DEBUG="GST_TRACER:7" GST_TRACERS="graphic" gst-launch-1.0 videotestsrc is-live=true ! tee name=t ! valve drop=TRUE ! queue max-size-buffers=0 ! avenc_ljpeg  multifilesink next-file=0 enable-last-sample=FALSE async=FALSE sync=FALSE location=./example_snapshot_%d.jpg t. ! queue max-size-buffers=0 ! 'video/x-raw, format=(string)YUY2, width=(int)1280, height=(int)720, framerate=(fraction)10/1' ! videoconvert ! queue max-size-buffers=0 ! avenc_h263p ! identity ! queue max-size-buffers=0 max-size-bytes=0 max-size-time=9000000000 ! mux. audiotestsrc ! volume ! avenc_mp2 bitrate=128 ! identity ! queue max-size-buffers=0 max-size-bytes=0 max-size-time=9000000000 ! matroskamux name=mux ! multifilesink next-file=1 location=example_50mb_%s.mkv enable-last-sample=FALSE sync=TRUE async=FALSE
$ GST_DEBUG="GST_TRACER:7" GST_TRACERS="graphic" gst-launch-1.0 videotestsrc is-live=true ! tee name=t ! valve drop=TRUE ! queue max-size-buffers=0 ! avenc_ljpeg  multifilesink next-file=0 enable-last-sample=FALSE async=FALSE sync=FALSE location=./example_snapshot_%d.jpg t. ! queue max-size-buffers=0 ! 'video/x-raw, format=(string)YUY2, width=(int)1280, height=(int)720, framerate=(fraction)10/1' ! videoconvert ! queue max-size-buffers=0 ! avenc_h263p ! identity ! queue max-size-buffers=0 max-size-bytes=0 max-size-time=9000000000 ! mux. audiotestsrc ! volume ! avenc_mp2 bitrate=128 ! identity ! queue max-size-buffers=0 max-size-bytes=0 max-size-time=9000000000 ! matroskamux name=mux ! multifilesink next-file=1 location=example_50mb_%s.mkv enable-last-sample=FALSE sync=TRUE async=FALSE
</syntaxhighlight>
</syntaxhighlight>
|graph=[[File:test_graphic.png|1000px|center]]
 
}}
==Graph==
[[File:test_graphic.png|1000px|center]]
 
{{GstShark/Foot |previous=CPU usage tracer|next=Bitrate tracer}}

Latest revision as of 03:09, 6 March 2023





Previous: CPU usage tracer Index Next: Bitrate tracer




The graphic tracer is an add-on to the GstShark tracer suit. It does not generate any output log providing any information about the performance of the pipeline neither it helps the user with the debugging process at the time of facing an unexpected issue on the behavior of a pipeline. However, this tracer is very useful since it shows to the user the pipeline graphically so the user can easily inspect it visually.

In the examples of the previous tracers the pipelines used were very simple and small which makes them very easy to inspect. This is not the case with the applications usually developed in the actual market. There are scenarios in which an application uses a more complex pipeline with a lot of elements interconnected with several source elements, tees, muxers, encoders, decoders, among others. In those cases is very difficult to inspect and review every section of a pipeline manually and here is when the Graphic tracer becomes handy.

The tracer provides a graphical representation of the pipeline without having to set any other environment variables and it shows the diagram instantaneously when the pipeline starts to run. The tracer also stores the diagram of the pipeline together with the output log generated by the other tracers in a DOT format file. It can be opened with the experimental Eclipse plugin or with any DOT file viewer at any time that the user might want after the pipeline has stopped its operation. For more information on the DOT format file, refer to the pipeline diagram wiki page.

The generated diagram is placed in a new folder called "graphic", inside the selected output directory. If the Graphic tracer is used alone on the pipeline, or if the other tracers have been disabled using the GST_SHARK_CTF_DISABLE environment variable, the diagram file will be stored in the "graphic" directory in the current path. When the Graphic tracer is running along with other enabled tracers, the diagram is stored in the "graphic" sub-directory inside the output folder (by default "gstshark_YY-MM-DD_hh:mm:ss").

It is important to mention that the generation of the graphic file cannot be disabled in the same way than the other tracers above. The other tracers can be disabled by defining the environment variable GST_SHARK_CTF_DISABLE, but if the Graphic tracer is selected at the time of running a pipeline, the diagram will be generated and stored anyway.

Problems running the pipelines shown on this page?
Please see our GStreamer Debugging guide for help.

Pipeline

All the simple pipeline diagrams shown on the others tracer pages on this wiki have been obtained using the Graphic tracer. The following pipeline has a more complicated layout that illustrates better the capabilities of the Graphic tracer.

$ GST_DEBUG="GST_TRACER:7" GST_TRACERS="graphic" gst-launch-1.0 videotestsrc is-live=true ! tee name=t ! valve drop=TRUE ! queue max-size-buffers=0 ! avenc_ljpeg  multifilesink next-file=0 enable-last-sample=FALSE async=FALSE sync=FALSE location=./example_snapshot_%d.jpg t. ! queue max-size-buffers=0 ! 'video/x-raw, format=(string)YUY2, width=(int)1280, height=(int)720, framerate=(fraction)10/1' ! videoconvert ! queue max-size-buffers=0 ! avenc_h263p ! identity ! queue max-size-buffers=0 max-size-bytes=0 max-size-time=9000000000 ! mux. audiotestsrc ! volume ! avenc_mp2 bitrate=128 ! identity ! queue max-size-buffers=0 max-size-bytes=0 max-size-time=9000000000 ! matroskamux name=mux ! multifilesink next-file=1 location=example_50mb_%s.mkv enable-last-sample=FALSE sync=TRUE async=FALSE

Graph


Previous: CPU usage tracer Index Next: Bitrate tracer