Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revisionBoth sides next revision | ||
faq [2019/05/01 14:26] – More causes for self-intersecting scrap outlines tarquinwj | faq [2019/12/07 09:54] – Maps can contain surveys and maps at the same time now tarquinwj | ||
---|---|---|---|
Line 381: | Line 381: | ||
====How do export centerline only?==== | ====How do export centerline only?==== | ||
- | There are two types of maps definitions - one from scraps and other maps and second only from surveys. | + | There are two types of maps definitions - one from scraps and other maps and second only from surveys. |
survey index_survey -title " | survey index_survey -title " | ||
Line 563: | Line 563: | ||
If you create an object outside the //scrap ... endscrap// construction, | If you create an object outside the //scrap ... endscrap// construction, | ||
- | ====How do I use Debug Mode in Layout?==== | + | ====How do I use Debug Mode in Layout? |
If your map is coming out distorted or joins are not connecting in the right place then debug mode is a very useful way to see what is going on. Indeed it is generally useful to get a visual display of the distortions in the map. | If your map is coming out distorted or joins are not connecting in the right place then debug mode is a very useful way to see what is going on. Indeed it is generally useful to get a visual display of the distortions in the map. | ||
Line 621: | Line 621: | ||
colour preview-below 80 | colour preview-below 80 | ||
colour preview-above 80 | colour preview-above 80 | ||
+ | ## Consider invoking 'maps off' in your thconfig file to suppress offsets and previews due to map definitions | ||
opacity 10 #mostly transparent | opacity 10 #mostly transparent | ||
| | ||
Line 660: | Line 661: | ||
TO DO: Add some pictures | TO DO: Add some pictures | ||
+ | |||
+ | See also [[faq# | ||
+ | |||
+ | ====How do I find miss-drawn holes in scraps?==== | ||
+ | Each scrap defines a piece of cave passage, which (almost) always is defined by walls, being the boundary between a rock mass and the open space of the passage. | ||
+ | |||
+ | If these openings are very wide, then you may have to close the opening with a wall line with '' | ||
+ | If you want to draw a wall ' | ||
+ | If you have an oxbow, or large pillar, then you need to set '' | ||
+ | |||
+ | If you follow these rules, Therion can correctly determine what is ' | ||
+ | |||
+ | And beyond this, if you want your kml __maps__ and 3d outputs to be generated correctly, you will also need to get the wall line orientations correct. | ||
+ | |||
+ | If you get it wrong, you can get significant distortion and incorrect colouring in your 2d and 3d outputs. | ||
+ | |||
+ | Here is a layout that you can apply to your export statement. ie '' | ||
+ | |||
+ | layout LayoutCheckScrapsForHoles | ||
+ | ## Martin Sluka Nov2019 | ||
+ | ## Hides most objects and emphasises passage interiors and walls | ||
+ | ## Does not check for correct line orientation (-reverse on|off). You need to export a map to kml to check line wall orientations | ||
+ | symbol-hide group all | ||
+ | symbol-show line wall | ||
+ | debug station-names | ||
+ | debug scrap-names | ||
+ | colour map-bg 85 | ||
+ | endlayout LayoutCheckScrapsForHoles | ||
+ | | ||
+ | Here is what it looks like. Grey areas inside or between scraps mean there is a problem that you need to fix.\\ | ||
+ | {{therion: | ||
+ | |||
+ | ====How to solve the incorrectly determined interior of the scrap==== | ||
+ | |||
+ | Warning: scrap outline intersects itself in bmb3_s3@fake. | ||
+ | |||
+ | //I have this warning in a few scraps in that survey - I wondered how serious it was, and what I should do about it. But without more details of _where_ it intersects itself (and why this is a problem), I could not do anything but ignore it.// | ||
+ | |||
+ | The only information we can give here is the scrap name. There is no way how to find out in MetaPost where exactly the closed path intersects itself :-( | ||
+ | |||
+ | //I have several more scraps which I cannot include in the overall survey at the moment because if I do I get cryptic metapost errors. We have to work out a way of getting better feedback to the user about _where_ the problem lies as it is currently extremely difficult to fix as you don't know which of many lines is at fault.// | ||
+ | |||
+ | We think it's doable to give a line number in th2 file where the error occurs. It would be perhaps possible to also identify area border lines which don't intersect. | ||
+ | |||
+ | //How did you find the above problem. If I understood the process you used to find this it might help me next time.// | ||
+ | |||
+ | We got this error (incorrectly determined interior of the scrap) long time ago in Dead Bats Cave map. There was some strange clipping by the scrap border, which we couldn' | ||
+ | |||
+ | We added the MP warning to point to this problem. When we see it now, we first check scrap ends if something could cause the problem. The biggest problem is if the loop is introduced only after morphing the scrap ends before joining scraps. We can only recommend to move control point in the last bezier arc of wall just before the scrap end, run therion, undo the change by pressing Ctrl+Z and repeat with other walls until the problem remains. | ||
+ | |||
+ | The loop may occur also in the middle of the wall, but it should be visible, at least in 400% zoom. | ||
+ | |||
+ | We are sorry that there is no cleverer algorithm to find the loop :( | ||
+ | |||
+ | see also [[faq# | ||
+ | |||
+ | (There are some other scrap drawing tips in [[tips# | ||
+ | |||
+ | This warning can sometimes happen if you have two wall lines joining on a single point, where Bézier curve controls pull the lines into a very acute angle (where the " | ||
+ | |||
+ | It can also happen if you have inserted a point along a wall line, with its Bézier controls oriented backwards compared with the rest of the line, so that the backwards one points forwards, or vice versa. The rendering looks normal, but Metapost has had to flip the orientation of the line twice, so it complains. | ||
+ | |||
+ | It can also happen if you have accidentally added two linepoints at the same location - this also causes Metapost to flip directions in order to get from one point to the next. Step through each linepoint in turn (in the " | ||
+ | |||
+ | It can also happen on a closed wall line, when the ends join, and you pull the wrong Bézier control past the junction - this causes a combination of the two problems mentioned above. | ||
+ | |||
+ | |||
====How to solve strange errors?==== | ====How to solve strange errors?==== | ||
Line 714: | Line 782: | ||
There is actually nothing wrong with that arrow -- that is the reason why it took so long to find it :) It has the last control point identical with the last point, which is perfectly acceptable in metapost. Unfortunately there is some bug in the arrow definition, which doesn' | There is actually nothing wrong with that arrow -- that is the reason why it took so long to find it :) It has the last control point identical with the last point, which is perfectly acceptable in metapost. Unfortunately there is some bug in the arrow definition, which doesn' | ||
- | ====How to solve the incorrectly determined interior of the scrap==== | ||
- | |||
- | Warning: scrap outline intersects itself in bmb3_s3@fake. | ||
- | |||
- | //I have this warning in a few scraps in that survey - I wondered how serious it was, and what I should do about it. But without more details of _where_ it intersects itself (and why this is a problem), I could not do anything but ignore it.// | ||
- | |||
- | The only information we can give here is the scrap name. There is no way how to find out in MetaPost where exactly the closed path intersects itself :-( | ||
- | |||
- | //I have several more scraps which I cannot include in the overall survey at the moment because if I do I get cryptic metapost errors. We have to work out a way of getting better feedback to the user about _where_ the problem lies as it is currently extremely difficult to fix as you don't know which of many lines is at fault.// | ||
- | |||
- | We think it's doable to give a line number in th2 file where the error occurs. It would be perhaps possible to also identify area border lines which don't intersect. | ||
- | |||
- | //How did you find the above problem. If I understood the process you used to find this it might help me next time.// | ||
- | |||
- | We got this error (incorrectly determined interior of the scrap) long time ago in Dead Bats Cave map. There was some strange clipping by the scrap border, which we couldn' | ||
- | |||
- | We added the MP warning to point to this problem. When we see it now, we first check scrap ends if something could cause the problem. The biggest problem is if the loop is introduced only after morphing the scrap ends before joining scraps. We can only recommend to move control point in the last bezier arc of wall just before the scrap end, run therion, undo the change by pressing Ctrl+Z and repeat with other walls until the problem remains. | ||
- | |||
- | The loop may occur also in the middle of the wall, but it should be visible, at least in 400% zoom. | ||
- | |||
- | We are sorry that there is no cleverer algorithm to find the loop :( | ||
- | |||
- | see also [[faq# | ||
- | |||
- | (There are some other scrap drawing tips in [[tips# | ||
- | |||
- | This warning can sometimes happen if you have two wall lines joining on a single point, where Bézier curve controls pull the lines into a very acute angle (where the " | ||
- | |||
- | It can also happen if you have inserted a point along a wall line, with its Bézier controls oriented backwards compared with the rest of the line, so that the backwards one points forwards, or vice versa. The rendering looks normal, but Metapost has had to flip the orientation of the line twice, so it complains. | ||
- | |||
- | It can also happen if you have accidentally added two linepoints at the same location - this also causes Metapost to flip directions in order to get from one point to the next. Step through each linepoint in turn (in the " | ||
- | |||
- | It can also happen on a closed wall line, when the ends join, and you pull the wrong Bézier control past the junction - this causes a combination of the two problems mentioned above. | ||
====What are the limits for map and for atlas PDFs?==== | ====What are the limits for map and for atlas PDFs?==== | ||