Listing Program
#include"ExampleApplication.h"
classBelajarOgre1 : publicExampleApplication {
public:
BelajarOgre1(){
}
~B...
BelajarOgre1 app;
try {
app.go();
} catch (Exception e) {
#if OGRE_PLATFORM == OGRE_PLATFORM_WIN32
MessageBox(NULL,e.what(...
Logika program
Pada pertemuan minggu lalu kita akan menambahkan partikel asap dan angin pada objek ogre. Dengan
cara menam...
Output
LAPORAN AKHIR PRAKTIKUM
Mata Praktikum : GRAFKOM 2
Kelas : 3IA12
Praktikum ke- : 4
Tanggal :
Materi :
NPM : 57411634
Nama ...
Upcoming SlideShare
Loading in …5
×

La 4 grafik komputer

407 views

Published on

Laporan Akhir Praktikum LAB TI Gunadarma

Published in: Education, Technology, Business
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
407
On SlideShare
0
From Embeds
0
Number of Embeds
4
Actions
Shares
0
Downloads
2
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

La 4 grafik komputer

  1. 1. Listing Program #include"ExampleApplication.h" classBelajarOgre1 : publicExampleApplication { public: BelajarOgre1(){ } ~BelajarOgre1(){ } protected: voidcreateScene(void){ //langit mSceneMgr->setSkyBox(true, "Examples/StormySkyBox"); //mSceneMgr utk manage semuasemuaygtampilpd screen mSceneMgr->setAmbientLight(ColourValue(1,1,1)); //Entity ad objekygbsdirenderdiscene Entity *ent1 = mSceneMgr->createEntity("ujicoba","Cube.001.mesh"); SceneNode *node1 = mSceneMgr->getRootSceneNode()->createChildSceneNode("RobotNode"); //attach entity kescenenodeutberilokasi render robot node1->attachObject(ent1); node1->scale(30,30,30); node1->setDirection(0,0,100); //partikelangin ParticleSystem* pSys2 = mSceneMgr- >createParticleSystem("aureola","Examples/Aureola"); SceneNode *mpn2 = mSceneMgr->getRootSceneNode()->createChildSceneNode("aureolaTes"); mpn2->attachObject(pSys2); pSys2->setDefaultHeight(400); pSys2->setDefaultWidth(400); //partikelasap ParticleSystem* pSys1 = mSceneMgr->createParticleSystem("Smoke","Examples/Smoke"); SceneNode *mpn = mSceneMgr->getRootSceneNode()- >createChildSceneNode("smokeTes",Vector3(0,100,500)); mpn->attachObject(pSys1); pSys1->setDefaultHeight(150); pSys1->setDefaultWidth(80); } }; #if OGRE_PLATFORM == OGRE_PLATFORM_WIN32 #define WIN32_LEAN_AND_MEAN #include"windows.h" INT WINAPI WinMain(HINSTANCE hInst, HINSTANCE, LPSTR strCmdLine, INT) #else int main(int argc, char **argv) #endif { //bikinobjekaplikasi
  2. 2. BelajarOgre1 app; try { app.go(); } catch (Exception e) { #if OGRE_PLATFORM == OGRE_PLATFORM_WIN32 MessageBox(NULL,e.what(),"Terjadi Error!",MB_OK | MB_ICONERROR |MB_TASKMODAL); #else fprintf(stderr,"Terjadi Error = %sn",e.what()); #endif } return 0; }
  3. 3. Logika program Pada pertemuan minggu lalu kita akan menambahkan partikel asap dan angin pada objek ogre. Dengan cara menambahkan kodingan berikut ini : //partikelangin ParticleSystem* pSys2 = mSceneMgr- >createParticleSystem("aureola","Examples/Aureola"); SceneNode *mpn2 = mSceneMgr->getRootSceneNode()->createChildSceneNode("aureolaTes"); mpn2->attachObject(pSys2); pSys2->setDefaultHeight(400); pSys2->setDefaultWidth(400); //partikelasap ParticleSystem* pSys1 = mSceneMgr->createParticleSystem("Smoke","Examples/Smoke"); SceneNode *mpn = mSceneMgr->getRootSceneNode()- >createChildSceneNode("smokeTes",Vector3(0,100,500)); mpn->attachObject(pSys1); pSys1->setDefaultHeight(150); pSys1->setDefaultWidth(80); } };
  4. 4. Output
  5. 5. LAPORAN AKHIR PRAKTIKUM Mata Praktikum : GRAFKOM 2 Kelas : 3IA12 Praktikum ke- : 4 Tanggal : Materi : NPM : 57411634 Nama : Yudo Rahadyatmo Ketua Asisten : Johannes Praskogery P. Paraf Asisten : Nama Asisten : Jumlah Lembar : 5 LABORATORIUM INFORMATIKA UNIVERSITAS GUNADARMA 2014

×