Skip to content
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

Migrate to gdext #84

Merged
merged 261 commits into from
Jun 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
261 commits
Select commit Hold shift + click to select a range
a2e71fe
add yet more code. Add almost all files so far as stub.
Ughuuu Apr 27, 2024
adf00ec
upd to singleton again
Ughuuu Apr 27, 2024
f27b6ed
update some shapes.
Ughuuu Apr 28, 2024
5686aad
finish shapes impl
Ughuuu Apr 28, 2024
9741fc0
start joint update
Ughuuu Apr 28, 2024
a816a69
update
Ughuuu Apr 28, 2024
95379f6
update rapier version
Ughuuu Apr 28, 2024
4b42541
upd body and area with base
Ughuuu Apr 28, 2024
e76bbd4
add empty methods to all classes.
Ughuuu Apr 30, 2024
a924e1e
update code with all api's for states.
Ughuuu Apr 30, 2024
e161a8a
add implementation for body_direct_state
Ughuuu May 2, 2024
2a50954
update direct space and finish impl of them.
Ughuuu May 2, 2024
bdb2183
upd
Ughuuu May 2, 2024
a030f66
update joints
Ughuuu May 3, 2024
87ce14b
upd
Ughuuu May 4, 2024
8135d01
Fix parent scale not getting applied correctly (#94)
Ughuuu May 4, 2024
75a9e9f
Fix destroy shape race condition (#95)
Ughuuu May 4, 2024
d9d5c34
Fix parent scale not getting applied correctly (#94)
Ughuuu May 4, 2024
9752636
Fix destroy shape race condition (#95)
Ughuuu May 4, 2024
9f1eae9
upd
Ughuuu May 8, 2024
4cec516
upd
Ughuuu May 8, 2024
4b19e7e
remove option around wrapper functions. Update physics server with ar…
Ughuuu May 9, 2024
bd724ec
upd
Ughuuu May 10, 2024
a7af2bd
update space a little
Ughuuu May 10, 2024
16cc82c
update some more
Ughuuu May 11, 2024
c4efb66
upd
Ughuuu May 12, 2024
0a26fb5
new idea for bodies to keep reference to space and not selflist
Ughuuu May 12, 2024
7eb76ea
upd
Ughuuu May 12, 2024
13c606b
add space handle
Ughuuu May 13, 2024
d961333
upd
Ughuuu May 13, 2024
e0d8874
Update rapier_body_2d.rs
Ughuuu May 14, 2024
62b5ec0
Fix build issue in build after rapier 0.19. Also fix pin joint rotati…
Ughuuu May 14, 2024
983adcf
fix joint rotation.
Ughuuu May 14, 2024
c260d52
update body gravity
Ughuuu May 14, 2024
11b6025
update body functions
Ughuuu May 15, 2024
5fee762
update
Ughuuu May 15, 2024
ca8e824
upd
Ughuuu May 15, 2024
830d1c7
update to a state where it builds.
Ughuuu May 16, 2024
2f7d4c4
upd make it compile
Ughuuu May 16, 2024
50c01c5
fix physics server with tool.
Ughuuu May 17, 2024
dc03078
make all tool
Ughuuu May 17, 2024
175c45e
Remove error message when body/area already monitored. (#100)
Ughuuu May 17, 2024
4f5949b
add impl for remaining things for add/set shapes
Ughuuu May 19, 2024
bc014e5
fix locking issue
Ughuuu May 19, 2024
70a9586
upd
Ughuuu May 20, 2024
e6190b6
first update to fix deadlock
Ughuuu May 27, 2024
3c182ec
update/fix deadlock.
Ughuuu May 28, 2024
e8f7496
update to transform updating part. Need to update direct body state w…
Ughuuu May 28, 2024
fd416ff
fix direct_state to get it working.
Ughuuu May 28, 2024
965a809
fix shape update transform
Ughuuu May 29, 2024
a67cae1
update/move code around
Ughuuu May 29, 2024
3d7ba3d
apply cargo clippy --fix
Ughuuu May 29, 2024
b6238d6
update
Ughuuu May 29, 2024
b429e9f
big update. Fix callbacks.
Ughuuu May 30, 2024
960ac4a
remove locks
Ughuuu May 30, 2024
3579226
update contact skin and try to build web
Ughuuu May 30, 2024
ab7ed85
add gut and a few tests
Ughuuu May 31, 2024
6d8a297
update contact skin
Ughuuu Jun 1, 2024
a3a1521
add integration tests.
Ughuuu Jun 2, 2024
d81262a
upd
Ughuuu Jun 4, 2024
6199a11
remove unused stuff
Ughuuu Jun 5, 2024
36ce514
Update physics_world.rs
Ughuuu Jun 5, 2024
86407e3
format and remove unwrap from most places
Ughuuu Jun 5, 2024
b8b9050
rename singleton and remove most empty places {} blocks.
Ughuuu Jun 5, 2024
5501bc6
upd
Ughuuu Jun 5, 2024
f22f6a7
update tests
Ughuuu Jun 6, 2024
d0351cd
update shapes
Ughuuu Jun 6, 2024
cad590a
spaces refactor
Ughuuu Jun 6, 2024
4648eeb
upd joints
Ughuuu Jun 7, 2024
ab79dbe
move some files around
Ughuuu Jun 7, 2024
6e2fc65
update/move files around
Ughuuu Jun 8, 2024
8cef84f
update
Ughuuu Jun 8, 2024
0aeec18
upd
Ughuuu Apr 26, 2024
89a4e19
Update .gitignore
Ughuuu Apr 26, 2024
89b1868
upd
Ughuuu Apr 26, 2024
c3dd1c8
Update godot-rapier2d.gdextension
Ughuuu Apr 26, 2024
821bf7f
upd
Ughuuu Apr 26, 2024
1e0061b
update with all functions
Ughuuu Apr 26, 2024
a54f2b0
update unsafe api
Ughuuu Apr 26, 2024
26ff331
fix compilation errors
Ughuuu Apr 26, 2024
6a7edae
move source code to rapier2d folder
Ughuuu Apr 26, 2024
916342a
upd
Ughuuu Apr 27, 2024
ce5902d
add a lot of boilerplate code
Ughuuu Apr 27, 2024
441b8c6
add yet more code. Add almost all files so far as stub.
Ughuuu Apr 27, 2024
7cb0073
upd to singleton again
Ughuuu Apr 27, 2024
b105288
update some shapes.
Ughuuu Apr 28, 2024
fae2e78
finish shapes impl
Ughuuu Apr 28, 2024
d382849
start joint update
Ughuuu Apr 28, 2024
2c9202e
update
Ughuuu Apr 28, 2024
39d9174
update rapier version
Ughuuu Apr 28, 2024
534122e
upd body and area with base
Ughuuu Apr 28, 2024
b7ea5b8
add empty methods to all classes.
Ughuuu Apr 30, 2024
56d046b
update code with all api's for states.
Ughuuu Apr 30, 2024
41356d1
add implementation for body_direct_state
Ughuuu May 2, 2024
6cc7bc5
update direct space and finish impl of them.
Ughuuu May 2, 2024
368c300
upd
Ughuuu May 2, 2024
3894d8d
update joints
Ughuuu May 3, 2024
f289382
upd
Ughuuu May 4, 2024
b98e7bc
upd
Ughuuu May 8, 2024
d903d50
upd
Ughuuu May 8, 2024
8cc7fef
remove option around wrapper functions. Update physics server with ar…
Ughuuu May 9, 2024
f1ef590
upd
Ughuuu May 10, 2024
d2e440f
update space a little
Ughuuu May 10, 2024
8453e25
update some more
Ughuuu May 11, 2024
4451334
upd
Ughuuu May 12, 2024
8dad090
new idea for bodies to keep reference to space and not selflist
Ughuuu May 12, 2024
ce75dca
upd
Ughuuu May 12, 2024
864f4e1
add space handle
Ughuuu May 13, 2024
9d06d8a
upd
Ughuuu May 13, 2024
f6dc2ca
Update rapier_body_2d.rs
Ughuuu May 14, 2024
8248853
fix joint rotation.
Ughuuu May 14, 2024
aaecf1f
update body gravity
Ughuuu May 14, 2024
34c83dc
update body functions
Ughuuu May 15, 2024
0d05e82
update
Ughuuu May 15, 2024
f6d7868
upd
Ughuuu May 15, 2024
d4e26ca
update to a state where it builds.
Ughuuu May 16, 2024
9bf50d0
upd make it compile
Ughuuu May 16, 2024
f1b6251
fix physics server with tool.
Ughuuu May 17, 2024
ce1a118
make all tool
Ughuuu May 17, 2024
2ad8a63
add impl for remaining things for add/set shapes
Ughuuu May 19, 2024
87a2063
fix locking issue
Ughuuu May 19, 2024
490930c
upd
Ughuuu May 20, 2024
40f2bc4
first update to fix deadlock
Ughuuu May 27, 2024
f45d020
update/fix deadlock.
Ughuuu May 28, 2024
4ad53ea
update to transform updating part. Need to update direct body state w…
Ughuuu May 28, 2024
21a5acf
fix direct_state to get it working.
Ughuuu May 28, 2024
a46a5ad
fix shape update transform
Ughuuu May 29, 2024
fa43038
update/move code around
Ughuuu May 29, 2024
2c0f2bf
apply cargo clippy --fix
Ughuuu May 29, 2024
d2ea995
update
Ughuuu May 29, 2024
1a5f495
big update. Fix callbacks.
Ughuuu May 30, 2024
19e45d7
remove locks
Ughuuu May 30, 2024
0086071
update contact skin and try to build web
Ughuuu May 30, 2024
6ae2f3d
add gut and a few tests
Ughuuu May 31, 2024
32fff83
update contact skin
Ughuuu Jun 1, 2024
7860550
add integration tests.
Ughuuu Jun 2, 2024
d7a500d
upd
Ughuuu Jun 4, 2024
d8e5a53
remove unused stuff
Ughuuu Jun 5, 2024
068cd37
Update physics_world.rs
Ughuuu Jun 5, 2024
732de24
format and remove unwrap from most places
Ughuuu Jun 5, 2024
bc57132
rename singleton and remove most empty places {} blocks.
Ughuuu Jun 5, 2024
617ed04
upd
Ughuuu Jun 5, 2024
f8b098f
update tests
Ughuuu Jun 6, 2024
1e7bfa3
update shapes
Ughuuu Jun 6, 2024
04d5be6
spaces refactor
Ughuuu Jun 6, 2024
267dda1
upd joints
Ughuuu Jun 7, 2024
200fea2
move some files around
Ughuuu Jun 7, 2024
b25190e
update/move files around
Ughuuu Jun 8, 2024
59e1646
update
Ughuuu Jun 8, 2024
69ab7c9
Merge branch 'migrate-to-gdext-' of https://github.com/appsinacup/god…
Ughuuu Jun 8, 2024
b2f0d11
upd
Ughuuu Jun 8, 2024
ffa7827
Update action.yml
Ughuuu Jun 8, 2024
d30cedf
Update action.yml
Ughuuu Jun 8, 2024
91288da
Update action.yml
Ughuuu Jun 8, 2024
8068dfe
Update linux_builds.yml
Ughuuu Jun 8, 2024
30b2d12
Update action.yml
Ughuuu Jun 8, 2024
999631d
upd actions
Ughuuu Jun 8, 2024
dd6cead
Update action.yml
Ughuuu Jun 8, 2024
654e82f
disable some builds
Ughuuu Jun 8, 2024
21b3081
disable some builds
Ughuuu Jun 8, 2024
0ccc403
Update runner.yml
Ughuuu Jun 8, 2024
e296a46
fix warnings
Ughuuu Jun 8, 2024
b88ce02
fix upload warning
Ughuuu Jun 8, 2024
15f9c2d
update with bin_dim2 and bin_dim3
Ughuuu Jun 8, 2024
6208d00
fix
Ughuuu Jun 8, 2024
9482c69
update name
Ughuuu Jun 8, 2024
7cef7ac
use parallel and simd-stable from feature
Ughuuu Jun 8, 2024
e8d9241
update dim
Ughuuu Jun 8, 2024
a2f175a
upd folder names
Ughuuu Jun 8, 2024
5c38689
update
Ughuuu Jun 8, 2024
4230950
upd
Ughuuu Jun 8, 2024
51220cc
add info plist
Ughuuu Jun 8, 2024
cd8df9c
Update .gitignore
Ughuuu Jun 8, 2024
c2e77f2
call ls
Ughuuu Jun 8, 2024
c955ef0
upd
Ughuuu Jun 8, 2024
105b703
Update rapier_area_2d.rs
Ughuuu Jun 8, 2024
e73863a
disavble 3d
Ughuuu Jun 8, 2024
bf651b8
fix release
Ughuuu Jun 8, 2024
940586e
fix paths
Ughuuu Jun 8, 2024
82f2c1b
use arch for multiple uploads
Ughuuu Jun 8, 2024
aa81123
Update runner.yml
Ughuuu Jun 8, 2024
e174d3c
Update release.yml
Ughuuu Jun 8, 2024
c6acd69
Update release.yml
Ughuuu Jun 8, 2024
5d0634d
Update release.yml
Ughuuu Jun 9, 2024
e19bcf3
Update runner.yml
Ughuuu Jun 9, 2024
8899d02
initial change for 3d support
Ughuuu Jun 9, 2024
7887f81
fix salva issue and issues with 2d
Ughuuu Jun 9, 2024
5700d69
update
Ughuuu Jun 10, 2024
39f777f
update imports. Fix lints.
Ughuuu Jun 10, 2024
7e375b2
Update README.md
Ughuuu Jun 10, 2024
fa15b33
fix paths
Ughuuu Jun 10, 2024
513bf15
update/fix some tests with length unit
Ughuuu Jun 10, 2024
e2f4334
add godot builds
Ughuuu Jun 10, 2024
30f7557
lint prefer inline
Ughuuu Jun 10, 2024
ad13eda
upload godot files
Ughuuu Jun 10, 2024
a14c494
upd
Ughuuu Jun 10, 2024
369430b
upd
Ughuuu Jun 11, 2024
87476c6
refactor
Ughuuu Jun 12, 2024
d2d5360
add counters
Ughuuu Jun 12, 2024
bd90f9f
upd
Ughuuu Jun 12, 2024
c3bed70
upd
Ughuuu Jun 12, 2024
726d9e9
upd tests and some space use cases
Ughuuu Jun 12, 2024
d9c9eae
push fixes
Ughuuu Jun 13, 2024
77d3af1
update with rapier structs
Ughuuu Jun 14, 2024
708ad36
upd123
Ughuuu Jun 15, 2024
d915aec
revert the rapier structures everywhere change
Ughuuu Jun 15, 2024
5274240
upd for 3d too
Ughuuu Jun 15, 2024
d27ec4b
upd
Ughuuu Jun 15, 2024
0820a8a
first try 3d builds
Ughuuu Jun 15, 2024
b78751a
Update action.yml
Ughuuu Jun 15, 2024
4c201c1
update 3d with circles
Ughuuu Jun 16, 2024
b455977
try to do releases for 2d/3d also. Update readme.
Ughuuu Jun 16, 2024
f1d8239
Update release.yml
Ughuuu Jun 16, 2024
c71b67a
use faster hashmap
Ughuuu Jun 16, 2024
625bcc8
update
Ughuuu Jun 16, 2024
1267967
upd
Ughuuu Jun 16, 2024
60814eb
update areas
Ughuuu Jun 16, 2024
6657b15
fix 3d build
Ughuuu Jun 16, 2024
35f092a
3d add more shapes.
Ughuuu Jun 16, 2024
bbe6186
fix set shape issues
Ughuuu Jun 16, 2024
d92a7e5
Update action.yml
Ughuuu Jun 17, 2024
3001de5
update readme.
Ughuuu Jun 17, 2024
d27753c
try build web
Ughuuu Jun 17, 2024
e2db85a
upd
Ughuuu Jun 17, 2024
2ea896a
Update web_builds.yml
Ughuuu Jun 17, 2024
73093f8
Update android_builds.yml
Ughuuu Jun 17, 2024
190c9d3
Update runner.yml
Ughuuu Jun 17, 2024
d36ed19
Update android_builds.yml
Ughuuu Jun 17, 2024
1a98749
usen ightly for web builds?
Ughuuu Jun 17, 2024
1b1ed31
Update rapier_physics_server_3d.rs
Ughuuu Jun 17, 2024
10a4db4
update lock
Ughuuu Jun 17, 2024
5630bcd
add install ndk step
Ughuuu Jun 17, 2024
f973fdd
Update android_builds.yml
Ughuuu Jun 17, 2024
8b4e5b6
Update android_builds.yml
Ughuuu Jun 17, 2024
92bf0f1
Update android_builds.yml
Ughuuu Jun 17, 2024
02ae4fe
nightly
Ughuuu Jun 17, 2024
01ebb92
Update android_builds.yml
Ughuuu Jun 17, 2024
02289f4
update
Ughuuu Jun 17, 2024
cca0161
Update runner.yml
Ughuuu Jun 17, 2024
8ab071d
update extension for stuff
Ughuuu Jun 17, 2024
18848b6
fix normalize issue assert panicking
Ughuuu Jun 17, 2024
3a3abd4
Update Cargo.toml
Ughuuu Jun 17, 2024
e143228
Update Cargo.lock
Ughuuu Jun 17, 2024
8ff7a50
update shape
Ughuuu Jun 18, 2024
cdd1e8e
update readme. Add convex shape 3d
Ughuuu Jun 18, 2024
7725ffd
fix 2d
Ughuuu Jun 18, 2024
ac59745
update lint
Ughuuu Jun 18, 2024
b7cfbdb
add readme and contribute more info
Ughuuu Jun 18, 2024
9cc0a96
Update CONTRIBUTE.md
Ughuuu Jun 18, 2024
8aaf88a
lint
Ughuuu Jun 18, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .cargo/config.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
[target.wasm32-unknown-emscripten]
rustflags = [
"-C", "link-args=-sSIDE_MODULE=2",
"-C", "link-args=-sUSE_PTHREADS=1",
"-C", "target-feature=+atomics,+bulk-memory,+mutable-globals",
"-Zlink-native-libraries=no"
]
[target.armv7-linux-androideabi]
linker = "armv7a-linux-androideabi31-clang"
rustflags = [
"-C", "link-arg=-undefined",
"-C", "link-arg=dynamic_lookup",
]

[target.aarch64-linux-android]
linker = "aarch64-linux-android31-clang"
rustflags = [
"-C", "link-arg=-undefined",
"-C", "link-arg=dynamic_lookup",
]
199 changes: 0 additions & 199 deletions .clang-format

This file was deleted.

2 changes: 0 additions & 2 deletions .gitattributes

This file was deleted.

22 changes: 10 additions & 12 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,26 +8,24 @@ assignees: ''
---

**Describe the bug**
A clear and concise description of what the bug is.

Add description here

**To Reproduce**

Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

Add steps here

**Expected behavior**
A clear and concise description of what you expected to happen.

**Screenshots**
If applicable, add screenshots to help explain your problem.
A clear and concise description of what you expected to happen.

**Environment (please complete the following information):**
**Environment:**
- OS: [e.g. Windows]
- Version [e.g. v0.3]
- Godot Version [e.g. v4.2]
- Type [e.g. simd single is the default one from asset store]
- Version [e.g. latest or v0.x]
- Godot Version [e.g. v4.x]
- Type [e.g. simd single 2d]

**Example project(zip)**

Expand Down
71 changes: 22 additions & 49 deletions .github/actions/build/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,77 +2,50 @@ name: Physics Server Rapier Build
description: Build Godot Cpp and the Physics Server 2D Extension.

inputs:
platform:
required: true
description: Target platform.
rust_target:
arch:
required: true
default: ''
description: Rust target platform.
rust_extra_flags:
extra_flags:
required: false
default: ''
description: Rust extra flags.
rust_env_flags:
env_flags:
required: false
default: ''
description: RUSTFLAGS env var.
arch:
default: ''
description: Target architecture.
precision:
required: true
description: single or double
features:
required: true
description: simd-nightly,simd-stable,parallel,enhanced-determinism

runs:
using: composite
steps:
- name: Cache .scons_cache
uses: actions/cache@v3
with:
path: |
${{ github.workspace }}/.scons-cache/
${{ github.workspace }}/godot-cpp/.scons-cache/
key: ${{ inputs.platform }}_${{ inputs.arch }}_${{ inputs.precision }}_cache
- name: Setup python and scons
uses: ./.github/actions/deps
- name: Build Godot Cpp
- name: Rust Install Nightly
shell: sh
env:
SCONS_CACHE: .scons-cache
SCONS_CACHE_DIR: .scons-cache
run: |
cd godot-cpp && \
scons target=template_debug platform=${{ inputs.platform }} arch=${{ inputs.arch }} generate_bindings=yes precision=${{ inputs.precision }} && \
scons target=template_release platform=${{ inputs.platform }} arch=${{ inputs.arch }} generate_bindings=yes precision=${{ inputs.precision }}
- name: Build Rapier
rustup install nightly
rustup default nightly
rustup target add ${{ inputs.arch }}
cargo update
- name: Build
shell: sh
run: |
cd src/rapier2d-wrapper && \
rustup target add ${{ inputs.rust_target }} && \
cargo build --target=${{ inputs.rust_target }} --release --features="${{ inputs.features }},${{ inputs.precision }}" ${{ inputs.rust_extra_flags}} && \
mkdir -p target/release && \
rm -rf target/release && \
cp -rf target/${{ inputs.rust_target }}/release target/release
cargo +nightly build --target=${{ inputs.arch }} --release --features="${{ inputs.features }}" ${{ inputs.extra_flags}} --no-default-features
env:
RUSTFLAGS: ${{ inputs.rust_env_flags }}
- name: Build Rapier Macos Universal
RUSTFLAGS: ${{ inputs.env_flags }}
- name: Copy to release
shell: sh

# we already built for x86_64-apple-darwin for mac, now build arm64
if: ${{ inputs.platform == 'macos'}}
run: |
cd src/rapier2d-wrapper && mkdir -p target/release && rustup target add aarch64-apple-darwin && \
cargo build --target=aarch64-apple-darwin --release --features="${{ inputs.features }},${{ inputs.precision }}" && \
lipo -create -output target/release/librapier2d_wrapper.a target/aarch64-apple-darwin/release/librapier2d_wrapper.a target/x86_64-apple-darwin/release/librapier2d_wrapper.a
- name: Build Physics Server Rapier
mkdir -p target/release
rm -rf target/release
cp -rf target/${{ inputs.arch }}/release target/release
- name: Build Rapier Macos Universal
shell: sh
env:
SCONS_CACHE: .scons-cache
SCONS_CACHE_DIR: .scons-cache
# we already built for x86_64-apple-darwin for mac, now build arm64
if: ${{ inputs.arch == 'x86_64-apple-darwin'}}
run: |
scons target=template_debug platform=${{ inputs.platform }} arch=${{ inputs.arch }} generate_bindings=no precision=${{ inputs.precision }}
scons target=template_release platform=${{ inputs.platform }} arch=${{ inputs.arch }} generate_bindings=no precision=${{ inputs.precision }}
mkdir -p target/release
rustup target add aarch64-apple-darwin
cargo build --target=aarch64-apple-darwin --release --features="${{ inputs.features }}" --no-default-features
lipo -create -output target/release/libgodot_rapier.dylib target/aarch64-apple-darwin/release/libgodot_rapier.dylib target/x86_64-apple-darwin/release/libgodot_rapier.dylib
34 changes: 0 additions & 34 deletions .github/actions/deps/action.yml

This file was deleted.

Loading
Loading