I updated the plug-in developer guide with a automatic facial blurring example, complete with source code from the Ricoh GitHub repository.
The application comes with a good example of controlling the camera through a web interface.
The example shows a live stream over Wi-Fi to the browser.
Hey, wow, this is a lot of fun! It was an easy download from the new Plug-in Store, easy install and setting as the primary plug-in, and then, wow, it uses Safari (on my iPhone) to take the pictures! What kind of cool magic is this?? When pressing the shutter button, it seems to take about 10 seconds to do the blurring. Pretty quick, and super clear with the shutter sounds at the beginning and end.
This is really fun! Attaching my images:
Not Blurred Jesse
How did the resolution of the live preview stream look on your iPhone? Also, how did you get the IP address?
It was good, plenty clear, though maybe slightly lower resolution than the THETA app. I’ll grab a screenshot tomorrow and post.
How are you getting the IP address of the camera? Does it work using the official Ricoh app?
The IP address of the camera appears to be grabbed automatically. I didn’t have to do anything to set it.
Here’s the instructions from the Plug-in Store page (click “more”):
When using remote shooting, tap the icon displayed next to “Camera settings” > “Starting plug-in” in the basic app for smartphone. The browser is launched and the shooting screen appears.
When the browser was launched, it pointed to the THETA IP address. I didn’t do anything to set it.
Updated based on recent discussion.
The Ricoh mobile app has a button to open up a browser.
I looked at the source code for the live view section.
publishProgress("start Live view");
HttpConnector camera = new HttpConnector();
InputStream is = camera.getLivePreview();
mjis = new MJpegInputStream(is);
It’s using the OSC API, Ricoh THETA API 2.1 camera.getLivePreview().
I was hoping it would use the
RicMoviePreview3840 or similar value for
RIC_SHOOTING_MODE that is explained in the THETA Plug-in API.
The resolution of
getLivePreview() is going to be lower and the framerate slower.
getLivePreview() with the THETA V will result in a maximum resolution of 1920x960 using MotionJPEG, not the 3840x1920 for Live Streaming. As shown with the Wireless Live Streaming plug-in, Wi-Fi streaming at 4K is smooth from the camera directly.
I don’t know what the framerate is for Live Preview on the THETA V. On the THETA S, it was 15fps.
I went through the code for face detection and it looks like the example uses FaceDetector, which is part of the Android media classes. Here’s a nice tutorial on tracking faces using FaceDetector.