[GRASS-dev] Re: [GRASS-user] check vector geometry

Jachym Cepicky jachym.cepicky at centrum.cz
Mon Sep 25 12:16:52 EDT 2006


hi,
since nobody complained, i just commited the patch in cvs

i hope, it will work as desired

jachym

On Sun, Sep 24, 2006 at 10:44:55PM +0200, Jachym Cepicky wrote:
> hi,
> 
> On Sun, Sep 24, 2006 at 01:33:09PM -0700, Dylan Beaudette wrote:
> > Thanks for the great patch Jachym. Looking forward to giving it a try.
> 
> someone with clear imagination about how to write code in C and who
> knows SUBMITTING file by heart would have to review it. it works, but
> i'm not shure, if the code is celear enough
> 
> > 
> > Macieck:: i think that some flags are more condusive to being used
> > together than others, i.e. : g.region res=1 -ap both the 'a' and 'p'
> > flags are respected.
> > 
> > for something like the example you gave with g.region -eg -- I would
> > imagine that there is a case statement that computes these values, but
> > only one at a time (for efficiency in the old days?) . perhaps work
> > needs to be done to standardize flag parsing...
> > 
> 
> in most cases, flags are handeld via
> 
>     if (flag1) {
>     }
>     else if (flag2) {
>     }
>     ...
> 
> this we have to check and rewrite (if it makes sence).
> 
> just my 2 cents
> 
> jachym
> 
> > cheers,
> > 
> > dylan
> > 
> > On 9/24/06, Maciej Sieczka <tutey at o2.pl> wrote:
> > >Jachym Cepicky wrote:
> > >> at your service
> > >
> > >And vice-versa.
> > >
> > >Works like a charm! Anybody minds it applied?
> > >
> > >What a nice working Sunday. Thanks Jachym!
> > >
> > >Maciek
> > >
> > >P.S.
> > >
> > >I'm wondering if flags should be exclusive or not in Grass modules, in
> > >general.
> > >
> > >For example, I asked Jachym to make it possible to his new '-t' flag
> > >not to be excluded if used together with '-g', and it works. No matter
> > >what flag seqeunce, if both are used, first goes the '-g' output, then
> > >'-t'. But maybe I asked him for a wrong thing, maybe flags should be
> > >exclusive? Or if they should be not exclusive, should the order they
> > >are called metter? Eg. should '-tg' and '-gt' output in the same sequence?
> > >
> > >Other modules (eg. g.region and r.info) don't allow for using many
> > >flags at the same time, and they have some hierachy in excluding them,
> > >but I can't find a pattern for that (is there one?).
> > >
> > >
> > >
> > >Moreover, I found a strange thing about g.region. Try this:
> > >
> > >$ g.region -e
> > >region north-south extent: 270.000000
> > >region east-west extent: 300.000000
> > >
> > >$ g.region -g
> > >n=4916070
> > >s=4915800
> > >w=602940
> > >e=603240
> > >nsres=30
> > >ewres=30
> > >rows=9
> > >cols=10
> > >
> > >BUT A COMBINATION OF BOTH GIVES NEITHER OF THE ABOVE:
> > >
> > >$ g.region -eg
> > >ns_extent=270.000000
> > >ew_extent=300.000000
> > >
> > >The region extent is printed, like if -e alone was used, but instead of
> > >"region north-south extent" we get "ns_extent". Same thing, but
> > >different wording.
> > >
> > >?
> > >
> > >Maciek
> > >
> > >_______________________________________________
> > >grassuser mailing list
> > >grassuser at grass.itc.it
> > >http://grass.itc.it/mailman/listinfo/grassuser
> > >
> 
> -- 
> Jachym Cepicky
> e-mail: jachym.cepicky at centrum.cz
> URL: http://les-ejk.cz
> GPG: http://les-ejk.cz/gnupg_public_key/jachym_cepicky-gpg_public_key.asc
> -----------------------------------------   
> OFFICE:                                     
> GDF-Hannover
> Mengendamm 16d
> 30177 Hannover
> Germany
> e-mail: cepicky at gdf-hannover.de
> URL:    http://gdf-hannover.de
> Tel.:   +49 511-39088507



> _______________________________________________
> grass-dev mailing list
> grass-dev at grass.itc.it
> http://grass.itc.it/mailman/listinfo/grass-dev

-- 
Jachym Cepicky
e-mail: jachym.cepicky at centrum.cz
URL: http://les-ejk.cz
GPG: http://les-ejk.cz/gnupg_public_key/jachym_cepicky-gpg_public_key.asc
-----------------------------------------   
OFFICE:                                     
GDF-Hannover
Mengendamm 16d
30177 Hannover
Germany
e-mail: cepicky at gdf-hannover.de
URL:    http://gdf-hannover.de
Tel.:   +49 511-39088507
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 191 bytes
Desc: Digital signature
Url : http://lists.osgeo.org/pipermail/grass-dev/attachments/20060925/d25b6041/attachment.bin


More information about the grass-dev mailing list