Skip to content

LivePreview - MotionJPEG Live Stream

There are many problems and workarounds using getLivePreview with the SC2. Refer to the problem section of this document.

Using getLivePreview in mobile apps

We know that getLivePreview from the SC2 does work. On the official RICOH mobile app, there is a live preview of the scene before a picture is taken.

official app

Unfortunately, getLivePreview does not work smoothly in the SDK. You can get through some of the problems by calling getLivePreview frequently. The stream on the SC2 does stop in the SDK, but you can restart with a new getLivePreview.

getLivePreview in web-based applications

getLivePreview also works with third-party applications.

Amelia Viewer for RICOH THETA by Jake Kenin. GitHub repository.

Amelia Viewer

The stream worked without any problems. In Firefox, I'm using A-Frame to handle the navigation in a normal 360 view.

Pre-compiled binaries for Windows 10 and Linux are here.

I am using a stream of 1920x960 by 8 FPS.

Amelia Config

Binary data of live view (MotionJPEG). Binary data is transferred as Content-Type: multipart/x-mixed-replace.

Main code example is here:

Function for get live preview is here:

A stripped down example of displaying the MotionJPEG stream is here.

Another excellent source of information on MotionJPEG is this plug-in from the skunkworks club.

Note that the THETA SC2 cannot use plug-in technology. However, other parts of the article are relevant.