0 Members and 2 Guests are viewing this topic.
#include <SFML/System.hpp>#include <SFML/Window.hpp>#include <SFML/Graphics.hpp>#include <iostream>int main(int argc, char** argv){ sf::ContextSettings Settings; Settings.DepthBits = 24; // Request a 24 bits depth buffer Settings.StencilBits = 8; // Request a 8 bits stencil buffer // Opens window and passes in my context settings sf::Window App(sf::VideoMode(400,400,32), "Test Window", sf::Style::Close, Settings); // Prints out the Depth Bits and Stencil Bits of the Window std::cout << "DepthBits: " << App.GetSettings().DepthBits << std::endl; std::cout << "StencilBits: " << App.GetSettings().StencilBits << std::endl; while ( App.IsOpened() ) { sf::Event Event; while ( App.PollEvent(Event) ) { if (Event.Type == sf::Event::Closed) App.Close(); if (Event.Type == sf::Event::KeyPressed) App.Close(); } App.Display(); } return 0;}
DepthBits: 16StencilBits: 0