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.

DM368 dual H264+MJPEG resolution problem!

HI,

    I use appro DM368 ipnc version 2.5(20101214).

    After I changed the dual stream (H264+MJPEG)  resolution to H264 D1, & MJPEG 1600x1200. 

The MJPEG image has a color block like this:

 

but the H264 stream is right,

 

And I measure the width of FIRST MJPEG pic, the width of left part is 1080.

Then some other resolutions were tried, the width also restricted by 1080.

Please help & give me some advise

Thank you very much!!

  • you need to focus on 2 thins:

    - the order of stream: each format will be support by 2 streams. one is main and the another is sub stream. In Normally, the main stream should have higher solution than the sub stream. In dual stream case,  if you choose MJPG as a higher resolution stream, so you should set it in main stream that support for MJPG and H264 in sub stream of it.

    - Before streaming, the image should go through encode, resizing, ... for the support limit of these engines, we need to divide the image by a half and do the processing separately.    

  • I resolve this problem :

    the first time as I posted , I use 2 captureStream, D1 & 1600x1200,  and 2 encodeStream seperately match the two capture streams.

    Now I changed to 1 capturestream, only 1600, then everything is ok.

     

    but I don't know why? may be the memory is not enought? I checked the settings ,it use MEM_LAYOUT6, there are 4M byte ram and 4M cache.

    Can anyone explain this?

    Thank you!

  • sorry , i hadn't seen your reply, I'll change the order and try

  • There are still some problems.

    First I put the higher resolution stream ahead , that is

    Capture Stream 0 = 1600x1200

    Capture Stream 1 = D1

    Encode Stream 0 ---->  Capture Stream 1

    Encode Stream 1 ----> Capture Stream 0

    so I don't have to change the command line  "./av_server.out %s D1_2MP H264 %d %s %s MJPEG %d MENUOFF &\n"

    The result is good except the osd label “stream1” & "stream2" exchanged. I think this is because the cross of encode stream and capture stream.

    Then I use "./av_server.out %s D1_2MP MJPEG %d H264 %d %s %s MENUOFF &\n"

     

    Capture Stream 0 = 1600x1200

    Capture Stream 1 = D1

    Encode Stream 0 ---->  Capture Stream 0

    Encode Stream 1 ----> Capture Stream 1

     

    I receive this error 

    Error:MEM_MNG_WRITE_FAIL

    encode error -1 at 184 , the function is MemMng_Video_Write();

    give me some hint?

     

  • HI,

     

    for this you need to check in mem_mng.c, what is the exact MEM_Layout it is getting mapped to, like MJPEG+H264 usecase,

     

    PLease add memory size for cache_size and mem_size in this file based on the usecase.

    MEM_MNG_WRITE_FAIL is writtern only if the streaming memory is not assigned

     

    Regards,

     

    Raghu


  • Raghu, 

    I checked mem_mng.c and found that after I changed the stream order, IPNC use H264 stream2 instead of 1

    A new MEM_LAYOUT added and problem resolved.

    Thanks !!

     

          But now it seems that the webpage and the stream does not match.  It's likely that I have to add a new stream type to BOA server...

          By the way, I put some  printf("xxxx") in boa sources ,for example in  iface.c , but I can not see this line in the serial terminal?(Use web browser and change settings)

          How can I debug BOA and other web related codes? 

  • Hi,

    Please check web translate .c in boa source code for default interface and avServerUI.c for the live interface of the setting on webpage. Because you have changed the order of stream, you need to change the way UI will be shown also to make them properly.

    Hope this can help!

  • bioz,

           Really appreciate your help!

          I will have a try