-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Add alpha coverage details #864
Merged
Merged
Changes from 1 commit
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
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
This file contains 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
This file contains 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
This file contains 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 |
---|---|---|
|
@@ -5,9 +5,9 @@ | |
"description": "The material appearance of a primitive.", | ||
"allOf": [ { "$ref": "glTFChildOfRootProperty.schema.json" } ], | ||
"properties": { | ||
"name": {}, | ||
"extensions": {}, | ||
"extras": {}, | ||
"name": { }, | ||
"extensions": { }, | ||
"extras": { }, | ||
"pbrMetallicRoughness": { | ||
"allOf": [ { "$ref": "material.pbrMetallicRoughness.schema.json" } ], | ||
"description": "A set of parameter values that are used to define the metallic-roughness material model from Physically-Based Rendering (PBR) methodology." | ||
|
@@ -39,7 +39,30 @@ | |
"default": [ 0.0, 0.0, 0.0 ], | ||
"description": "The emissive color of the material.", | ||
"gltf_detailedDescription": "The RGB components of the emissive color of the material. If an emissiveTexture is specified, this value is multiplied with the texel values." | ||
}, | ||
"alphaMode": { | ||
"type": "string", | ||
"enum": [ "OPAQUE", "MASK", "BLEND" ], | ||
"default": "OPAQUE", | ||
"description": "The alpha rendering mode of the material.", | ||
"gltf_detailedDescription": "The material's alpha rendering mode enumeration specifying the interpretation of the alpha value of the main factor and texture. If the alpha mode is not specified, it defaults to `OPAQUE` where the alpha value is ignored and the rendered output is fully opaque. In `MASK` mode, the rendered output is either fully opaque or fully transparent depending on the alpha value and the specified alpha cutoff value. In `BLEND` mode, the alpha value is used to composite the source and destination areas. The rendered output is combined with the background using the normal painting operation (i.e. the Porter and Duff over operator)." | ||
}, | ||
"alphaCutoff": { | ||
"type": "number", | ||
"minimum": 0.0, | ||
"default": 0.5, | ||
"description": "The alpha cutoff value of the material.", | ||
"gltf_detailedDescription": "This value specifies the cutoff threshold when in `MASK` mode. If the alpha value is greater than or equal to this value then it is rendered as fully opaque, otherwise, it is rendered as fully transparent. This value is ignored for other modes." | ||
}, | ||
"doubleSided": { | ||
"type": "boolean", | ||
"default": false, | ||
"description": "Indicates whether a material is double sided.", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. nit: a material --> the material (to be consistent with the rest of the descriptions) |
||
"gltf_detailedDescription": "Declares whether back-face culling should be disabled for this material." | ||
} | ||
}, | ||
"dependencies" : { | ||
"alphaCutoff" : ["alphaMode"] | ||
}, | ||
"additionalProperties": false | ||
} |
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems a bit out of place. Double sided has nothing to do with alpha coverage?