Sophie

Sophie

distrib > Mageia > 4 > x86_64 > by-pkgid > d620e9f76c810e9fbdaebc304909c8fc > files > 272

lib64gstreamer0.10-devel-0.10.36-7.mga4.x86_64.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<HTML
><HEAD
><TITLE
>Testing your element</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.79;charset=UTF-8"><LINK
REL="HOME"
TITLE="GStreamer Plugin Writer's Guide (0.10.36)"
HREF="index.html"><LINK
REL="UP"
TITLE="Things to check when writing an element"
HREF="chapter-checklist-element.html"><LINK
REL="PREVIOUS"
TITLE="Querying, events and the like"
HREF="section-checklist-query.html"><LINK
REL="NEXT"
TITLE="Porting 0.8 plug-ins to 0.10"
HREF="chapter-porting.html"></HEAD
><BODY
CLASS="sect1"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><DIV
CLASS="NAVHEADER"
><TABLE
SUMMARY="Header navigation table"
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TH
COLSPAN="3"
ALIGN="center"
><SPAN
CLASS="application"
>GStreamer</SPAN
> Plugin Writer's Guide (0.10.36)</TH
></TR
><TR
><TD
WIDTH="10%"
ALIGN="left"
VALIGN="bottom"
><A
HREF="section-checklist-query.html"
ACCESSKEY="P"
>Prev</A
></TD
><TD
WIDTH="80%"
ALIGN="center"
VALIGN="bottom"
>Chapter 23. Things to check when writing an element</TD
><TD
WIDTH="10%"
ALIGN="right"
VALIGN="bottom"
><A
HREF="chapter-porting.html"
ACCESSKEY="N"
>Next</A
></TD
></TR
></TABLE
><HR
ALIGN="LEFT"
WIDTH="100%"></DIV
><DIV
CLASS="sect1"
><H1
CLASS="sect1"
><A
NAME="section-checklist-testing"
>23.4. Testing your element</A
></H1
><P
></P
><UL
><LI
><P
>&#13;          <B
CLASS="command"
>gst-launch</B
> is <SPAN
CLASS="emphasis"
><I
CLASS="emphasis"
>not</I
></SPAN
> a good
          tool to show that your element is finished. Applications such as
          Rhythmbox and Totem (for GNOME) or AmaroK (for KDE)
          <SPAN
CLASS="emphasis"
><I
CLASS="emphasis"
>are</I
></SPAN
>. <B
CLASS="command"
>gst-launch</B
> will not
          test various things such as proper clean-up on reset, interrupt
          event handling, querying and so on.
        </P
></LI
><LI
><P
>&#13;          Parsers and demuxers should make sure to check their input. Input
          cannot be trusted. Prevent possible buffer overflows and the like.
          Feel free to error out on unrecoverable stream errors. Test your
          demuxer using stream corruption elements such as
          <CODE
CLASS="classname"
>breakmydata</CODE
> (included in gst-plugins). It
          will randomly insert, delete and modify bytes in a stream, and is
          therefore a good test for robustness. If your element crashes
          when adding this element, your element needs fixing. If it errors
          out properly, it's good enough. Ideally, it'd just continue to
          work and forward data as much as possible.
        </P
></LI
><LI
><P
>&#13;          Demuxers should not assume that seeking works. Be prepared to
          work with unseekable input streams (e.g. network sources) as
          well.
        </P
></LI
><LI
><P
>&#13;          Sources and sinks should be prepared to be assigned another clock
          then the one they expose themselves. Always use the provided clock
          for synchronization, else you'll get A/V sync issues.
        </P
></LI
></UL
></DIV
><DIV
CLASS="NAVFOOTER"
><HR
ALIGN="LEFT"
WIDTH="100%"><TABLE
SUMMARY="Footer navigation table"
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
><A
HREF="section-checklist-query.html"
ACCESSKEY="P"
>Prev</A
></TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="index.html"
ACCESSKEY="H"
>Home</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
><A
HREF="chapter-porting.html"
ACCESSKEY="N"
>Next</A
></TD
></TR
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
>Querying, events and the like</TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="chapter-checklist-element.html"
ACCESSKEY="U"
>Up</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
>Porting 0.8 plug-ins to 0.10</TD
></TR
></TABLE
></DIV
></BODY
></HTML
>