Android Question Slow Motion using CAMEX2

Miguel Antonio

New Member
Hi everyone!

I follow this example on https://www.b4x.com/android/forum/threads/slow-motion-video-recording-using-camex2.108478/ for record videos on Slow Motion, but when i run the code this error appear:

Error: (NullPointerException) java.lang.NullPointerException: Attempt to invoke virtual method 'java.util.List android.hardware.camera2.CameraConstrainedHighSpeedCaptureSession.createHighSpeedRequestList(android.hardware.camera2.CaptureRequest)' on a null object reference

getHighSpeedVideoSizesAndFPS from Xiaomi log = (ArrayList) [{sizeObject=1280x720, FPSRange=[240, 240], FPS=240, quality=720p}, {sizeObject=1280x480, FPSRange=[240, 240], FPS=240, quality=480p}, {sizeObject=1280x400, FPSRange=[240, 240], FPS=240, quality=400p}, {sizeObject=800x480, FPSRange=[240, 240], FPS=240, quality=480p}, {sizeObject=720x480, FPSRange=[240, 240], FPS=240, quality=480p}, {sizeObject=640x480, FPSRange=[240, 240], FPS=240, quality=480p}, {sizeObject=480x320, FPSRange=[240, 240], FPS=240, quality=320p}, {sizeObject=320x240, FPSRange=[240, 240], FPS=240, quality=240p}, {sizeObject=1920x1080, FPSRange=[120, 120], FPS=120, quality=1080p}, {sizeObject=480x360, FPSRange=[240, 240], FPS=240, quality=360p}]

The device supports High FPS video, it´s a Xiaomi Redmi Note 8.

I appreciate any help,

Thanks a lot!
 
Top