-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Integrate sceUsbGps and sceUsbCam with Android #9927
Conversation
GPS_STATE_OFF = 0, | ||
GPS_STATE_ACTIVATING1 = 1, | ||
GPS_STATE_ACTIVATING2 = 2, | ||
GPS_STATE_ON = 3, | ||
}; | ||
|
||
GpsStatus gpsStatus = GPS_STATE_OFF; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is state, so if you want save states to work correctly this needs to be saved. Implement a DoState function like most other HLE modules do.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Most of the code looks quite good, you've done a good job matching the style and so on. I only have some doubt about requiring a new Android permission for an extremely niche feature like this...
android/AndroidManifest.xml
Outdated
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /> | ||
<uses-permission android:name="android.permission.INTERNET" /> | ||
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Requiring new permissions adds friction to the update process as people will be asked for it. Extremely few people are going to need this so I'm a bit dubious that it's worth supporting this on older devices where we can't do the runtime permission question...
Here is a test program I've used; http://lukasz.dk/mirror/forums.ps2dev.org/viewtopica9f1.html?t=7222#49724 |
50fb98c
to
6ab8b11
Compare
@@ -261,6 +263,7 @@ void __KernelDoState(PointerWrap &p) | |||
__UmdDoState(p); | |||
__UtilityDoState(p); | |||
__UsbDoState(p); | |||
__UsbGpsDoState(p); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
New DoState functions should be added at the end of the list, for compatibility with old states. Actually come to think of it, that might not be an issue after all, but that's how we've always done it so please do so anyway in case I'm missing something...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Finally got around to reading the rest of the code. You've done a really good job!
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /> | ||
<uses-permission android:name="android.permission.INTERNET" /> | ||
<uses-permission android:name="archos.permission.FULLSCREEN.FULL" /> | ||
<uses-permission-sdk-23 android:name="android.permission.ACCESS_COARSE_LOCATION" /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh! I didn't notice this little trick, had no idea you could do this. This alleviates all my concerns about adding permissions.
(https://developer.android.com/guide/topics/manifest/uses-permission-sdk-23-element.html for those living in ignorance like me)
I have not found the camera mode feature in android 6.0, ppsspp build a new one |
No description provided.