You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have been attempting to dissect this project for a number of days. In its current state (as a complete react-native application) it works quite well however I have been unsuccessful in importing it into an existing application to add ARCore functionality.
From what I have gathered, the application and ARCore seem to be quite closely intertwined. Is separating them into both application and standalone module feasible? Or have you found that, in order to incorporate ARCore into react-native it must be built closely within the application itself? (Which appears to be the case.)
I have tried creating a new module, taking relative segments from this project and then importing said module into a separate react-native application, but did not have any luck. I have also tried importing the entire application as a library into an existing react-native application, but seem to get stuck on the abi defined in build.gradle:
Error: Could not find method getFilter() for arguments [ABI] on object of type com.android.build.gradle.internal.api.LibraryVariantOutputImpl
I'm still relatively new to the react-native native module space, apologies if the answer to this may seem obvious.
The text was updated successfully, but these errors were encountered:
Hi Luke,
The good news is that what are you trying to do is definitely feasible. The bad news is that is not going to be an easy task. This project was built only to showcase the arcore wrapper into an application and the code is spread along, not being concentrated to a module that can be easy extracted. This experiment resulted in the end into a module that was integrated, but unfortunately that code is proprietary to the company I worked for.
In order to integrate this into another application you will need both the java and javascript code. The first step will be to separate all the java code that will be needed into a package and re-run this app with the new structure until it works as it should. After that you can create a jar / aar containg the java modules (React based classes included). You can now import that module into another project with compile('module path') in build.gradle. Once imported a very important step is to instantiate the module in MainApplication.java like this:
I don't work on Android anymore so I have no time/ tools installed for updating / maintaining this project. After you manage to get it working feel free to make a pull request.
I have been attempting to dissect this project for a number of days. In its current state (as a complete react-native application) it works quite well however I have been unsuccessful in importing it into an existing application to add ARCore functionality.
From what I have gathered, the application and ARCore seem to be quite closely intertwined. Is separating them into both application and standalone module feasible? Or have you found that, in order to incorporate ARCore into react-native it must be built closely within the application itself? (Which appears to be the case.)
I have tried creating a new module, taking relative segments from this project and then importing said module into a separate react-native application, but did not have any luck. I have also tried importing the entire application as a library into an existing react-native application, but seem to get stuck on the abi defined in build.gradle:
Error:
Could not find method getFilter() for arguments [ABI] on object of type com.android.build.gradle.internal.api.LibraryVariantOutputImpl
I'm still relatively new to the react-native native module space, apologies if the answer to this may seem obvious.
The text was updated successfully, but these errors were encountered: