Imagination PowerVR SDK Blog

malloc error in powerVR SDK


#1

Hi,
I’m trying to switch a png sized 4096*4096 to pvr via the function ‘Transcode’ in powerVR SDK. when I passed ePVRTCBest to param named ‘const ECompressorQuality eQuality’, I got a malloc error as follows:

PC: Panic:pImgStats->RegRow[row] failed malloc
MAC: malloc: *** mach_vm_map(size=xxxx) failed(error code = 3)

Is there any way to avoid this error?
Thank you very much.


#2

Hi Xiao,

how much RAM do you have?
Do you use a 64 bit OS?

Compressing 4kx4k textures on max settings can take 8GB+ RAM.

bests,
Marton


#3

Thanks for you replying, I’m running a 32 bit program on 64 bit OS with 32G RAM. Should I transform the program to 64 bit?
Thank you very much.


#4

Hi Xiao,

Yes, that should solve the problem.

bests,
Marton


#5

Hi Marton,
I would have a try, what a big project! Thanks