Screen recording using FPSStreamingCast with audio and NRSDK 1.9.3 experimental

I’ve managed to do a screen recording by following the guidance here and using FPSStreamingCast:

By default, it records video without any application or mic audio. To enable audio recording, I tried modifying this file:


by setting:
public NRVideoCapture.AudioState m_AudioState = NRVideoCapture.AudioState.ApplicationAndMicAudio;

instead of NRVideoCapture.AudioState.None which was the original value.

However, the video still records without any audio stream. Also, the Android MediaProjection permission dialog which is supposed to show up when we start recording doesn’t show up, so I’m guessing something is wrong with the audio recording part.

Do you have any ideas to enable audio recording? Thanks.

Hi, you can add the audio permission in the flowing two methods:

  • Mebubar: NRSDK-AddAudioPermission
  • Modify the manifest file:
    1. file path: /Assets/Plugins/Android/AndroidManifest.xml
    2. open the file and add this line: <uses-permission android:name="android.permission.RECORD_AUDIO" />
    3. rebuild and run your apk, the permission dialog will show up.

Hope it’s helpful for you!

It works! Thank you!