Pregunta

I'm trying to include the CImg library (CImg.h) in my project, but when I attempted to compile, I get the following error:

fatal error C1091: compiler limit: string exceeds 65535 bytes in length

I'm using Visual Studio 2010, and I have my compiler command line setting set to /Zm2000. I have no idea what to try next. Any insight is appreciated.

(And if anyone is wondering why I'm using CImg, I needed an image processing library that can calculate the gradient vectors of an image, and CImg seemed the most straight-forward to pick up)

¿Fue útil?

Solución

I had the the same problem with CImg 1.5.8 and VS 2010 (and with VS 2012 too). The solution is to roll back to CImg 1.5.7. In 1.5.8 they use different way to store font data:

const char *const data_font47x53 = " ...

instead of

const unsigned int font29x57[29*57*256/32] = {0x0,0x0 ...

in earlier versions. It looks like that's the problem.

Otros consejos

A bug report has been posted on the CImg bug tracker. Apparently, they will fix this in future releases.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top