Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wrong setting for dash symbol in OCD export #2194

Open
eolmapper opened this issue Dec 8, 2023 · 4 comments
Open

wrong setting for dash symbol in OCD export #2194

eolmapper opened this issue Dec 8, 2023 · 4 comments

Comments

@eolmapper
Copy link

Actual behaviour

when oom exports dash symbol in ocd format, the parameter:
“distance” tab
at least "x" space(s)/symbol(s) is 1

This amplifies the problem of ocad which does not respect the minimum size of the dashes for shorts lines.

Expected behaviour

it should be 0

@eolmapper
Copy link
Author

eolmapper commented Oct 15, 2024

I have partialy solved this issue.
The "show_at_least_one_mid_symbol" parameter for the mid symbol is grayed out when there is no mid symbol, but ocad also uses this parameter for dash symbols. This parameter must therefore be correctly configured even if there is no mid symbol defined.
To do this, you must either create an mid symbol, change the parameter and then delete the mid symbol, or directly modify the parameter in the file code by changing show_at_least_one_symbol="true" at "false".
I modified my own symbol set, but it should be done on the base models and perhaps set this parameter as disabled by default when creating a new line symbol.

@dl3sdo
Copy link
Member

dl3sdo commented Oct 16, 2024

When I create a new map in OCAD (ISOM 2017) the symbol 508 (Narrow Ride) is created with 'at least 1 gap/symbol'. In Mapper the symbol's default setting if of course 'show_at_least_one_mid_symbol' being set.
For the 'Footpath' symbol however, OCAD creates the symbol with 'at least 0 gap/symbol' whereas Mapper again uses 'show_at_least_one_mid_symbol' being set.

Following your proposal of changing the property to 0 would work for 'Footpath' but not for the 'Narrow ride'.

@dl3sdo
Copy link
Member

dl3sdo commented Oct 16, 2024

BTW: There is a mismatch between export and import:
Export: ocd_line_common.min_sym = line_symbol->getShowAtLeastOneSymbol() ? 0 : -1;
The min_sym property is not evaluated, thus
Import: line_symbol->show_at_least_one_symbol = true;

@eolmapper
Copy link
Author

Thanks dl3sdo for the answer
First, ocad does not hold the truth and is not an example to follow for OOM. There are also some errors or non-conformities with respect to ISOM in Ocad's symbol sets.

What is concerned by this subject: these are all the dash lines.
The dash must never be shorter than 0.8 times the given length (ISOM spec). However, this is what ocad does when you check show_at_least_one_symbol and therefore what should be avoided.
'Narrow ride' does not except to the rule.

Regarding the import export code, it is a bit beyond my skills, but there seems to be a mismatch. If the export work correctly, the import systematically returns the parameter "show_at_least_one_symbol" to "true" whether it is set like that or not in ocad.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants