Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Eclipse Layout Kernel » How to avoid edge overlap
How to avoid edge overlap [message #1810145] Thu, 01 August 2019 12:00 Go to next message
Bo Zhang is currently offline Bo ZhangFriend
Messages: 28
Registered: July 2017
Junior Member
I have a diagram, I need the edge must be ORTHOGONAL, and not overlap, I don't care the direction of the edge.
I use layered layout algorithm, but the edges always overlap at the begin and end of the edge. I try to use MULTI_EDGE, but it can't reslove the problem.
I want to know how to configuration to avoid edge overlap.
This is a diagram data on JSON format, you can check the diagram. on https://rtsys.informatik.uni-kiel.de/elklive/json.html
{
"id": "root",
"layoutOptions": {
"elk.algorithm": "layered",
"org.eclipse.elk.edgeRouting": "ORTHOGONAL",
"org.eclipse.elk.direction": "DOWN",
"org.eclipse.elk.layered.spacing.edgeNodeBetweenLayers": 40,
"org.eclipse.elk.layered.nodePlacement.strategy": "NETWORK_SIMPLEX",
"org.eclipse.elk.layered.wrapping.strategy": "MULTI_EDGE",
"org.eclipse.elk.layered.wrapping.correctionFactor": 100
},
"children": [{
"id": "node1",
"width": 400,
"height": 200,
"layoutOptions": {
"portConstraints": "FIXED_POS"
},
"ports": [{
"id": "port1-1",
"x": 50,
"y": 200,
"width": 10,
"height": 10
},
{
"id": "port1-2",
"x": 100,
"y": 200,
"width": 10,
"height": 10
},
{
"id": "port1-3",
"x": 150,
"y": 200,
"width": 10,
"height": 10
},
{
"id": "port1-4",
"x": 200,
"y": 200,
"width": 10,
"height": 10
}
]
},
{
"id": "node2",
"width": 400,
"height": 200,
"layoutOptions": {
"portConstraints": "FIXED_POS"
},
"ports": [{
"id": "port2-1",
"x": 50,
"y": 0,
"width": 10,
"height": 10
},
{
"id": "port2-2",
"x": 100,
"y": 0,
"width": 10,
"height": 10
},
{
"id": "port2-3",
"x": 150,
"y": 0,
"width": 10,
"height": 10
},
{
"id": "port2-4",
"x": 200,
"y": 0,
"width": 10,
"height": 10
}
]
}
],
"edges": [{
"layoutOptions": {},
"id": "edge1",
"sources": [
"port1-1"
],
"targets": [
"port1-3"
]
},
{
"layoutOptions": {},
"id": "edge2",
"sources": [
"port1-2"
],
"targets": [
"port1-3"
]
},
{
"layoutOptions": {},
"id": "edge3",
"sources": [
"port1-2"
],
"targets": [
"port2-1"
]
},
{
"layoutOptions": {},
"id": "edge4",
"sources": [
"port1-2"
],
"targets": [
"port2-1"
]
},
{
"layoutOptions": {},
"id": "edge5",
"sources": [
"port1-2"
],
"targets": [
"port2-2"
]
},
{
"layoutOptions": {},
"id": "edge6",
"sources": [
"port2-2"
],
"targets": [
"port2-3"
]
},
{
"layoutOptions": {},
"id": "edge7",
"sources": [
"port2-2"
],
"targets": [
"port2-4"
]
}
]
}
Re: How to avoid edge overlap [message #1810836 is a reply to message #1810145] Tue, 20 August 2019 11:37 Go to previous message
Miro Spönemann is currently offline Miro SpönemannFriend
Messages: 71
Registered: March 2015
Location: Kiel, Germany
Member

The edges overlap because you have multiple edges connected to the same ports. If you do that, ELK will interpret those edges as being part of one hyperedge (edge with multiple sources and targets). Remove a few edges and the problem will disappear.

Example:
https://rtsys.informatik.uni-kiel.de/elklive/json.html?compressedContent=N4KABBYEQJYCZQFzQE4Hs0BcoBpySgBsBDATzQFdMB5AB0xjQDsBnJMUSL6AU0IGsAdMUIBzNChiYAFgFt2RMjxQ8EebgQmjBPAMaEYtFjx0CdcUTwBKlBk1ELqVgCoAJagHFqAOQCCAGVx8DSgtHX1DY1MhOBgVXQZmBQARagB1byCNCFCUbT0DIxM+IRJSZVVBFlpiXRh7c0tvNDgeACEeTAB3Hh4mfyUUNmQAFgAGdWzc-Iii6MEyirhBJhaeAAUSXR5ZPswqzBRiTB5RUgVvAFFnNKcAaQB9AGUASQBZdf9LgA0sqbCCpFimZFipll0jrRaPVtCxDsdTudkFA3gBVfzOF4PS7JDyXP4hAGzKIlBaDSoQ4hQmGCXQSeKJJgAMVqmAk7AAjGMxsEwABfSY5XTSGCEOAqJjsADavK4nGyXFgCGRq1aHIJCugXXgMnY4wmsqm0h4MFE0mwyAATNzBZrFOQqHRGcMOIbNdBaBJMABhZhwo71TAuqBMl7fHEPdbUJ5QN3cAVxxWelBB6WJ7Ly90KpUKZOYDkAWnVtqz3CgAA92ABWA2l7NIsDW2t1kLauC65Bckst6DG03mzk8nv87vuzPD6DwXNewuWjXDiuD5sT6ANpujutQNsdsBd9PuqB9s0W3dDnsJ4fjhdT5F5wsAZnnPcXnZrG9LUDXNv3du30kH75ZoeJrHoOP5cBePZXs+N4ejOBYjE+LYvo234rjkX7LhOW46v+nZYQuR4Dvh4GQHyP4ALpxpBGjQSEsFQKqPBzoBOR-nqaFAURJ7rj+9q2E6jCsOwdF2nmvqsPCgbBqG4bJJG0axqWNFiV6LoypepH0cqcEppaRZIZulbIG+Wllg2RYEc+7H4axdrcWBw4qaWokfgxeb6SxZmKsZp5WchFl7uhWq4QB3kEA5JFOXZcrhTk7levpj4xVMvkcqZwWfuwlkpa2oW2XFvYgcRp5mc5WauUBCV6Qhhkfr5vGZYF-mbjZp65WWkWlU5lHUbyFG2lAqiWOpcaVTkZQCfQQkusA5XaQow08MWfEsJQKDbKNC53gZlF2VAmDEHknRbc+Hm7aWVEKvNrofpNjrTX6Ik3YqDFLV5H5rRQG08KdyE7XOe18Ydx2psgGlnYlBaA5d1EbuN0D3TQj3Ccgc37W9Fg8Mlq3rZtabbfBj5Ax+IOWGDYAQ-9UPE7D13w3xSOCU9aMvQQmOWIh+1fT9f2bjtiEk0BZMnQTkM1YLdPZCpVF8kAA
Previous Topic:Custom properties on node
Next Topic:ELK Use with GmF
Goto Forum:
  


Current Time: Sat Apr 17 06:31:42 GMT 2021

Powered by FUDForum. Page generated in 0.01657 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top