A Simple Program That Makes Random Maze Using Opengl Api With C++ Language. This Program Was Made On My Current Computer Graphics Courses Finish In 2017. View Release Here
Thanks : Mr.Yonathan Ferry Hendrawan
-
Kruskal’s algorithm is a method for producing a minimal spanning tree from a weighted graph. The algorithm I’ll cover here is actually a randomized version of Kruskal’s; the original works something like this:
- Throw all of the edges in the graph into a big burlap sack. (Or, you know, a set or something.)
- Pull out the edge with the lowest weight. If the edge connects two disjoint trees, join the trees. Otherwise, throw that edge away.
- Repeat until there are no more edges left. Learn More Here
-
Maze Feature
- Generate new layout "C"
- Change Object player "P"
- Change view "V" (2 Dimension, 3 Dimension, Fps)
- Move the player Up:"W" | Down:"S" | Left:"A" | Right:"D"
- Rotate maze -YAxis:"J" | -XAxis:"K" | XAxis:"I" | XAxis:"L" (Only In 3dimension)
- Action For Key --> 1,2,3,4,5
- Key 1 -> Active/Deactive Ambient Light
- Key 2 -> Active/Deactive Diffuse Light
- Key 3 -> Active/Deactive Specular Light
- Key 4 -> Change The Day (Background)
- Key 5 -> Change Wall Transparant or Not
- Change Maze size , "+" to Increase and "-" to Decrease
- Arroy Key To Walk Inside Maze While in Fps Mode (ArrowKeyUP , ArrowKeyDOWN , ArrowKeyLEFT, ArrowKeyRIGHT)
- Change Nim (ID) Rotation Using Mouse Click (Left,Center,Right)
- Space to Run/Stop another one player.
-
Windows
- Required ... To Run This Program In Windows You Can Use The Codeblock IDE (Get Here) After That Follow The Instructions The Installation With The Addition Of The Opengl Api (Learn Here).
- How To Run :
- Create A New Project Glut/Opengl Project - Just Copy Paste The Code In Your main.Cpp Has Been Made - Build & Run
-
Linux
- You Can Use The Codeblock For Linux As Well.
- You Can Execute Your Code Using A Text Editor That You Love. Like Atoms, Sublime,Geany Or Another.
Before Executing, You Must Install Some Dependenci Of Glut On Linux. What You Need To Do Is (Installation Via Terminal):
- Install The Compiler And Necessary Tools.A Fairly Complete Compiler You Can Use G++, How to :
sudo apt-get install g++ cmake
- Install Freeglut :
sudo apt-get install freeglut3 freeglut3-dev
- Run Using Terminal :
gcc -o excecutebin filename.cpp -lglut -lGL -lm -lGLU -lstdc++
- V-1.0
- In This Version, The Object The Player Can Still Penetrate The Wall
- Object Player Running (Right, Left, Bottom, Top) With Magnitude 0.1.
- The Shape Of The Maze Randomed By Using Button C & Player Can Walk A = Left, S = Down, D = To, W = Up
- Still 2 Dimensional Maze Form
- V-2.0
- Object cant penetrate the wall
- Have two object player (cube and cone)
- Have 2 different view, 2d and 3d
- When 3dviewmode, maze can rotation by I,J,K,L
- Nim rotation can change by mouse click (left,center,right)
- Change maze size using "+" to increase and "-" to decrease
- V-3.0
- Have 3 different view, 2d, 3d, Fps
- Can walk inside the maze using arrowKey when fps viewmode
- Active / Deactive 3 Light usign 1,2,3 Key
- Tranparant Wall usign the 5 Key
- Day or Night usign the 4 key
- Spaace to Run/Stop another one player.
Copyright (c) 2017 Sofian Eka Sandra
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so