google-code-export / marinemap

Automatically exported from code.google.com/p/marinemap
Other
1 stars 2 forks source link

server-side process for clipping MPAs to each other #321

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
We need a way to eliminate overlap between MPAs. Issue 320 will add client-side 
functionality to 
kmlEditor/kmlTree to allow for multiple-select on MPAs (and Arrays or 
anything). Atom links will 
then be able to define "actions" that can be run on multiple MPAs.

I'm imagining the server-side component of this would be a webservice which 
would accept 
requests like GET /clipping_form?
shape=http://path/to/mpa/resource&shape=http://path/to/another/mpa
That would return a form that would show up in the sidebar, allowing a user to 
order the 
clipping operation (what gets clipped to what). That form could then be posted 
back with the 
ordering and the MPAs would be clipped. Only the clipped geometry would be 
modified on the 
MPA, so if the user wanted to undo the action they could just edit their 
geometry.

What would make this even more useful then, is a little summary in the Array 
attributes screen of 
where in your Array there is overlap. That summary could contain a link to 
/clipping_form with 
the appropriate shapes pre-populated.

We should discuss this functionality during a dev call once we start 1.3. I 
know Jared has some 
strong opinions about how this functionality should work and we'll want his 
input.

Original issue reported on code.google.com by underbluewaters on 29 Mar 2010 at 3:51

GoogleCodeExporter commented 9 years ago
Issue 228 has been merged into this issue.

Original comment by underbluewaters on 29 Mar 2010 at 3:51

GoogleCodeExporter commented 9 years ago

Original comment by underbluewaters on 8 Apr 2010 at 3:38

GoogleCodeExporter commented 9 years ago
I had some work done on this already so i checked it in; revision r1443.

When you do a get request supplying some mpa ids:
http://localhost:8000/mpas/clip/?mpaid=1000017&mpaid=1000018&mpaid=1000016

you get a form with some fancy js stuff that allows the list items to be sorted 
by
drag-n-drop and then posted in that order to the same URL. The order determines
clipping precedence.

The server-side view uses the geodjango methods to clip the mpas according to 
their
order. I tried to put in a number of checks to handle all the edge cases but 
there
will no doubt be wierd GEOS errors popping up in its current state. 

All in all it works pretty well for the common cases but is not yet integrated 
with
marinemap as we still have some UI/workflow issues to figure out first. 

Original comment by perrygeo...@gmail.com on 13 Apr 2010 at 8:11

GoogleCodeExporter commented 9 years ago
Issue 335 has been merged into this issue.

Original comment by underbluewaters on 16 Apr 2010 at 4:52

GoogleCodeExporter commented 9 years ago
moving this to milestone 1.4

Original comment by sfletche@gmail.com on 26 Apr 2010 at 6:19

GoogleCodeExporter commented 9 years ago
After discussing this with Charles, it doesn't seem like this approach is going 
to solve our problem. It makes it 
possible that users could draw shapes in a way that creates topologically 
correct MPAs, but only at one 
boundary. It's unlikely that users would even go thru the trouble to do this 
though. If it doesn't make hand-fixing 
of the MPA boundaries unnecessary there isn't much point in adding it to the 
interface.

A better solution would be to have some process that actually does 
edge-matching. That would be great, but I 
don't think we have time for it :(

Original comment by underbluewaters on 31 May 2010 at 5:17