NvBufferComposite width & height problem

I have png images loaded from file into buffers and I am using NvBufferComposite to composite a series of these buffers. Everything works really well if the images are 320x240, 640x480, 64x64, 128x128.

But If I use a size like 300x300, 160x120 then there is tearing in the output. Image attached.

Can the NvBufferComposite() use arbitrary width & height, or is there some kind of restriction like word size on the values, or is there a bug in the NbBufferComposite?

The same thing happens when I use NvBufferTransform to copy the buffer.

I am using r32.3.1.

Buffer params:

cParams.colorFormat = NvBufferColorFormat_ABGR32;
	cParams.width = width;
	cParams.height = height;
	cParams.layout = NvBufferLayout_Pitch;
        cParams.payloadType = NvBufferPayload_SurfArray;

Thank you.

Calling NvBufferComposite() uses hardware engine and there is constraints in width/height alignment. Please use standard resolution to get best performance. Arbitrary resolutions may not be handled well by hardware engine, leading to tearing output.

Thank you very much for the answers. I understand that there could be alignment issues with DMA etc. I think 64x64 and 128x128 etc. are not standard resolutions and they do work. I thought the alignment would need to be multiple of 16, or 32 but I have examples where they do not work. Is there any way I can find out what these constraints are. Our product will allow end user to select their own images but I need to know how to constrain them.


Ok so the TRM details this on page 717.

What I have found is that the width needs to be a multiple of 64 pixels.