I tracked the error down to this section of code and it has raised a few questions:Could not draw triangles, too many primitives(2000000), maximum is 1048575.
Code: Select all
//! Returns the maximum amount of primitives (mostly vertices) which
//! the device is able to render with one drawIndexedTriangleList
//! call.
s32 CNullDriver::getMaximalPrimitiveCount()
{
return (1<<30)-1;
}
//! checks triangle count and print warning if wrong
bool CNullDriver::checkPrimitiveCount(s32 prmCount)
{
s32 m = getMaximalPrimitiveCount();
if ((prmCount-1) > m)
{
char tmp[1024];
sprintf(tmp,"Could not draw triangles, too many primitives(%d), maxium is %d.", prmCount, m);
os::Printer::log(tmp, ELL_ERROR);
return false;
}
return true;
}2. The maximum primitive count is hardcoded rather than being obtained from a query. Why?
The mesh renders fine in Max, I doubt its a hardware issue. I'm using 768MB Nvivia GTX8800 xXx, so there is enough horsepower.
Are there any hardcoded limits I can alter that will allow the loading of huge terrains (i.e. 150MB or more)?