[GRASS5] Other vectors colors

fpacheco@adinet.com.uy wrote:

We don't know how -please tell me how- to add more colors to vectors
maps -red, blue, ...- then I modifyed the source code of d.vect to use
RGB. It's very simple but It works. I send to you de source code
(d.vect.rgb).
I'll modify the source code of the d.dm command to work with this comand
then my users can use it.
I'm working on a graphic interface PostgreSQL-GRASS like the d.dm and a
Visual SQL designer. Fernando.

I think that we should not add new d.vect.* modules if possible.
We have already d.vect, d.vect.cats, d.area. It would be better
to merge all into one module d.vect instead of adding d.vect.rgb,
d.area.cat, d.area.rgb, d.dot, d.dot.cat, d.dot.rgb.

My suggestion for rgb colors is:

1. Write function D_translate_color_rgb (char *color, int *r, int *g,
int *b)
   where input color could be: red or 255000000 or 1.000.000.00
   (or 255_0_0, 255-0-0, 255-- or something similar)

2. Rewrite display modules from:

    color = D_translate_color();
    R_standard_color(color) ;

   to:

    D_translate_color_rgb (opt2->answer, &r, &g, &b);
    R_RGB_color ( r,g,b);

Radim

----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'

On Mon, Aug 21, 2000 at 12:02:49PM +0200, Radim Blazek wrote:

fpacheco@adinet.com.uy wrote:

> We don't know how -please tell me how- to add more colors to vectors
> maps -red, blue, ...- then I modifyed the source code of d.vect to use
> RGB. It's very simple but It works. I send to you de source code
> (d.vect.rgb).
> I'll modify the source code of the d.dm command to work with this comand
> then my users can use it.
> I'm working on a graphic interface PostgreSQL-GRASS like the d.dm and a
> Visual SQL designer. Fernando.

I think that we should not add new d.vect.* modules if possible.
We have already d.vect, d.vect.cats, d.area. It would be better
to merge all into one module d.vect instead of adding d.vect.rgb,
d.area.cat, d.area.rgb, d.dot, d.dot.cat, d.dot.rgb.

I agree.

My suggestion for rgb colors is:

1. Write function D_translate_color_rgb (char *color, int *r, int *g,
int *b)
   where input color could be: red or 255000000 or 1.000.000.00
   (or 255_0_0, 255-0-0, 255-- or something similar)

2. Rewrite display modules from:

    color = D_translate_color();
    R_standard_color(color) ;

   to:

    D_translate_color_rgb (opt2->answer, &r, &g, &b);
    R_RGB_color ( r,g,b);

Radim,
I have patches from Pierre for an RGB-change for *all* display
modules and the patch for the display library. I will send it
to you personally. It was for GRASS 5 beta6. Unfortunately Pierre
seems to have stopped his support. I would be sad, if his work
gets lost.

Perhaps you can take a look at it? Should be almost ready!

Markus

----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'

Hi all,

now I send it to the list as other might be interested, too.
layered_rgb_driver.tar.gz

This is the work of Pierre de Mouveaux <pmx@audiovu.com>,
I am very grateful to him for all his time spend on this.
As he currently does not support it, hopefully YOU can
take care for it :slight_smile:

Contents
* src/display/devices/XDRIVER2: layered XDRIVER
  - to be used with d.layers (included)

* 3-may.diff: new library function: R_open_driver2 with RGB support
  - (nearly) all display modules updated with new RGB parameter

* pmx.*: Pierre's and my email traffic containing comments
  (reversed order, pmx.7 is oldest letter)

Reference status should be against beta7.

I would be glad if Pierre's work can be integrated!!

Best wishes

Markus

(attachments)

layered_rgb_driver.tar.gz (92 KB)

Radim Blazek wrote:

fpacheco@adinet.com.uy wrote:

> We don't know how -please tell me how- to add more colors to vectors
> maps -red, blue, ...- then I modifyed the source code of d.vect to use
> RGB. It's very simple but It works. I send to you de source code
> (d.vect.rgb).
> I'll modify the source code of the d.dm command to work with this comand
> then my users can use it.
> I'm working on a graphic interface PostgreSQL-GRASS like the d.dm and a
> Visual SQL designer. Fernando.

I think that we should not add new d.vect.* modules if possible.
We have already d.vect, d.vect.cats, d.area. It would be better
to merge all into one module d.vect instead of adding d.vect.rgb,
d.area.cat, d.area.rgb, d.dot, d.dot.cat, d.dot.rgb.

My suggestion for rgb colors is:

1. Write function D_translate_color_rgb (char *color, int *r, int *g,
int *b)
   where input color could be: red or 255000000 or 1.000.000.00
   (or 255_0_0, 255-0-0, 255-- or something similar)

2. Rewrite display modules from:

    color = D_translate_color();
    R_standard_color(color) ;

   to:

    D_translate_color_rgb (opt2->answer, &r, &g, &b);
    R_RGB_color ( r,g,b);

Radim

----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'

OK. I'll try to do this.

I have d.vect.rgb, d.area.rgb, d.sites.rgb and I modyfied the d.dm to use this
commands, then my users can paint their maps with the colors in the graphic
palette. Fernando.

----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'

fpacheco@dinama.gub.uy wrote:

Radim Blazek wrote:

> fpacheco@adinet.com.uy wrote:
>
> > We don't know how -please tell me how- to add more colors to vectors
> > maps -red, blue, ...- then I modifyed the source code of d.vect to use
> > RGB. It's very simple but It works. I send to you de source code
> > (d.vect.rgb).
> > I'll modify the source code of the d.dm command to work with this comand
> > then my users can use it.
> > I'm working on a graphic interface PostgreSQL-GRASS like the d.dm and a
> > Visual SQL designer. Fernando.
>
> I think that we should not add new d.vect.* modules if possible.
> We have already d.vect, d.vect.cats, d.area. It would be better
> to merge all into one module d.vect instead of adding d.vect.rgb,
> d.area.cat, d.area.rgb, d.dot, d.dot.cat, d.dot.rgb.
>
> My suggestion for rgb colors is:
>
> 1. Write function D_translate_color_rgb (char *color, int *r, int *g,
> int *b)
> where input color could be: red or 255000000 or 1.000.000.00
> (or 255_0_0, 255-0-0, 255-- or something similar)
>
> 2. Rewrite display modules from:
>
> color = D_translate_color();
> R_standard_color(color) ;
>
> to:
>
> D_translate_color_rgb (opt2->answer, &r, &g, &b);
> R_RGB_color ( r,g,b);
>
> Radim

OK. I'll try to do this.

I have d.vect.rgb, d.area.rgb, d.sites.rgb and I modyfied the d.dm to use this
commands, then my users can paint their maps with the colors in the graphic
palette. Fernando.

Please look into layere_rgb_driver.tar.gz attached to Markus message:
http://www.geog.uni-hannover.de/cgi-bin/minorweb.pl?A=READ&L=grass5/2000/8/21/3

It is already written there.

Radim

----------------------------------------
If you want to unsubscribe from GRASS Development Team mailing list write to:
minordomo@geog.uni-hannover.de with
subject 'unsubscribe grass5'