Opened 9 years ago

Last modified 5 years ago

#2531 new defect

v.parallel/v.segment: strange output

Reported by: hellik Owned by: grass-dev@…
Priority: critical Milestone: 7.6.2
Component: Vector Version: svn-trunk
Keywords: v.parallel, v.segment Cc:
CPU: Unspecified Platform: MSWindows Vista

Description

tested in the nc sample data set

v.extract input=streams@PERMANENT cats=83348 output=streams_oneline
v.parallel --verbose input=streams_oneline@user1 output=streams_oneline_parallel_test distance=100 side=both

see attached result; is this correct?

Attachments (3)

vparallel.png (28.5 KB ) - added by hellik 9 years ago.
vsegment.png (43.2 KB ) - added by hellik 9 years ago.
example_parallel_lines_longer_than_original.png (21.8 KB ) - added by mlennert 9 years ago.

Download all attachments as: .zip

Change History (21)

by hellik, 9 years ago

Attachment: vparallel.png added

in reply to:  description comment:1 by hellik, 9 years ago

Replying to hellik:

tested in the nc sample data set

v.extract input=streams@PERMANENT cats=83348 output=streams_oneline
v.parallel --verbose input=streams_oneline@user1 output=streams_oneline_parallel_test distance=100 side=both

see attached result; is this correct?

tested with

System Info                                                                     
GRASS Version: 7.1.svn                                                          
GRASS SVN Revision: 63945                                                       
Erstellungsdatum: 2015-01-04                                                    
Build Platform: i686-pc-mingw32                                                 
GDAL/OGR: 1.11.1                                                                
PROJ.4: 4.8.0                                                                   
GEOS: 3.4.2                                                                     
SQLite: 3.7.17                                                                  
Python: 2.7.4                                                                   
wxPython: 2.8.12.1                                                              
Platform: Windows-Vista-6.0.6002-SP2 (OSGeo4W)  

comment:2 by neteler, 9 years ago

Keywords: v.parallel added; parallel removed

IMHO this ticket is a duplicate of #90

comment:3 by hellik, 9 years ago

Milestone: 7.1.07.0.0
Priority: majorblocker

in reply to:  2 comment:4 by hellik, 9 years ago

Replying to neteler:

IMHO this ticket is a duplicate of #90

yes it seems to be duplicate of #90. #90 is for g6. as also v.segment is affected by this bug, I've raised priority.

in reply to:  3 ; comment:5 by martinl, 9 years ago

Replying to hellik:

I wonder why it's blocker? I would say it's critical, but not the blocker.

in reply to:  5 comment:6 by hellik, 9 years ago

Replying to martinl:

Replying to hellik:

I wonder why it's blocker? I would say it's critical, but not the blocker.

IMHO create parallel vector lines is a basic GIS function which should work in a release of a new GRASS GIS generation. additionally it's still an longstanding issue in g6 (see #90).

please feel free to downgrade.

comment:7 by neteler, 9 years ago

Priority: blockercritical

It does not impact the overall GRASS functionality, hence downgrading.

We may also consider to move it to Addons... I am not sure how important v.parallel is.

by hellik, 9 years ago

Attachment: vsegment.png added

in reply to:  7 comment:8 by hellik, 9 years ago

Replying to neteler:

I am not sure how important v.parallel is.

IMHO creating parallel vector lines is a core functionality of a GIS vector engine.

We may also consider to move it to Addons...

then, also v.segment should be moved to addons (see screenshot), as also this module is affected by the underlying function.

my 0.02c

comment:9 by hellik, 9 years ago

Keywords: v.segment added

comment:10 by hellik, 9 years ago

Summary: v.parallel: strange outputv.parallel/v.segment: strange output

comment:11 by mlennert, 9 years ago

In Vect_line_parallel2 in lib/vector/Vlib/buffer2.c, a call to clean_parallel is commented out. clean_parallel exists in buffer.c, not in buffer2.c. Maybe this might be a path to a solution.

What seems to be the issue (AFAIU) is that the length of the parallel line segments is longer than that of the original line segments, as if the lines as projected outward. This seems to be what leads to the loops. Don't know why such a projection is done... I'll attach a screenshot to show what I mean.

Have you checked out the -b flag ? And possibly tried to generalize the line before creating using v.parallel. Both might actually give you what you are looking for ?

comment:12 by neteler, 8 years ago

Milestone: 7.0.07.0.3

comment:13 by neteler, 8 years ago

Milestone: 7.0.3

Ticket retargeted after milestone closed

comment:14 by neteler, 8 years ago

Milestone: 7.0.4

Ticket retargeted after 7.0.3 milestone closed

comment:15 by martinl, 8 years ago

Milestone: 7.0.47.0.5

comment:16 by neteler, 8 years ago

Milestone: 7.0.57.0.6

comment:17 by neteler, 6 years ago

Milestone: 7.0.67.0.7

comment:18 by martinl, 5 years ago

Milestone: 7.0.77.6.2
Note: See TracTickets for help on using tickets.