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

Integrate sceUsbGps and sceUsbCam with Android #9927

Merged
merged 2 commits into from
Aug 31, 2017

Conversation

Florin9doi
Copy link
Contributor

No description provided.

@Florin9doi Florin9doi changed the title sceUsbGps Integrate sceUsbGps with Android Location API Aug 23, 2017
GPS_STATE_OFF = 0,
GPS_STATE_ACTIVATING1 = 1,
GPS_STATE_ACTIVATING2 = 2,
GPS_STATE_ON = 3,
};

GpsStatus gpsStatus = GPS_STATE_OFF;
Copy link
Owner

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.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Copy link
Owner

@hrydgard hrydgard left a 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...

<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" />
Copy link
Owner

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...

@Florin9doi
Copy link
Contributor Author

Here is a test program I've used; http://lukasz.dk/mirror/forums.ps2dev.org/viewtopica9f1.html?t=7222#49724

@Florin9doi Florin9doi force-pushed the master branch 5 times, most recently from 50fb98c to 6ab8b11 Compare August 27, 2017 13:54
@Florin9doi Florin9doi changed the title Integrate sceUsbGps with Android Location API Integrate sceUsbGps and sceUsbCam with Android Aug 27, 2017
@Florin9doi
Copy link
Contributor Author

Updated with some Camera features:
device-2017-08-27-125025

The camera images are correctly processed by Invizimals games, but they have other unrelated graphical problems.
Eye Pet don't starts at all.

@@ -261,6 +263,7 @@ void __KernelDoState(PointerWrap &p)
__UmdDoState(p);
__UtilityDoState(p);
__UsbDoState(p);
__UsbGpsDoState(p);
Copy link
Owner

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...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Copy link
Owner

@hrydgard hrydgard left a 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" />
Copy link
Owner

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)

@hrydgard hrydgard merged commit 42cb559 into hrydgard:master Aug 31, 2017
@Endarko
Copy link

Endarko commented Jan 18, 2018

I have not found the camera mode feature in android 6.0, ppsspp build a new one

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants