#include <stdio.h>
#include <stdlib.h>
#include <gst/gstpipeline.h>
#include <gst/app/gstappsink.h>

int main()
{
  gst_init(0,0);
  
  GstElement *sink;
  if(!(sink=gst_element_factory_make("appsink",0)))
  {
        fprintf(stderr,"Creation of sink failed\n");
        return 0;
  }

  g_object_set(G_OBJECT(sink),
            "drop",TRUE,
            NULL);
  g_object_set(G_OBJECT(sink),
            "max-buffers",1,
            NULL);

  gint maxbuffs=-1;
  gint drops=-1;
  g_object_get(G_OBJECT(sink),
               "drop",&drops,
	       NULL);
  g_object_get(G_OBJECT(sink),
               "max-buffers",&maxbuffs,
	       NULL);
  printf("drops: %i\nmaxbuffs: %i\n",drops,maxbuffs);

  return 0;
}



