Comments (4)
Hey @hradec , there are a bunch of changes that went through in the last week or so that I need to update in this project.
One thing that is very important and possibly the cause of your particular issue is that the headers in the godot_header repo are outdated. They will hopefully be updated soon now that Godot 3 has gone into feature freeze. Assuming you are building Godot 3 from source as well you can set an environment variable to point to \modules\gdnative\include
Other then that the tres file needs to be replaced by a gdnlib file that is structured differently, I've done this for the openvr repo already though I'm still having some issues with it crashing on the objects it exposes. Hope to have that fixed sometime this week.
from godot_openhmd.
Before anything, thanks for the quick reply!!! really appreciate!! :)
Yep, I'm building from godot 3.0.
Actually, this error is happening after I've updated the godot_headers_path
to the proper include path of my godot 3.0 folder, in the SConstruct file, like this:
godot_headers_path = ARGUMENTS.get("headers", "../godot.git/modules/gdnative/include")
So, it seens it's not only that.
I was able to get it to compile further by adding this to the ./src/godot_openhmd.c file:
#define godot_gdnative_api_struct godot_gdnative_core_api_struct
since it seens the godot_gdnative_core_api_struct
is the one that holds godot_alloc
and others.
but then I got more errors:
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
gcc -o src/godot_openhmd.os -c -DOHMD_STATIC -DDRIVER_OCULUS_RIFT -DDRIVER_DEEPOON -DDRIVER_HTC_VIVE -DDRIVER_PSVR -DDRIVER_NOLO -fPIC -g -O3 -std=c++14 -fPIC -DOHMD_STATIC -Ilibusb -Ilibusb/libusb -Ilibusb/libusb/os -Ihidapi/hidapi -Iopenhmd/include -I. -I/RAID/atomo/home/rhradec/dev/godot.git/modules/gdnative/include -Iglad src/godot_openhmd.c
cc1: warning: command line option '-std=c++14' is valid for C++/ObjC++ but not for C
src/godot_openhmd.c: In function 'openhmd_close_controller_device':
src/godot_openhmd.c:216:8: error: 'godot_gdnative_core_api_struct {aka const struct godot_gdnative_core_api_struct}' has no member named 'godot_arvr_remove_controller'; did you mean 'godot_color_contrasted'?
api->godot_arvr_remove_controller(openhmd_data->controller_tracker_mapping[p_index].tracker);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
godot_color_contrasted
and it seems the godot_arvr_remove_controller
is not in the godot_gdnative_core_api_struct
... so I would guess that godot 3.0 has splitted the functionality into 2 or more structures?
I'll keep digging (as time permits), since I can't wait to get my DK1 to work in godot 3.0!
If you have any more pointers to share, maybe I can get this working for you! ;)
anyhow, thanks loads for this driver anyway!! really cool!!!
cheers...
-H
from godot_openhmd.
Yes a number of things were renamed very recently.
Have a look at the most recent changes to godot_openvr:
https://github.com/BastiaanOlij/godot_openvr/blob/render_components/src/godot_openvr.cpp
You'll see the API struct has been broken up into 3 parts which now need to be initialised.
I changed the prefix here to see if that fixed an issue I was dealing with, you actually set this prefix in the new gdnlib file:
https://github.com/BastiaanOlij/godot_openvr/blob/render_components/demo/bin/godot_openvr.gdnlib
It can stay godot_ or we can also rename it for openhmd.
The godot_openhmd.tres file needs to be similarly changed to a gdnlib file with that new layout.
I need to find time to do the final refactoring changes to the openvr implementation so I know what I still need to change and retrofit the same changes here and to the reference implementation. But yeah if you have some time that be good. There are more changes then this, Karroffel and Endragor have been doing a lot of changes to make GDNative libraries deployable on iOS and android
from godot_openhmd.
See PR #2, that should fix the issues. I haven't tested it other then checking if it'll run.
from godot_openhmd.
Related Issues (10)
- Build fails on Ubuntu 18.04 - missing config.h (for libusb submodule) HOT 2
- API Change for Godot 3.1
- Crashes with multithreading
- PSVR no stereo rendering
- CI Linux and Mac builds HOT 2
- 4.0 version
- undefined symbol: hid_get_product_string HOT 5
- Change compilation of 3rd party sources
- Controllers in demo scene HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from godot_openhmd.