ModelicaSpecification
ModelicaSpecification copied to clipboard
Non-exhaustive list of supported bitmap formats
It seems odd that we don't give a complete list of supported bitmap formats: https://github.com/modelica/ModelicaSpecification/blob/a61982fa6be2f8e6e071bc9ea468a39be77cebb8/chapters/annotations.tex#L1015-L1017
Shouldn't we simply replace include by are?
If we are going to have a restrictive list, we should also consider including others, like GIF and WebP.
To me it makes sense to not give an exhaustive restrictive list.
The reason is that if a "new" format, such as gif or webp then:
- Tools can directly start supporting them.
- It can then be added to this list.
The reason for giving a list is to indicate that every tool should support png, bmp, jpeg, and svg.
The problem, of course, is that such a non-exhaustive list means that if you don't stick to the list you have a valid model that at the same time isn't portable between tools. I'd gladly wait for the standard to catch up with new cool image formats for the sake of ensuring portability across tools.
The problem, of course, is that such a non-exhaustive list means that if you don't stick to the list you have a valid model that at the same time isn't portable between tools. I'd gladly wait for the standard to catch up with new cool image formats for the sake of ensuring portability across tools.
That is exactly the idea with giving the non-exhaustive list; as the standard says that the given list shall be supported. If you use another new format it isn't portable until the standard catches up with new format.
To me, a central idea of having a standard implemented by several tools is that the standard should ensure portability. Having a normative gap between being standard compliant and being portable is bad for everyone. If the standard has a definite list and some tool decides to allow non-compliant image formats, then that's up to that tool vendor and its users, but all parties should be aware of the violation of the standard.
To answer your original question, I think the answer should be "no".
I think the current wording makes it (sufficiently) clear that portable models should only use the listed file formats. However, it does open up the possibility for a tool to support something else/new. To me this is an issue that does not need fixing, I don't see any value in restricting the small flexibility the specification currently allows.
If somebody wants to issue warning messages for "GIF" then fine by me. But making it a hard restriction seems misplaced, and we risk getting into a long debate of what formats "must" be on the list.
What are the chances that it would be detected in time that new documentation added to the MSL doesn't stick to the list of portable formats, if the restriction isn't enforced by the library author's tool?
Would it really be that much work to convert images to one of the supported formats?