Can the recording process be optimized?
When recording video, I noticed that it takes about 2 seconds for the recording to go from the STARTED state to the RECORDING state, but the actual recording only starts from the RECORDING state. This explains why the actual recording time seems 2 seconds shorter than I mentioned earlier.
Considering real-world usage scenarios, users usually start moving their phones from the moment they tap to record, but the actual recording only begins after 2 seconds. Although I added a loading indicator to the button, the user experience is still quite poor. Could this step be optimized?
2025-12-01 14:08:02.840 D status=STARTED
2025-12-01 14:08:04.993 D status=RECORDING
2025-12-01 14:08:07.135 D status=STOPPED
The record need start with a keyframe and the library already request for it to the encoder to reduce the time. I don't know if I can optimize it more or not. I will check it.
Hello,
I optimized it here: https://github.com/pedroSG94/RootEncoder/commit/5dc1671309ba5e39cc689010e9b8e537d40eb95e
The time was reduced from 2000ms to 400ms aprox. You can test using the demo app with the master branch