-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
AR hit test #4892
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
AR hit test #4892
Changes from 1 commit
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
a91ea0e
add background updating options and remove copy position from the cam…
AdaRoseCannon bd0f3b3
add ar-hit-test
AdaRoseCannon 3ac2007
tweak events
AdaRoseCannon 72e39cd
add new events to docs
AdaRoseCannon 22665f3
remove ar-hit-test script from example because this includes it in AF…
AdaRoseCannon 75c65ee
add shadow shader and select-start event
AdaRoseCannon 6c3504a
correct the lighting direction
AdaRoseCannon 5321189
demonstrate AR shadows in example
AdaRoseCannon 9ba5f58
fix offset reticle
AdaRoseCannon fcf70dc
add support for anchors
AdaRoseCannon af0fb7d
fix camera rotation issue
AdaRoseCannon 498df40
update docs
AdaRoseCannon 1be4dc0
Use ar-hit-test instead of bringing it's own
AdaRoseCannon a2823cd
Merge branch 'master' of https://github.com/aframevr/aframe into ar-h…
AdaRoseCannon c40f4d2
remove git mistake
AdaRoseCannon aa8905b
Merge branch 'master' of https://github.com/aframevr/aframe into ar-h…
AdaRoseCannon d9badf7
PR Feedback
AdaRoseCannon fb16806
add some comments
AdaRoseCannon 08588f9
update webxr to automatically include optional features
AdaRoseCannon 9c90934
remove unnesacary removeEventListener since duplicate event listeners…
AdaRoseCannon cd290ff
make more robust for targets without meshes
AdaRoseCannon 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
add shadow shader and select-start event
- Loading branch information
commit 75c65ee0cb697643c0b3b12826d0d7866b15ec12
There are no files selected for viewing
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
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 |
|---|---|---|
|
|
@@ -3,3 +3,4 @@ require('./standard'); | |
| require('./sdf'); | ||
| require('./msdf'); | ||
| require('./ios10hls'); | ||
| require('./shadow'); | ||
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,29 @@ | ||
| var registerShader = require('../core/shader').registerShader; | ||
| var THREE = require('../lib/three'); | ||
|
|
||
| /** | ||
| * Flat shader using THREE.ShadowMaterial. | ||
| */ | ||
| module.exports.Shader = registerShader('shadow', { | ||
| schema: { | ||
| opacity: {default: 0.5}, | ||
| transparent: {default: true}, | ||
| alphaToCoverage: {default: true} | ||
| }, | ||
|
|
||
| /** | ||
| * Initializes the shader. | ||
| * Adds a reference from the scene to this entity as the camera. | ||
| */ | ||
| init: function (data) { | ||
| this.rendererSystem = this.el.sceneEl.systems.renderer; | ||
| this.material = new THREE.ShadowMaterial(); | ||
| }, | ||
|
|
||
| update: function (data) { | ||
| this.material.opacity = data.opacity; | ||
| this.material.alphaToCoverage = data.alphaToCoverage; | ||
| this.material.transparent = data.transparent; | ||
| } | ||
| }); | ||
|
|
||
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.