MCPcopy Create free account
hub / github.com/carlonluca/pot / loadWithOmx

Method loadWithOmx

piomxtextures_src/glwidget.cpp:368–386  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

366}
367
368void GLWidget::loadWithOmx()
369{
370 LOG_VERBOSE(LOG_TAG, "Loading with OMX.");
371 QPlatformNativeInterface* nativeInterface = QGuiApplicationPrivate::platformIntegration()->nativeInterface();
372 Q_ASSERT(nativeInterface);
373 EGLDisplay eglDisplay = nativeInterface->nativeResourceForIntegration("egldisplay");
374 EGLContext eglContext = nativeInterface->nativeResourceForContext("eglcontext", QOpenGLContext::currentContext());
375
376 for (int i = 5; i < 6; i++) {
377 QString fileAbsPath = QString("%1%2.jpg").arg(prefix).arg(i);
378 OpenMAXILTextureLoader* omTextureLoader = OpenMAXILTextureLoader::intance();
379 if (!omTextureLoader->loadTextureFromImage(fileAbsPath, eglDisplay, eglContext, textures[i])) {
380 LOG_ERROR(LOG_TAG, "Failed to load image.");
381 }
382 else {
383 LOG_INFORMATION(LOG_TAG, "Image %s successfully decoded and loaded.", qPrintable(fileAbsPath));
384 }
385 }
386}

Callers

nothing calls this directly

Calls 1

loadTextureFromImageMethod · 0.80

Tested by

no test coverage detected