Re: gif to binary data




"tanu" <tanumeister@xxxxxxxxx> wrote in message
news:1158148235.476036.290200@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
hi all
i m using a 240*128 pix lcd with t6963c controller
wanna see the graphics in it
lcd is interfaced with atmega 128 microcontroller

By assigning 3840 bytes for the Bitmap buffer I assume you are using 1
bit per pixel black and white. I can't see a reason why the LCD array is
the size it is 42240 bytes or why you need to define it. A frame buffer
of 3840 will be plenty by itself.

for graphics i thougt of converting the gif file to binary data so did
this

The files would definitely have to be treated as binaries when opening,
although you shouldn't have to convert anything - fopen will handle
that.

i had 1st save the gif file in to the txt
so to get ascii data
before i aslo tried direct gif to binary

The gif won't map directly to your bitmap buffer - you will need to
decode it. Why don't you start with a bitmap file until you get the hang
of the display and then move onto compressed formats like gif.

i m getting binary data rite acording to the txt file but when i m
seeing this data
in the lcd i m not getting that image
infact i had discarded the 22 bytes from the data

Do you mean that 22 bytes of the data were missing from the buffer or
did you purposefully discard them. If so, why? Is this you stripping off
the header?

If you use bitmap data then you can just copy the data section of the
file straight to the buffer. In windows bitmaps, the 32bit word in the
11th, 12th, 13th and 14th bytes of the file tells you how far from the
start of the file the data begins.

<snip code>

Your code could really use some comments and some more meaningful
variable names.

so do tell me where m i wrong
and do tell if there is any other way to find the binary data

You may need "rb" in your fopen to open the file as a binary file. Other
than that then you should have the binary data where you want it but I'm
not convinced it will be data in the form you think it should be.

And for goodness sake use capital letters and apostrophes - you're a big
boy now.


.



Relevant Pages

  • Re: 8 bit to 18 bit per pixel lookup palette
    ... I can say with some confidence the frame buffer and pallete are both being ... The problem is my palette is still not right on the 18-bpp. ... pixel format (see PXA documentation) and the actual LCD ...
    (microsoft.public.windowsce.platbuilder)
  • Re: LCD-dsp interface timing
    ... i have to interface an lcd to a dsp ... the problem is that the lcd controller is very slow in accepting data. ... buffer, I use a gal16v8, programmed as a state machine. ...
    (comp.arch.embedded)
  • gif to binary data
    ... i m using a 240*128 pix lcd with t6963c controller ... for graphics i thougt of converting the gif file to binary data so did ... typedef unsigned char byte; ... static int i; ...
    (comp.arch.embedded)
  • Re: How to Spalsh screen in PXA255 ?
    ... You'll need to port the Initial code of Display Driver into your bootloader ... also need to include a Bitmap into your Bootloader for splash screen. ... the LCD was still blank. ...
    (microsoft.public.windowsce.platbuilder)
  • Re: LCD Interface
    ... I've been using a LCD module with an Epson SED1335 ... >> on the board only has about 24k memory bits and the memory buffer for the ... > screen as being a matrix of character to display text with some char ... > Imagine dividing 8x8 tiles with 256 possible chars. ...
    (comp.arch.fpga)