RE: [GRASS5] anyone use/need fragstats?

Radim,
I have a question about:

v.patch input=a,b output=c1
v.clean input=c1 output=c2 tool=break,rmdupl

Given: ___
  _________ | |
| | | |
| A | | |
|_________| | B |
                      | |
                      |___|

patch A,B gives:
        ___
     __|___|__
    | | | |
    | A| | | ?
    |__|___|__|
       | B |
       |___|

There are 4 intersections and 5 areas created
by the patch operation in this example. What does
"v.clean input=c1 output=c2 tool=break,rmdupl"
do to patch's result?

I am interested in a v.mapcalc that would do A union B,
A intersection B, A-B, B-A, as well as Booleans like
is_simple(A), is_convex(A). Are there library functions
for doing such things in 5.1? I suspect that we are not
quite there yet?

Actually, I am more interested in having the library functions
than having v.mapcalc.

Could you tell me what you are working on with respect
to these kinds of problems and what your plans are?

Ref: general polygon clipper library (gpc)
     http://www.cs.man.ac.uk/aig/staff/alan/software/index.html

     CGAL, the Computational Geometry Algorithms Library
     CGAL Basic Library Manuals, Polygon Operations
     http://www.cgal.org/Manual/doc_html/index.html

John

On Wed, Jun 18, 2003 at 12:47:39PM -0400, John Gillette wrote:

Ref: general polygon clipper library (gpc)
     http://www.cs.man.ac.uk/aig/staff/alan/software/index.html

     CGAL, the Computational Geometry Algorithms Library
     CGAL Basic Library Manuals, Polygon Operations
     http://www.cgal.org/Manual/doc_html/index.html

Keep in mind that both gpc and CGAL are non-free.

Looking at their code for reference _might_ get you into trouble
if you implement similiar functionality some day.
(I know that is a hard thing to say, but looking at the screaming SCO
comes up with in the ongoing kernel case we really see the dangers
of proprietory code. And this is depressing.)

On Wednesday 18 June 2003 18:47, John Gillette wrote:

Radim,

I have a question about:
> v.patch input=a,b output=c1
> v.clean input=c1 output=c2 tool=break,rmdupl

Given: ___
  _________ | |
| A | | |
| | | |
|_________| | B |
                      |___|

patch A,B gives:
        ___
     __|___|__
    | A| | | ?
    | | | |
    |__|___|__|
       | B |
       |___|

There are 4 intersections and 5 areas created
by the patch operation in this example. What does
"v.clean input=c1 output=c2 tool=break,rmdupl"
do to patch's result?

v.clean breaks boundaries on intersections so that c2
realy contains 5 areas.

I am interested in a v.mapcalc that would do A union B,

v.extract input=c4 output=x where="a is not null or b is not null"

A intersection B,

v.extract input=c4 output=x where="a is not null and b is not null"

A-B,
v.extract input=c4 output=x where="a is not null and b is null"

B-A,
v.extract input=c4 output=x where="a is null and b is not null"

as well as Booleans like
is_simple(A), is_convex(A).

Not available.

Are there library functions
for doing such things in 5.1? I suspect that we are not
quite there yet?

There are no such functions. I want only to remind, that such functions
working on 2 areas only, are useless in GRASS. Function overlaying
2 vectors must work on 2 complete input vector layers and produce new
vector layer.

Actually, I am more interested in having the library functions
than having v.mapcalc.

Could you tell me what you are working on with respect
to these kinds of problems and what your plans are?

Currently I am doing nothing for this. For future, there
are 2 options, I think,
1) develop these functions in GRASS
2) get rid of topological model (i.e. 5.1) and use GEOS

Ref: general polygon clipper library (gpc)
     http://www.cs.man.ac.uk/aig/staff/alan/software/index.html

     CGAL, the Computational Geometry Algorithms Library
     CGAL Basic Library Manuals, Polygon Operations
     http://www.cgal.org/Manual/doc_html/index.html

Maybe better (in this context): http://geos.refractions.net/

Radim

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Bernhard Reiter wrote:

On Wed, Jun 18, 2003 at 12:47:39PM -0400, John Gillette wrote:

Ref: general polygon clipper library (gpc)
    http://www.cs.man.ac.uk/aig/staff/alan/software/index.html

    CGAL, the Computational Geometry Algorithms Library
    CGAL Basic Library Manuals, Polygon Operations
    http://www.cgal.org/Manual/doc_html/index.html

Keep in mind that both gpc and CGAL are non-free.

Looking at their code for reference _might_ get you into trouble
if you implement similiar functionality some day.
(I know that is a hard thing to say, but looking at the screaming SCO
comes up with in the ongoing kernel case we really see the dangers
of proprietory code. And this is depressing.)

Was libart not written as a free (LGPL) replacement for this?

http://www.levien.com/libart/

- --
|--------------Another happy Mandrake Club member--------------|
Buchan Milne Mechanical Engineer, Network Manager
Cellphone * Work +27 82 472 2231 * +27 21 8828820x202
Stellenbosch Automotive Engineering http://www.cae.co.za
GPG Key http://ranger.dnsalias.com/bgmilne.asc
1024D/60D204A7 2919 E232 5610 A038 87B1 72D6 AC92 BA50 60D2 04A7
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQE+8ZHtrJK6UGDSBKcRAvnQAJ43NGPAvRoPAiL1t1UCyQl81pyupQCfY5lu
me459eDFuo5Qh02KPsIzw/Y=
=IZvY
-----END PGP SIGNATURE-----

******************************************************************
Please click on http://www.cae.co.za/disclaimer.htm to read our
e-mail disclaimer or send an e-mail to info@cae.co.za for a copy.
******************************************************************