filesrc

filesrc — Read from arbitrary point in a file

Synopsis

struct              GstFileSrc;

Object Hierarchy

  GObject
   +----GInitiallyUnowned
         +----GstObject
               +----GstElement
                     +----GstBaseSrc
                           +----GstFileSrc

Implemented Interfaces

GstFileSrc implements GstURIHandler.

Properties

  "fd"                       gint                  : Read
  "location"                 gchar*                : Read / Write
  "mmapsize"                 gulong                : Read / Write
  "touch"                    gboolean              : Read / Write
  "use-mmap"                 gboolean              : Read / Write
  "sequential"               gboolean              : Read / Write

Description

Read data from a file in the local file system.

Example launch line

1
gst-launch filesrc location=song.ogg ! decodebin2 ! autoaudiosink
Play a song.ogg from local dir.

Synopsis

Element Information

plugin

coreelements

author

Erik Walthinsen <omega@cse.ogi.edu>

class

Source/File

Element Pads

name

src

direction

source

presence

always

details

ANY

Details

struct GstFileSrc

struct GstFileSrc;

Opaque GstFileSrc structure.

Property Details

The "fd" property

  "fd"                       gint                  : Read

File-descriptor for the file being mmap()d.

Allowed values: >= 0

Default value: 0


The "location" property

  "location"                 gchar*                : Read / Write

Location of the file to read.

Default value: NULL


The "mmapsize" property

  "mmapsize"                 gulong                : Read / Write

Size in bytes of mmap()d regions.


The "touch" property

  "touch"                    gboolean              : Read / Write

Touch mmapped data regions to force them to be read from disk.

Default value: TRUE


The "use-mmap" property

  "use-mmap"                 gboolean              : Read / Write

Whether to use mmap() instead of read().

Default value: FALSE


The "sequential" property

  "sequential"               gboolean              : Read / Write

Whether to use madvise to hint to the kernel that access to mmap pages will be sequential.

Default value: FALSE

See Also

GstFileSrc