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 h264 decoder decoded data alignment.



Hi,

I am working on h264 decoder on dm368. The decoder works fine, except one small problem - output buffer alignment. The decoder receives an output buffer with the following alignments (resolution 1920x1080):

for Y - virtp 0x4222d000, physp 84C00000

for UV - virtp 0x4246b000, physp 84E3E000

After successful decoding, the decoded data is aligned as following:

Y - virtp=0x42244418, physp=0x84c17418

UV - virtp=0x42476a18, physp=0x84e49a18

i.e there is an offset from original pointers. I assume this space is used for the decoding process.

But the decoded data now is not 32 byte aligned (0x84c17418 % 32 = 24), so it is not suitable for direct display through OSD VPBE - the image will show 24 pixels from off screen memory on the left.

Currently I am using a simple work around - I add 8 bytes to the output buffers.

for Y - virtp 0x4222d008, physp 84C00008

for UV - virtp 0x4246b008, physp 84E3E008

So decoded data is properly aligned.

Y - virtp=0x42244420, physp=0x84c17420

UV - virtp=0x42476a20, physp=0x84e49a20

I checked a few resolutions and h264 profiles/preset and it seems that the 24 byte offset is pretty consistent. So my question is -  will it always be 24 bytes, or it depends on some configuration parameter I missed? Can I rely on my work around in the future?

Thank you

  • Oops, forgot software versions:

    All from ti-dvsdk_dm368-evm_4_02_00_06:
    codec-engine_2_26_02_11
    codecs-dm365_4_02_00_00
    framework-components_2_26_00_01
    linuxutils_2_26_01_02
    xdais_6_26_01_03
    xdctools_3_16_03_36
    
    
    h264 decoder: dm365_h264dec_02_00_00_10_production