forked from KhronosGroup/glTF
-
Notifications
You must be signed in to change notification settings - Fork 9
BENTLEY_materials_point_style #91
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
Merged
Merged
Changes from 13 commits
Commits
Show all changes
24 commits
Select commit
Hold shift + click to select a range
538d0b5
draft wip
markschlosseratbentley 370bb69
flesh out
markschlosseratbentley 8dc4d4f
edit
markschlosseratbentley 660547b
edit
markschlosseratbentley 4c2db7a
edit
markschlosseratbentley df42e1f
edit
markschlosseratbentley fa417ca
edit
markschlosseratbentley 9d7bd80
edit
markschlosseratbentley 71b76a2
edit
markschlosseratbentley 7c0392b
edit
markschlosseratbentley 8ab1475
revise as suggested
markschlosseratbentley 44ae369
materials->material
markschlosseratbentley f72cc1f
rename schema
markschlosseratbentley d68e400
Update extensions/2.0/Vendor/BENTLEY_materials_point_style/schema/mat…
markschlosseratbentley 875d8d0
copyright change
markschlosseratbentley 70cd77b
Merge branch 'BENTLEY_materials_point_style' of https://github.com/Ce…
markschlosseratbentley 9046f36
Update README.md
danielzhong 12c6134
Update material.BENTLEY_material_point_style.schema.json
danielzhong 56ffd04
Rename point style property from width to diameter
danielzhong 96487a3
plural materials
markschlosseratbentley 638e66a
materials plural
markschlosseratbentley 8914e81
materials plural
markschlosseratbentley edd8283
known implementations
markschlosseratbentley be7ce30
pixel clarification
markschlosseratbentley File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
43 changes: 43 additions & 0 deletions
43
extensions/2.0/Vendor/BENTLEY_materials_point_style/README.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,43 @@ | ||
| <!-- | ||
| Copyright 2015-2025 The Khronos Group Inc. | ||
| SPDX-License-Identifier: CC-BY-4.0 | ||
| --> | ||
|
|
||
| # BENTLEY_material_point_style | ||
|
|
||
| ## Contributors | ||
|
|
||
| * Paul Connelly, Bentley Systems, [@pmconne](https://github.com/pmconne) | ||
| * Mark Schlosser, Bentley Systems, [@markschlosseratbentley](https://github.com/markschlosseratbentley) | ||
|
|
||
| ## Status | ||
|
|
||
| Draft | ||
|
|
||
| ## Dependencies | ||
|
|
||
| Written against the glTF 2.0 spec. | ||
|
|
||
| ## Overview | ||
|
|
||
| Points are fundamental elements in many 3D modeling and computer-aided design (CAD) environments. In such visualizations, individual point primitives may differ in their styling, mainly focused around their width in screen pixels. Such width can be used to indicate a variety of meanings useful to CAD applications. | ||
|
|
||
| This specification describes a minimal extension sufficient to meet Bentley Systems' requirements in supporting CAD-style visualizations of points using glTF. | ||
|
|
||
| ## Specifying Point Styles | ||
|
|
||
| The `BENTLEY_material_point_style` extension is applied to a material. When that material is used by a `POINTS` primitive (indicated by a value of `0` for [`mesh.primitive.mode`](https://registry.khronos.org/glTF/specs/2.0/glTF-2.0.html#_mesh_primitive_mode)), the extension dictates the width of those points in pixels. | ||
|
|
||
| ### Width | ||
|
|
||
| The `width` property specifies the diameter of each point in pixels. When specified, this value must be greater than zero. | ||
|
|
||
| For each point, implementations should render the point such that a filled circle is centered at the point's pixel screen position with a pixel diameter equal to `width`. This point faces the camera. | ||
|
|
||
| ## Implementation Notes | ||
|
|
||
| Some graphics APIs may not require that implementations directly support point sizes greater than one. For example, [Section 3.4 of the OpenGL ES 3.0 Specification](https://registry.khronos.org/OpenGL/specs/es/3.0/es_spec_3.0.pdf) only guarantees a maximum point size of at least one via `ALIASED_POINT_SIZE_RANGE`. In such cases, points with widths greater than one could be rendered as quads which are shaped into circles using a shader. | ||
|
|
||
| ## JSON Schema | ||
|
|
||
| * [material.BENTLEY_material_point_style.schema.json](schema/material.BENTLEY_material_point_style.schema.json) | ||
19 changes: 19 additions & 0 deletions
19
...or/BENTLEY_materials_point_style/schema/material.BENTLEY_material_point_style.schema.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,19 @@ | ||
| { | ||
| "$schema": "http://json-schema.org/draft-04/schema", | ||
|
markschlosseratbentley marked this conversation as resolved.
Outdated
|
||
| "title": "BENTLEY_material_point_style extension", | ||
| "type": "object", | ||
| "description": "Specifies point width for CAD-style visualization.", | ||
| "allOf": [ | ||
| { "$ref": "glTFProperty.schema.json" } | ||
| ], | ||
| "properties": { | ||
| "width": { | ||
| "type": "number", | ||
| "description": "Width of the point in screen pixels. Must be > 0.", | ||
| "minimum": 0 | ||
|
markschlosseratbentley marked this conversation as resolved.
Outdated
|
||
| }, | ||
| "extensions": {}, | ||
| "extras": {} | ||
| }, | ||
| "required": ["width"] | ||
| } | ||
|
markschlosseratbentley marked this conversation as resolved.
Outdated
|
||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.