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.
@dmnsgn Created this pull request so we can track progress.
Comments so far:
Scope
Is this about antialiasing or A2C? Or is A2C form of antialiasing?
Asset sources
We need to provide sources for the used textures and if unknown or license doesn't allow redistribution we should make our own
A2C vs Alpha Test
It's unnecessary as it actually stops A2C gradient half way and looks wrong. Although this tweet suggest otherwise and mattdesl has dynamically adjusted cutout value of 0.4 https://twitter.com/mattdesl/status/900009193649975296?lang=en
Maybe alpha test / cutoff is for performance reasons?
AlphaToCoverage vs Sample Coverage
AlphaToCoverage is just a toggle and not related (?) to gl.sampleCoverage which takes 0..1 value but it has to be also enabled separately with
gl.enable(gl.SAMPLE_COVERAGE)
. Not sure what is it doing or how is it supposed to be used as it clamps max alpha and therefore causes image to "fade out" via dithering.Better assets
Brush asset should be completely white and only have alpha channel
API
Any suggestions for the interface? E.g. regl/API.md#sample-coverage
Given that sampleCoverage is different from alphaToCoverage i suggest