Welcome back.
We downloaded the SSD mobile.
Net version one model.
Now let's move to Android Studio.
Create a new project.
Empty compose activity.
Next name it as Object detection SSD mobile.
Or you can see SSD SSD app.
It's good.
Click finish.
Let me start by adding the libraries that we're going to use in our application.
Of course.
Let me add that TensorFlow.
We can search for TensorFlow Android dependency.
Copy them and we will use those libraries before in the previous videos.
So there's no need to relecture them.
This is for the Android TensorFlow.
You can search online for those dependencies, or you can open the previous examples and copy the dependencies
for the TensorFlow.
So copy those dependencies and paste them here.
And to solve those, uh, those, uh, errors, we need to open YAML file version here.
Go to the previous project.
Copy those paste them here, scroll down copy those.
Scroll down to here.
Paste them and everything should work fine.
Sync the project here.
We added TensorFlow.
Now let's add the camera, copy the dependencies for camera and paste them here.
Also you can search for Camerax Android dependencies.
Get the Camerax from developer.android.com and the stable release is 1.5.0.
This is the latest one you can see if you need to add camera lifecycle library.
And this is what we used in the previous videos and in the previous sections Also, if you want additional
use Camerax video capture, you can add this if you want to additional use Camerax view class.
ML Kit vision integration and a Camerax extension library.
Okay, copy this dependency.
Paste it here.
And if you want to allow the user to, uh, like, uh, video capturing, copy it, you can add it.
Okay.
Click sync.
Now close the previous project.
And now let's add new libraries here.
The permission libraries permission and navigation libraries.
The permission implementation libs dot accompanist dot permissions.
Also you can search Google for accompanist permission library and you get the library.
So scroll down.
You get the latest versions for the composer 70.37.3.
Okay.
Or you can simply write this a companion a companion permission 0.28.
You can update it to 0.37 okay.
So click sync.
Now we're going to use Hilde for dependency injection.
So I'm going to make it a professional and a complex application.
So we're going to use dependency injection using Hilde search for Hilde navigation compose dependency.
Select Android Developer website 1.3 for the Hilde.
Scroll down.
Let me check the dependency.
Another search for Hilde.
Compose dependency, not navigation.
Use Hilde with other jetpack libraries.
Scroll down integrating with Jetpack Compose.
And here we don't need to use the cap, we need to use the KSB.
Okay, so for this purpose Go and search for KSP.
Go to dagger KSP dagger dev and this is the website.
And here select migrate to KSP.
Open it in another tab.
Scroll down and copy this ID this is for the KSP and paste it where in the Kotlin build.gradle file
the project level.
So project level here paste it.
Enable it in the build.gradle file at the build or the app level.
Scroll up paste it here.
Then we need to add the k not for room.
We need to use the KSP with dagger.
So go up you see guys the KSP here and add the KSP.
This is for hilt compiler.
Add the KSP down.
Click sync now from dagger.dev select Tilt.
And since we are using hilt with Jetpack Compose, you can go to Gradle setup.
Let's add the dependency of hilt and copy this and paste it here.
Make sure you make it in the correct format.
I tagged about Ccpp and dagger in the previous sections, so please go back to get more info about it.
We need to apply this plugin, so copy this and paste it inside the Build.gradle.
At the level of the application, write the.
Write it in the correct format.
Sync the project.
Now we need to add the dependency for hilt, so scroll down or scroll up.
We need to get hilt, copy it.
Copy this implementation.
Paste it here.
Try to sync the project and here we go.
In order to ensure that there is no errors, please run the application and the.
If KSB and health causes some errors, please refer to the documentations and downgrade the hilt or
the Gradle or the plugins like this.
So you should you see guys that here we have the accompanist permission 0.28 is causing the errors.
Let me upgrade it to the latest versions.
As we said before 0.37.3.
So here
0.37.3
sync now.
And here we go.
Our application.
Oops my fault I missed to use com dot google dot accompany okay.
Also you can replace with the new catalog declaration sync.
Now run the project again accompanist sync now.