Board index » delphi » Speedy brightness & contrast

Speedy brightness & contrast

hi all,

  i've been searching a lot for an answer for this question, and all what i
get is 'slow' or 'Limited' answers..

SLOW one is the using of scanline property

Limited one is using shifting palate method which is only limited for gary
scale 8 bit BMP.

i think there is something missing there, which is i need to change the way
the bmp looks an not the bmp itself!! like photoshop uses in the preview of
Brightness / contrast change with a large bmp. It previews the changes at no
time, then, it takes its time when you agree.

  my question is: Is there a windows API that controls the B/C of an
object?, or, how to do something like a preview without actually go in depth
inside your bmp?

Any help, tips are appreciated...

Hammady

 

Re:Speedy brightness & contrast


Hi Hammady,
    I don't know any windows API function to change B/C of an object. If you
want "more of the same"...  I'm developing an applicattion that do as
follows:
    1) I take the source bitmap and copy it to the buffer.
    2) If it's a palettized bitmap, I shift the palette. If not, have to
shift every pixel. I work on the buffer every time.
    3) If the user agree, I copy the buffer on the source bitmap. If the
source bitmap is, i.e., into a TImage object, you can save it later.
    4) I don't know any windows API function to

Hammady escribi en mensaje <3795A316.A37A8...@idsc1.gov.eg>...

Quote
>hi all,

>  i've been searching a lot for an answer for this question, and all what i
>get is 'slow' or 'Limited' answers..

>SLOW one is the using of scanline property

>Limited one is using shifting palate method which is only limited for gary
>scale 8 bit BMP.

>i think there is something missing there, which is i need to change the way
>the bmp looks an not the bmp itself!! like photoshop uses in the preview of
>Brightness / contrast change with a large bmp. It previews the changes at
no
>time, then, it takes its time when you agree.

>  my question is: Is there a windows API that controls the B/C of an
>object?, or, how to do something like a preview without actually go in
depth
>inside your bmp?

>Any help, tips are appreciated...

>Hammady

Re:Speedy brightness & contrast


Hi Pablo,

  Please explain what do you mean by buffer! is it a temp BMP or memory
stream or somthing else? Also, could you please send me the code for
shifting the palate for brightness an contrast? i have some code but only
work for gary scale 8 bit.. it is fast, but my code is inaccurate :(

Thanks

Hammady

Quote
Pablo Pedrocca wrote:

> Hi Hammady,
>     I don't know any windows API function to change B/C of an object. If you
> want "more of the same"...  I'm developing an applicattion that do as
> follows:
>     1) I take the source bitmap and copy it to the buffer.
>     2) If it's a palettized bitmap, I shift the palette. If not, have to
> shift every pixel. I work on the buffer every time.
>     3) If the user agree, I copy the buffer on the source bitmap. If the
> source bitmap is, i.e., into a TImage object, you can save it later.
>     4) I don't know any windows API function to

Re:Speedy brightness & contrast


I believe that photoshop is speedy on changing the brightness/hue or
whatever because it fakes the effect by using the scaled down version
of the picture.   Doing an image of the size of the preview picture by
scanline is fast enough to make you feel it;s real time.

Or, if the picture is zoomed, only do the portion on screen.

On Wed, 21 Jul 1999 13:38:14 +0300, Hammady <mhamm...@idsc1.gov.eg>
wrote:

Quote
>hi all,

>  i've been searching a lot for an answer for this question, and all what i
>get is 'slow' or 'Limited' answers..

>SLOW one is the using of scanline property

>Limited one is using shifting palate method which is only limited for gary
>scale 8 bit BMP.

>i think there is something missing there, which is i need to change the way
>the bmp looks an not the bmp itself!! like photoshop uses in the preview of
>Brightness / contrast change with a large bmp. It previews the changes at no
>time, then, it takes its time when you agree.

>  my question is: Is there a windows API that controls the B/C of an
>object?, or, how to do something like a preview without actually go in depth
>inside your bmp?

>Any help, tips are appreciated...

>Hammady

Other Threads