GTK+ Forums

Discussion forum for GTK+ and Programming. Ask questions, troubleshoot problems, view and post example code, or express your opinions.
It is currently Wed Apr 16, 2014 7:31 am

All times are UTC




Post new topic Reply to topic  [ 1 post ] 
Author Message
 Post subject: YUV to BMP conversion
PostPosted: Thu Apr 05, 2007 5:10 am 
Offline

Joined: Thu Mar 15, 2007 6:52 am
Posts: 3
Location: chennai
Hi friends,

I'm trying to convert a YUV frames into each BMP images, Presently i acheived to read a Y,U and V data from YUV frames,Actaully our image ie., YUV frame is 352x288.

So we do some interpolation for converting our Y,U,V data into 352x288 size. Then i coverted to RGB using the following formulas
*red++ = 1.164*((*yimage++)-16) +( 1.596*((*voutimage++)-128));
*green++ =1.164*((*yimage++)-16) - (0.391*((*uoutimage++)-128)) - 0.813*((*voutimage++)-128));
*blue++ = 1.164*((*yimage++)-16) + (2.018*((*uoutimage++)-128));
I have RGB values,this values directly store in a array because image data generally write reverse in BMP files.

Newly opened BMP file,i wrote a imagebuffer array write into that file,But I can,t get
full size image ie.,352x288.Also I want to get perfect coversion.

Pls help me.Share your views and ideas.

Thanks


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group