Skip to content

Commit

Permalink
Merge pull request #41 from Schmarni-Dev/hand_refactor
Browse files Browse the repository at this point in the history
Hand refactor
  • Loading branch information
MalekiRe authored Nov 20, 2023
2 parents 2f91b5c + f47375b commit f76e81c
Show file tree
Hide file tree
Showing 20 changed files with 1,942 additions and 1,393 deletions.
5 changes: 3 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/target
/Cargo.lock
**/target
**/Cargo.lock
**/runtime_libs/arm64-v8a/*
\.DS_Store
2 changes: 1 addition & 1 deletion examples/demo/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ version = "0.1.0"
edition = "2021"

[lib]
crate-type = ["lib", "cdylib"]
crate-type = ["rlib", "cdylib"]

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

Expand Down
24 changes: 24 additions & 0 deletions examples/demo/Cargo_back.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
[package]
name = "demo"
version = "0.1.0"
edition = "2021"


[lib]
crate-type = ["cdylib", "lib"]
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
bevy = { git = "https://github.com/bevyengine/bevy.git" }
# bevy = "0.11.3"
# default-features is false because it for some reason complains when trying to statically link openxr
bevy_oxr = { path = "../../" }
# bevy_openxr = { git = "https://github.com/Schmarni-Dev/bevy_openxr", default-features = false, branch = "demo"}
bevy_rapier3d = { git = "https://github.com/devil-ira/bevy_rapier", version = "0.22.0", branch = "bevy-0.12" }
# bevy_rapier3d = { git = "https://github.com/Schmarni-Dev/bevy_rapier" }
color-eyre = "0.6.2"

[profile.release]
lto = "fat"
codegen-units = 1
panic = "abort"
11 changes: 11 additions & 0 deletions examples/demo/Readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
## setup
install xbuild ```cargo install --git https://github.com/rust-mobile/xbuild```
run ```x doctor``` and install all required depencencies
download the [openxr loader](https://developer.oculus.com/downloads/package/oculus-openxr-mobile-sdk/) and put it in the runtime_libs/arm64-v8a folder

## how to run
run ```x devices```

and get the device name that looks something like this ```adb:1WD523S``` (probably a bit longer)

then ```run x run --release```
6 changes: 3 additions & 3 deletions examples/demo/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ use bevy_oxr::{
input::XrInput,
resources::{XrFrameState, XrInstance, XrSession},
xr_input::{
actions::XrActionSets,
debug_gizmos::OpenXrDebugRenderer,
hand::{HandBone, HandInputDebugRenderer, HandResource, HandsResource, OpenXrHandInput},
hands::common::{ HandInputDebugRenderer, HandResource, HandsResource, OpenXrHandInput},
hands::HandBone,
interactions::{
draw_interaction_gizmos, draw_socket_gizmos, interactions, socket_interactions,
update_interactable_states, InteractionEvent, Touched, XRDirectInteractor,
Expand All @@ -29,7 +29,7 @@ use bevy_oxr::{
oculus_touch::OculusController,
prototype_locomotion::{proto_locomotion, PrototypeLocomotionConfig},
trackers::{OpenXRController, OpenXRLeftController, OpenXRRightController, OpenXRTracker},
Hand,
Hand, actions::XrActionSets,
},
DefaultXrPlugins,
};
Expand Down
Loading

0 comments on commit f76e81c

Please sign in to comment.