git-svn-id: svn://db.shs.com.ru/libs@47 a8b55f48-bf90-11e4-a774-851b48703e85

This commit is contained in:
2015-11-26 11:53:29 +00:00
parent 2ace72ff47
commit 4cbcbb5174
26 changed files with 346 additions and 105 deletions

View File

@@ -245,9 +245,8 @@ GLObjectBase * loadFrom3DSFile(const QString & filepath, double scale) {
globject_cast<Light * >(co)->direction = (pos.toQVector3D() - co->pos()).normalized();
stream.readRawData((char * )&fl1, sizeof(float));
stream.readRawData((char * )&fl, sizeof(float));
fl1 /= 2.f; fl /= 2.f;
globject_cast<Light * >(co)->angle_spread = fl;
globject_cast<Light * >(co)->angle_decay_exp = (fl - fl1) / fl * 16.;
globject_cast<Light * >(co)->angle_start = fl1;
globject_cast<Light * >(co)->angle_end = fl;
//qDebug() << "spotlight" << globject_cast<Light * >(co)->direction << globject_cast<Light * >(co)->angle_spread;
break;
case LOADER_3DS_CHUNK_LIGHT_OFF: