KhronosGroup / KhronosGroup/Vulkan-Docs
Sanity of pointSizeGranularity and lineWidthGranularity
- Dominant language
- JavaScript
- Stars
- 3.3k
- Forks
- 549
- Avg merge
- 5d 5h
- Merged PRs (30d)
- 2
Description
I think `pointSizeGranularity` and `lineWidthGranularity` should additionally have these requirements:
1) They must be greater than `0.0f`
2) They must divide `1.0f` exactly, i.e. be 2-N.
3) They must be large enough so `lineWidthRange[1] - lineWidthGranularity != lineWidthRange[1]`.
4) `lineWidthRange[0]` must be so `lineWidthRange[0] == N*lineWidthGranularity` where `N` is integer
BTW: There is "fixed point increment" stated in Limit Type column of the table. It is ambiguous what that means. Is that the same as nr. 2?
PS:
- Per https://vulkan.gpuinfo.org/displaydevicelimit.php?name=lineWidthGranularity there are only some really old drivers violating 2.
- Per https://vulkan.gpuinfo.org/displaydevicelimit.php?name=lineWidthRange[0] nr. 4 seems ok to make.
- Lowest sane granularity seems to be `0.0078125` (2-7) and largest `lineWidthRange[1]` is `8192`, so nr 3 seems to be fine too.
- Nr. 1 is I think outright bug if `wideLines` is supported. Surely should not be negative either way.
Contributor guide
Assessment
This issue has not been assessed yet.