This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

dm365 IPNC encoder configuration changes without shutting down av_server and restarting the avserver, creates problems in AEWB.

Hi all,

Currently I am having problem with dm365 IPNC software from appro 1.5 ver.

I do not want to restart the application, every time I change the encoder parameters.  So I changed the av_server application, to chage the encoder configurations like encoder resolutions, frame rate, key frame interval on the fly. 

I changed some static variables in the alg_aewb_control.c to global and reinitiaze to default values(which works 95%).

But some times( 5%),  I get darker picture from the encoder.

Is there any list of static variables, that I have to Initialize to make the appro AEWB work with out restarting the whole application?

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

  • Hi,

     

    Is your issue resolved, can you give more details on your issue?

     

    Also, version 2.0 of the code is released, please use that for further tests.

     

    Regards,

     

    Raghu

     

  • Hi,

    There are lot of static variables in auto white balance and auto exposure algorithms.  Because of these I am not able to restart the enocder without shuting down the whole av_server.out.

    I tried to find every single static varible and reinitialitzed.and then the encoder was delvering normal frames.  For example the static varibles like "prevValue" are made gloabal and reinitialized.

    But some times if I restart the encoder  it delevers darker frames.

    I think there are some more staic varibles inside the appro library (closed source) which has to be reinitialized to fix this problem.

    Are you guys aware of any function call to make the appro Auto white balnce work properly with out restarting the av_server.out..

    I do not think there is fix for this in appro 2.0 version, as the code looks similar in version 2.0.

     

    The parts of the source code which is having the static variables are listed below.

     

     

    short ALG_aewbSetSensorGain(int gain) {

    static int prevValue = -1;

    int gain32;

    if(prevValue==gain) return 0;

    #ifdef ALG_AEWB_DEBUG OSA_printf(" AEWB: Sensor Gain = %d\n", gain);

    #endif

    prevValue = gain;

    gain32 = (int)gain*1;

    if((gALG_aewbObj.vsEnable)||(gALG_aewbObj.vnfDemoCfg))

         gain32 = (gain*ENABLE_COMPENSATION)/100;

    DRV_imgsSetAgain(gain32, 0);

    return 0;

    }

     

    short ALG_aewbSetSensorExposure(int shutter)

    {

    static int prevValue = -1;

    int shutter32;

    ....

    ...

    ...

     

    If I can restart the encoder without shutting down, then I can save more memory. Appro is using the cyclic shared memory (23MB). I can completly avoid that. The performance of the application also improves as there are less copies involved.

    If I take encoded buffers from the cyclic buffer provided by appro, the arm load of our application goes up to 25% for triple encoding . The av_server.out  consumes 30%.

    The rest 50% is only left for our streaming application which is very less.

    This is the reason I do not want to take the encoded buffer from shared memory.

    I even used DMA to copy the encoded buffer, But the performance remains same.

     

     

     

     

     

  • I checked on the version 2.0. The problem remains the same.

  • Hi Mahendra Kumar,

                      I am working one IP CAM project with Appro 3.0 SDK. In which I need to optimize the Av Server restart time by configuring resolution frame rate and bit rate dynamically.

    Currently the SDK supports the dynamic configuration for Frame rate and bit rate.

    From your queries I understood you have worked on the similar  dynamic resolution change. Can you please share the Logic which you have implemented for dynamic resolution change.

    I have tried to modify the Av server global variables for width height parameters, but it doesn't helped me.

    Thanks,

    Jithin Krishnan.K