discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Discuss-gnuradio] Comb Filter


From: Eric Blossom
Subject: Re: [Discuss-gnuradio] Comb Filter
Date: Tue, 4 Jan 2005 13:32:57 -0800
User-agent: Mutt/1.5.6i

On Tue, Jan 04, 2005 at 01:13:15PM -0800, Prateek Dayal wrote:
> Thanks .. my concern right now is to get a video decoding system
> working. Speed is not the issue. Once I am able to do this, I can fine
> tune different modules. 

> I also have to find out how to convert the
> decoded intensity (Y) values to something that can be displayed by the
> display driver ....

Just convert them to a value between 0 and 255, then convert on the
fly to whatever your display will support.  Take a look at the output
of "xdpyinfo"

Basically you're going to want to create a pixmap, say 640x480 by some
convenient depth for each frame (or field if you're not
deinterleaving).  If you've got a 16 or 24-bit deep display card, then
use that depth.  For 16-bit color, the raw pixels are formatted like
this: 5:6:5 (top 5 bits are red, middle 6 bits are green, bottom 5
bits are blue).  For 24-bit color it's 8:8:8.

Write the data to a file, then build a (small) tool to play it back,
frame at a time.


For starters you could treat each frame as if it had this format...

static const int NLINES = 480;
static const int NPIXELS = 640;

struct ntsc_frame {
    unsigned char intensity[NLINES][NPIXELS];
}

... and you wouldn't be far off.  I'd probably start by just doubling
the lines of each field and not worrying about deinterlacing the odd
and even fields.

unsigned short intensity_to_16[256] = {
  // appropriate lookup table
}

unsigned long intensity_to_24_or_32[256] = {
  // appropriate lookup table
}

Eric




reply via email to

[Prev in Thread] Current Thread [Next in Thread]