Re: [GRASS-user] r.colors- transparent, HSB color

2009-03-19 Thread Hamish

Glynn:
> OTOH, you can obtain this functionality by
> pre-processing the rules with a script.


see the r.cpt2grass addon script in the grass wiki
(for converting GMT color tables to grass's r.colors format)


Hamish





___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] reclass

2009-03-19 Thread Christian Schwartze
What just doesn't work? Tried this:
cat rule | r.reclass input=map_a output=map_b
while rule contains your new classes like
1 = 2 
..

Christian

> Hello, I', new in grass
>
> I'm trying  to do a raster reclassification (r.reclass) but i can't set the
> rules. Someone can teach me how to do it?
>
>
>
> Yks
>
>
>
>

>
>
> ___
> grass-user mailing list
> grass-user@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-user
>
>
>
>
> 
> This mail was sent through http://webmail.uni-jena.de
>





This mail was sent through http://webmail.uni-jena.de
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Merging Boundaries and Centroids

2009-03-19 Thread Moritz Lennert

On 19/03/09 18:34, peter.lo...@gmx.de wrote:

hi,

I just got stuck with a seemingly simple task:

Let's assume vector layer A holds bunch of boundaries (for example,
some non-overlapping circles) without categories, while vector layer
B contains points/centroids which have categories AND attributes
(Soil type, etc).

What's the recipe to blend the two layers A and B into a new layer C
which consists of circles having centroids with soil type attributes
?

This question is caused the fact that v.in.ascii has (for the moment)
no option to import lines/areas with attributes beyond a category.


If the question concerns two layers in GRASS: v.patch.

If the question concerns import of ascii file with attributes: the 
easiest is probably to import the features with category, import the 
table separately with db.in.ogr and then link the two with db.connect.


Moritz
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Building GRASS on Windows

2009-03-19 Thread Paul Kelly

On Thu, 19 Mar 2009, Markus Neteler wrote:


A related suggestion: some libraries need manual modifications
(zlib etc). Would you be willing to package all those precompiled libs
into a convenient ZIP file which we could host on grass.osgeo.org?


Just wondering why not use zlib and libjpeg from the gnuwin32 project 
instead of compiling them manually? The internationalisation packages 
(libintl, libiconv and gettext) from there also work well "out of the box" 
and gives mult-language support to GRASS on Windows.


I just noticed gnuwin32 has pdcurses as well (I think that is new) - so 
maybe manual compilation of it could also be avoided. Freetype also seems 
to be there which is pretty useful to include too.


Paul
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


[GRASS-user] Merging Boundaries and Centroids

2009-03-19 Thread peter . loewe
hi,

I just got stuck with a seemingly simple task:

Let's assume vector layer A holds bunch of boundaries (for example, some 
non-overlapping circles) without categories, while vector layer B contains 
points/centroids which have categories AND attributes (Soil type, etc).

What's the recipe to blend the two layers A and B into a new layer C which 
consists of circles having centroids with soil type attributes ?

This question is caused the fact that v.in.ascii has (for the moment) no option 
to import lines/areas with attributes beyond a category.

Peter
-- 
Dr. Peter Löwe






