Skip to content

Commit

Permalink
Line2 world units raycaster (#23358)
Browse files Browse the repository at this point in the history
* Try brute force...

* Add example and clean-up code

* Remove comment

* Applying PR comments, bug fix, creating new example for raycasting

* adding new example to the tags

* Add example icon and undo build/ changes

* Revert build files

* Checkout build/ from updated upstream

* WIP refactor to split logic

* Bug fixes and cleanup

* Fix screenshot

* PR notes

* Cleaning up

* More cleanup

* Bug fixes

Co-authored-by: ariel-resonai <ariel@resonai.com>
  • Loading branch information
bergden-resonai and ariel-resonai authored Mar 9, 2022
1 parent 7454db3 commit aa01ab3
Show file tree
Hide file tree
Showing 8 changed files with 593 additions and 146 deletions.
1 change: 1 addition & 0 deletions examples/files.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@
"webgl_lines_colors",
"webgl_lines_dashed",
"webgl_lines_fat",
"webgl_lines_fat_raycasting",
"webgl_lines_fat_wireframe",
"webgl_lines_sphere",
"webgl_loader_3dm",
Expand Down
2 changes: 1 addition & 1 deletion examples/jsm/lines/LineMaterial.js
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ ShaderLib[ 'line' ] = {
vec4 clip = projectionMatrix * worldPos;
// shift the depth of the projected points so the line
// segements overlap neatly
// segments overlap neatly
vec3 clipPose = ( position.y < 0.5 ) ? ndcStart : ndcEnd;
clip.z = clipPose.z * clip.w;
Expand Down
Loading

0 comments on commit aa01ab3

Please sign in to comment.