Drawing an image (osd)

"Hal far" <[email protected]>
Newsgroups gmane.comp.video.xine.user
Message-ID <[email protected]>
Hi all,

I'm trying  to paste an image in my stream using osd.
I use the code below..

        sd_img =stream->osd_renderer->new_object(stream->osd_renderer, 800,600);

         FILE * f;
	f=fopen("osd-mid.gif","r");
	int size;  // size file
	char c;

	size=0;
	while(c!=EOF)
 	{
		c=fgetc(f);
		size++;
	}
		
	uint8_t * immagine = xine_xmalloc(size);

	int fd;
	fd=open("osd-mid.png",O_RDONLY);
	read(fd,immagine,size);
	
     stream->osd_renderer->draw_bitmap(osd_img, immagine, 10, 10,640, 110, 0);

      stream->osd_renderer->show(osd_img, 0);

With this code I see some point in my display, ...Can you help me?

Thanks for all,

A.F.

-------------------------------------------------------------------------
SF.Net email is sponsored by: The Future of Linux Business White Paper
from Novell.  From the desktop to the data center, Linux is going
mainstream.  Let it simplify your IT future.
http://altfarm.mediaplex.com/ad/ck/8857-50307-18918-4
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.