Skip to content

Commit 0020564

Browse files
committed
stupid editor
1 parent 5bf9714 commit 0020564

File tree

1 file changed

+6
-22
lines changed
  • extensions/2.0/Vendor/BENTLEY_materials_line_style

1 file changed

+6
-22
lines changed

extensions/2.0/Vendor/BENTLEY_materials_line_style/README.md

Lines changed: 6 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Copyright 2015-2025 The Khronos Group Inc.
33
SPDX-License-Identifier: CC-BY-4.0
44
-->
55

6-
# BENTLEY_materials_line_style
6+
# BENTLEY_materials_point_style
77

88
## Contributors
99

@@ -19,41 +19,25 @@ Written against the glTF 2.0 spec.
1919

2020
## Overview
2121

22-
3D modeling and computer-aided drafting (CAD) environments like SketchUp, MicroStation, and Revit use lines extensively to annotate both two- and three-dimensional visualizations. Different lines are rendered with different styles to convey particular semantics and/or differing levels of emphasis. A CAD line style specifies the width of the line and a dash pattern. The BENTLEY_materials_line_style augments a material with a description of a CAD line style.
23-
2422
This specification describes a minimal extension sufficient to meet Bentley Systems' requirements, with some suggestions for how it might be broadened and/or generalized while retaining a focus on CAD visualization.
2523

2624
## Specifying Line Styles
2725

28-
The `BENTLEY_materials_line_style` extension is applied to a material. If that material is used by any line-type primitive, or by the edges described by the `EXT_mesh_primitive_edge_visibility` extension, then it dictates the width and pattern with which the lines are to be drawn.
29-
30-
The `width` property specifies the width in pixels of the lines. For each line segment, extrude by half this width perpendicularly on both sides.
26+
The `BENTLEY_materials_point_style` extension is applied to a material. When that material is used by a POINTS primitive, the extension dictates the size of the points.
3127

32-
> Potential generalization: permit width to be specified in meters.
33-
>
34-
> Potential generalization: permit pixel width to scale with distance between a minimum and maximum.
35-
>
36-
> Potential generalization: we currently assume lines face the camera, which is sensible when using pixels as units of measure. But the glTF spec permits for lines to have normal and tangent attributes for purposes of lighting; this could also be used to specify the plane in which they should be extruded.
28+
The `size` property specifies the diameter of each point in pixels.
3729

38-
The `pattern` property specifies a pixel pattern to be repeated along the length of the line. It is an arbitrary length bitfield expressed as a string in which a `-` (hyphen) indicates a lit pixel and a ` ` (space) indicates an unlit pixel. The first character in the string determines whether the first pixel drawn by the line is lit or not, and so on until the last character, at which point the pattern repeats from the first character.
30+
> Potential generalization: we assume round points. Permit square points? Permit the material's texture to be mapped to the point's bounding box to support arbitrary point shapes?
3931
40-
> Potential generalization: permit patterns to be specified in meters, such that each character in the bitfield correspond to some specified number of meters.
32+
> Potential generalization: we currently assume points face the camera, which is sensible when using pixels as units of measure. But the glTF spec permits for points to have normal attributes for purposes of lighting; this could also be used to specify the plane in which they should be drawn.
4133
42-
> TBD: do pixel widths and patterns refer to device pixels or screen pixels?
34+
> Potential generalization: permit size to be specified in meters.
4335
4436
## glTF Schema Updates
4537

4638

47-
4839
## Implementation Notes
4940

50-
Because many graphics APIs do not support line primitives with a width larger than 1, tesselation is generally required to draw wide lines. Implementations may smooth out the tesselated lines by, e.g., inserting additional triangles at the joints to round them.
51-
52-
> Potential generalization: permit the join style (e.g., round, miter, bevel, diamond) and end cap style (butt, round, diamond, square) to be specified.
53-
54-
The pattern should be continuous along the length of each continuous line string or line loop.
55-
56-
Implementations may choose to aggregate the set of unique dash patterns into a texture with one row per pattern to be indexed by the shader program when applying a line style's pattern.
5741

5842
## JSON Schema
5943

0 commit comments

Comments
 (0)