Android PTZ Camera Controls with Live Video Preview

We often see requests for the ability to add a live preview to the mobile control applications that are available for the PTZOptics cameras and until recently there was no solution we could offer. Using the Android 7.0, or greater, platform there is a multi-window feature that was added, sometimes referred to as “split-screen,” where you can view two active applications at the same time. With this feature, we can now have a live preview of a PTZOptics camera with P/T/Z control on the same screen at the same time using the proper applications.

Required Applications

  • PanTiltZoom – on Google Play Store for P/T/Z control
  • VLC – on Google Play Store for Live Preview using RTSP

pan tilt zoom app for android
pan tilt zoom app for android

That PanTiltZoom application has the ability to control up 8 PTZOptics cameras. You will need to enter each camera’s static IP address in order to connect them to your smartphone. Also, you smartphone will need to be on the same WiFi network as the IP connected cameras. Once your smartphone and PTZOptics cameras are connected to the same network you can control the Pan Tilt and Zoom functionality of these cameras with some advanced features that are demonstrated in this video. In the settings area, you will see that you can adjust unique PTZ camera control for both manual and preset speeds. Therefore you can control the camera with manual speeds and different speeds for movements between PTZ presets.

Once you have installed both applications on your Android device you’ll need to open both applications and setup as follows:

PanTiltZoom Setup

  1. Open the PanTiltZoom application

  2. Click the “Setup” gear in the top right corner to setup your camera

    1. Name – use any title that works for you

    2. IP Address – Current IP address of the PTZOptics camera to control

    3. VISCA Port – 5678 (default)

    4. VISCA Address – 1 (default)

  3. Exit this screen, using the back button and the close button that follows, and you should now see your name shown on the first camera selection button

    1. Click that button with the new Name in place and the button should turn green.

    2. You can verify you have control of the camera at this time by moving the joystick around

  4. Your PanTiltZoom Application is now ready to be “split-screened” with VLC… we just have to get VLC setup

RTSP information regarding VLC
RTSP information regarding VLC

VLC Setup

Just like the PanTiltZoom application, your smartphone must be on the same network as the PTZOptics cameras. Once connected to the same network you can bring live video preview into your smartphone from your cameras. If you are interested in tweaking the RTSP streaming settings to reduce latency, the PTZOptics team has this guide that you can reference. This guide references best practices for optimizing your RTSP streaming settings to achieve the highest quality and lowest latency for your video preview.

  1. Open the VLC application

  2. Click the three (3) bars in the top left of the application

    1. Click “Stream”

    2. For “Enter network address: e.g…” you’ll need to supply the string used to access the RTSP feed of your PTZOptics camera

      1. HD RTSP Stream – rtsp://<camera ip>:554/1

      2. SD RTSP Stream – rtsp://<camera ip>:554/2

      3. Example

        1. Camera IP =

        2. RTSP = rtsp://

      4. Click the “Paper Airplane” icon to start streaming a live preview  Note: please be aware there may be latency experienced in viewing the stream via VLC

  3. VLC is now setup to be “split-screened” with the PanTiltZoom application

Split-Screen Setup

Android phones offer a split-screen setting that is used for this project. You will be able to select VLC as your main split-screen source and add the PanTiltZoom app so that you can use both applications at the same time.

split screen VLC and PTZ
split screen VLC and PTZ

Note: I did not need to enable “split-screen” or multi-window mode on my Android device however with different versions you may need to enable the feature before you can proceed.

  1. Exit to the main Android screen using the “HOME” button

  2. Now use Android to show you all active applications… for me this is done by swiping up from the “HOME” button but differs depending on the manufacturer please see the example screenshot below


  1. You’ll notice each application has a small “bubble,” or circle, with its own icon at the top

    1. Push and hold the “bubble” icon above VLC until a new menu appears

    2. Select “Split-Screen” and the application will lock itself to the top of your screen

    3. Now without exiting the application selection screen, as shown above, simply click on the PanTiltZoom application to make it the second application used with “split-screen” mode.

  2. You can drag the bar in between the two (2) applications to adjust the size of each application until you find a comfortable fit

    1. Please see screen-shot example of the finished solution below