Revert "OMXEncoder: add calls to OMX_Init()&OMX_Deinit() (#19905)"

This reverts commit 8f00813089.
pull/19946/head
Adeeb Shihadeh 4 years ago
parent c95c4df51d
commit ea74f558f4
  1. 2
      selfdrive/loggerd/omx_encoder.cc

@ -184,7 +184,6 @@ OmxEncoder::OmxEncoder(const char* filename, int width, int height, int fps, int
this->v_ptr2 = (uint8_t *)malloc(this->width*this->height/4); this->v_ptr2 = (uint8_t *)malloc(this->width*this->height/4);
} }
OMX_CHECK(OMX_Init());
auto component = (OMX_STRING)(h265 ? "OMX.qcom.video.encoder.hevc" : "OMX.qcom.video.encoder.avc"); auto component = (OMX_STRING)(h265 ? "OMX.qcom.video.encoder.hevc" : "OMX.qcom.video.encoder.avc");
int err = OMX_GetHandle(&this->handle, component, this, &omx_callbacks); int err = OMX_GetHandle(&this->handle, component, this, &omx_callbacks);
if (err != OMX_ErrorNone) { if (err != OMX_ErrorNone) {
@ -604,7 +603,6 @@ OmxEncoder::~OmxEncoder() {
wait_for_state(OMX_StateLoaded); wait_for_state(OMX_StateLoaded);
OMX_CHECK(OMX_FreeHandle(this->handle)); OMX_CHECK(OMX_FreeHandle(this->handle));
OMX_CHECK(OMX_Deinit());
while (queue_try_pop(&this->free_in)); while (queue_try_pop(&this->free_in));
while (queue_try_pop(&this->done_out)); while (queue_try_pop(&this->done_out));

Loading…
Cancel
Save