LibArgus with freeglut not woking

I am trying to view the output from libargus using freeglut.
For this i modified oneshot sample and obtained YUV output from IFrame using IImageNative buffer and then NVBuffer.
Converted this YUV buffer to RGB buffer.
This buffer is trying to be displayed using OpenGL (using texture) and freeglut.

But after calling initglut(), libargus APIs are crashing after CameraProvider.
Crashing at CaptureSession or CaptureSession Interface.

So please help, how to integrate libArgus to a freeglut application.

There’s a openGL sample code that for your reference. (tegra_multimedia_api/argsu/samples/openglBox/)

Thanks Shane,

I have checked this sample. But OpenGL Box is using OpenGLES and EGL for rendering and windowing system.

I already have a glut application using OpenGL for displaying. I need to integrate the libargus code to the existing application.

I need only a capturing system using libarus.

From the samples, all the ibargus codes are depending EGL.
So is there any way to avoid the dependency of libargus with EGL and get the capturing part alone.

Hi Sijo,

Could you send your source code in private message to me?

Hi WayneWWW/ShaneCCC,

Sorry for the late response.

I was trying to build the code using a makefile and run from a folder outside tegra_multimedia_api folder.
Build is success. But segmentation fault was coming.

As of now I have solved the problem by placing code as another sample in the tegra_multimedia_api/argus/samples/ folder.

Modifications done are

  • Modified the CMakeList.txt file in tegra_multimedia_api/argus/ folder.
  • Created CMakeList.txt (modified from CMakeList.txt of oneShot)

If i am build using the CMakeList.txt, the code is built successfully and runs without any error.

But I want to make that code as standalone application which should be build using makefile and run from a folder other than tegra_multimedia_api folder.
How to remove the dependency with the tegra_multimedia_api folder structure?

Please help.

Hi Sijo,

Please take 09 or 10 MMAPI samples as your reference. These examples use argus and have their own makefile.

Hi Sijo, are u able to get glut working with libargus?