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.

TDA4VM: 4k display support

Part Number: TDA4VM
Other Parts Discussed in Thread: DRA829

Hi Team,

We are trying to display the images on 4k monitor using display port on the TDA4x board using QNX OS.

For that I have made changes in \vision_apps\apps\basic_demos\app_tirtos\common\app_init.c

For 4k support I have following changes

prm.timings.width = 3840U;
prm.timings.height = 2160U;
prm.timings.hFrontPorch = 88U;
prm.timings.hBackPorch = 148U;
prm.timings.hSyncLen = 44U;
prm.timings.vFrontPorch = 4U;
prm.timings.vBackPorch = 36U;
prm.timings.vSyncLen = 5U;
prm.timings.pixelClock = 148500000ULL;

Whether I need to change any other parameter to support 4k display .

Note :While executing the application, tivxDisplayNode does not throw any errors. but not be able to see images on the screen.

Please tell me what I need to check further .


On the TDA4x board, we have used the following packages listed below.

QNX SDP7.1 BSP for Texas instrument Jacinto 7 J721E (DRA829/TDA4xM )
QNX Software Development platform 7.1
ti-processor-sdk-qnx_j721e_07_03_00.tar.gz
ti-processor-sdk-rtos-j721e-evm-07_03_00_07.tar.gz

  • Does the pixel clock look correct for 4K display?

    prm.timings.pixelClock = 148500000ULL;

    Regards,

    Brijesh

  • Hi Brijesh,

    I don't know how to calculate  correct pixel clock for 4k . Where to get it .

    Regards

    Pushparaj.M

  • What is the fps at which you are running display? 

    Regards,

    Brijesh

  • According to your timing, it would require around 272.5MHz pixel clock.

    Regards,

    Brijesh

  • When I connect the TDAVX board with the 4K monitor, Getting the following message on the screen

    The current input timing is not supported by the monitor display. Please change your input timing to 3840*2160, 60 Hz. or any other monitor listed timing as per the monitor specifications.

    For 60 fps . What is the pixel clock frequency and how to calculate it. 

  • (3840U + 88 + 148 + 44) x (2160 + 4 + 36 + 5) x fps.


    Please use above equation. 

    Rgds,

    Brijesh

  • Hi Brijesh

    We are trying to display grey scale input image resolution (2592X1944) on the 4K monitor . but we are able to see the images on the screen . The image appears stretched (not displayed as an original image).

    Please find display params structure of type tivx_display_params_t as passing to tivxDisplayNode as given below

    display_params.outWidth = 3840; 

    display_params.outHeight = 2160;

    display_params.posX = 0;

    display_params.posY = 0; 

    tivxDisplayNode (vx_graph graph, vx_user_data_object configuration, vx_image image);

    Kindly help us to solve this issue

  • Hi,

    We are trying to display grey scale input image resolution (2592X1944) on the 4K monitor . but we are able to see the images on the screen . The image appears stretched (not displayed as an original image).

    This is expected, isn't it? 

    The input image resolution is 2592x1944 and you are trying to display it on 3840x2160. DSS will scale this input resolution to full resolution. 

    One possible way to solve this issue is by disabling scalar. Which usecase are you using? In the usecase, can you please set the tarWidth/tarHeight in the display params to same as image resolution?

    Regards,

    Brijesh

  • How to disable the scalar ?  

    My usecase
    To display input image ( 2592x1944 ) on 4k monitor without any scaling

    for that
    I will set the tarWidth/tarHeight in the display params to same as image resolution.But what about x and y coordinate for starting point

  • what do you mean starting point? 

    This parameters startx and starty can be used to position input frame (2592x1944) onto bigger output frame (3840x2160). 

  • starting point

    Using below configuration parameter in app and driver .  Image get stretched  on 4k monitor

    In application

    display_params.posX = 0;

    display_params.posY = 0; 

    display_params.outWidth = 2592

    display_params.outHeight = 1944;

    Driver

    prm.timings.width = 3840U;
    prm.timings.height = 2160U;

    \vision_apps\apps\basic_demos\app_tirtos\common\app_init.c

    prm.timings.pixelClock = (3840U + 88 + 148 + 44) x (2160 + 4 + 36 + 5) x 30  fps .

    How to disable scaling to avoid stretching ?

     

  • display_params.posX = 0;

    display_params.posY = 0; 

    display_params.outWidth = 2592

    display_params.outHeight = 1944;

    Are you sure that above parameters are being used for the display that you are using? This is because node uses above config to enable scalar.

    Regards,

    brijesh

  • With the above configuration, How to disable scalar to get proper input image without getting stretched on the display  

  • There is no control to the application for scalar. It is controlled using input and output frame size, so please make sure that both the sizes are equal to disable scalar.

  • Is there a  way to change  input image (2592 *1944 ) to  (3840*1944) output frame size . 

    Can i make both sizes equal by adding extra white pixel to input image(using tiovx api)?

    Can you suggest how to do it programmatically using tiovx api?

  • Is there a  way to change  input image (2592 *1944 ) to  (3840*1944) output frame size . 

    did not get it, do you mean scaling?

    Can i make both sizes equal by adding extra white pixel to input image(using tiovx api)?

    Yes, you could change DSS node to do it. there is no tiovx api for it.

    Can you suggest how to do it programmatically using tiovx api?

    no tiovx api to fill up the extra pixels, you need to change one of the node in the pipeline.

  • Can i make both sizes equal by adding extra white pixel to input image(using tiovx api)?

    Yes, you could change DSS node to do it. there is no tiovx api for it. 

    Please explain in details how to change it on DSS node .

  • Can i make both sizes equal by adding extra white pixel to input image(using tiovx api)?

    Again, there is no tiovx api.. you need to change display node for it, or the node before display node.

    Please explain in details how to change it on DSS node .

    In the display, when you get the input buffer pointer, fill the region with the white pixels, wherever you require it.. 

    You essentially require to use bigger frame and then put the image in the center of the buffer in the node before display and then in the display node, you could fill up the image with the white color...

  • Instead of white space,  Can i use text to fill the gap?
    Will this solve my problem? 
    Can i use below function for the same? 
    app_grpx_init_prms_t grpx_prms;
    appGrpxInitParamsInit(&grpx_prms, _context);
    grpx_prms.draw_callback = app_draw_graphics;
    appGrpxInit(&grpx_prms);
  • Well grpx can be used to fill the image with the known value, but this will be overhead. Instead i would suggest to figure out why image is stretched. 

    Which display pipeline/vision apps usecase are you using? Can you share the changes you did in the usecase? 

  • In the case of a 2K monitor, we are not facing this issue ( input image resolution less than 2K monitor size resolution) . Images display properly on the monitor.

    But in the case of a 4K monitor, we are facing this issue ( image not straight got stretched).

    We are using Visions_app (a single-camera image display pipeline approach).

  • For single camera example,

    1, make sure to set output size in below two variables, same the viss output image size, in app_init API..  

    memset(&obj->display_params, 0, sizeof(tivx_display_params_t));
    obj->display_params.opMode = TIVX_KERNEL_DISPLAY_ZERO_BUFFER_COPY_MODE;
    obj->display_params.pipeId = 2;
    obj->display_params.outHeight = 1080;
    obj->display_params.outWidth = 1920;
    obj->display_params.posX = 0;
    obj->display_params.posY = 0;

    2, make sure to disable LDC node

    3, make sure to disable scalar (obj->scaler_enable to false) in the app_create_graph API.

    4, also make sure to set position as 0 in the same function.

    obj->display_params.posX = (1920U - obj->display_params.outWidth)/2;
    obj->display_params.posY = (1080U - obj->display_params.outHeight)/2;

  • 1. In point#4 you have mentioned to set position as 0 but in next line you are assigning different values. 

    obj->display_params.posX = (1920U - obj->display_params.outWidth)/2;
    obj->display_params.posY = (1080U - obj->display_params.outHeight)/2;

    May I know the purpose for this above command?  I didn't understand.

    2. As per previous post you have mentioned  that input image size and display size should be same. but that's not the case,  as per the above code we 're displaying image at the center of display screen.

    3. As per knowledge image got stretched due to aspect ratio. Is this aspect ratio issue taken care of?

  • 1. In point#4 you have mentioned to set position as 0 but in next line you are assigning different values. 

    obj->display_params.posX = (1920U - obj->display_params.outWidth)/2;
    obj->display_params.posY = (1080U - obj->display_params.outHeight)/2;

    This is place where i asked you to change the position..

    2. As per previous post you have mentioned  that input image size and display size should be same. but that's not the case,  as per the above code we 're displaying image at the center of display screen.

    That's the output size of the pipeline.. You could set it in obj->display_params.outHeight/outWidth parameters.

    3. As per knowledge image got stretched due to aspect ratio. Is this aspect ratio issue taken care of?

    Check this API appIssGetResizeParams and comment out if not required..