I want to receive the YUV data and do something with it. Then I followed the document and wrote such code:
mCodecManager.enabledYuvData(true);
mCodecManager.setYuvDataCallback(this);
while the MainAcitivity implements DJICodecManager.YuvDataCallback, and when clicking a button the code above would be executed.
But now as long as I click the button, the preview of the TextureView will be stuck. Even if I commented the code mCodecManager.setYuvDataCallback(this), the code mCodecManager.enabledYuvData(true) would still make the preview stuck when I click the button.
So how to deal with the problem and receive the YUV data correctly?
My devices' information:
UAV: Phantom 4 Pro
DJI SDK version: 4.5.1
Android System version: 7.0
AS version: 3.1
I want to receive the YUV data and do something with it. Then I followed the document and wrote such code:
while the MainAcitivity implements DJICodecManager.YuvDataCallback, and when clicking a button the code above would be executed.
But now as long as I click the button, the preview of the TextureView will be stuck. Even if I commented the code
mCodecManager.setYuvDataCallback(this), the codemCodecManager.enabledYuvData(true)would still make the preview stuck when I click the button.So how to deal with the problem and receive the YUV data correctly?
My devices' information:
UAV: Phantom 4 Pro
DJI SDK version: 4.5.1
Android System version: 7.0
AS version: 3.1