Coder Social home page Coder Social logo

xpg's Introduction

Cross-Platform Gaming (XPG)

XPG is a C++ game development library with a super simple API. It has the following goals/rules:

  • no exceptions or RTTI
  • no integration with STL (optional extensions available)
  • OpenGL-centric feature set

Requirements

The project files are for the Code::Blocks IDE. See http://www.codeblocks.org/ for more information. If you want to submit other build files, submit a patch!

xpg's People

Contributors

thebuzzsaw avatar cdaragorn avatar

Stargazers

 avatar

Watchers

 avatar Ryan Muse avatar  avatar James Cloos avatar Dave Ottley avatar

xpg's Issues

Capture window move events

The window needs an event for the window being repositioned: OnMove. The callback should include details about the window's new location.

OSX implementation

OSX is scary. Unless someone else comes along, I will likely have to be the one to implement this. :(

Add fullscreen modes

There needs to be a function Window::SetFullscreen that accepts three modes: off/disable, soft (fullscreen borderless window), and hard (actual fullscreen). The window should be able to dynamically switch between the three freely.

Capture window resize events

There needs to be a callback for when the window is resized: OnResize. It should pass the window's new width and height. The event should also fire on maximize and restore. In addition, there should be explicit OnMaximize, OnMinimize, and OnRestore events.

Create a font library

We need a library to create text. This will probably work closely with the image library.

Add enum to MouseState for each button

We need to change the MouseState interface so that outside objects don't need to know how the class uses the button flags. An enum should accomplish this nicely.

Remove std::map from X11 implementation.

Currently, the X11 event loop uses an std::map to connect X11 window handles to WindowMeta data. This map needs to be replaced either by a custom map structure or by associating user data with each window instance (like Win32 is able to to). The core code is to use no STL at all.

Add window configuration classes

The function Window::Open should accept a parameter: some kind of Configuration object. This class needs to include a number of important details:

General Window Settings

  • window size
  • window position
  • window title
  • fullscreen mode (off, soft, and hard)

OpenGL Context Settings

  • OpenGL context (legacy profile, core profile, specific version, etc.)
  • color buffer size
  • depth buffer size
  • stencil buffer size
  • enable double buffer

Add joystick/gamepad polling interface

Windows and Linux (and possibly OSX) interface with game hardware by simply querying values in memory or the file system. So, there should an XPG class that reflects this low level behavior. Perhaps a function Joystick::Poll updates all the values, and the local getter functions just expose the cached data.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.