Pt! Schon vom neuen GMX MultiMessenger gehört? Der kann`s mit allen: 
http://www.gmx.net/de/go/multimessenger01
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


[GRASS-user] reclass

2009-03-19 Thread Ricardo Almendra
Hello, I', new in grass

I'm trying  to do a raster reclassification (r.reclass) but i can't set the
rules. Someone can teach me how to do it?



Yks
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Building GRASS on Windows

2009-03-19 Thread Markus Neteler
Hi Colin,

On Thu, Mar 19, 2009 at 3:12 PM, Colin Nielsen  wrote:
> Hi Markus,
>> A related suggestion: some libraries need manual modifications
>> (zlib etc). Would you be willing to package all those precompiled libs
>> into a convenient ZIP file which we could host on grass.osgeo.org?
>
> I had that in my mind as I was going through all of this. Once I'm
> sure everything is working I'll be sure to do that. Would it be better
> to put them all into one zip, or separate zips?

I guess all-in-one is the best to get more people trying.

Thanks!
Markus
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Building GRASS on Windows

2009-03-19 Thread Colin Nielsen
Hi Markus,
> A related suggestion: some libraries need manual modifications
> (zlib etc). Would you be willing to package all those precompiled libs
> into a convenient ZIP file which we could host on grass.osgeo.org?

I had that in my mind as I was going through all of this. Once I'm
sure everything is working I'll be sure to do that. Would it be better
to put them all into one zip, or separate zips?

-Colin
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] r.colors- transparent, HSB color

2009-03-19 Thread Dwight Needels

Glynn Clements wrote:

For integer maps, you can create a reclass map using r.reclass. This
has much lower overhead than creating a complete new map with
r.mapcalc.



That is exactly what I was looking for (thanks!).

Glynn Clements wrote:

Are you talking about simply specifying colours in HSB, and keeping
the internal data in RGB, or having interpolation performed in HSB
space?

The former wouldn't be particularly involved; just an extension to
G_parse_color_rule(). OTOH, you can obtain this functionality by
pre-processing the rules with a script.



I was thinking of all interpolations in HSB space. However your first  
option (calculating RGB values from specified HSB colors but  
continuing to work in RGB space) would meet my current need. In fact,  
that is exactly what I have been doing, but externally to GRASS  
because I don't know how to write the script for HSB => RGB  
conversion. I would find this capability to be a useful enhancement of  
r.colors.


___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Building GRASS on Windows

2009-03-19 Thread Markus Neteler
On Thu, Mar 19, 2009 at 1:31 PM, Colin Nielsen  wrote:
> A MinGW package was missing on the wiki page, my fault not yours. I've
> added it, get "mingw-runtime" and get "bin-utils" too while you're at
> it. Both are now on the wiki. Sorry for the error.

Hi Colin,

you did a great job to update
http://trac.osgeo.org/grass/wiki/CompileOnWindows

thanks for that!

A related suggestion: some libraries need manual modifications
(zlib etc). Would you be willing to package all those precompiled libs
into a convenient ZIP file which we could host on grass.osgeo.org?

Best
Markus
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


[GRASS-user] Grass save on cluster?

2009-03-19 Thread Rainer M Krug
Hi

how save is GRASS 6.3.2 to be used on a cluster? I am starting several
instances of grass on a single node, they all have their own grass
database (but they share a linked PERMANENT and the name of the mapset
and location is the same). I am asking as I experience from time to
time crashes in my simulation because certain files can not be found,
and these crashes are not reproducible when only one GRASS instance
runs.

In addition, how safe is it to execute several r.mapcalc and other map
operations in the same mapset in parallel (obviously with different
maps)? Again, I experienced severe problems with that, wherefore I
abandoned it (although it increases my simulation time considerable).
I would have expected it to work, but again, I had non reproducible
(and inconsistent) crashes.

Can somebody comment on that or provide some pointers?

Thanks

Rainer

-- 
Rainer M. Krug, Centre of Excellence for Invasion Biology,
Stellenbosch University, South Africa
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] Building GRASS on Windows

2009-03-19 Thread Colin Nielsen
A MinGW package was missing on the wiki page, my fault not yours. I've
added it, get "mingw-runtime" and get "bin-utils" too while you're at
it. Both are now on the wiki. Sorry for the error.

-Colin

On Wed, Mar 18, 2009 at 8:37 PM, Darren Cope  wrote:
> Hi all,
>
> I'm following along with the instructions here:
> http://trac.osgeo.org/grass/wiki/CompileOnWindows
> and am getting stuck at Step 5 under PDCurses.  When running:
>
> make -f mingwin32.mak DLL=Y all
>
> The following error occurs:
>
> $ make -f mingwin32.mak DLL=Y all
> gcc -c -O2 -Wall -I.. -DPDC_DLL_BUILD ../pdcurses/addch.c
> In file included from ../curspriv.h:25,
>  from ../pdcurses/addch.c:14:
> ../curses.h:50:57: stdio.h: No such file or directory
> In file included from ../curspriv.h:25,
>  from ../pdcurses/addch.c:14:
> ../curses.h:928: error: syntax error before '*' token
> ../curses.h:1010: error: syntax error before "FILE"
> ../curses.h:1027: error: syntax error before "FILE"
> make: *** [addch.o] Error 1
>
> Any thoughts?  I'd really like to get a new version built so I can play with
> v.net.iso improvements, but am struggling!
>
> Darren Cope
> http://dmcope.freeshell.org
> http://bluesignweekly.blogspot.com/
>
> ___
> grass-user mailing list
> grass-user@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-user
>
>
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] raster merging

2009-03-19 Thread Cassiel
2009/3/18 Nikos Alexandris 

> On Wed, 2009-03-18 at 16:17 +0100, Cassiel wrote:
> > Hi you all,
> >
> > I am working with geotiff raster data served on a webgis (mapserver +
> > pmapper) and I would like to serve a merged raster (DEM + its shaded
> > relief) instead of serving two distinct raster/layer with my mapfile
> > (one for the dem and one for the shaded relief).
> >
> > Should I go with r.mapcalc in order to obtain a suitable GTiff for
> > mapserver?
> >
> > Regards
> > raffaele
>
> Raffaele,
>
> perhaps r.blend is what you are looking for. After some trial and error
> (concerning the "Percentage weight of first map for color blending")
> you'll get a nice looking shaded DEM that you can use (export).
>
> Kind regards, Nikos
>

Yes it is,

running

g.region res=80
r.blend first=italia20m second=shade80 output=m80 percent=50
r.composite -d red=m80.r green=m80.g blue=m80.b levels=32 output=dem80
r.out.tiff -t input=dem80 output=dem80.tif compression=lzw

give me the GTiff I wanted.

thank you for helping.

Regards
raffaele
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] problem about import of shp file

2009-03-19 Thread Markus Neteler
On Wed, Mar 18, 2009 at 3:46 PM, Natsuko YOSHIFUJI
 wrote:
> On 2009/03/18, at 22:07, Markus Neteler wrote:
>>> Natsuko YOSHIFUJI wrote:
>> ...

 Where can I get grass-6.5 and grass7?
>>>
>>> grass-6.5 and grass-7 are only available as source code via svn.
>>
>> If desired, I can set up cronjobs to generate also the grass-6.5 and
>> grass-7 binaries. For grass-7, there is the problem that I don't manage
>> to compile CAIRO >= 1.5.8 on Fedora FC4 which is used on grass.osgeo.org.
>> Help (i.e., 32bit RPM) welcome.
>>
>
> Thank you very very much!
> I hope binaries of grass-6.5 or grass7.

Here we are:

Weekly Binaries 6.4.0svn:
http://grass.osgeo.org/grass64/binary/linux/snapshot/

Weekly Binaries 6.5.svn:
http://grass.osgeo.org/grass65/binary/linux/snapshot/

Once I receive help from a community member for the CAIRO >= 1.5.8 on Fedora FC4
I can also set up weekly GRASS 7 binaries (the missing dependency breaks
the cronjob).

Markus
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] v.color with layer 2

2009-03-19 Thread Markus Neteler
On Thu, Mar 19, 2009 at 8:58 AM, Paolo Craveri  wrote:
> Hi to all
>
> I have some problems with v.colors (grass6.5.svn) when I try to use it
> with a vector on layer 2; I get this error:
>
> DBMI-SQLite driver error:
>
> Error in sqlite3_prepare():
>
> near "mypoints2_2": syntax error
>
> ERROR: Error while executing: 'UPDATE mypoints2
>
>       mypoints2_2 SET GRASSRGB = '0:0:255' WHERE cat = 1'
>
> ERROR: Processing SQL transaction
>
>
> Here a little script that reproduces this error:

Great - like this it was easy to reproduce here.

> #!/bin/sh
> # # spearfish60 dataset
> db.connect database='$GISDBASE/$LOCATION_NAME/$MAPSET/mydbsqlite' 
> driver=sqlite
> g.copy vect=archsites,mypoints --overwrite
> v.category in=mypoints layer=2 out=mypoints2 opt=add --overwrite
> v.db.addtable mypoints2 layer=2
> v.colors map=mypoints2 layer=2 color=bcyr column=cat
>
> Where I'm wrong?

You aren't. It was a bug which I have now fixed:
http://trac.osgeo.org/grass/changeset/36412

(also in the other branches).

Thanks for catching it,
Markus
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


[GRASS-user] v.color with layer 2

2009-03-19 Thread Paolo Craveri
Hi to all

I have some problems with v.colors (grass6.5.svn) when I try to use it
with a vector on layer 2; I get this error:

DBMI-SQLite driver error:

Error in sqlite3_prepare():

near "mypoints2_2": syntax error



ERROR: Error while executing: 'UPDATE mypoints2

   mypoints2_2 SET GRASSRGB = '0:0:255' WHERE cat = 1'

ERROR: Processing SQL transaction



Here a little script that reproduces this error:

#!/bin/sh
# # spearfish60 dataset
db.connect database='$GISDBASE/$LOCATION_NAME/$MAPSET/mydbsqlite' driver=sqlite
g.copy vect=archsites,mypoints --overwrite
v.category in=mypoints layer=2 out=mypoints2 opt=add --overwrite
v.db.addtable mypoints2 layer=2
v.colors map=mypoints2 layer=2 color=bcyr column=cat

Where I'm wrong?
-- 
-- 
Paolo C.
Lat. 44° 39' 11.08'' N  Long. 7° 23' 25.26'' E
___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user


[GRASS-user] (no subject)

2009-03-19 Thread Wim de Vries
Hamish wrote:
> Wim de Vries wrote:
>
>>> (v.5 on suse 10.3 as well as v.6.2 on debian lenny).
>>> I came to the point of defining a new location, but then the list for
>>> projections does not show Lambert conformal or mercator.
>>>
>
> it's there. lcc, merc, etc.

Ok.Thanks a lot. I'll have another try..

>
>>> Next, I cannot get out of the list. Had to hit CTRL-C to completely
>>> drop out of the app.
>>>
>
> "q"
>
> this is something which to me is rather annoying in the debian package.
> they/we change the default pager ("press any key for next page") to be
> the 'less' program instead of grass's default which is 'more'. the result
> is that you have to be used to it and know to press 'q' to get out of the
> list. with 'more' all you have to do is bash the spacebar and enter enough
> times and you get out automatically.
>
> sorry for the inconvenience. you can change it back to 'more' or whatever
> by setting the GRASS_PAGER variable, see the grass variables help page.
>
> for lenny you should get the latest grass, gdal, and proj packages from
> debian's www.backports.org. then you can have a pretty recent version to
> play with without much more than an apt-get call.
>
>
> Hamish
>
>
>
>


___
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user