Gif palette and border color

View: New views
2 Messages — Rating Filter:   Alert me  

Gif palette and border color

by jai-interest-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hello folks,

I'm trying to add a border color to a gif image. The operation works fine (I got the border color) but it is not the color I expected.
I think this is because my source gif image does not contains the color in its palette.
Given that my source gif image will not have more than 200 colors, do you know if there is a simple way to add my color to this palette ?

For example :

- My source gif image containes 2 colors : RED and BLUE
- I would like to add a GREEN border color
- Do I have to add this GREEN color to the palette before adding the border color ?

Do you know if there is a simple way to do it ?


Thanks a lot,

Best regards.

Antoine
[Message sent by forum member 'alarcher' (alarcher)]

http://forums.java.net/jive/thread.jspa?messageID=275766

---------------------------------------------------------------------
To unsubscribe, e-mail: interest-unsubscribe@...
For additional commands, e-mail: interest-help@...


Re: Gif palette and border color

by jai-interest-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

AFAIK you will have to add it to the palette. A palette or index-color image consists in effect of two entities: 1) a width x height array of integral values each of which is an index into the 2) palette of colors. In order for a given index value to represent anything meaningful the index has to have an entry in the palette.

Brian

> Hello folks,
>
> I'm trying to add a border color to a gif image. The
> operation works fine (I got the border color) but it
> is not the color I expected.
> I think this is because my source gif image does not
> contains the color in its palette.
> Given that my source gif image will not have more
> than 200 colors, do you know if there is a simple way
> to add my color to this palette ?
>
> For example :
>
> - My source gif image containes 2 colors : RED and
> BLUE
> - I would like to add a GREEN border color
> - Do I have to add this GREEN color to the palette
> before adding the border color ?
>
> Do you know if there is a simple way to do it ?
>
>
> Thanks a lot,
>
> Best regards.
>
> Antoine
[Message sent by forum member 'bpb' (bpb)]

http://forums.java.net/jive/thread.jspa?messageID=277101

---------------------------------------------------------------------
To unsubscribe, e-mail: interest-unsubscribe@...
For additional commands, e-mail: interest-help@...

LightInTheBox - Buy quality products at wholesale price!