Changeset 6329 in orxonox.OLD for branches/height_map/src/world_entities
- Timestamp:
- Dec 28, 2005, 1:51:28 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/height_map/src/world_entities/terrain.cc
r6268 r6329 44 44 this->tmp_mat = new Material(); 45 45 tmp_mat->setTransparency(1.0); 46 tmp_mat->setIllum(0. 3);46 tmp_mat->setIllum(0.2); 47 47 /* tmp_mat->setDiffuse(0.55,0.4,0.2); 48 48 tmp_mat->setAmbient(0.6,0.4,0.2); … … 51 51 tmp_mat->setAmbient(1.0,1.0,1.0 ); 52 52 tmp_mat->setSpecular(1.0,1.0,1.0); 53 tmp_mat->setShininess(. 1);53 tmp_mat->setShininess(.5); 54 54 tmp_mat->setTransparency(1.0); 55 55 56 56 tmp_mat->diffuseTexture = NULL; 57 57 tmp_mat->ambientTexture = NULL; 58 //tmp_mat->specularTexture = NULL;58 tmp_mat->specularTexture = NULL; 59 59 60 const char* texture_name = "pictures/ground1.tga"; 61 tmp_mat->setDiffuseMap(texture_name); 62 tmp_mat->setAmbientMap(texture_name); 63 tmp_mat->setSpecularMap(texture_name); 60 64 // this->loadParams(root); 61 65 … … 63 67 char* colourmapName = ResourceManager::getFullName("pictures/heightmapHelloCM.bmp"); 64 68 hm = new HeightMap(heightmapName, colourmapName); 65 hm->scale(Vector(23.0f,1.7f,23.0f)); 69 hm->scale(Vector(43.0f,1.10f,43.0f)); 70 hm->shift(Vector(-1000.0,-1500.0,-1000.0)); 66 71 hm->load(); 67 72 this->model=hm; … … 217 222 glPushMatrix(); 218 223 224 219 225 /* translate */ 220 glTranslatef (this->getAbsCoor ().x - 1000, 221 this->getAbsCoor ().y - 400, 222 this->getAbsCoor ().z - 1000) ; 226 glTranslatef (this->getAbsCoor ().x , 227 this->getAbsCoor ().y , 228 this->getAbsCoor ().z) ; 229 223 230 /* rotate */ 224 225 226 227 //this->tmp_mat->select();228 229 230 231 Vector tmpRot = this->getAbsDir().getSpacialAxis(); 232 glRotatef (this->getAbsDir().getSpacialAxisAngle(), tmpRot.x, tmpRot.y, tmpRot.z ); 233 234 235 236 this->tmp_mat->select(); 237 hm->draw(); 231 238 /* if (this->objectList) 232 239 glCallList(this->objectList);
Note: See TracChangeset
for help on using the changeset viewer.