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.

CMEM

Hi, everyone!
I have a question about CMEM!

In the file cmem.c, there is a function:CMEM_alloc. It can allocate the memory depends on params->type.

In the file app.c:

I can find that  the important function is encodeDecodeFile to allocate the memeory in main.

Why don't we use the CMEM_alloc in  app.c instead of using a new function??

And is there any  differences between them?

  • Hello!

     

    If you mean Memory_alloc() as the other function:

    Codec Engine depends on CMEM, as it builds upon its functionality: the Codec Engine Memory module is a layer on top CMEM, internally calling CMEM_* functions (Memory_alloc calling CMEM_alloc, etc, etc).

    (you can check this in its source: <codec engine dir>/packages/ti/sdo/ce/osal/linux/Memory_cmem.c for linux, .../osal/wince for WindowsCE)