Files
LCE-Revelations/Minecraft.Client/Common/UI/UIScene_SettingsGraphicsMenu.h
Revela 4fffcac6e7 Add VSync and fullscreen settings, fix swap chain resize and revert lighting changes
- Add VSync and Exclusive Fullscreen toggles to the graphics settings menu
- Rewrite D3D11 swap chain to use DXGI flip model with tearing support
- Fix black screen on resize by creating new swap chain instead of ResizeBuffers
- Revert conditional lighting optimization in Level::setTileAndData back to unconditional checkLight
- Revert deferred lightGaps flagging in LevelChunk::recalcHeight back to immediate lightGap calls
- Add SWF/ARC editing tools used to add new UI checkboxes
2026-03-19 11:04:49 -05:00

60 lines
1.8 KiB
C++

#pragma once
#include "UIScene.h"
#include "Common/UI/UIControl_CheckBox.h"
#include "Common/UI/UIControl_Slider.h"
class UIScene_SettingsGraphicsMenu : public UIScene
{
private:
enum EControls
{
eControl_Clouds,
eControl_BedrockFog,
eControl_CustomSkinAnim,
eControl_VSync,
eControl_ExclusiveFullscreen,
eControl_RenderDistance,
eControl_Gamma,
eControl_FOV,
eControl_InterfaceOpacity
};
UIControl_CheckBox m_checkboxClouds, m_checkboxBedrockFog, m_checkboxCustomSkinAnim, m_checkboxVSync, m_checkboxExclusiveFullscreen; // Checkboxes
UIControl_Slider m_sliderRenderDistance, m_sliderGamma, m_sliderFOV, m_sliderInterfaceOpacity; // Sliders
UI_BEGIN_MAP_ELEMENTS_AND_NAMES(UIScene)
UI_MAP_ELEMENT( m_checkboxClouds, "Clouds")
UI_MAP_ELEMENT( m_checkboxBedrockFog, "BedrockFog")
UI_MAP_ELEMENT( m_checkboxCustomSkinAnim, "CustomSkinAnim")
UI_MAP_ELEMENT( m_checkboxVSync, "VSync")
UI_MAP_ELEMENT( m_checkboxExclusiveFullscreen, "ExclusiveFullscreen")
UI_MAP_ELEMENT( m_sliderRenderDistance, "RenderDistance")
UI_MAP_ELEMENT( m_sliderGamma, "Gamma")
UI_MAP_ELEMENT(m_sliderFOV, "FOV")
UI_MAP_ELEMENT( m_sliderInterfaceOpacity, "InterfaceOpacity")
UI_END_MAP_ELEMENTS_AND_NAMES()
bool m_bNotInGame;
public:
UIScene_SettingsGraphicsMenu(int iPad, void *initData, UILayer *parentLayer);
virtual ~UIScene_SettingsGraphicsMenu();
virtual EUIScene getSceneType() { return eUIScene_SettingsGraphicsMenu;}
virtual void updateTooltips();
virtual void updateComponents();
protected:
// TODO: This should be pure virtual in this class
virtual wstring getMoviePath();
public:
// INPUT
virtual void handleInput(int iPad, int key, bool repeat, bool pressed, bool released, bool &handled);
virtual void handleSliderMove(F64 sliderId, F64 currentValue);
static int LevelToDistance(int dist);
static int DistanceToLevel(int dist);
};