Skip to content

Commit

Permalink
disable hidden cursor on fullscreen mode
Browse files Browse the repository at this point in the history
uncomment 'F' button to switch screen mode
make the far clipping plane smaller
revert camera mouse axis
make quraans models smaller
update exe
update readme : add 'F' button
  • Loading branch information
Abdalrahman-Alhamod committed Mar 1, 2024
1 parent 45676a7 commit a5129a6
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 7 deletions.
Binary file modified Al_Aqsa_Mosque/Al_Aqsa_Mosque.exe
Binary file not shown.
4 changes: 2 additions & 2 deletions Al_Aqsa_Mosque/src/Camera.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -470,10 +470,10 @@ void Camera::decodeMouse(int mouseX, int mouseY, bool isLeftClicked, bool isRigh
if (isLeftClicked)
{
// Rotate around Y-axis based on horizontal mouse movement
Camera::RotateY(-deltaX * sensitivity);
Camera::RotateY(deltaX * sensitivity);

// Rotate around X-axis based on vertical mouse movement
Camera::RotateX(-deltaY * sensitivity);
Camera::RotateX(deltaY * sensitivity);
}

// If the right mouse button is pressed, reset camera orientation
Expand Down
2 changes: 1 addition & 1 deletion Al_Aqsa_Mosque/src/EnvDrawer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -357,7 +357,7 @@ void EnvDrawer::drawBird(const Point& position, const float size) {
}

void EnvDrawer::drawQuraan(const Point& position, const float size) {
drawModel(quraanModel, position, size, 0.01);
drawModel(quraanModel, position, size, 0.005);
}

void EnvDrawer::drawLand(const Point points[4], const int count, const int textureID) {
Expand Down
8 changes: 4 additions & 4 deletions Al_Aqsa_Mosque/src/Source.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ GLvoid ReSizeGLScene(GLsizei width, GLsizei height) // Resize And Initialize Th
glLoadIdentity(); // Reset The Projection Matrix

// Calculate The Aspect Ratio Of The Window
gluPerspective(45.0f, (GLfloat)width / (GLfloat)height, 0.1f, 10000.0f);
gluPerspective(45.0f, (GLfloat)width / (GLfloat)height, 0.1f, 100.0f);

glMatrixMode(GL_MODELVIEW); // Select The Modelview Matrix
glLoadIdentity(); // Reset The Modelview Matrix
Expand Down Expand Up @@ -574,7 +574,7 @@ bool SwitchToFullScreen()
if (ChangeDisplaySettings(&dmScreenSettings, CDS_FULLSCREEN) == DISP_CHANGE_SUCCESSFUL)
{
// Hide the cursor
ShowCursor(FALSE);
// ShowCursor(FALSE);

// Set window styles for full-screen mode
SetWindowLong(hWnd, GWL_STYLE, WS_POPUP);
Expand Down Expand Up @@ -891,10 +891,10 @@ LRESULT CALLBACK WndProc(HWND hWnd, // Handle For This Window
keys[wParam] = TRUE; // If So, Mark It As TRUE

// Check if the 'F' key is pressed to toggle full-screen mode
/*if (keys['F'])
if (keys['F'])
{
ToggleFullscreen();
}*/
}

if (keys['C'])
{
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ Build and run using your preferred C++ compiler
- 'CTRL' + 'Num 0': Disable/Enable Sun Movement ☀️
- 'CTRL' + 'Num 1' -> 'Num6': Adjust Time Speed ⏰
- '1' -> '6': Disable/Enable Lighting in light pillars when sun movement is disabled 💡
- 'F': Switch between windowed and fullscreen mode 🖥️
- 'C': Switch between camera modes ( Free - FPS - TPS ) 🎥
- 'M': Mute/Unmute Sounds 🔇🔊
- '+' and '-' Keys: Zoom in and out. 🔍🔎
Expand Down

0 comments on commit a5129a6

Please sign in to comment.