diff --git a/.gitignore b/.gitignore index bea91a67..37c9fe57 100644 --- a/.gitignore +++ b/.gitignore @@ -6,3 +6,4 @@ *.pdb Debug/ +packages/ diff --git a/RoboCat/Animation.cpp b/RoboCat/Animation.cpp new file mode 100644 index 00000000..066da4d9 --- /dev/null +++ b/RoboCat/Animation.cpp @@ -0,0 +1,115 @@ +#include"Animation.h" +#include"GraphicsBuffer.h" +#include"Sprite.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 3 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +Animation::Animation() +{ + mIsInitialized = false; + mIsLooping = false; + + mCurrentSprite = 16; + mNumSprites = 0; + mFramerate = 60; + mElapsedTime = 0.0; + mBetweenFrames = 0.0; + + mWidth = 0; + mHeight = 0; + + mpSpriteArray = nullptr; +} + +void Animation::animInit( int rows, int columns, GraphicsBuffer* buffer, bool isLooping ) +{ + mIsInitialized = true; + + mWidth = buffer->getWidth() / columns; + mHeight = buffer->getHeight() / rows; + mNumSprites = rows * columns; + mIsLooping = isLooping; + + mpSpriteArray = new Sprite[mNumSprites](); + for (int i = 0; i < rows; i++) + { + for (int j = 0; j < columns; j++) + { + mpSpriteArray[j + (i * columns)].spriteInit( mWidth, mHeight, (mWidth * j), (mHeight * i), buffer ); + } + } + + mCurrentSprite = 0; + mElapsedTime = 0.0; + mFramerate = 60; + mBetweenFrames = 1 / mFramerate; +} + +Animation::Animation(int rows, int columns, GraphicsBuffer* buffer, bool isLooping) +{ + animInit(rows, columns, buffer, isLooping); +} + +Animation::~Animation() +{ + cleanup(); +} + +void Animation::init(int numSprites, bool isInitialized, Sprite* spriteArray) +{ + mNumSprites = numSprites; + mIsInitialized = isInitialized; + mpSpriteArray = spriteArray; + + if (mIsInitialized == false) + { + mIsInitialized = true; + } +} + + +void Animation::cleanup() +{ + if (mIsInitialized == true) + { + delete [] mpSpriteArray; + mpSpriteArray = nullptr; + + mIsInitialized = false; + mIsLooping = false; + } +} + +Sprite* Animation::getCurrentSprite() +{ + return &mpSpriteArray[mCurrentSprite]; +} + +void Animation::changeFPS(int fps) +{ + mBetweenFrames = 1.0 / fps; + mFramerate = fps; +} + +void Animation::animationUpdate(float elapsedTime) +{ + mElapsedTime += elapsedTime; + + if (mElapsedTime > mBetweenFrames) + { + mElapsedTime -= mBetweenFrames; + mCurrentSprite++; + + // loop back to first sprite + if (mCurrentSprite == mNumSprites) + { + mCurrentSprite = 0; + } + } +} \ No newline at end of file diff --git a/RoboCat/Animation.h b/RoboCat/Animation.h new file mode 100644 index 00000000..ed245f72 --- /dev/null +++ b/RoboCat/Animation.h @@ -0,0 +1,53 @@ +#pragma once +#include +#include +#include"../common/DeanLib/include/Trackable.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 3 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +class Sprite; +class GraphicsBuffer; + +class Animation : public Trackable +{ +public: + Animation(); + Animation(int rows, int columns, GraphicsBuffer* buffer, bool isLooping); + ~Animation(); + + void init(int numSprites, bool isInitialized, Sprite* spriteArray); + void animInit(int rows, int columns, GraphicsBuffer* buffer, bool isLooping); + void cleanup(); + + Sprite* getCurrentSprite(); + int getSpriteWidth() { return mWidth; } + int getSpriteHeight() { return mHeight; } + + void changeFPS(int fps); + int getAnimationSpeed() { return mFramerate; } + + void setAnimate(bool initialized) { mIsInitialized = initialized; } + + void animationUpdate(float elapsedTime); + +private: + bool mIsInitialized; + bool mIsLooping; + + int mCurrentSprite; + int mNumSprites; + int mFramerate; + float mElapsedTime; + float mBetweenFrames; + + int mWidth; + int mHeight; + + Sprite* mpSpriteArray; +}; \ No newline at end of file diff --git a/RoboCat/Chapter3.vcxproj b/RoboCat/Chapter3.vcxproj index 10d69fef..bdb6f20a 100644 --- a/RoboCat/Chapter3.vcxproj +++ b/RoboCat/Chapter3.vcxproj @@ -1,6 +1,10 @@  + + Debug + ARM + Debug Win32 @@ -9,6 +13,10 @@ Debug x64 + + Profile + ARM + Profile Win32 @@ -17,6 +25,10 @@ Profile x64 + + Release + ARM + Release Win32 @@ -37,11 +49,19 @@ Application MultiByte v142 + true + + + Application + MultiByte + v142 + true Application - Unicode + MultiByte v142 + true Application @@ -49,6 +69,12 @@ MultiByte v142 + + Application + true + MultiByte + v142 + Application true @@ -61,6 +87,12 @@ MultiByte v142 + + Application + true + MultiByte + v142 + Application true @@ -72,12 +104,21 @@ + + + + + + + + + @@ -92,6 +133,21 @@ true true Bin\$(Configuration)\ + true + true + true + true + true + true + true + true + true + true + true + + + true + true true @@ -101,6 +157,10 @@ false true + + false + true + false true @@ -109,6 +169,10 @@ false true + + false + true + false true @@ -127,20 +191,69 @@ WIN32;_DEBUG;DEBUG;PROFILE;_WINDOWS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions) ProgramDatabase EnableFastChecks - ..\SDL\include;Inc;..\ - Create + ..\SDL\include;Inc;..\; + NotUsing RoboCatPCH.h - d3d11.lib;dxguid.lib;winmm.lib;comctl32.lib;%(AdditionalDependencies);Ws2_32.lib + Ws2_32.lib true true true true MachineX86 AsInvoker - %(DelayLoadDLLs) + + Console + common\allegro\debug\v141\win32\bin;common\deanlib\lib;common\allegro\debug\v141\win32\lib;Graphicslib\Debug;%(AdditionalLibraryDirectories) + + + true + + + + + + + + + + + + + MachineX86 + + + + + Level4 + Disabled + MultiThreadedDebugDLL + false + true + Fast + StreamingSIMDExtensions2 + Sync + %(AdditionalOptions) + WIN32;_DEBUG;DEBUG;PROFILE;_WINDOWS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions) + ProgramDatabase + EnableFastChecks + ..\SDL\include;Inc;..\; + NotUsing + RoboCatPCH.h + + + Ws2_32.lib + true + true + true + true + AsInvoker + + + Console + common\allegro\debug\v141\win32\bin;common\deanlib\lib;common\allegro\debug\v141\win32\lib;Graphicslib\Debug;%(AdditionalLibraryDirectories) true @@ -175,7 +288,8 @@ %(AdditionalOptions) - d3d11.lib;dxguid.lib;winmm.lib;comctl32.lib;%(AdditionalDependencies) + + Windows true true @@ -183,7 +297,8 @@ true MachineX64 AsInvoker - %(DelayLoadDLLs) + + true @@ -243,6 +358,51 @@ MachineX86 + + + Level4 + MaxSpeed + MultiThreadedDLL + false + true + true + Fast + StreamingSIMDExtensions2 + Sync + %(AdditionalOptions) + WIN32;NDEBUG;_WINDOWS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions) + ..\SDL\include;Inc;..\ + + + %(AdditionalOptions) + d3d11.lib;dxguid.lib;winmm.lib;comctl32.lib;%(AdditionalDependencies);Ws2_32.lib + true + Windows + true + true + true + true + true + AsInvoker + %(DelayLoadDLLs) + + + true + + + + + + + + + + + + + MachineX86 + + Level4 @@ -329,6 +489,51 @@ MachineX86 + + + Level4 + MaxSpeed + MultiThreadedDLL + false + true + true + Fast + StreamingSIMDExtensions2 + Sync + %(AdditionalOptions) + WIN32;NDEBUG;PROFILE;_WINDOWS;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions) + ..\SDL\include;Inc;..\ + + + %(AdditionalOptions) + d3d11.lib;dxguid.lib;winmm.lib;comctl32.lib;%(AdditionalDependencies);Ws2_32.lib + true + Windows + true + true + true + true + true + AsInvoker + %(DelayLoadDLLs) + + + true + + + + + + + + + + + + + MachineX86 + + Level4 @@ -370,7 +575,71 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -378,22 +647,50 @@ + + + + + + - + + + + + + + Create + Create RoboCatPCH.h + RoboCatPCH.h + + + + - + + + + + + + This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}. + + + + \ No newline at end of file diff --git a/RoboCat/Color.cpp b/RoboCat/Color.cpp new file mode 100644 index 00000000..7a7977c9 --- /dev/null +++ b/RoboCat/Color.cpp @@ -0,0 +1,19 @@ +#include "Color.h" + +/* +Author: Ryan Littleton, with help from the rest of the class +Class : GPR-250-71 +Assignment : Assignment 2 +*/ + +Color::Color(int r, int g, int b, int alpha) +{ + mR = r; + mG = g; + mB = b; + mAlpha = alpha; +} + +ALLEGRO_COLOR Color::getColor() { + return al_map_rgba(mR, mG, mB, mAlpha); +} diff --git a/RoboCat/Color.h b/RoboCat/Color.h new file mode 100644 index 00000000..065c798e --- /dev/null +++ b/RoboCat/Color.h @@ -0,0 +1,27 @@ +#pragma once +#include +#include +#include +#include "../common/DeanLib/include/Trackable.h" + +/* +Author: Ryan Littleton, with help from the rest of the class +Class : GPR-250-71 +Assignment : Assignment 2 +*/ + +class Color : public Trackable +{ +public: + // Constructor. Will create a fully opaque white color if no values are input. + Color(int r = 0, int g = 0, int b = 0, int alpha = 255); + + // Returns the stored RGB values as an ALLEGRO_COLOR + ALLEGRO_COLOR getColor(); + +private: // Data here stores the RGBA values from constructor as ints. I opted to use these instead of an ALLEGRO_COLOR so that if someone wants to change it in the future all they need to do is change the getColor function. + int mR; + int mG; + int mB; + int mAlpha; +}; \ No newline at end of file diff --git a/RoboCat/Event.cpp b/RoboCat/Event.cpp new file mode 100644 index 00000000..a29ba4fa --- /dev/null +++ b/RoboCat/Event.cpp @@ -0,0 +1,48 @@ +#include "Event.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 5 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +Event::Event(EventType type) +:mType(type) +{ +} + +Event::~Event() +{ +} + +KeyEvent::KeyEvent(EventType type, int key) : Event(type) +{ + mKeyCode = key; + mIsPressed = true; +} + +KeyEvent::~KeyEvent() +{ +} + +ClickEvent::ClickEvent(EventType type, int click) : Event(type) +{ + mClick = click; + mIsClick = true; +} + +ClickEvent::~ClickEvent() +{ +} + +MouseEvent::MouseEvent(EventType type, int posX, int posY) : Event(type) +{ + mPosX = posX; + mPosY = posY; +} + +MouseEvent::~MouseEvent() +{ +} \ No newline at end of file diff --git a/RoboCat/Event.h b/RoboCat/Event.h new file mode 100644 index 00000000..81232855 --- /dev/null +++ b/RoboCat/Event.h @@ -0,0 +1,83 @@ +#pragma once + +#include +#include <../../common/DeanLib/include/Trackable.h> + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 5 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +using namespace std; + +enum EventType +{ + INVALID_EVENT_TYPE = -1, + MOVE_EVENT, + MESSAGE_EVENT, + KEY_DOWN_EVENT, + KEY_UP_EVENT, + MOUSE_DOWN_EVENT, + MOUSE_UP_EVENT, + MOUSE_MOVE_EVENT, + NUM_EVENT_TYPES +}; + +class Event:public Trackable +{ +public: + Event( EventType type ); + virtual ~Event(); + + EventType getType() const { return mType; }; + +private: + EventType mType; + +}; + +class KeyEvent : public Event +{ +public: + KeyEvent(EventType type, int key); + ~KeyEvent(); + + int getKeyCode() const { return mKeyCode; } + bool getPressed() { return mIsPressed; } + + void setPressed(bool pressed) { mIsPressed = pressed; } +private: + int mKeyCode; + bool mIsPressed; +}; + +class ClickEvent : public Event +{ +public: + ClickEvent(EventType type, int click); + ~ClickEvent(); + + int getClick() const { return mClick; } + bool getisClick() const { return mIsClick; } + + void setIsClick(bool clicked) { mIsClick = clicked; } +private: + bool mIsClick; + int mClick; +}; + +class MouseEvent : public Event +{ +public: + MouseEvent(EventType type, int posX, int posY); + ~MouseEvent(); + + int getPosX() const { return mPosX; } + int getPosY() const { return mPosY; } +private: + int mPosX; + int mPosY; +}; \ No newline at end of file diff --git a/RoboCat/EventListener.cpp b/RoboCat/EventListener.cpp new file mode 100644 index 00000000..e5c058e7 --- /dev/null +++ b/RoboCat/EventListener.cpp @@ -0,0 +1,11 @@ +#include "EventListener.h" +#include "EventSystem.h" + +EventListener::EventListener() +{ +} + +EventListener::~EventListener() +{ + EventSystem::getInstance()->removeListenerFromAllEvents( this ); +} diff --git a/RoboCat/EventListener.h b/RoboCat/EventListener.h new file mode 100644 index 00000000..dbdef177 --- /dev/null +++ b/RoboCat/EventListener.h @@ -0,0 +1,17 @@ +#pragma once + +#include <../../common/DeanLib/include/Trackable.h> + +class Event; +class EventSystem; + +class EventListener:public Trackable +{ +public: + EventListener(); + virtual ~EventListener(); + + virtual void handleEvent( const Event& theEvent ) = 0; + +private: +}; \ No newline at end of file diff --git a/RoboCat/EventSystem.cpp b/RoboCat/EventSystem.cpp new file mode 100644 index 00000000..0042dbf8 --- /dev/null +++ b/RoboCat/EventSystem.cpp @@ -0,0 +1,131 @@ +#include "EventSystem.h" +#include "Event.h" +#include "EventListener.h" +#include + +EventSystem* EventSystem::mspInstance = nullptr; + +EventSystem::EventSystem() +{ + mIsInitted = false; +} + +EventSystem::~EventSystem() +{ + cleanup(); +} + +void EventSystem::addListener(EventType type, EventListener* pListener) +{ + if (mIsInitted) + { + mListenerMap.insert(pair< EventType, EventListener* >(type, pListener)); + } +} + +void EventSystem::removeListener(EventType type, EventListener *pListener) +{ + if (mIsInitted) + { + pair::iterator, multimap::iterator> ret; + + ret = mListenerMap.equal_range(type); + multimap::iterator iter; + + for (iter = ret.first; iter != ret.second; ++iter) + { + if (iter->second == pListener) + { + mListenerMap.erase(iter); + break;//to prevent using invalidated iterator + } + } + } +} + +void EventSystem::removeListenerFromAllEvents( EventListener* pListener ) +{ + if (mIsInitted) + { + multimap::iterator iter; + + bool allTheWayThrough = false; + + while (!allTheWayThrough) + { + allTheWayThrough = true; + for (iter = mListenerMap.begin(); iter != mListenerMap.end(); ++iter) + { + if (iter->second == pListener) + { + mListenerMap.erase(iter); + allTheWayThrough = false; //didn't make it the whole way through + break;//to prevent using invalidated iterator + } + } + } + } +} + +EventSystem* EventSystem::getInstance() +{ + if (mspInstance != NULL) + { + assert(mspInstance); + return mspInstance; + } +} + +void EventSystem::initInstance() +{ + if (mspInstance == NULL) + { + assert(!mspInstance); + mspInstance = new EventSystem; + } +} + +void EventSystem::cleanupInstance() +{ + delete mspInstance; + mspInstance = nullptr; +} + +void EventSystem::init() +{ + if (mIsInitted) + { + cleanup(); + } + + mIsInitted = true; +} + +void EventSystem::cleanup() +{ + mListenerMap.clear(); + mIsInitted = false; +} + +void EventSystem::fireEvent( const Event& theEvent ) +{ + if (mIsInitted) + { + dispatchAllEvents(theEvent); + } +} + +void EventSystem::dispatchAllEvents( const Event& theEvent ) +{ + if (mIsInitted) + { + pair::iterator, multimap::iterator> ret; + ret = mListenerMap.equal_range(theEvent.getType()); + + multimap::iterator iter; + for (iter = ret.first; iter != ret.second; ++iter) + { + iter->second->handleEvent(theEvent); + } + } +} \ No newline at end of file diff --git a/RoboCat/EventSystem.h b/RoboCat/EventSystem.h new file mode 100644 index 00000000..c23ac23c --- /dev/null +++ b/RoboCat/EventSystem.h @@ -0,0 +1,36 @@ +#pragma once + +#include +#include <../../common/DeanLib/include/Trackable.h> + +class Event; +class EventListener; +enum EventType; + +using namespace std; + +class EventSystem:public Trackable +{ +public: + static EventSystem* getInstance(); + static void initInstance(); + static void cleanupInstance(); + + void init(); + void cleanup(); + + void fireEvent( const Event& theEvent ); + void addListener( EventType type, EventListener* pListener ); + void removeListener( EventType type, EventListener* pListener ); + void removeListenerFromAllEvents( EventListener* pListener ); + +private: + static EventSystem* mspInstance; + multimap< EventType, EventListener* > mListenerMap; + bool mIsInitted; + + void dispatchAllEvents( const Event& theEvent ); + + EventSystem(); + ~EventSystem(); +}; \ No newline at end of file diff --git a/RoboCat/Font.cpp b/RoboCat/Font.cpp new file mode 100644 index 00000000..5634f026 --- /dev/null +++ b/RoboCat/Font.cpp @@ -0,0 +1,24 @@ +#include "Font.h" + +/* +Author: Ryan Littleton, with help from the rest of the class +Class : GPR-250-71 +Assignment : Assignment 2 +*/ + +Font::Font(int size) +{ + mFontSize = size; + mpFont = al_load_ttf_font((FONT_ASSET_PATH).c_str(), mFontSize, 0); +} + +Font::~Font() +{ +} + +void Font::setSize(int size) +{ + al_destroy_font(mpFont); + mFontSize = size; + mpFont = al_load_font((FONT_ASSET_PATH).c_str(), mFontSize, 0); +} diff --git a/RoboCat/Font.h b/RoboCat/Font.h new file mode 100644 index 00000000..8001afab --- /dev/null +++ b/RoboCat/Font.h @@ -0,0 +1,32 @@ +#pragma once +#include +#include +#include +#include +#include +#include "../common/DeanLib/include/Trackable.h" + +/* +Author: Ryan Littleton, with help from the rest of the class +Class : GPR-250-71 +Assignment : Assignment 2 +*/ + +const std::string FONT_ASSET_PATH = "..\\..\\common\\assets\\cour.ttf"; +const int FONT_SIZE = 48; + +class Font : public Trackable +{ +public: + Font(int size = FONT_SIZE); + ~Font(); + + void setSize(int size); // This will also destroy and reinitialize the mFont so that size changes are actually reflected. + ALLEGRO_FONT* getFont() { return mpFont; } + + int getSize() {return mFontSize; } + +private: + ALLEGRO_FONT* mpFont; + int mFontSize; +}; \ No newline at end of file diff --git a/RoboCat/Game.cpp b/RoboCat/Game.cpp new file mode 100644 index 00000000..0966ddf2 --- /dev/null +++ b/RoboCat/Game.cpp @@ -0,0 +1,261 @@ +#include "NetworkManager.h" +#include "Animation.h" +#include "Event.h" +#include "EventListener.h" +#include "EventSystem.h" +#include "Game.h" +#include "GameEvent.h" +#include "GraphicsBuffer.h" +#include "GraphicsBufferManager.h" +#include "InputSystem.h" +#include "InputTranslator.h" +#include "Sprite.h" +#include "System.h" +#include "Unit.h" +#include "UnitManager.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 5 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +Game::Game() +{ + mpSystem = new System(); +} + +Game::~Game() +{ + cleanup(); +} + +void Game::initInstance() +{ + assert(!gpGame); + gpGame = new Game; +} + +Game* Game::getInstance() +{ + if (gpGame == nullptr) + { + gpGame = new Game; + } + + return gpGame; +} + +void Game::deleteInstance() +{ + delete gpGame; + gpGame = nullptr; +} + +void Game::init() +{ + EventSystem::initInstance(); + EventSystem::getInstance()->init(); + + mpSystem->init(); + + mpInputTranslator = new InputTranslator(mpSystem->getInputSystem()); + mpInputTranslator->init(); + + EventSystem::getInstance()->addListener(EventType(CREATE_UNIT_EVENT), this); + EventSystem::getInstance()->addListener(EventType(DESTROY_UNIT_EVENT), this); + EventSystem::getInstance()->addListener(EventType(UPDATE_MOUSE_POSITION_EVENT), this); + EventSystem::getInstance()->addListener(EventType(CHANGE_UNIT_ANIMATION_EVENT), this); + EventSystem::getInstance()->addListener(EventType(TOGGLE_ALL_UNIT_ANIMATIONS_EVENT), this); + EventSystem::getInstance()->addListener(EventType(EXIT_GAME_EVENT), this); + + //Create3GraphicsBuffers –one containing the woods.png image, one containing smurf_sprites.png, and one containing dean_sprites.pn + mpWoodsBuffer = new GraphicsBuffer(ASSET_FILEPATH + WOODS_FILEPATH); + mpSmurfBuffer = new GraphicsBuffer(ASSET_FILEPATH + SMURF_FILEPATH); + mpDeanBuffer = new GraphicsBuffer(ASSET_FILEPATH + DEAN_FILEPATH); + mpCurrentBuffer = mpSmurfBuffer; + + mpGraphicsBufferManager = new GraphicsBufferManager(); + + mpGraphicsBufferManager->addBuffer("Smurf", mpSmurfBuffer); + mpGraphicsBufferManager->addBuffer("Dean", mpDeanBuffer); + mpGraphicsBufferManager->addBuffer("Woods", mpWoodsBuffer); + + // create Animations to hold sprites and Unit to hold animations + mpWoodsSprite = new Sprite(mpWoodsBuffer, 0, 0, mpWoodsBuffer->getHeight(), mpWoodsBuffer->getWidth()); + + mpUnitManager = new UnitManager(); + + mpNetworkManager = new NetworkManager(); + + mAnimSpeed = 30; + + mShouldExit = false; + mIsPaused = false; + mIsSmurf = true; + + mpTimer = new Timer(); + mpPerformanceTracker = new PerformanceTracker(); +} + +void Game::cleanup() +{ + delete mpSystem; + mpSystem = nullptr; + + delete mpDeanBuffer; + mpDeanBuffer = nullptr; + + delete mpSmurfBuffer; + mpSmurfBuffer = nullptr; + + delete mpWoodsSprite; + mpWoodsSprite = nullptr; + delete mpWoodsBuffer; + mpWoodsBuffer = nullptr; + + delete mpDeanBuffer; + mpDeanBuffer = nullptr; + + delete mpSmurfBuffer; + mpSmurfBuffer = nullptr; + + delete mpGraphicsBufferManager; + mpGraphicsBufferManager = nullptr; + + delete mpUnitManager; + mpUnitManager = nullptr; + + delete mpInputTranslator; + mpInputTranslator = nullptr; + + delete mpTimer; + mpTimer = nullptr; + + delete mpPerformanceTracker; + mpPerformanceTracker = nullptr; +} + +void Game::doLoop() +{ + mpPerformanceTracker->startTracking( "doLoop" ); + + do + { + mpTimer->start(); + + //The game loop + mpSystem->getInputSystem()->update(); //<= Input System update throws an exception + update(); + render(); + + mpTimer->sleepUntilElapsed((1.0 / mFrameRate) * 1000); // wait for timer to reach ~16.7 milliseconds + cout << mpTimer->getElapsedTime() << endl; + } while (mShouldExit == false); + + mpPerformanceTracker->stopTracking("doLoop"); +} + +void Game::handleEvent(const Event& event) +{ + const GameEvent& myEvent = static_cast(event); + + switch (myEvent.getType()) + { + case CREATE_UNIT_EVENT: + + mpTempAnim = new Animation(4, 4, mpGraphicsBufferManager->getGraphicsBuffer("Smurf"), true); + mpTempUnit = new Unit(mpUnitManager->getPosX() - 30, mpUnitManager->getPosY() - 30, mpTempAnim); + + mpTempUnit->setAnimationSpeed(30); + mpUnitManager->addUnits(mpTempUnit); + + mIsSmurf = true; + + mpNetworkManager->sendData(PacketTypes::CREATE_OBJECT, 0, mpTempUnit); + break; + + case DESTROY_UNIT_EVENT: + + for (int i = mpUnitManager->getNumUnits()-1; i >= 0; i--) + { + Unit* current = mpUnitManager->getUnits(i); + if (mpUnitManager->getPosX() < current->getLocX() + current->getSpriteWidth() && mpUnitManager->getPosX() > current->getLocX()) + { + if (mpUnitManager->getPosY() < current->getLocY() + current->getSpriteHeight() && mpUnitManager->getPosY() > current->getLocY()) + { + mpUnitManager->deleteUnits(i); + mpNetworkManager->sendData(PacketTypes::DESTROY_OBJECT, 0, current); + break; + } + } + } + break; + + case UPDATE_MOUSE_POSITION_EVENT: + + mpUnitManager->setPosX(myEvent.getPosX()); + mpUnitManager->setPosY(myEvent.getPosY()); + + break; + + case CHANGE_UNIT_ANIMATION_EVENT: + + if (mIsSmurf) + { + mIsSmurf = false; + mpUnitManager->getUnits(mpUnitManager->getNumUnits() - 1)->setAnimation(new Animation(4, 4, mpGraphicsBufferManager->getGraphicsBuffer("Smurf"), true)); + mpUnitManager->getUnits(mpUnitManager->getNumUnits() - 1)->setAnimationSpeed(30); + } + else + { + mIsSmurf = true; + mpUnitManager->getUnits(mpUnitManager->getNumUnits() - 1)->setAnimation(new Animation(4, 4, mpGraphicsBufferManager->getGraphicsBuffer("Dean"), true)); + mpUnitManager->getUnits(mpUnitManager->getNumUnits() - 1)->setAnimationSpeed(30); + } + + break; + + case TOGGLE_ALL_UNIT_ANIMATIONS_EVENT: + + if (!mIsPaused) + { + for (int i = 0; i < mpUnitManager->getNumUnits(); i++) + { + mpUnitManager->getUnits(i)->setAnimationSpeed(0); + } + mIsPaused = true; + } + else + { + for (int i = 0; i < mpUnitManager->getNumUnits(); i++) + { + mpUnitManager->getUnits(i)->setAnimationSpeed(mAnimSpeed); + } + mIsPaused = false; + } + + break; + + case EXIT_GAME_EVENT: + mShouldExit = true; + break; + } +} + +void Game::update() +{ + mpUnitManager->updateUnits((1.0 / mFrameRate) * 1000); + mpNetworkManager->sendData(PacketTypes::UPDATE_OBJECT, 0); +} + +void Game::render() +{ + mpSystem->getGraphicsSystem()->draw(0, 0, mpWoodsSprite, WOODS_SCALE); + mpUnitManager->draw(mpSystem); + mpSystem->getGraphicsSystem()->flip(); +} + +Game* Game::gpGame = nullptr; \ No newline at end of file diff --git a/RoboCat/Game.h b/RoboCat/Game.h new file mode 100644 index 00000000..b2de8b91 --- /dev/null +++ b/RoboCat/Game.h @@ -0,0 +1,99 @@ +#pragma once +#include "../common/DeanLib/include/Trackable.h" +#include <../../common/DeanLib/include/Timer.h> +#include +#include <../../common/DeanLib/include/PerformanceTracker.h> +#include "Sprite.h" +#include "EventListener.h" + +/* +Author: Wesley Elmer + Class : Game Architecture <250-71> + Assignment : Assignment 3 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +using namespace std; + +class Animation; +class Event; +class EventListener; +class EventSystem; +class GraphicsBuffer; +class GraphicsBufferManager; +class InputSystem; +class InputTranslator; +class NetworkManager; +class Sprite; +class System; +class Unit; +class UnitManager; + + +const string ASSET_FILEPATH = "..\\common\\assets\\"; +const string SMURF_FILEPATH = "smurf_sprites.png"; +const string DEAN_FILEPATH = "dean_sprites.png"; +const string WOODS_FILEPATH = "Woods.png"; +const float ANIM_INCREMENT_AMOUNT = 5; +const float WOODS_SCALE = 0.5f; + +// The class which holds all systems and has the game loop +class Game : public EventListener +{ +public: + static void initInstance(); + static Game* getInstance(); // reference to the main game object. To use: Game* ptr = Game::getInstance(); where ptr is now the game object + static void deleteInstance(); + + void init(); + void cleanup(); + void doLoop(); + + void handleEvent(const Event& event); + + void update(); + void render(); + + System* getSystem() { return mpSystem; } +private: + Game(); + ~Game(); + + System* mpSystem; + + InputTranslator* mpInputTranslator; + EventListener* mpEventListener; + + GraphicsBuffer* mpWoodsBuffer = nullptr; + GraphicsBuffer* mpSmurfBuffer = nullptr; + GraphicsBuffer* mpDeanBuffer = nullptr; + GraphicsBuffer* mpCurrentBuffer = nullptr; + GraphicsBufferManager* mpGraphicsBufferManager; + + Animation* mpTempAnim; + Unit* mpTempUnit; + + Sprite* mpWoodsSprite; + + Unit* mpUnit; + UnitManager* mpUnitManager = nullptr; + + Sprite mSmurfSpriteArr[16]; + Sprite mDeanSpriteArr[16]; + + float mFrameRate = 60; + float mAnimSpeed; + + bool mShouldExit; + bool mIsSmurf; + bool mIsPaused; + + Timer* mpTimer; + PerformanceTracker* mpPerformanceTracker; + + static Game* gpGame; + + NetworkManager* mpNetworkManager; +}; + diff --git a/RoboCat/GameEvent.cpp b/RoboCat/GameEvent.cpp new file mode 100644 index 00000000..b69b8fe6 --- /dev/null +++ b/RoboCat/GameEvent.cpp @@ -0,0 +1,27 @@ +#include"GameEvent.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 5 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +GameEvent::GameEvent(GameEventType type) : Event(EventType(type)) +{ + mType = type; + mPosX = 0; + mPosY = 0; +} + +GameEvent::GameEvent(GameEventType type, int posX, int posY) : Event(EventType(type)) +{ + mType = type; + mPosX = posX; + mPosY = posY; +} + +GameEvent::~GameEvent() +{ +} \ No newline at end of file diff --git a/RoboCat/GameEvent.h b/RoboCat/GameEvent.h new file mode 100644 index 00000000..02b4d59a --- /dev/null +++ b/RoboCat/GameEvent.h @@ -0,0 +1,44 @@ +#pragma once +#include +#include"Event.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 5 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +using namespace std; + +enum GameEventType +{ + INVALID_TYPE_OF_EVENT = 7, + CREATE_UNIT_EVENT, + DESTROY_UNIT_EVENT, + UPDATE_MOUSE_POSITION_EVENT, + CHANGE_UNIT_ANIMATION_EVENT, + TOGGLE_ALL_UNIT_ANIMATIONS_EVENT, + EXIT_GAME_EVENT, + NUM_OF_EVENT_TYPES +}; + +class GameEvent : public Event +{ +public: + GameEvent(GameEventType type); + GameEvent(GameEventType type, int posX, int posY); + ~GameEvent(); + + int getPosX() const { return mPosX; } + int getPosY() const { return mPosY; } + + GameEventType getType() const { return mType; } +private: + int mPosX; + int mPosY; + + GameEventType mType; +}; + diff --git a/RoboCat/GraphicsBuffer.cpp b/RoboCat/GraphicsBuffer.cpp new file mode 100644 index 00000000..14f94a2c --- /dev/null +++ b/RoboCat/GraphicsBuffer.cpp @@ -0,0 +1,50 @@ +#include"GraphicsBuffer.h" +#include"Color.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 2 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +GraphicsBuffer::GraphicsBuffer() +{ + mWidth = 800; + mHeight = 600; + mpGraphicsBuffer = al_create_bitmap(mWidth, mHeight); + mIsInited = false; +} + +GraphicsBuffer::GraphicsBuffer(string filename) +{ + mIsInited = true; + mpGraphicsBuffer = al_load_bitmap(filename.c_str()); + assert(mpGraphicsBuffer); + mWidth = al_get_bitmap_width(mpGraphicsBuffer); + mHeight = al_get_bitmap_height(mpGraphicsBuffer); +} + +GraphicsBuffer::GraphicsBuffer(int height, int width) +{ + mpGraphicsBuffer = al_create_bitmap(width, height); +} + +GraphicsBuffer::GraphicsBuffer(int width, int height, Color* color) +{ + mWidth = width; + mHeight = height; + + ALLEGRO_BITMAP* pOldBuffer = al_get_target_bitmap(); + mIsInited = true; + mpGraphicsBuffer = al_create_bitmap(width, height); + al_set_target_bitmap(mpGraphicsBuffer); + assert(mpGraphicsBuffer); + al_clear_to_color(color->getColor()); + al_set_target_bitmap(pOldBuffer); +} + +GraphicsBuffer::~GraphicsBuffer() +{ +} \ No newline at end of file diff --git a/RoboCat/GraphicsBuffer.h b/RoboCat/GraphicsBuffer.h new file mode 100644 index 00000000..0b70f1ab --- /dev/null +++ b/RoboCat/GraphicsBuffer.h @@ -0,0 +1,36 @@ +#pragma once +#include +#include +#include +#include"../common/DeanLib/include/Trackable.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 2 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ +using namespace std; + +class Color; + +class GraphicsBuffer : public Trackable +{ +public: + GraphicsBuffer(); + GraphicsBuffer(string filename); + GraphicsBuffer(int height, int width); + GraphicsBuffer(int width, int height, Color* color); + GraphicsBuffer( GraphicsBuffer& ) = delete; // prevents the creation of a copy constructor so people can't pass this class by value + ~GraphicsBuffer(); + + int getWidth() { return mWidth; } + int getHeight() { return mHeight; } + ALLEGRO_BITMAP* getGraphicsBuffer() { return mpGraphicsBuffer; } +private: + int mHeight; + int mWidth; + ALLEGRO_BITMAP* mpGraphicsBuffer; + bool mIsInited; +}; \ No newline at end of file diff --git a/RoboCat/GraphicsBufferManager.cpp b/RoboCat/GraphicsBufferManager.cpp new file mode 100644 index 00000000..ae74d727 --- /dev/null +++ b/RoboCat/GraphicsBufferManager.cpp @@ -0,0 +1,59 @@ +#include"GraphicsBufferManager.h" +#include"GraphicsBuffer.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 4 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +GraphicsBufferManager::GraphicsBufferManager() +{ + mDeleted = false; + mBuffer = new map(); +} + +GraphicsBufferManager::~GraphicsBufferManager() +{ + cleanup(); +} + +void GraphicsBufferManager::addBuffer(string bufferName, GraphicsBuffer* buffer) +{ + mBuffer->emplace(bufferName, buffer); +} + +void GraphicsBufferManager::deleteBuffer(string bufferName) +{ + delete mBuffer->find(bufferName)->second; + mBuffer->erase(bufferName); +} + +GraphicsBuffer* GraphicsBufferManager::getGraphicsBuffer(string bufferName) +{ + map::iterator iter; + iter = mBuffer->find(bufferName); + + if (iter != mBuffer->end()) + { + return iter->second; + } + + return NULL; +} + +void GraphicsBufferManager::cleanup() +{ + if (!mDeleted) + { + map::iterator iterate; + for (iterate = mBuffer->begin(); iterate != mBuffer->end(); iterate++) + { + iterate->second; + } + + mDeleted = true; + } +} diff --git a/RoboCat/GraphicsBufferManager.h b/RoboCat/GraphicsBufferManager.h new file mode 100644 index 00000000..54c1feae --- /dev/null +++ b/RoboCat/GraphicsBufferManager.h @@ -0,0 +1,35 @@ +#pragma once +#include +#include"../common/DeanLib/include/Trackable.h" +#include +#include + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 4 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +using namespace std; + +class GraphicsBuffer; +class Color; + +class GraphicsBufferManager +{ +public: + GraphicsBufferManager(); + ~GraphicsBufferManager(); + + void addBuffer(string bufferName, GraphicsBuffer* buffer); + void deleteBuffer(string bufferName); + GraphicsBuffer* getGraphicsBuffer(string bufferName); + + void cleanup(); +private: + map* mBuffer; + bool mDeleted; +}; + diff --git a/RoboCat/GraphicsSystem.cpp b/RoboCat/GraphicsSystem.cpp new file mode 100644 index 00000000..2097f47c --- /dev/null +++ b/RoboCat/GraphicsSystem.cpp @@ -0,0 +1,130 @@ +#include "GraphicsSystem.h" + +/* +Author: Ryan Littleton, with help from the rest of the class +Class : GPR-250-71 +Assignment : Assignment 2 +*/ + +GraphicsSystem::GraphicsSystem(int width, int height) +{ + mDisplayWidth = width; + mDisplayHeight = height; +} +GraphicsSystem::~GraphicsSystem() +{ + cleanUp(); + mDisplayWidth = DISP_WIDTH; + mDisplayHeight = DISP_HEIGHT; + mpDisplay = nullptr; +} + +void GraphicsSystem::init() +{ + if (!al_init()) + { + cout << "error initting Allegro\n"; + } + if (!al_init_image_addon()) + { + cout << "error - Image Add-on not initted\n"; + } + if (!al_init_font_addon()) + { + cout << "error - Font Add-on not initted\n"; + } + if (!al_init_ttf_addon()) + { + cout << "error - TTF Add-on not initted\n"; + } + if (!al_init_primitives_addon()) + { + cout << "error - primitives Add-on not initted\n"; + } + if (!al_install_audio()) + { + cout << "error - Audio Add-on not initted\n"; + } + if (!al_init_acodec_addon()) + { + cout << "error - Audio Codec Add-on not initted\n"; + } + if (!al_reserve_samples(1)) + { + cout << "error - samples not reserved\n"; + } + + mpDisplay = al_create_display( mDisplayWidth, mDisplayHeight ); + assert( mpDisplay ); +} + +void GraphicsSystem::cleanUp() +{ + al_destroy_display(mpDisplay); +} + +int GraphicsSystem::getHeight() +{ + return al_get_display_height(mpDisplay); +} + +int GraphicsSystem::getWidth() +{ + return al_get_display_width(mpDisplay); +} + +ALLEGRO_BITMAP* GraphicsSystem::getBackBuffer() +{ + return al_get_backbuffer(mpDisplay); +} + +void GraphicsSystem::flip() +{ + al_flip_display(); +} + +void GraphicsSystem::draw(int xLoc, int yLoc, Sprite* sprite, float scale) +{ + al_set_target_bitmap(al_get_backbuffer(mpDisplay)); + ALLEGRO_BITMAP* bitmap = sprite->getGraphicsBuffer()->getGraphicsBuffer(); + float width = sprite->getWidth(); + float height = sprite->getHeight(); + float x = sprite->getLocX(); + float y = sprite->getLocY(); + al_draw_scaled_bitmap(bitmap, x, y, width, height, xLoc, yLoc, width * scale, height * scale, 0); +} + +void GraphicsSystem::draw(GraphicsBuffer targetBuffer, int xLoc, int yLoc, Sprite sprite, float scale) +{ + al_set_target_bitmap(targetBuffer.getGraphicsBuffer()); + ALLEGRO_BITMAP* bitmap = sprite.getGraphicsBuffer()->getGraphicsBuffer(); + float width = sprite.getHeight(); + float height = sprite.getHeight(); + float x = sprite.getLocX(); + float y = sprite.getLocY(); + cout << scale << endl; + al_draw_scaled_bitmap(bitmap, x, y, width, height, xLoc, yLoc, width * scale, height * scale, 0); + al_set_target_bitmap(al_get_backbuffer(mpDisplay)); +} + +void GraphicsSystem::writeText(int xLoc, int yLoc, Font font, Color color, std::string text) +{ + al_draw_text(font.getFont(), color.getColor(), xLoc, yLoc, ALLEGRO_ALIGN_LEFT, text.c_str()); +} + +void GraphicsSystem::writeText(GraphicsBuffer targetBuffer, int xLoc, int yLoc, Font font, Color color, std::string text) +{ + al_set_target_bitmap(targetBuffer.getGraphicsBuffer()); + al_draw_text(font.getFont(), color.getColor(), xLoc, yLoc, ALLEGRO_ALIGN_LEFT, text.c_str()); + al_set_target_bitmap(al_get_backbuffer(mpDisplay)); +} + +void GraphicsSystem::saveBuffer(GraphicsBuffer targetBuffer, std::string filename) +{ + al_save_bitmap(filename.c_str(), targetBuffer.getGraphicsBuffer()); +} + +void GraphicsSystem::saveBuffer(ALLEGRO_BITMAP* targetBuffer, std::string filename) +{ + al_save_bitmap(filename.c_str(), targetBuffer); +} diff --git a/RoboCat/GraphicsSystem.h b/RoboCat/GraphicsSystem.h new file mode 100644 index 00000000..6609ee22 --- /dev/null +++ b/RoboCat/GraphicsSystem.h @@ -0,0 +1,54 @@ +#pragma once +#include +#include +#include +#include +#include +#include +#include +#include +#include "../common/DeanLib/include/Trackable.h" +#include "Sprite.h" +#include "GraphicsBuffer.h" +#include "Font.h" +#include "Color.h" + +/* +Author: Ryan Littleton, with help from the rest of the class +Class : GPR-250-71 +Assignment : Assignment 2 +*/ + +const int DISP_WIDTH = 800; +const int DISP_HEIGHT = 600; + +class GraphicsSystem : public Trackable +{ +public: + GraphicsSystem(int width = DISP_WIDTH, int height = DISP_HEIGHT); + ~GraphicsSystem(); + + void init(); // This will also initialize the rest of allegro, make sure to use it before using any allegro functions. + void cleanUp(); + + int getHeight(); + int getWidth(); + ALLEGRO_BITMAP* getBackBuffer(); + + void flip(); // Flips using al_flip. If not using allegro, change this. + + void draw(int xLoc, int yLoc, Sprite* sprite, float scale = 1.0f); // Draws a sprite at a specified location and scale. + void draw(GraphicsBuffer targetBuffer, int xLoc, int yLoc, Sprite sprite, float scale = 1.0f); // Draws a sprite on a specified GraphicsBuffer and scale + + void writeText(int xLoc, int yLoc, Font font, Color color, std::string text); + void writeText(GraphicsBuffer targetBuffer, int xLoc, int yLoc, Font font, Color color, std::string text); + + void saveBuffer(GraphicsBuffer targetBuffer, std::string filename); // Saves an image file of the given GraphicsBuffer + void saveBuffer(ALLEGRO_BITMAP* targetBuffer, std::string filename); // Saves an image file of the given ALLEGRO_BITMAP, this is so the display doesn't first need to be converted to a graphics buffer to save + +private: + ALLEGRO_DISPLAY* mpDisplay; + int mDisplayWidth; + int mDisplayHeight; + +}; \ No newline at end of file diff --git a/RoboCat/Inc/AckRange.h b/RoboCat/Inc/AckRange.h new file mode 100644 index 00000000..004d14c9 --- /dev/null +++ b/RoboCat/Inc/AckRange.h @@ -0,0 +1,35 @@ +//typedef PacketSequenceNumber uint16_t; + +class AckRange +{ +public: + AckRange() : mStart( 0 ), mCount( 0 ) {} + + AckRange( PacketSequenceNumber inStart ) : mStart( inStart ), mCount( 1 ) {} + + //if this is the next in sequence, just extend the range + inline bool ExtendIfShould( PacketSequenceNumber inSequenceNumber ); + + PacketSequenceNumber GetStart() const { return mStart; } + uint32_t GetCount() const { return mCount; } + + void Write( OutputMemoryBitStream& inOutputStream ) const; + void Read( InputMemoryBitStream& inInputStream ); + +private: + PacketSequenceNumber mStart; + uint32_t mCount; +}; + +inline bool AckRange::ExtendIfShould( PacketSequenceNumber inSequenceNumber ) +{ + if( inSequenceNumber == mStart + mCount ) + { + ++mCount; + return true; + } + else + { + return false; + } +} \ No newline at end of file diff --git a/RoboCat/Inc/ByteSwap.h b/RoboCat/Inc/ByteSwap.h new file mode 100644 index 00000000..5407540c --- /dev/null +++ b/RoboCat/Inc/ByteSwap.h @@ -0,0 +1,117 @@ + +#ifndef RoboCat_ByteSwap_h +#define RoboCat_ByteSwap_h + +inline uint16_t ByteSwap2( uint16_t inData ) +{ + return ( inData >> 8 ) | ( inData << 8 ); +} + +inline uint32_t ByteSwap4( uint32_t inData ) +{ + return ( ( inData >> 24 ) & 0x000000ff ) | + ( ( inData >> 8 ) & 0x0000ff00 ) | + ( ( inData << 8 ) & 0x00ff0000 ) | + ( ( inData << 24 ) & 0xff000000 ); +} + +inline uint64_t ByteSwap8( uint64_t inData ) +{ + return ( ( inData >> 56 ) & 0x00000000000000ff ) | + ( ( inData >> 40 ) & 0x000000000000ff00 ) | + ( ( inData >> 24 ) & 0x0000000000ff0000 ) | + ( ( inData >> 8 ) & 0x00000000ff000000 ) | + ( ( inData << 8 ) & 0x000000ff00000000 ) | + ( ( inData << 24 ) & 0x0000ff0000000000 ) | + ( ( inData << 40 ) & 0x00ff000000000000 ) | + ( ( inData << 56 ) & 0xff00000000000000 ); +} + + +template < typename tFrom, typename tTo > +class TypeAliaser +{ +public: + TypeAliaser( tFrom inFromValue ) : + mAsFromType( inFromValue ) {} + tTo& Get() { return mAsToType; } + + union + { + tFrom mAsFromType; + tTo mAsToType; + }; +}; + + +template class ByteSwapper; + +//specialize for 1... +template +class ByteSwapper< T, 1 > +{ +public: + T Swap( T inData ) const + { + return inData; + } +}; + + +//specialize for 2... +template +class ByteSwapper< T, 2 > +{ +public: + T Swap( T inData ) const + { + uint16_t result = + ByteSwap2( TypeAliaser< T, uint16_t >( inData ).Get() ); + return TypeAliaser< uint16_t, T >( result ).Get(); + } +}; + +//specialize for 4... +template +class ByteSwapper< T, 4 > +{ +public: + T Swap( T inData ) const + { + uint32_t result = + ByteSwap4( TypeAliaser< T, uint32_t >( inData ).Get() ); + return TypeAliaser< uint32_t, T >( result ).Get(); + } +}; + + +//specialize for 8... +template +class ByteSwapper< T, 8 > +{ +public: + T Swap( T inData ) const + { + uint64_t result = + ByteSwap8( TypeAliaser< T, uint64_t >( inData ).Get() ); + return TypeAliaser< uint64_t, T >( result ).Get(); + } +}; + +template < typename T > +T ByteSwap( T inData ) +{ + return ByteSwapper< T, sizeof( T ) >().Swap( inData ); +} + +inline void TestByteSwap() +{ + int32_t test = 0x12345678; + float floatTest = 1.f; + + printf( "swapped 0x%x is 0x%x\n", test, ByteSwap( test ) ); + printf( "swapped %f is %f\n", floatTest, ByteSwap( floatTest ) ); + printf( "swapped 0x%x is 0x%x\n", TypeAliaser< float, uint32_t >( floatTest ).Get(), TypeAliaser< float, uint32_t >( ByteSwap( floatTest ) ).Get() ); +} + +#endif diff --git a/RoboCat/Inc/DeliveryNotificationManager.h b/RoboCat/Inc/DeliveryNotificationManager.h new file mode 100644 index 00000000..b6a795a4 --- /dev/null +++ b/RoboCat/Inc/DeliveryNotificationManager.h @@ -0,0 +1,72 @@ + +class DeliveryNotificationManager +{ +public: + + + DeliveryNotificationManager( bool inShouldSendAcks, bool inShouldProcessAcks ); + ~DeliveryNotificationManager(); + + inline InFlightPacket* WriteState( OutputMemoryBitStream& inOutputStream ); + inline bool ReadAndProcessState( InputMemoryBitStream& inInputStream ); + + void ProcessTimedOutPackets(); + + uint32_t GetDroppedPacketCount() const { return mDroppedPacketCount; } + uint32_t GetDeliveredPacketCount() const { return mDeliveredPacketCount; } + uint32_t GetDispatchedPacketCount() const { return mDispatchedPacketCount; } + + const deque< InFlightPacket >& GetInFlightPackets() const { return mInFlightPackets; } + +private: + + + + InFlightPacket* WriteSequenceNumber( OutputMemoryBitStream& inOutputStream ); + void WriteAckData( OutputMemoryBitStream& inOutputStream ); + + //returns wether to drop the packet- if sequence number is too low! + bool ProcessSequenceNumber( InputMemoryBitStream& inInputStream ); + void ProcessAcks( InputMemoryBitStream& inInputStream ); + + + void AddPendingAck( PacketSequenceNumber inSequenceNumber ); + void HandlePacketDeliveryFailure( const InFlightPacket& inFlightPacket ); + void HandlePacketDeliverySuccess( const InFlightPacket& inFlightPacket ); + + PacketSequenceNumber mNextOutgoingSequenceNumber; + PacketSequenceNumber mNextExpectedSequenceNumber; + + deque< InFlightPacket > mInFlightPackets; + deque< AckRange > mPendingAcks; + + bool mShouldSendAcks; + bool mShouldProcessAcks; + + uint32_t mDeliveredPacketCount; + uint32_t mDroppedPacketCount; + uint32_t mDispatchedPacketCount; + +}; + + + +inline InFlightPacket* DeliveryNotificationManager::WriteState( OutputMemoryBitStream& inOutputStream ) +{ + InFlightPacket* toRet = WriteSequenceNumber( inOutputStream ); + if( mShouldSendAcks ) + { + WriteAckData( inOutputStream ); + } + return toRet; +} + +inline bool DeliveryNotificationManager::ReadAndProcessState( InputMemoryBitStream& inInputStream ) +{ + bool toRet = ProcessSequenceNumber( inInputStream ); + if( mShouldProcessAcks ) + { + ProcessAcks( inInputStream ); + } + return toRet; +} \ No newline at end of file diff --git a/RoboCat/Inc/InFlightPacket.h b/RoboCat/Inc/InFlightPacket.h new file mode 100644 index 00000000..494e097e --- /dev/null +++ b/RoboCat/Inc/InFlightPacket.h @@ -0,0 +1,33 @@ +class DeliveryNotificationManager; + +//in case we decide to change the type of the sequence number to use fewer or more bits +typedef uint16_t PacketSequenceNumber; + +class InFlightPacket +{ +public: + + InFlightPacket( PacketSequenceNumber inSequenceNumber ); + + PacketSequenceNumber GetSequenceNumber() const { return mSequenceNumber; } + float GetTimeDispatched() const { return mTimeDispatched; } + + void SetTransmissionData( int inKey, TransmissionDataPtr inTransmissionData ) + { + mTransmissionDataMap[ inKey ] = inTransmissionData; + } + const TransmissionDataPtr GetTransmissionData( int inKey ) const + { + auto it = mTransmissionDataMap.find( inKey ); + return ( it != mTransmissionDataMap.end() ) ? it->second : nullptr; + } + + void HandleDeliveryFailure( DeliveryNotificationManager* inDeliveryNotificationManager ) const; + void HandleDeliverySuccess( DeliveryNotificationManager* inDeliveryNotificationManager ) const; + +private: + PacketSequenceNumber mSequenceNumber; + float mTimeDispatched; + + unordered_map< int, TransmissionDataPtr > mTransmissionDataMap; +}; \ No newline at end of file diff --git a/RoboCat/Inc/LinkingContext.h b/RoboCat/Inc/LinkingContext.h new file mode 100644 index 00000000..893e73aa --- /dev/null +++ b/RoboCat/Inc/LinkingContext.h @@ -0,0 +1,67 @@ + +#ifndef RoboCat_LinkingContext_h +#define RoboCat_LinkingContext_h + +class GameObject; + +class LinkingContext +{ +public: + + LinkingContext() : + mNextNetworkId( 1 ) + {} + + uint32_t GetNetworkId( GameObject* inGameObject, bool inShouldCreateIfNotFound ) + { + auto it = mGameObjectToNetworkIdMap.find( inGameObject ); + if( it != mGameObjectToNetworkIdMap.end() ) + { + return it->second; + } + else if( inShouldCreateIfNotFound ) + { + uint32_t newNetworkId = mNextNetworkId++; + AddGameObject( inGameObject, newNetworkId ); + return newNetworkId; + } + else + { + return 0; + } + } + + GameObject* GetGameObject( uint32_t inNetworkId ) const + { + auto it = mNetworkIdToGameObjectMap.find( inNetworkId ); + if( it != mNetworkIdToGameObjectMap.end() ) + { + return it->second; + } + else + { + return nullptr; + } + } + + void AddGameObject( GameObject* inGameObject, uint32_t inNetworkId ) + { + mNetworkIdToGameObjectMap[ inNetworkId ] = inGameObject; + mGameObjectToNetworkIdMap[ inGameObject ] = inNetworkId; + } + + void RemoveGameObject( GameObject *inGameObject ) + { + uint32_t networkId = mGameObjectToNetworkIdMap[ inGameObject ]; + mGameObjectToNetworkIdMap.erase( inGameObject ); + mNetworkIdToGameObjectMap.erase( networkId ); + } + +private: + std::unordered_map< uint32_t, GameObject* > mNetworkIdToGameObjectMap; + std::unordered_map< const GameObject*, uint32_t > mGameObjectToNetworkIdMap; + + uint32_t mNextNetworkId; +}; + +#endif diff --git a/RoboCat/Inc/MemoryBitStream.h b/RoboCat/Inc/MemoryBitStream.h new file mode 100644 index 00000000..c2138925 --- /dev/null +++ b/RoboCat/Inc/MemoryBitStream.h @@ -0,0 +1,161 @@ + +#include +#include +#include +#include + +class GameObject; + +inline uint32_t ConvertToFixed( float inNumber, float inMin, float inPrecision ) +{ + return static_cast< int > ( ( inNumber - inMin ) / inPrecision ); +} + +inline float ConvertFromFixed( uint32_t inNumber, float inMin, float inPrecision ) +{ + return static_cast< float >( inNumber ) * inPrecision + inMin; +} + + +class OutputMemoryBitStream +{ +public: + + OutputMemoryBitStream() : + mBitHead(0), + mBuffer(nullptr) + { + ReallocBuffer( 1500 * 8 ); + } + + ~OutputMemoryBitStream() { std::free(mBuffer); } + + void WriteBits( uint8_t inData, uint32_t inBitCount ); + void WriteBits( const void* inData, uint32_t inBitCount ); + + const char* GetBufferPtr() const { return mBuffer; } + uint32_t GetBitLength() const { return mBitHead; } + uint32_t GetByteLength() const { return ( mBitHead + 7 ) >> 3; } + + void WriteBytes( const void* inData, uint32_t inByteCount ) { WriteBits( inData, inByteCount << 3 ); } + + /* + void Write( uint32_t inData, uint32_t inBitCount = 32 ) { WriteBits( &inData, inBitCount ); } + void Write( int inData, uint32_t inBitCount = 32 ) { WriteBits( &inData, inBitCount ); } + void Write( float inData ) { WriteBits( &inData, 32 ); } + + void Write( uint16_t inData, uint32_t inBitCount = 16 ) { WriteBits( &inData, inBitCount ); } + void Write( int16_t inData, uint32_t inBitCount = 16 ) { WriteBits( &inData, inBitCount ); } + + void Write( uint8_t inData, uint32_t inBitCount = 8 ) { WriteBits( &inData, inBitCount ); } + */ + + template< typename T > + void Write( T inData, uint32_t inBitCount = sizeof( T ) * 8 ) + { + static_assert( std::is_arithmetic< T >::value || + std::is_enum< T >::value, + "Generic Write only supports primitive data types" ); + WriteBits( &inData, inBitCount ); + } + + void Write( bool inData ) { WriteBits( &inData, 1 ); } + + void Write( const Vector3& inVector ); + void Write( const Quaternion& inQuat ); + + void Write( const std::string& inString ) + { + uint32_t elementCount = static_cast< uint32_t >( inString.size() ); + Write( elementCount ); + for( const auto& element : inString ) + { + Write( element ); + } + } + +private: + void ReallocBuffer( uint32_t inNewBitCapacity ); + + char* mBuffer; + uint32_t mBitHead; + uint32_t mBitCapacity; +}; + +class InputMemoryBitStream +{ +public: + + InputMemoryBitStream( char* inBuffer, uint32_t inBitCount ) : + mBuffer( inBuffer ), + mBitCapacity( inBitCount ), + mBitHead( 0 ), + mIsBufferOwner( false ) {} + + InputMemoryBitStream( const InputMemoryBitStream& inOther ) : + mBitCapacity( inOther.mBitCapacity ), + mBitHead( inOther.mBitHead ), + mIsBufferOwner( true ) + { + //allocate buffer of right size + int byteCount = ( mBitCapacity + 7 ) / 8; + mBuffer = static_cast< char* >( malloc( byteCount ) ); + //copy + memcpy( mBuffer, inOther.mBuffer, byteCount ); + } + + ~InputMemoryBitStream() { if (mIsBufferOwner) { std::cout << "Freeing " << mBuffer << std::endl; free(mBuffer); }; } + + const char* GetBufferPtr() const { return mBuffer; } + uint32_t GetRemainingBitCount() const { return mBitCapacity - mBitHead; } + + void ReadBits( uint8_t& outData, uint32_t inBitCount ); + void ReadBits( void* outData, uint32_t inBitCount ); + + void ReadBytes( void* outData, uint32_t inByteCount ) { ReadBits( outData, inByteCount << 3 ); } + + template< typename T > + void Read( T& inData, uint32_t inBitCount = sizeof( T ) * 8 ) + { + static_assert( std::is_arithmetic< T >::value || + std::is_enum< T >::value, + "Generic Read only supports primitive data types" ); + ReadBits( &inData, inBitCount ); + } + + void Read( uint32_t& outData, uint32_t inBitCount = 32 ) { ReadBits( &outData, inBitCount ); } + void Read( int& outData, uint32_t inBitCount = 32 ) { ReadBits( &outData, inBitCount ); } + void Read( float& outData ) { ReadBits( &outData, 32 ); } + + void Read( uint16_t& outData, uint32_t inBitCount = 16 ) { ReadBits( &outData, inBitCount ); } + void Read( int16_t& outData, uint32_t inBitCount = 16 ) { ReadBits( &outData, inBitCount ); } + + void Read( uint8_t& outData, uint32_t inBitCount = 8 ) { ReadBits( &outData, inBitCount ); } + void Read( bool& outData ) { ReadBits( &outData, 1 ); } + + void Read( Quaternion& outQuat ); + + void ResetToCapacity( uint32_t inByteCapacity ) { mBitCapacity = inByteCapacity << 3; mBitHead = 0; } + + + void Read( std::string& inString ) + { + uint32_t elementCount; + Read( elementCount ); + inString.resize( elementCount ); + for( auto& element : inString ) + { + Read( element ); + } + } + + void Read( Vector3& inVector ); + +private: + char* mBuffer; + uint32_t mBitHead; + uint32_t mBitCapacity; + bool mIsBufferOwner; + +}; + diff --git a/RoboCat/Inc/RoboCatShared.h b/RoboCat/Inc/RoboCatShared.h index 83a3871a..91e54e7d 100644 --- a/RoboCat/Inc/RoboCatShared.h +++ b/RoboCat/Inc/RoboCatShared.h @@ -1,3 +1,5 @@ +#pragma once + #ifdef _WIN32 #define WIN32_LEAN_AND_MEAN #define NOMINMAX @@ -49,6 +51,17 @@ using std::unordered_set; class RoboCat; class GameObject; +#include "RoboMath.h" + +#include "TransmissionData.h" +#include "InFlightPacket.h" + +#include "LinkingContext.h" +#include "ByteSwap.h" +#include "MemoryBitStream.h" +#include "AckRange.h" + +#include "Timing.h" #include "StringUtils.h" #include "SocketAddress.h" #include "SocketAddressFactory.h" @@ -56,3 +69,4 @@ class GameObject; #include "TCPSocket.h" #include "SocketUtil.h" #include "OutputWindow.h" +#include "DeliveryNotificationManager.h" diff --git a/RoboCat/Inc/RoboMath.h b/RoboCat/Inc/RoboMath.h new file mode 100644 index 00000000..718080a9 --- /dev/null +++ b/RoboCat/Inc/RoboMath.h @@ -0,0 +1,199 @@ +class Vector3 +{ +public: + + float mX, mY, mZ; + + Vector3( float x, float y, float z ) : + mX( x ), + mY( y ), + mZ( z ) + {} + + Vector3() : + mX( 0.0f ), + mY( 0.0f ), + mZ( 0.0f ) + {} + + void Set( float x, float y, float z ) + { + mX = x; + mY = y; + mZ = z; + } + + friend Vector3 operator+( const Vector3& inLeft, const Vector3& inRight ) + { + return Vector3( inLeft.mX + inRight.mX, inLeft.mY + inRight.mY, inLeft.mZ + inRight.mZ ); + } + + friend Vector3 operator-( const Vector3& inLeft, const Vector3& inRight ) + { + return Vector3( inLeft.mX - inRight.mX, inLeft.mY - inRight.mY, inLeft.mZ - inRight.mZ ); + } + + // Component-wise multiplication + friend Vector3 operator*( const Vector3& inLeft, const Vector3& inRight ) + { + return Vector3( inLeft.mX * inRight.mX, inLeft.mY * inRight.mY, inLeft.mZ * inRight.mZ ); + } + + // Scalar multiply + friend Vector3 operator*( float inScalar, const Vector3& inVec ) + { + return Vector3( inVec.mX * inScalar, inVec.mY * inScalar, inVec.mZ * inScalar ); + } + + friend Vector3 operator*( const Vector3& inVec, float inScalar ) + { + return Vector3( inVec.mX * inScalar, inVec.mY * inScalar, inVec.mZ * inScalar ); + } + + Vector3& operator*=( float inScalar ) + { + mX *= inScalar; + mY *= inScalar; + mZ *= inScalar; + return *this; + } + + Vector3& operator+=( const Vector3& inRight ) + { + mX += inRight.mX; + mY += inRight.mY; + mZ += inRight.mZ; + return *this; + } + + Vector3& operator-=( const Vector3& inRight ) + { + mX -= inRight.mX; + mY -= inRight.mY; + mZ -= inRight.mZ; + return *this; + } + + float Length() + { + return sqrtf( mX * mX + mY * mY + mZ * mZ ); + } + + float LengthSq() + { + return mX * mX + mY * mY + mZ * mZ; + } + + float Length2D() + { + return sqrtf( mX * mX + mY * mY ); + } + + float LengthSq2D() + { + return mX * mX + mY * mY; + } + + void Normalize() + { + float length = Length(); + mX /= length; + mY /= length; + mZ /= length; + } + + void Normalize2D() + { + float length = Length2D(); + mX /= length; + mY /= length; + } + + friend float Dot( const Vector3& inLeft, const Vector3& inRight ) + { + return ( inLeft.mX * inRight.mX + inLeft.mY * inRight.mY + inLeft.mZ * inRight.mZ ); + } + + friend float Dot2D( const Vector3& inLeft, const Vector3& inRight ) + { + return ( inLeft.mX * inRight.mX + inLeft.mY * inRight.mY ); + } + + friend Vector3 Cross( const Vector3& inLeft, const Vector3& inRight ) + { + Vector3 temp; + temp.mX = inLeft.mY * inRight.mZ - inLeft.mZ * inRight.mY; + temp.mY = inLeft.mZ * inRight.mX - inLeft.mX * inRight.mZ; + temp.mZ = inLeft.mX * inRight.mY - inLeft.mY * inRight.mX; + return temp; + } + + friend Vector3 Lerp( const Vector3& inA, const Vector3& inB, float t ) + { + return Vector3( inA + t * ( inB - inA ) ); + } + + static const Vector3 Zero; + static const Vector3 UnitX; + static const Vector3 UnitY; + static const Vector3 UnitZ; +}; + + +class Quaternion +{ +public: + + float mX, mY, mZ, mW; + +}; + + +template< int tValue, int tBits > +struct GetRequiredBitsHelper +{ + enum { Value = GetRequiredBitsHelper< ( tValue >> 1 ), tBits + 1 >::Value }; +}; + +template< int tBits > +struct GetRequiredBitsHelper< 0, tBits > +{ + enum { Value = tBits }; +}; + +template< int tValue > +struct GetRequiredBits +{ + enum { Value = GetRequiredBitsHelper< tValue, 0 >::Value }; +}; + +namespace RoboMath +{ + const float PI = 3.1415926535f; + float GetRandomFloat(); + + Vector3 GetRandomVector( const Vector3& inMin, const Vector3& inMax ); + + inline bool Is2DVectorEqual( const Vector3& inA, const Vector3& inB ) + { + return ( inA.mX == inB.mX && inA.mY == inB.mY ); + } + + inline float ToDegrees( float inRadians ) + { + return inRadians * 180.0f / PI; + } +} + +namespace Colors +{ + static const Vector3 Black( 0.0f, 0.0f, 0.0f ); + static const Vector3 White( 1.0f, 1.0f, 1.0f ); + static const Vector3 Red( 1.0f, 0.0f, 0.0f ); + static const Vector3 Green( 0.0f, 1.0f, 0.0f ); + static const Vector3 Blue( 0.0f, 0.0f, 1.0f ); + static const Vector3 LightYellow( 1.0f, 1.0f, 0.88f ); + static const Vector3 LightBlue( 0.68f, 0.85f, 0.9f ); + static const Vector3 LightPink( 1.0f, 0.71f, 0.76f ); + static const Vector3 LightGreen( 0.56f, 0.93f, 0.56f ); +} diff --git a/RoboCat/Inc/Timing.h b/RoboCat/Inc/Timing.h new file mode 100644 index 00000000..b5af28d8 --- /dev/null +++ b/RoboCat/Inc/Timing.h @@ -0,0 +1,31 @@ +class Timing +{ +public: + + Timing(); + + void Update(); + + float GetDeltaTime() const { return mDeltaTime; } + + double GetTime() const; + + float GetTimef() const + { + return static_cast< float >( GetTime() ); + } + + float GetFrameStartTime() const { return mFrameStartTimef; } + + + static Timing sInstance; + +private: + float mDeltaTime; + uint64_t mDeltaTick; + + double mLastFrameStartTime; + float mFrameStartTimef; + double mPerfCountDuration; + +}; \ No newline at end of file diff --git a/RoboCat/Inc/TransmissionData.h b/RoboCat/Inc/TransmissionData.h new file mode 100644 index 00000000..cc599ec0 --- /dev/null +++ b/RoboCat/Inc/TransmissionData.h @@ -0,0 +1,9 @@ +class DeliveryNotificationManager; + +class TransmissionData +{ +public: + virtual void HandleDeliveryFailure( DeliveryNotificationManager* inDeliveryNotificationManager ) const = 0; + virtual void HandleDeliverySuccess( DeliveryNotificationManager* inDeliveryNotificationManager ) const = 0; +}; +typedef shared_ptr< TransmissionData > TransmissionDataPtr; \ No newline at end of file diff --git a/RoboCat/InputSystem.cpp b/RoboCat/InputSystem.cpp new file mode 100644 index 00000000..599b2968 --- /dev/null +++ b/RoboCat/InputSystem.cpp @@ -0,0 +1,94 @@ +#include"InputSystem.h" +#include"Event.h" +#include"EventSystem.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 5 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +InputSystem::InputSystem() +{ + mpEventQueue = nullptr; + + mPosX = 0; + mPosY = 0; + + mDeleted = false; +} + +InputSystem::~InputSystem() +{ + cleanup(); +} + +void InputSystem::init() +{ + mpEventQueue = al_create_event_queue(); + al_register_event_source(mpEventQueue, al_get_keyboard_event_source()); + al_register_event_source(mpEventQueue, al_get_mouse_event_source()); +} + +void InputSystem::cleanup() +{ + if (!mDeleted) + { + al_uninstall_keyboard(); + al_uninstall_mouse(); + + al_unregister_event_source(mpEventQueue, al_get_keyboard_event_source()); + al_unregister_event_source(mpEventQueue, al_get_mouse_event_source()); + al_destroy_event_queue(mpEventQueue); + + mDeleted = true; + } +} + +void InputSystem::update() +{ + ALLEGRO_EVENT event; + + while (al_get_next_event(mpEventQueue, &event)) + { + switch (event.type) + { + case ALLEGRO_EVENT_KEY_UP: + { + KeyEvent myEvent(KEY_UP_EVENT, event.keyboard.keycode); + myEvent.setPressed(false); + } + break; + + case ALLEGRO_EVENT_KEY_DOWN: + { + KeyEvent myEvent(KEY_DOWN_EVENT, event.keyboard.keycode); + EventSystem::getInstance()->fireEvent(myEvent); + } + break; + + case ALLEGRO_EVENT_MOUSE_AXES: + { + MouseEvent mouseEvent(MOUSE_MOVE_EVENT, event.mouse.x, event.mouse.y); + EventSystem::getInstance()->fireEvent(mouseEvent); + } + break; + + case ALLEGRO_EVENT_MOUSE_BUTTON_UP: + { + ClickEvent myEvent(MOUSE_UP_EVENT, event.mouse.button); + EventSystem::getInstance()->fireEvent(myEvent); + } + break; + case ALLEGRO_EVENT_MOUSE_BUTTON_DOWN: + { + ClickEvent myEvent(MOUSE_DOWN_EVENT, event.mouse.button); + EventSystem::getInstance()->fireEvent(myEvent); + } + break; + + } + } +} \ No newline at end of file diff --git a/RoboCat/InputSystem.h b/RoboCat/InputSystem.h new file mode 100644 index 00000000..61bbfb5a --- /dev/null +++ b/RoboCat/InputSystem.h @@ -0,0 +1,172 @@ +#pragma once +#include +#include +#include +#include +#include"../common/DeanLib/include/Trackable.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 5 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +using namespace std; + +class Event; +class EventSystem; + +class InputSystem +{ +public: + InputSystem(); + ~InputSystem(); + + void init(); + void cleanup(); + void update(); + + // This enum is all of the keycodes used by the input system. I highly recommend collapsing this in VS. +// It should also be noted that these are mapped identically to the Allegro keycodes and can actually replace them in code - wes + enum Keycode + { + KEY_A = 1, + KEY_B, + KEY_C, + KEY_D, + KEY_E, + KEY_F, + KEY_G, + KEY_H, + KEY_I, + KEY_J, + KEY_K, + KEY_L, + KEY_M, + KEY_N, + KEY_O, + KEY_P, + KEY_Q, + KEY_R, + KEY_S, + KEY_T, + KEY_U, + KEY_V, + KEY_W, + KEY_X, + KEY_Y, + KEY_Z, + KEY_0, + KEY_1, + KEY_2, + KEY_3, + KEY_4, + KEY_5, + KEY_6, + KEY_7, + KEY_8, + KEY_9, + KEY_PAD_0, + KEY_PAD_1, + KEY_PAD_2, + KEY_PAD_3, + KEY_PAD_4, + KEY_PAD_5, + KEY_PAD_6, + KEY_PAD_7, + KEY_PAD_8, + KEY_PAD_9, + KEY_F1, + KEY_F2, + KEY_F3, + KEY_F4, + KEY_F5, + KEY_F6, + KEY_F7, + KEY_F8, + KEY_F9, + KEY_F10, + KEY_F11, + KEY_F12, + KEY_ESC, + KEY_TILDE, + KEY_MINUS, + KEY_EQUALS, + KEY_BACKSPACE, + KEY_TAB, + KEY_OPENBRACE, + KEY_CLOSEBRACE, + KEY_ENTER, + KEY_SEMICOLON, + KEY_QUOTE, + KEY_BACKSLASH, + KEY_BACKSLASH2, + KEY_COMMA, + KEY_FULLSTOP, + KEY_SLASH, + KEY_SPACE, + KEY_INSERT, + KEY_DELETE, + KEY_HOME, + KEY_END, + KEY_PGUP, + KEY_PGDN, + KEY_LEFT, + KEY_RIGHT, + KEY_UP, + KEY_DOWN, + KEY_PAD_SLASH, + KEY_PAD_ASTERISK, + KEY_PAD_MINUS, + KEY_PAD_PLUS, + KEY_PAD_DELETE, + KEY_PAD_ENTER, + KEY_PRINTSCREEN, + KEY_PAUSE, + KEY_ABNT_C1, + KEY_YEN, + KEY_KANA, + KEY_CONVERT, + KEY_NOCONVERT, + KEY_AT, + KEY_CIRCUMFLEX, + KEY_COLON2, + KEY_KANJI, + KEY_LSHIFT, + KEY_RSHIFT, + KEY_LCTRL, + KEY_RCTRL, + KEY_ALT, + KEY_ALTGR, + KEY_LWIN, + KEY_RWIN, + KEY_MENU, + KEY_SCROLLLOCK, + KEY_NUMLOCK, + KEY_CAPSLOCK, + KEY_PAD_EQUALS, + KEY_BACKQUOTE, + KEY_SEMICOLON2, + KEY_COMMAND, + }; + + // This is the same as Keycode but specifically for mouse buttons + enum Mousecode + { + MOUSE_1 = 1, + MOUSE_2, + MOUSE_3, + MOUSE_4, + }; + +private: + ALLEGRO_EVENT_QUEUE* mpEventQueue; + + int mPosX; + int mPosY; + + bool mDeleted; +}; + diff --git a/RoboCat/InputTranslator.cpp b/RoboCat/InputTranslator.cpp new file mode 100644 index 00000000..169206aa --- /dev/null +++ b/RoboCat/InputTranslator.cpp @@ -0,0 +1,111 @@ +#include"InputTranslator.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 5 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +InputTranslator::InputTranslator(InputSystem* input) +{ + //EventSystem::initInstance(); + mEventSystem = EventSystem::getInstance(); + mInputSystem = input; + mDeleted = false; +} + +InputTranslator::~InputTranslator() +{ + cleanup(); +} + +void InputTranslator::init() +{ + EventSystem::getInstance()->addListener(KEY_UP_EVENT, this); + EventSystem::getInstance()->addListener(KEY_DOWN_EVENT, this); + EventSystem::getInstance()->addListener(MOUSE_UP_EVENT, this); + EventSystem::getInstance()->addListener(MOUSE_DOWN_EVENT, this); + EventSystem::getInstance()->addListener(MOUSE_MOVE_EVENT, this); +} + +void InputTranslator::cleanup() +{ + if (!mDeleted) + { + mEventSystem->removeListenerFromAllEvents(this); + mDeleted = true; + } +} + +void InputTranslator::handleEvent(const Event& event) +{ + switch (event.getType()) + { + case KEY_DOWN_EVENT: + { + const KeyEvent& myEvent = static_cast(event); + + if (myEvent.getKeyCode() == mInputSystem->KEY_SPACE) + { + GameEvent eventToFire(TOGGLE_ALL_UNIT_ANIMATIONS_EVENT); + mEventSystem->fireEvent(eventToFire); + } + + if (myEvent.getKeyCode() == mInputSystem->KEY_ENTER) + { + GameEvent eventToFire(CHANGE_UNIT_ANIMATION_EVENT); + mEventSystem->fireEvent(eventToFire); + } + + if (myEvent.getKeyCode() == mInputSystem->KEY_ESC) + { + GameEvent eventToFire(EXIT_GAME_EVENT); + mEventSystem->fireEvent(eventToFire); + } + } + break; + + case KEY_UP_EVENT: + { + } + break; + + case MOUSE_DOWN_EVENT: + { + const ClickEvent& myEvent = static_cast(event); + + if (myEvent.getClick() == mInputSystem->MOUSE_1) + { + GameEvent eventToFire(CREATE_UNIT_EVENT); + mEventSystem->fireEvent(eventToFire); + } + + if (myEvent.getClick() == mInputSystem->MOUSE_2) + { + GameEvent eventToFire(DESTROY_UNIT_EVENT); + mEventSystem->fireEvent(eventToFire); + } + } + break; + + case MOUSE_UP_EVENT: + { + } + break; + + case MOUSE_MOVE_EVENT: + { + const MouseEvent& myEvent = static_cast(event); + GameEvent eventToFire(UPDATE_MOUSE_POSITION_EVENT, myEvent.getPosX(), myEvent.getPosY()); + mEventSystem->fireEvent(eventToFire); + } + break; + + default: + GameEvent invalid(INVALID_TYPE_OF_EVENT); + mEventSystem->fireEvent(invalid); + break; + } +} diff --git a/RoboCat/InputTranslator.h b/RoboCat/InputTranslator.h new file mode 100644 index 00000000..08ceef94 --- /dev/null +++ b/RoboCat/InputTranslator.h @@ -0,0 +1,35 @@ +#pragma once +#include +#include"Event.h" +#include"EventListener.h" +#include"EventSystem.h" +#include"InputSystem.h" +#include"GameEvent.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 5 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +using namespace std; + +class InputTranslator : public EventListener +{ +public: + InputTranslator(InputSystem* input); + ~InputTranslator(); + + void init(); + void cleanup(); + + void handleEvent(const Event& event); +private: + EventSystem* mEventSystem; + InputSystem* mInputSystem; + + bool mDeleted; +}; + diff --git a/RoboCat/NetworkManager.cpp b/RoboCat/NetworkManager.cpp new file mode 100644 index 00000000..1a79e614 --- /dev/null +++ b/RoboCat/NetworkManager.cpp @@ -0,0 +1,319 @@ +#include "NetworkManager.h" + +NetworkManager::NetworkManager() +{ + mpEventSystem = EventSystem::getInstance(); + + mpGame = nullptr; + mpSocket = nullptr; +} + +NetworkManager::NetworkManager(int dropChance) +{ + mpEventSystem = EventSystem::getInstance(); + + mpGame = nullptr; + mpSocket = nullptr; + + mDropChance = dropChance; + srand(time(NULL)); +} + +NetworkManager::~NetworkManager() +{ +} + +bool NetworkManager::initServer(std::string serverPort) +{ + SocketUtil::StaticInit(); + + TCPSocketPtr listenSocket = SocketUtil::CreateTCPSocket(SocketAddressFamily::INET); + if (listenSocket == nullptr) + { + SocketUtil::ReportError("Creating listening socket"); + ExitProcess(1); + } + + listenSocket->SetNonBlockingMode(true); + + std::cout << "Listening socket created" << endl; + + // Bind() - "Bind" socket -> tells OS we want to use a specific address + + SocketAddressPtr listenAddress = SocketAddressFactory::CreateIPv4FromString("0.0.0.0:" + serverPort); + if (listenAddress == nullptr) + { + SocketUtil::ReportError("Creating listen address"); + ExitProcess(1); + } + + if (listenSocket->Bind(*listenAddress) != NO_ERROR) + { + SocketUtil::ReportError("Binding listening socket"); + // This doesn't block! + ExitProcess(1); + } + + LOG("%s", "Bound listening socket"); + + // Listen() - Listen on socket -> Non-blocking; tells OS we care about incoming connections on this socket + if (listenSocket->Listen() != NO_ERROR) + { + SocketUtil::ReportError("Listening on listening socket"); + ExitProcess(1); + } + + LOG("%s", "Listening on socket"); + + // Accept() - Accept on socket -> Blocking; Waits for incoming connection and completes TCP handshake + + LOG("%s", "Waiting to accept connections..."); + SocketAddress incomingAddress; + TCPSocketPtr connSocket = listenSocket->Accept(incomingAddress); + while (connSocket == nullptr) + { + connSocket = listenSocket->Accept(incomingAddress); + // SocketUtil::ReportError("Accepting connection"); + // ExitProcess(1); + } + + LOG("Accepted connection from %s", incomingAddress.ToString().c_str()); + + *mpSocket = connSocket; + + if (!mpSocket) + { + return false; + } + + else + { + Game::initInstance(); + mpGame = Game::getInstance(); + mpGame->init(); + return true; + } +} + +bool NetworkManager::connect(std::string clientIP, std::string clientPort) +{ + SocketUtil::StaticInit(); + + TCPSocketPtr clientSocket = SocketUtil::CreateTCPSocket(SocketAddressFamily::INET); + if (clientSocket == nullptr) + { + SocketUtil::ReportError("Creating client socket"); + ExitProcess(1); + return false; + } + + LOG("%s", "Client socket created"); + + std::string address = "0.0.0.0:0"; + SocketAddressPtr clientAddress = SocketAddressFactory::CreateIPv4FromString(address.c_str()); + if (clientAddress == nullptr) + { + SocketUtil::ReportError("Creating client address"); + ExitProcess(1); + return false; + } + + if (clientSocket->Bind(*clientAddress) != NO_ERROR) + { + SocketUtil::ReportError("Binding client socket"); + // This doesn't block! + ExitProcess(1); + } + + LOG("%s", "Bound client socket"); + + // Connect() -> Connect socket to remote host + + SocketAddressPtr servAddress = SocketAddressFactory::CreateIPv4FromString(clientIP + ":" + clientPort); + if (servAddress == nullptr) + { + SocketUtil::ReportError("Creating server address"); + ExitProcess(1); + } + + if (clientSocket->Connect(*servAddress) != NO_ERROR) + { + SocketUtil::ReportError("Connecting to server"); + ExitProcess(1); + } + + mpSocket = &clientSocket; + + if (!mpSocket) + { + return false; + } + else + { + Game::initInstance(); + mpGame = Game::getInstance(); + mpGame->init(); + return true; + } +} + +void NetworkManager::createObject(Unit* obj, int objID) +{ + mvGameObjects.push_back(pair(obj, objID)); +} + +void NetworkManager::sendData(PacketTypes packet, int ID, Unit* obj) +{ + bool needsConfirmPacket = false; + bool destroyed = false; + OutputMemoryBitStream MemStream; + MemStream.Write(packet); + + switch (packet) + { + case CREATE_OBJECT: + { + needsConfirmPacket = true; + createObject(obj, ID); + + break; + } + case UPDATE_OBJECT: + { + break; + } + case DESTROY_OBJECT: + { + needsConfirmPacket = true; + if (mvGameObjects.size() > 0) + { + std::vector>::iterator iter; + for (iter = mvGameObjects.begin(); iter != mvGameObjects.end(); iter++) + { + mvGameObjects.erase(iter); + destroyed = true; + break; + } + } + break; + } + default: + return; + } + + (*mpSocket)->Send(MemStream.GetBufferPtr(), MemStream.GetBitLength()); + + if (destroyed) + { + mCurrentID--; + } + + if (needsConfirmPacket) + { + mvPacketResendQueue.push_back(std::pair, int>(std::pair + (MemStream.GetBufferPtr(), MemStream.GetBitLength()), mCurrentID)); + } +} + +void NetworkManager::receiveData() +{ + char buffer[4096]; + int32_t bytesReceived = (*mpSocket)->Receive(buffer, 4096); + + int drop = rand() % 101; + + + + if (bytesReceived > 0) + { + InputMemoryBitStream MemStream = InputMemoryBitStream(buffer, 4096); + PacketTypes recievePacketType; + MemStream.Read(recievePacketType); + + if (drop > mDropChance) + { + int networkID; + MemStream.Read(networkID); + if (mCurrentID < networkID) + { + mCurrentID = networkID; + } + + switch (recievePacketType) + { + case CREATE_OBJECT: + { + //MemStream.Read(mvGameObjects[mCurrentID]); + break; + } + + case UPDATE_OBJECT: + { + if (mvGameObjects[networkID].first != nullptr) + { + //MemStream.Read(mvGameObjects[networkID]); + break; + } + else + { + std::cout << "Nothing to update.\n"; + } + + break; + } + + case DESTROY_OBJECT: + { + if (mvGameObjects.size() > 0) + { + std::vector>::iterator iter; + for (iter = mvGameObjects.begin(); iter != mvGameObjects.end(); iter++) + { + mvGameObjects.erase(iter); + mCurrentID--; + break; + } + } + break; + } + default: + break; + } + + int ID; + MemStream.Read(ID); + sendConfirmation(ID); + } + } + + else if (bytesReceived <= -10035) + { + std::cout << "Connection terminated"; + exit(0); + } +} + +bool NetworkManager::waitForConfirmation(int ID) +{ + if (mvPacketResendQueue.size() > 0) + { + std::vector, int>>::iterator iter; + for (iter = mvPacketResendQueue.begin(); iter != mvPacketResendQueue.end(); iter++) + { + if (iter->second == ID) + { + mvPacketResendQueue.erase(iter); + } + return true; + } + } + return false; +} + +void NetworkManager::sendConfirmation(int ID) +{ + OutputMemoryBitStream* MemStream = new OutputMemoryBitStream(); + MemStream->Write(CONFIRM_PACKET); + MemStream->Write(ID); + (*mpSocket)->Send(MemStream->GetBufferPtr(), MemStream->GetBitLength()); +} diff --git a/RoboCat/NetworkManager.h b/RoboCat/NetworkManager.h new file mode 100644 index 00000000..3a3a5b7f --- /dev/null +++ b/RoboCat/NetworkManager.h @@ -0,0 +1,61 @@ +#pragma once +#include "RoboCatPCH.h" +#include "../common/DeanLib/include/Trackable.h" +#include "Game.h" +#include "GameEvent.h" +#include "EventSystem.h" +#include "Unit.h" +#include +#include + +enum PacketTypes +{ + CREATE_OBJECT, + UPDATE_OBJECT, + DESTROY_OBJECT, + CONFIRM_PACKET +}; + +class NetworkManager : public Trackable +{ +public: + + static NetworkManager* GetInstance() + { + if (mpsNetworkInstance) + { + delete mpsNetworkInstance; + mpsNetworkInstance = nullptr; + } + mpsNetworkInstance = new NetworkManager; + return mpsNetworkInstance; + } + + NetworkManager(); + NetworkManager(int dropChance); + ~NetworkManager(); + + bool initServer(std::string serverPort); + bool connect(std::string clientIP, std::string clientPort); + + void createObject(Unit* obj, int objID); + + void sendData(PacketTypes packet, int ID, Unit* obj = nullptr); + void receiveData(); + + bool waitForConfirmation(int ID); + void sendConfirmation(int ID); + +private: + + Game* mpGame; + TCPSocketPtr* mpSocket; + static NetworkManager* mpsNetworkInstance; + EventSystem* mpEventSystem; + + std::vector> mvGameObjects; + std::vector, int>> mvPacketResendQueue; + int mCurrentID; + + int mDropChance; +}; \ No newline at end of file diff --git a/RoboCat/Sprite.cpp b/RoboCat/Sprite.cpp new file mode 100644 index 00000000..26f7eaff --- /dev/null +++ b/RoboCat/Sprite.cpp @@ -0,0 +1,41 @@ +#include"Sprite.h" +#include"GraphicsBuffer.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 2 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +Sprite::Sprite() +{ + mHeight = 0; + mWidth = 0; + mLocX = 0; + mLocY = 0; + mpGraphicsBuffer = nullptr; +} + +Sprite::Sprite(GraphicsBuffer* graphicsBuffer, int locX, int locY, int height, int width) +{ + mHeight = height; + mWidth = width; + mLocX = locX; + mLocY = locY; + mpGraphicsBuffer = graphicsBuffer; +} + +Sprite::~Sprite() +{ +} + +void Sprite::spriteInit(int width, int height, int locX, int locY, GraphicsBuffer* buffer) +{ + mWidth = width; + mHeight = height; + mLocX = locX; + mLocY = locY; + mpGraphicsBuffer = buffer; +} \ No newline at end of file diff --git a/RoboCat/Sprite.h b/RoboCat/Sprite.h new file mode 100644 index 00000000..ab880b69 --- /dev/null +++ b/RoboCat/Sprite.h @@ -0,0 +1,39 @@ +#pragma once +#include +#include +#include +#include"../common/DeanLib/include/Trackable.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 2 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +class GraphicsBuffer; + +class Sprite : public Trackable +{ +public: + Sprite(); + Sprite(GraphicsBuffer* graphicsBuffer, int locX, int locY, int height, int width); + ~Sprite(); + + int getHeight() { return mHeight; } + int getWidth() { return mWidth; } + int getLocX() { return mLocX; } + int getLocY() { return mLocY; } + void spriteInit(int width, int height, int locX, int locY, GraphicsBuffer* buffer); + GraphicsBuffer* getGraphicsBuffer() { return mpGraphicsBuffer; } + +private: + + int mHeight; + int mWidth; + int mLocX; + int mLocY; + + GraphicsBuffer* mpGraphicsBuffer; +}; \ No newline at end of file diff --git a/RoboCat/Src/AckRange.cpp b/RoboCat/Src/AckRange.cpp new file mode 100644 index 00000000..99bed803 --- /dev/null +++ b/RoboCat/Src/AckRange.cpp @@ -0,0 +1,33 @@ +#include "RoboCatPCH.h" + +void AckRange::Write( OutputMemoryBitStream& inOutputStream ) const +{ + inOutputStream.Write( mStart ); + bool hasCount = mCount > 1; + inOutputStream.Write( hasCount ); + if( hasCount ) + { + //most you can ack is 255... + uint32_t countMinusOne = mCount - 1; + uint8_t countToAck = countMinusOne > 255 ? 255 : static_cast< uint8_t >( countMinusOne ); + inOutputStream.Write( countToAck ); + } +} + +void AckRange::Read( InputMemoryBitStream& inInputStream ) +{ + inInputStream.Read( mStart ); + bool hasCount; + inInputStream.Read( hasCount ); + if( hasCount ) + { + uint8_t countMinusOne; + inInputStream.Read( countMinusOne ); + mCount = countMinusOne + 1; + } + else + { + //default! + mCount = 1; + } +} \ No newline at end of file diff --git a/RoboCat/Src/DeliveryNotificationManager.cpp b/RoboCat/Src/DeliveryNotificationManager.cpp new file mode 100644 index 00000000..ea85baa9 --- /dev/null +++ b/RoboCat/Src/DeliveryNotificationManager.cpp @@ -0,0 +1,209 @@ +#include "RoboCatPCH.h" + +namespace +{ + const float kDelayBeforeAckTimeout = 0.5f; +} + +DeliveryNotificationManager::DeliveryNotificationManager( bool inShouldSendAcks, bool inShouldProcessAcks ) : +mNextOutgoingSequenceNumber( 0 ), +mNextExpectedSequenceNumber( 0 ), +//everybody starts at 0... +mShouldSendAcks( inShouldSendAcks ), +mShouldProcessAcks( inShouldProcessAcks ), +mDeliveredPacketCount( 0 ), +mDroppedPacketCount( 0 ), +mDispatchedPacketCount( 0 ) +{ +} + + +//we're going away- log how well we did... +DeliveryNotificationManager::~DeliveryNotificationManager() +{ + LOG( "DNM destructor. Delivery rate %d%%, Drop rate %d%%", + ( 100 * mDeliveredPacketCount ) / mDispatchedPacketCount, + ( 100 * mDroppedPacketCount ) / mDispatchedPacketCount ); +} + + + +InFlightPacket* DeliveryNotificationManager::WriteSequenceNumber( OutputMemoryBitStream& inOutputStream ) +{ + //write the sequence number, but also create an inflight packet for this... + PacketSequenceNumber sequenceNumber = mNextOutgoingSequenceNumber++; + inOutputStream.Write( sequenceNumber ); + + ++mDispatchedPacketCount; + + if( mShouldProcessAcks ) + { + mInFlightPackets.emplace_back( sequenceNumber ); + + return &mInFlightPackets.back(); + } + else + { + return nullptr; + } +} + +void DeliveryNotificationManager::WriteAckData( OutputMemoryBitStream& inOutputStream ) +{ + //we usually will only have one packet to ack + //so we'll follow that with a 0 bit if that's the case + //however, if we have more than 1, we'll make that 1 bit a 1 and then write 8 bits of how many packets + //we could do some statistical analysis to determine if this is the best strategy but we'll use it for now + + //do we have any pending acks? + //if so, write a 1 bit and write the first range + //otherwise, write 0 bit + bool hasAcks = ( mPendingAcks.size() > 0 ); + + inOutputStream.Write( hasAcks ); + if( hasAcks ) + { + //note, we could write all the acks + mPendingAcks.front().Write( inOutputStream ); + mPendingAcks.pop_front(); + } +} + + + +//returns wether to drop the packet- if sequence number is too low! +bool DeliveryNotificationManager::ProcessSequenceNumber( InputMemoryBitStream& inInputStream ) +{ + PacketSequenceNumber sequenceNumber; + + inInputStream.Read( sequenceNumber ); + if( sequenceNumber == mNextExpectedSequenceNumber ) + { + mNextExpectedSequenceNumber = sequenceNumber + 1; + //is this what we expect? great, let's add an ack to our pending list + if( mShouldSendAcks ) + { + AddPendingAck( sequenceNumber ); + } + //and let's continue processing this packet... + return true; + } + //is the sequence number less than our current expected sequence? silently drop it. + //if this is due to wrapping around, we might fail to ack some packets that we should ack, but they'll get resent, so it's not a big deal + //note that we don't have to re-ack it because our system doesn't reuse sequence numbers + else if( sequenceNumber < mNextExpectedSequenceNumber ) + { + return false; + } + else if( sequenceNumber > mNextExpectedSequenceNumber ) + { + //we missed a lot of packets! + //so our next expected packet comes after this one... + mNextExpectedSequenceNumber = sequenceNumber + 1; + //we should nack the missing packets..this will happen automatically inside AddPendingAck because + //we're adding an unconsequitive ack + //and then we can ack this and process it + if( mShouldSendAcks ) + { + AddPendingAck( sequenceNumber ); + } + return true; + } + + //drop packet if we couldn't even read sequence number! + return false; +} + + +//in each packet we can ack a range +//anything in flight before the range will be considered nackd by the other side immediately +void DeliveryNotificationManager::ProcessAcks( InputMemoryBitStream& inInputStream ) +{ + + bool hasAcks; + inInputStream.Read( hasAcks ); + if( hasAcks ) + { + AckRange ackRange; + ackRange.Read( inInputStream ); + + //for each InfilghtPacket with a sequence number less than the start, handle delivery failure... + PacketSequenceNumber nextAckdSequenceNumber = ackRange.GetStart(); + uint32_t onePastAckdSequenceNumber = nextAckdSequenceNumber + ackRange.GetCount(); + while( nextAckdSequenceNumber < onePastAckdSequenceNumber && !mInFlightPackets.empty() ) + { + const auto& nextInFlightPacket = mInFlightPackets.front(); + //if the packet has a lower sequence number, we didn't get an ack for it, so it probably wasn't delivered + PacketSequenceNumber nextInFlightPacketSequenceNumber = nextInFlightPacket.GetSequenceNumber(); + if( nextInFlightPacketSequenceNumber < nextAckdSequenceNumber ) + { + //copy this so we can remove it before handling the failure- we don't want to find it when checking for state + auto copyOfInFlightPacket = nextInFlightPacket; + mInFlightPackets.pop_front(); + HandlePacketDeliveryFailure( copyOfInFlightPacket ); + } + else if( nextInFlightPacketSequenceNumber == nextAckdSequenceNumber ) + { + HandlePacketDeliverySuccess( nextInFlightPacket ); + //received! + mInFlightPackets.pop_front(); + //decrement count, advance nextAckdSequenceNumber + ++nextAckdSequenceNumber; + } + else if( nextInFlightPacketSequenceNumber > nextAckdSequenceNumber ) + { + //we've already ackd some packets in here. + //keep this packet in flight, but keep going through the ack... + ++nextAckdSequenceNumber; + } + } + } +} + +void DeliveryNotificationManager::ProcessTimedOutPackets() +{ + float timeoutTime = Timing::sInstance.GetTimef() - kDelayBeforeAckTimeout; + + while( !mInFlightPackets.empty() ) + { + const auto& nextInFlightPacket = mInFlightPackets.front(); + + //was this packet dispatched before the current time minus the timeout duration? + if( nextInFlightPacket.GetTimeDispatched() < timeoutTime ) + { + //it failed! let us know about that + HandlePacketDeliveryFailure( nextInFlightPacket ); + mInFlightPackets.pop_front(); + } + else + { + //it wasn't, and packets are all in order by time here, so we know we don't have to check farther + break; + } + } +} + +void DeliveryNotificationManager::AddPendingAck( PacketSequenceNumber inSequenceNumber ) +{ + //if you don't have a range yet, or you can't correctly extend the final range with the sequence number, + //start a new range + if( mPendingAcks.size() == 0 || !mPendingAcks.back().ExtendIfShould( inSequenceNumber ) ) + { + mPendingAcks.emplace_back( inSequenceNumber ); + } +} + + +void DeliveryNotificationManager::HandlePacketDeliveryFailure( const InFlightPacket& inFlightPacket ) +{ + ++mDroppedPacketCount; + inFlightPacket.HandleDeliveryFailure( this ); + +} + + +void DeliveryNotificationManager::HandlePacketDeliverySuccess( const InFlightPacket& inFlightPacket ) +{ + ++mDeliveredPacketCount; + inFlightPacket.HandleDeliverySuccess( this ); +} diff --git a/RoboCat/Src/InFlightPacket.cpp b/RoboCat/Src/InFlightPacket.cpp new file mode 100644 index 00000000..251abe36 --- /dev/null +++ b/RoboCat/Src/InFlightPacket.cpp @@ -0,0 +1,25 @@ +#include "RoboCatPCH.h" + +InFlightPacket::InFlightPacket( PacketSequenceNumber inSequenceNumber ) : +mSequenceNumber( inSequenceNumber ), +mTimeDispatched( Timing::sInstance.GetTimef() ) +{ + //null out other transmision data params... +} + + +void InFlightPacket::HandleDeliveryFailure( DeliveryNotificationManager* inDeliveryNotificationManager ) const +{ + for( const auto& pair : mTransmissionDataMap ) + { + pair.second->HandleDeliveryFailure( inDeliveryNotificationManager ); + } +} + +void InFlightPacket::HandleDeliverySuccess( DeliveryNotificationManager* inDeliveryNotificationManager ) const +{ + for( const auto& pair : mTransmissionDataMap ) + { + pair.second->HandleDeliverySuccess( inDeliveryNotificationManager ); + } +} \ No newline at end of file diff --git a/RoboCat/Src/Main.cpp b/RoboCat/Src/Main.cpp index f8c6c7d0..63740996 100644 --- a/RoboCat/Src/Main.cpp +++ b/RoboCat/Src/Main.cpp @@ -1,14 +1,17 @@ #include "RoboCatPCH.h" - #include -#include -#include -#include +#include "RoboCat/Game.h" +#include"./RoboCat/EventSystem.h" +#include "./common/DeanLib/include/MemoryTracker.h" +#include "./RoboCat/NetworkManager.h" +#include "./RoboCat/InputSystem.h" +#include "./RoboCat/InputTranslator.h" +#include +#include #if _WIN32 - int main(int argc, const char** argv) { UNREFERENCED_PARAMETER(argc); @@ -23,31 +26,36 @@ int main(int argc, const char** argv) #endif SocketUtil::StaticInit(); + srand(time(0)); + int dropChance = rand() % 101; + + //Assignment 2 code here + NetworkManager* mpNetManager = new NetworkManager(dropChance); + InputSystem* mpInput = new InputSystem(); + InputTranslator* mpTranslator = new InputTranslator(mpInput); + + std::string serverPort = "8080"; + std::string clientIP = "127.0.0.1"; + std::string clientPort = "8081"; - OutputWindow win; - - std::thread t([&win]() - { - int msgNo = 1; - while (true) - { - std::this_thread::sleep_for(std::chrono::milliseconds(250)); - std::string msgIn("~~~auto message~~~"); - std::stringstream ss(msgIn); - ss << msgNo; - win.Write(ss.str()); - msgNo++; - } - }); - - while (true) + bool serverInited = false; + bool clientInited = false; + + int networkID; + bool portnumber = StringUtils::GetCommandLineArg(1) == "8080"; + + if (portnumber) + { + serverInited = mpNetManager->initServer(serverPort); + networkID = 0; + } + else { - std::string input; - std::getline(std::cin, input); - win.WriteFromStdin(input); + clientInited = mpNetManager->connect(clientIP, serverPort); + networkID = 1; } - SocketUtil::CleanUp(); + system("pause"); return 0; } diff --git a/RoboCat/Src/MemoryBitStream.cpp b/RoboCat/Src/MemoryBitStream.cpp new file mode 100644 index 00000000..39958ad7 --- /dev/null +++ b/RoboCat/Src/MemoryBitStream.cpp @@ -0,0 +1,171 @@ +#include "RoboCatPCH.h" + +void OutputMemoryBitStream::WriteBits( uint8_t inData, + uint32_t inBitCount ) +{ + uint32_t nextBitHead = mBitHead + static_cast< uint32_t >( inBitCount ); + + if( nextBitHead > mBitCapacity ) + { + ReallocBuffer( std::max( mBitCapacity * 2, nextBitHead ) ); + } + + //calculate the byteOffset into our buffer + //by dividing the head by 8 + //and the bitOffset by taking the last 3 bits + uint32_t byteOffset = mBitHead >> 3; + uint32_t bitOffset = mBitHead & 0x7; + + uint8_t currentMask = ~( 0xff << bitOffset ); + mBuffer[ byteOffset ] = ( mBuffer[ byteOffset ] & currentMask ) | ( inData << bitOffset ); + + //calculate how many bits were not yet used in + //our target byte in the buffer + uint32_t bitsFreeThisByte = 8 - bitOffset; + + //if we needed more than that, carry to the next byte + if( bitsFreeThisByte < inBitCount ) + { + //we need another byte + mBuffer[ byteOffset + 1 ] = inData >> bitsFreeThisByte; + } + + mBitHead = nextBitHead; +} + +void OutputMemoryBitStream::WriteBits( const void* inData, uint32_t inBitCount ) +{ + const char* srcByte = static_cast< const char* >( inData ); + //write all the bytes + while( inBitCount > 8 ) + { + WriteBits( *srcByte, 8 ); + ++srcByte; + inBitCount -= 8; + } + //write anything left + if( inBitCount > 0 ) + { + WriteBits( *srcByte, inBitCount ); + } +} + +void OutputMemoryBitStream::Write( const Vector3& inVector ) +{ + Write( inVector.mX ); + Write( inVector.mY ); + Write( inVector.mZ ); +} + +void InputMemoryBitStream::Read( Vector3& outVector ) +{ + Read( outVector.mX ); + Read( outVector.mY ); + Read( outVector.mZ ); +} + +void OutputMemoryBitStream::Write( const Quaternion& inQuat ) +{ + float precision = ( 2.f / 65535.f ); + Write( ConvertToFixed( inQuat.mX, -1.f, precision ), 16 ); + Write( ConvertToFixed( inQuat.mY, -1.f, precision ), 16 ); + Write( ConvertToFixed( inQuat.mZ, -1.f, precision ), 16 ); + Write( inQuat.mW < 0 ); +} + + + +void OutputMemoryBitStream::ReallocBuffer( uint32_t inNewBitLength ) +{ + if( mBuffer == nullptr ) + { + //just need to memset on first allocation + mBuffer = static_cast( std::malloc( inNewBitLength >> 3 ) ); + memset( mBuffer, 0, inNewBitLength >> 3 ); + } + else + { + //need to memset, then copy the buffer + char* tempBuffer = static_cast( std::malloc( inNewBitLength >> 3 ) ); + memset( tempBuffer, 0, inNewBitLength >> 3 ); + memcpy( tempBuffer, mBuffer, mBitCapacity >> 3 ); + std::free( mBuffer ); + mBuffer = tempBuffer; + } + + //handle realloc failure + //... + mBitCapacity = inNewBitLength; +} + + +void test1() +{ + OutputMemoryBitStream mbs; + + mbs.WriteBits( 11, 5 ); + mbs.WriteBits( 52, 6 ); +} + +void InputMemoryBitStream::ReadBits( uint8_t& outData, uint32_t inBitCount ) +{ + uint32_t byteOffset = mBitHead >> 3; + uint32_t bitOffset = mBitHead & 0x7; + + outData = static_cast< uint8_t >( mBuffer[ byteOffset ] ) >> bitOffset; + + uint32_t bitsFreeThisByte = 8 - bitOffset; + if( bitsFreeThisByte < inBitCount ) + { + //we need another byte + outData |= static_cast< uint8_t >( mBuffer[ byteOffset + 1 ] ) << bitsFreeThisByte; + } + + //don't forget a mask so that we only read the bit we wanted... + outData &= ( ~( 0x00ff << inBitCount ) ); + + mBitHead += inBitCount; +} + +void InputMemoryBitStream::ReadBits( void* outData, uint32_t inBitCount ) +{ + uint8_t* destByte = reinterpret_cast< uint8_t* >( outData ); + //write all the bytes + while( inBitCount > 8 ) + { + ReadBits( *destByte, 8 ); + ++destByte; + inBitCount -= 8; + } + //write anything left + if( inBitCount > 0 ) + { + ReadBits( *destByte, inBitCount ); + } +} + +void InputMemoryBitStream::Read( Quaternion& outQuat ) +{ + float precision = ( 2.f / 65535.f ); + + uint32_t f = 0; + + Read( f, 16 ); + outQuat.mX = ConvertFromFixed( f, -1.f, precision ); + Read( f, 16 ); + outQuat.mY = ConvertFromFixed( f, -1.f, precision ); + Read( f, 16 ); + outQuat.mZ = ConvertFromFixed( f, -1.f, precision ); + + outQuat.mW = sqrtf( 1.f - + (outQuat.mX * outQuat.mX + + outQuat.mY * outQuat.mY + + outQuat.mZ * outQuat.mZ)); + bool isNegative; + Read( isNegative ); + + if( isNegative ) + { + outQuat.mW *= -1; + } +} diff --git a/RoboCat/Src/TCPSocket.cpp b/RoboCat/Src/TCPSocket.cpp deleted file mode 100644 index 494f776c..00000000 --- a/RoboCat/Src/TCPSocket.cpp +++ /dev/null @@ -1,105 +0,0 @@ -#include "RoboCatPCH.h" - - -int TCPSocket::Connect( const SocketAddress& inAddress ) -{ - int err = connect( mSocket, &inAddress.mSockAddr, inAddress.GetSize() ); - if( err < 0 ) - { - SocketUtil::ReportError( "TCPSocket::Connect" ); - return -SocketUtil::GetLastError(); - } - return NO_ERROR; -} - -int TCPSocket::Listen( int inBackLog ) -{ - int err = listen( mSocket, inBackLog ); - if( err < 0 ) - { - SocketUtil::ReportError( "TCPSocket::Listen" ); - return -SocketUtil::GetLastError(); - } - return NO_ERROR; -} - -TCPSocketPtr TCPSocket::Accept( SocketAddress& inFromAddress ) -{ - socklen_t length = inFromAddress.GetSize(); - SOCKET newSocket = accept( mSocket, &inFromAddress.mSockAddr, &length ); - - if( newSocket != INVALID_SOCKET ) - { - return TCPSocketPtr( new TCPSocket( newSocket ) ); - } - else - { - SocketUtil::ReportError( "TCPSocket::Accept" ); - return nullptr; - } -} - -int32_t TCPSocket::Send( const void* inData, size_t inLen ) -{ - int bytesSentCount = send( mSocket, static_cast< const char* >( inData ), inLen, 0 ); - if( bytesSentCount < 0 ) - { - SocketUtil::ReportError( "TCPSocket::Send" ); - return -SocketUtil::GetLastError(); - } - return bytesSentCount; -} - -int32_t TCPSocket::Receive( void* inData, size_t inLen ) -{ - int bytesReceivedCount = recv( mSocket, static_cast< char* >( inData ), inLen, 0 ); - if( bytesReceivedCount < 0 ) - { - SocketUtil::ReportError( "TCPSocket::Receive" ); - return -SocketUtil::GetLastError(); - } - return bytesReceivedCount; -} - -int TCPSocket::Bind( const SocketAddress& inBindAddress ) -{ - int error = bind( mSocket, &inBindAddress.mSockAddr, inBindAddress.GetSize() ); - if( error != 0 ) - { - SocketUtil::ReportError( "TCPSocket::Bind" ); - return SocketUtil::GetLastError(); - } - - return NO_ERROR; -} - -int TCPSocket::SetNonBlockingMode(bool inShouldBeNonBlocking) -{ -#if _WIN32 - u_long arg = inShouldBeNonBlocking ? 1 : 0; - int result = ioctlsocket(mSocket, FIONBIO, &arg); -#else - int flags = fcntl(mSocket, F_GETFL, 0); - flags = inShouldBeNonBlocking ? (flags | O_NONBLOCK) : (flags & ~O_NONBLOCK); - int result = fcntl(mSocket, F_SETFL, flags); -#endif - - if (result == SOCKET_ERROR) - { - SocketUtil::ReportError("TCPSocket::SetNonBlockingMode"); - return SocketUtil::GetLastError(); - } - else - { - return NO_ERROR; - } -} - -TCPSocket::~TCPSocket() -{ -#if _WIN32 - closesocket( mSocket ); -#else - close( mSocket ); -#endif -} diff --git a/RoboCat/Src/Timing.cpp b/RoboCat/Src/Timing.cpp new file mode 100644 index 00000000..9a8be86c --- /dev/null +++ b/RoboCat/Src/Timing.cpp @@ -0,0 +1,62 @@ +#include "RoboCatPCH.h" + + +#if !_WIN32 + #include + using namespace std::chrono; +#endif + +Timing Timing::sInstance; + +namespace +{ +#if _WIN32 + LARGE_INTEGER sStartTime = { 0 }; +#else + high_resolution_clock::time_point sStartTime; +#endif +} + +Timing::Timing() +{ +#if _WIN32 + LARGE_INTEGER perfFreq; + QueryPerformanceFrequency( &perfFreq ); + mPerfCountDuration = 1.0 / perfFreq.QuadPart; + + QueryPerformanceCounter( &sStartTime ); + + mLastFrameStartTime = GetTime(); +#else + sStartTime = high_resolution_clock::now(); +#endif +} + +void Timing::Update() +{ + + double currentTime = GetTime(); + + mDeltaTime = ( float ) ( currentTime - mLastFrameStartTime ); + + mLastFrameStartTime = currentTime; + mFrameStartTimef = static_cast< float > ( mLastFrameStartTime ); + +} + +double Timing::GetTime() const +{ +#if _WIN32 + LARGE_INTEGER curTime, timeSinceStart; + QueryPerformanceCounter( &curTime ); + + timeSinceStart.QuadPart = curTime.QuadPart - sStartTime.QuadPart; + + return timeSinceStart.QuadPart * mPerfCountDuration; +#else + auto now = high_resolution_clock::now(); + auto ms = duration_cast< milliseconds >( now - sStartTime ).count(); + //a little uncool to then convert into a double just to go back, but oh well. + return static_cast< double >( ms ) / 1000; +#endif +} \ No newline at end of file diff --git a/RoboCat/System.cpp b/RoboCat/System.cpp new file mode 100644 index 00000000..95026e57 --- /dev/null +++ b/RoboCat/System.cpp @@ -0,0 +1,39 @@ +#include "System.h" + +System::System() +{ + mGraphicsSystem = new GraphicsSystem(DISP_WIDTH, DISP_HEIGHT); + mInput = new InputSystem(); +} + +System::~System() +{ + cleanup(); +} + +void System::init() +{ + mGraphicsSystem->init(); // this also contains init allegro and should always be called before anything else + + if (!al_install_mouse()) + { + cout << "error - Mouse Add-on not installed\n"; + } + if (!al_install_keyboard()) + { + cout << "error - Keyboard Add-on not installed\n"; + } + mInput->init(); + mIsDeleted = false; +} + +void System::cleanup() +{ + if (mIsDeleted == false) + { + delete mGraphicsSystem; + mGraphicsSystem = nullptr; + + mIsDeleted = true; + } +} \ No newline at end of file diff --git a/RoboCat/System.h b/RoboCat/System.h new file mode 100644 index 00000000..c4cc066f --- /dev/null +++ b/RoboCat/System.h @@ -0,0 +1,37 @@ +#pragma once +#include "GraphicsSystem.h" +#include "InputSystem.h" +#include "../common/DeanLib/include/Trackable.h" +#include "../common/DeanLib/include/DeanLibDefines.h" +#include "../common/DeanLib/include/DeanLibUtilities.h" +#include "../common/DeanLib/include/DeanMath.h" + +/* +Author: Wesley Elmer + Class : Game Architecture <250-71> + Assignment : Assignment 3 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +// The class which holds the Graphics System and has functions to get keyboard/mouse state –part of GraphicsLib project. +class System : public Trackable +{ +public: + System(); + ~System(); + void init(); + void cleanup(); + + GraphicsSystem* getGraphicsSystem() { return mGraphicsSystem; } + InputSystem* getInputSystem() { return mInput; } + +private: + GraphicsSystem* mGraphicsSystem; + InputSystem* mInput; + + ALLEGRO_MOUSE_STATE mMouseState; + ALLEGRO_KEYBOARD_STATE mKeyboardState; + bool mIsDeleted; +}; + diff --git a/RoboCat/TCPSocket.cpp b/RoboCat/TCPSocket.cpp new file mode 100644 index 00000000..15cb8696 --- /dev/null +++ b/RoboCat/TCPSocket.cpp @@ -0,0 +1,105 @@ +#include "RoboCatPCH.h" + + +int TCPSocket::Connect(const SocketAddress& inAddress) +{ + int err = connect(mSocket, &inAddress.mSockAddr, inAddress.GetSize()); + if (err < 0) + { + SocketUtil::ReportError("TCPSocket::Connect"); + return -SocketUtil::GetLastError(); + } + return NO_ERROR; +} + +int TCPSocket::Listen(int inBackLog) +{ + int err = listen(mSocket, inBackLog); + if (err < 0) + { + SocketUtil::ReportError("TCPSocket::Listen"); + return -SocketUtil::GetLastError(); + } + return NO_ERROR; +} + +TCPSocketPtr TCPSocket::Accept(SocketAddress& inFromAddress) +{ + socklen_t length = inFromAddress.GetSize(); + SOCKET newSocket = accept(mSocket, &inFromAddress.mSockAddr, &length); + + if (newSocket != INVALID_SOCKET) + { + return TCPSocketPtr(new TCPSocket(newSocket)); + } + else + { + SocketUtil::ReportError("TCPSocket::Accept"); + return nullptr; + } +} + +int32_t TCPSocket::Send(const void* inData, size_t inLen) +{ + int bytesSentCount = send(mSocket, static_cast(inData), inLen, 0); + if (bytesSentCount < 0) + { + SocketUtil::ReportError("TCPSocket::Send"); + return -SocketUtil::GetLastError(); + } + return bytesSentCount; +} + +int32_t TCPSocket::Receive(void* inData, size_t inLen) +{ + int bytesReceivedCount = recv(mSocket, static_cast(inData), inLen, 0); + if (bytesReceivedCount < 0) + { + SocketUtil::ReportError("TCPSocket::Receive"); + return -SocketUtil::GetLastError(); + } + return bytesReceivedCount; +} + +int TCPSocket::Bind(const SocketAddress& inBindAddress) +{ + int error = bind(mSocket, &inBindAddress.mSockAddr, inBindAddress.GetSize()); + if (error != 0) + { + SocketUtil::ReportError("TCPSocket::Bind"); + return SocketUtil::GetLastError(); + } + + return NO_ERROR; +} + +int TCPSocket::SetNonBlockingMode(bool inShouldBeNonBlocking) +{ +#if _WIN32 + u_long arg = inShouldBeNonBlocking ? 1 : 0; + int result = ioctlsocket(mSocket, FIONBIO, &arg); +#else + int flags = fcntl(mSocket, F_GETFL, 0); + flags = inShouldBeNonBlocking ? (flags | O_NONBLOCK) : (flags & ~O_NONBLOCK); + int result = fcntl(mSocket, F_SETFL, flags); +#endif + + if (result == SOCKET_ERROR) + { + SocketUtil::ReportError("TCPSocket::SetNonBlockingMode"); + return SocketUtil::GetLastError(); + } + else + { + return NO_ERROR; + } +} + +TCPSocket::~TCPSocket() +{ +#if _WIN32 + closesocket(mSocket); +#else + close(mSocket); +#endif +} \ No newline at end of file diff --git a/RoboCat/Unit.cpp b/RoboCat/Unit.cpp new file mode 100644 index 00000000..62cd119f --- /dev/null +++ b/RoboCat/Unit.cpp @@ -0,0 +1,106 @@ +#include"Unit.h" +#include"Animation.h" +#include"GraphicsBuffer.h" +#include"GraphicsSystem.h" +#include"System.h" +#include"Game.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 3 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +Unit::Unit() +{ + mLocX = 0; + mLocY = 0; + + mpAnimate = new Animation(); + mIsAnimated = false; + mScale = 0.0; +} + +Unit::Unit(int locX, int locY, Animation* animate) +{ + mLocX = locX; + mLocY = locY; + + mpAnimate = animate; + mIsAnimated = true; + mScale = 1.0; +} + +Unit::~Unit() +{ + cleanup(); +} + +void Unit::init(Animation* animate, int locX, int locY) +{ + mpAnimationList.push_back(animate); + mpAnimate = mpAnimationList[0]; + + mLocX = locX; + mLocY = locY; +} + +void Unit::locationUpdate(float elapsedTime) +{ + mpAnimate->animationUpdate(elapsedTime); +} + +void Unit::drawSprite(System* system) +{ + system->getGraphicsSystem()->draw(mLocX, mLocY, mpAnimate->getCurrentSprite(), mScale); +} + +void Unit::addAnimation(Animation* toAdd) +{ + mpAnimationList.push_back(toAdd); +} + +void Unit::setAnimation(Animation* toAdd) +{ + mpAnimate = toAdd; +} + +void Unit::setPosition(int locX, int locY) +{ + mLocX = locX; + mLocY = locY; +} + +void Unit::setAnimationSpeed(int speed) +{ + mpAnimate->changeFPS(speed); +} + +void Unit::toggleAnimations(bool animate) +{ + //Iterate through the animations list + for (auto& p : mpAnimationList) + { + //Toggle the animation pause + p->setAnimate(animate); + } + + //Toggle the current animation pause + mpAnimate->setAnimate(animate); +} + +void Unit::cleanup() +{ + if (mIsAnimated == true) + { + // HACK I think that some this might need to call cleanup on mpAnimate? - wes + + //mpAnimate->cleanup(); + delete mpAnimate; + mpAnimate = nullptr; + + mIsAnimated = false; + } +} diff --git a/RoboCat/Unit.h b/RoboCat/Unit.h new file mode 100644 index 00000000..e0c6bb32 --- /dev/null +++ b/RoboCat/Unit.h @@ -0,0 +1,54 @@ +#pragma once +#include +#include +#include +#include"../common/DeanLib/include/Trackable.h" +#include"Animation.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 3 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +class Animation; +class GraphicsBuffer; +class GraphicsSystem; +class System; + +class Unit : public Trackable +{ +public: + Unit(); + Unit(int locX, int locY, Animation* animate); + ~Unit(); + + void init(Animation* animate, int locX, int locY); + + int getLocX() { return mLocX; } + int getLocY() { return mLocY; } + int getSpriteWidth() { return mpAnimate->getSpriteWidth(); } + int getSpriteHeight() { return mpAnimate->getSpriteHeight(); } + Animation* getAnimation() { return mpAnimate; } + + void locationUpdate(float elapsedTime); + void drawSprite(System* system); + void addAnimation(Animation* toAdd); + void setAnimation(Animation* toAdd); + void setPosition(int locX, int locY); + void setAnimationSpeed(int speed); + void toggleAnimations(bool animate); + + void cleanup(); +private: + int mLocX; + int mLocY; + + std::vector mpAnimationList; + + Animation* mpAnimate; + bool mIsAnimated; + float mScale = 1; +}; \ No newline at end of file diff --git a/RoboCat/UnitManager.cpp b/RoboCat/UnitManager.cpp new file mode 100644 index 00000000..aa387c62 --- /dev/null +++ b/RoboCat/UnitManager.cpp @@ -0,0 +1,95 @@ +#include"UnitManager.h" +#include"Unit.h" +#include"Animation.h" +#include"Sprite.h" +#include"System.h" + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 4 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +UnitManager::UnitManager() +{ + if (mpUnits != nullptr) + { + cleanup(); + } + else + { + mpUnits = new vector(); + } +} + +UnitManager::~UnitManager() +{ + if (mpUnits != nullptr) + { + cleanup(); + } +} + +void UnitManager::addUnits(Unit* units) +{ + mpUnits->push_back(units); +} + +void UnitManager::deleteUnits(int deletedUnits) +{ + delete mpUnits->at(deletedUnits); + + mpUnits->erase(mpUnits->begin() + deletedUnits); +} + +Unit* UnitManager::getUnits(int getUnits) +{ + return mpUnits->at(getUnits); +} + +void UnitManager::clearUnits() +{ + cleanup(); +} + +void UnitManager::updateUnits(float elapsedTime) +{ + int i = 0; + + for (i; i < mpUnits->size(); i++) + { + mpUnits->at(i)->locationUpdate(elapsedTime); + } +} + +void UnitManager::draw(System* system) +{ + for (int i = 0; i < mpUnits->size(); i++) + { + mpUnits->at(i)->drawSprite(system); + } +} + +int UnitManager::getNumUnits() +{ + if (mpUnits != nullptr) + { + return mpUnits->size(); + } + else + { + return 0; + } +} + +void UnitManager::cleanup() +{ + for (int i = 0; i < mpUnits->size(); i++) + { + delete mpUnits->at(i); + } + + mpUnits->clear(); +} \ No newline at end of file diff --git a/RoboCat/UnitManager.h b/RoboCat/UnitManager.h new file mode 100644 index 00000000..15c30837 --- /dev/null +++ b/RoboCat/UnitManager.h @@ -0,0 +1,49 @@ +#pragma once +#include +#include"../common/DeanLib/include/Trackable.h" +#include + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 4 + Certification of Authenticity : +I certify that this assignment is entirely my own work. +*/ + +using namespace std; + +class Unit; +class Animation; +class System; + +class UnitManager : public Trackable +{ +public: + UnitManager(); + ~UnitManager(); + + void addUnits(Unit* units); + Unit* getUnits(int numUnits); + void deleteUnits(int deletedUnits); + + void clearUnits(); + void updateUnits(float elapsedTime); + + int getPosX() { return mPosX; } + int getPosY() { return mPosY; } + + void setPosX(int posX) { mPosX = posX; }; + void setPosY(int posY) { mPosY = posY; }; + + void draw(System* system); + + int getNumUnits(); + void cleanup(); +private: + vector* mpUnits = nullptr; + + int mPosX; + int mPosY; +}; + diff --git a/RoboCat/main.cpp b/RoboCat/main.cpp new file mode 100644 index 00000000..35244fbc --- /dev/null +++ b/RoboCat/main.cpp @@ -0,0 +1,51 @@ +#include +#include +#include + +#include +#include + +#include"Color.h" +#include"EventSystem.h" +#include"Font.h" +#include"Game.h" +#include"GraphicsBuffer.h" +#include"GraphicsSystem.h" +#include"Sprite.h" +#include"System.h" +#include + +/* +Author: Nicholas Preis + Class : Game Architecture <250-71> + Assignment : Assignment 4 + Certification of Authenticity : +I certify that this assignment is entirely our own work. +*/ + +using namespace std; + +const int DISPLAY_WIDTH = 800; +const int DISPLAY_HEIGHT = 600; + +int main() +{ + Game::initInstance(); + Game* instance = Game::getInstance(); + + instance->init(); + + instance->doLoop(); + + instance->cleanup(); + Game::deleteInstance(); + EventSystem::cleanupInstance(); + + cout << endl; + + MemoryTracker::getInstance()->reportAllocations( cout ); + system( "pause" ); + + + return 0; +} \ No newline at end of file diff --git a/RoboCat/packages.config b/RoboCat/packages.config new file mode 100644 index 00000000..9ff6486d --- /dev/null +++ b/RoboCat/packages.config @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/SocketDemo.sln b/SocketDemo.sln index d4b486ba..4a67398e 100644 --- a/SocketDemo.sln +++ b/SocketDemo.sln @@ -1,28 +1,37 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 2013 -VisualStudioVersion = 12.0.31101.0 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.30011.22 MinimumVisualStudioVersion = 10.0.40219.1 -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Chapter3", "RoboCat\Chapter3.vcxproj", "{B3B75176-8D81-4E7B-A5D0-C2E5423844D3}" +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "SocketDemo", "RoboCat\Chapter3.vcxproj", "{B3B75176-8D81-4E7B-A5D0-C2E5423844D3}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|ARM = Debug|ARM Debug|Win32 = Debug|Win32 Debug|x64 = Debug|x64 + Profile|ARM = Profile|ARM Profile|Win32 = Profile|Win32 Profile|x64 = Profile|x64 + Release|ARM = Release|ARM Release|Win32 = Release|Win32 Release|x64 = Release|x64 EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution + {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Debug|ARM.ActiveCfg = Debug|Win32 + {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Debug|ARM.Build.0 = Debug|Win32 {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Debug|Win32.ActiveCfg = Debug|Win32 {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Debug|Win32.Build.0 = Debug|Win32 - {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Debug|x64.ActiveCfg = Debug|x64 - {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Debug|x64.Build.0 = Debug|x64 + {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Debug|x64.ActiveCfg = Debug|Win32 + {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Debug|x64.Build.0 = Debug|Win32 + {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Profile|ARM.ActiveCfg = Profile|ARM + {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Profile|ARM.Build.0 = Profile|ARM {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Profile|Win32.ActiveCfg = Profile|Win32 {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Profile|Win32.Build.0 = Profile|Win32 {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Profile|x64.ActiveCfg = Profile|x64 {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Profile|x64.Build.0 = Profile|x64 + {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Release|ARM.ActiveCfg = Release|ARM + {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Release|ARM.Build.0 = Release|ARM {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Release|Win32.ActiveCfg = Release|Win32 {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Release|Win32.Build.0 = Release|Win32 {B3B75176-8D81-4E7B-A5D0-C2E5423844D3}.Release|x64.ActiveCfg = Release|x64 @@ -31,4 +40,7 @@ Global GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {22135BD3-88E9-49B5-AC5D-7502E700EE28} + EndGlobalSection EndGlobal diff --git a/common/Cards/Card.cpp b/common/Cards/Card.cpp new file mode 100644 index 00000000..74f4ee99 --- /dev/null +++ b/common/Cards/Card.cpp @@ -0,0 +1,47 @@ +#include "Card.h" + +Card::Card(Value val, Suit suit) + :mVal(val) + , mSuit(suit) +{ +} + +bool Card::operator==(const Card& rhs) const +{ + return (mVal == rhs.mVal && mSuit == rhs.mSuit); +} + +bool Card::valLess(const Card& rhs) const +{ + return mVal < rhs.mVal; +} + +//static +bool Card::valComp(const Card& lhs, const Card& rhs) +{ + return lhs.valLess(rhs); +} + +bool Card::suitLess(const Card& rhs) const +{ + return mSuit < rhs.mSuit; +} + +//static +bool Card::suitComp(const Card& lhs, const Card& rhs) +{ + return lhs.suitLess(rhs); +} + +bool Card::isValid() const +{ + return (mVal >= ACE && mVal <= KING && mSuit >= SPADES && mSuit <= DIAMONDS); +} + +std::ostream& operator<<(std::ostream& theStream, const Card& theCard) +{ + static char suitChar[4] = { 'S', 'C', 'H', 'D' }; + static char valChar[13] = { 'A', '2', '3', '4', '5', '6', '7', '8', '9', 'X', 'J', 'Q', 'K' }; + theStream << valChar[theCard.mVal] << suitChar[theCard.mSuit] << ' '; + return theStream; +} diff --git a/common/Cards/Card.h b/common/Cards/Card.h new file mode 100644 index 00000000..2f01ec10 --- /dev/null +++ b/common/Cards/Card.h @@ -0,0 +1,61 @@ +#pragma once + +#include + +class Card +{ +public: + + enum Suit + { + INVALID_SUIT = -1, + SPADES, + CLUBS, + HEARTS, + DIAMONDS + }; + + enum Value + { + INVALID_VALUE = -1, + ACE, + TWO, + THREE, + FOUR, + FIVE, + SIX, + SEVEN, + EIGHT, + NINE, + TEN, + JACK, + QUEEN, + KING + }; + + Card(Value val, Suit suit); + Card() {}; + + bool operator==(const Card& rhs) const; + + //returns true if value of card is less than that of rhs + bool valLess(const Card& rhs) const; + //returns true if value of lhs is less than that of rhs + static bool valComp(const Card& lhs, const Card& rhs); + //returns true if suit of card is less than that of rhs + bool suitLess(const Card& rhs) const; + //returns true if suit of lhs is less than that of rhs + static bool suitComp(const Card& lhs, const Card& rhs); + + bool isValid() const; + + Value getValue() const { return mVal; }; + Suit getSuit() const { return mSuit; }; + + friend std::ostream& operator<<(std::ostream& theStream, const Card& theCard); +private: + Value mVal=Value::INVALID_VALUE; + Suit mSuit=Suit::INVALID_SUIT; +}; + +std::ostream& operator<<(std::ostream& theStream, const Card& theCard); \ No newline at end of file diff --git a/common/Cards/Cards.sln b/common/Cards/Cards.sln new file mode 100644 index 00000000..352ace98 --- /dev/null +++ b/common/Cards/Cards.sln @@ -0,0 +1,31 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.29411.108 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Cards", "Cards.vcxproj", "{D3D51FF8-F9D2-43F3-9482-921390B58943}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|x64 = Debug|x64 + Debug|x86 = Debug|x86 + Release|x64 = Release|x64 + Release|x86 = Release|x86 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {D3D51FF8-F9D2-43F3-9482-921390B58943}.Debug|x64.ActiveCfg = Debug|x64 + {D3D51FF8-F9D2-43F3-9482-921390B58943}.Debug|x64.Build.0 = Debug|x64 + {D3D51FF8-F9D2-43F3-9482-921390B58943}.Debug|x86.ActiveCfg = Debug|Win32 + {D3D51FF8-F9D2-43F3-9482-921390B58943}.Debug|x86.Build.0 = Debug|Win32 + {D3D51FF8-F9D2-43F3-9482-921390B58943}.Release|x64.ActiveCfg = Release|x64 + {D3D51FF8-F9D2-43F3-9482-921390B58943}.Release|x64.Build.0 = Release|x64 + {D3D51FF8-F9D2-43F3-9482-921390B58943}.Release|x86.ActiveCfg = Release|Win32 + {D3D51FF8-F9D2-43F3-9482-921390B58943}.Release|x86.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {93FB441B-FADC-4608-AE9A-5D075DAA6369} + EndGlobalSection +EndGlobal diff --git a/common/Cards/Cards.vcxproj b/common/Cards/Cards.vcxproj new file mode 100644 index 00000000..3dd7678a --- /dev/null +++ b/common/Cards/Cards.vcxproj @@ -0,0 +1,139 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + Debug + x64 + + + Release + x64 + + + + 16.0 + {D3D51FF8-F9D2-43F3-9482-921390B58943} + Cards + 10.0 + + + + Application + true + v142 + MultiByte + + + Application + false + v142 + true + MultiByte + + + Application + true + v142 + MultiByte + + + Application + false + v142 + true + MultiByte + + + + + + + + + + + + + + + + + + + + + + + Level3 + Disabled + true + true + + + Console + + + + + Level3 + Disabled + true + true + + + Console + + + + + Level3 + MaxSpeed + true + true + true + true + + + Console + true + true + + + + + Level3 + MaxSpeed + true + true + true + true + + + Console + true + true + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/common/Cards/Deck.cpp b/common/Cards/Deck.cpp new file mode 100644 index 00000000..d34da277 --- /dev/null +++ b/common/Cards/Deck.cpp @@ -0,0 +1 @@ +#include "Deck.h" \ No newline at end of file diff --git a/common/Cards/Deck.h b/common/Cards/Deck.h new file mode 100644 index 00000000..6f70f09b --- /dev/null +++ b/common/Cards/Deck.h @@ -0,0 +1 @@ +#pragma once diff --git a/common/Cards/Hand.cpp b/common/Cards/Hand.cpp new file mode 100644 index 00000000..c743d720 --- /dev/null +++ b/common/Cards/Hand.cpp @@ -0,0 +1 @@ +#include "Hand.h" \ No newline at end of file diff --git a/common/Cards/Hand.h b/common/Cards/Hand.h new file mode 100644 index 00000000..6f70f09b --- /dev/null +++ b/common/Cards/Hand.h @@ -0,0 +1 @@ +#pragma once diff --git a/common/Cards/main.cpp b/common/Cards/main.cpp new file mode 100644 index 00000000..a40ceb86 --- /dev/null +++ b/common/Cards/main.cpp @@ -0,0 +1,29 @@ +#include "Card.h" +#include "Deck.h" +#include "Hand.h" + +#include +#include +#include +#include + +int main() +{ +/*pseudo code + Seed the random number generator with time + Ask the user if they would like to use a test deck or a standard deck + Create a Deck (of the correct type) - test deck contains only 9, 10, J, Q, K's in just Spades and Hearts + Shuffle the Deck + ask the user how may hands they wish to have dealt - store this as numHands + do this numHands times + deal 5 cards to the hand + if deck runs out of cards in the middle of the deal clear the hand, shuffle the deck, and re-deal all 5 cards + write out the contents of the hand + evaluate what multiples the hand contains and write them out + evaluate if the hand contains a straight - if so write it out + evaluate if the hand contains a flush - if so write it out + clear the hand before the next deal +*/ + system("pause"); + return 0; +} \ No newline at end of file diff --git a/common/DeanLib/CircularQueue.cpp b/common/DeanLib/CircularQueue.cpp new file mode 100644 index 00000000..184644b5 --- /dev/null +++ b/common/DeanLib/CircularQueue.cpp @@ -0,0 +1,7 @@ +#include "CircularQueue.h" + + + + + + diff --git a/common/DeanLib/DataRepository.cpp b/common/DeanLib/DataRepository.cpp new file mode 100644 index 00000000..e99f6644 --- /dev/null +++ b/common/DeanLib/DataRepository.cpp @@ -0,0 +1,88 @@ +#include "../DeanLib/include/DataRepository.h" +#include + +DataEntry::DataEntry( int val ) + :mType(INT_VAL) +{ + mData.intVal = val; +} + +DataEntry::DataEntry( float val ) + :mType(FLOAT_VAL) +{ + mData.floatVal = val; +} + +DataEntry::DataEntry( double val ) + :mType(DOUBLE_VAL) +{ + mData.doubleVal = val; +} + +DataEntry::DataEntry( const std::string& val ) + :mType(STRING_VAL) +{ + assert( val.size() + 1 < MAX_STRING_VAL_SIZE ); + strcpy_s( mData.stringVal, val.c_str() ); +} + +DataEntry::DataEntry( UINT val ) + :mType(UINT_VAL) +{ + mData.uintVal = val; +} + +void DataRepository::addEntry( const DataKey& key, int val ) +{ + DataEntry entry( val ); + mMap[key] = entry; +} + +void DataRepository::addEntry( const DataKey& key, float val ) +{ + DataEntry entry( val ); + mMap[key] = entry; +} + +void DataRepository::addEntry( const DataKey& key, double val ) +{ + DataEntry entry( val ); + mMap[key] = entry; +} + +void DataRepository::addEntry( const DataKey& key, const std::string& val ) +{ + DataEntry entry( val ); + mMap[key] = entry; +} + +void DataRepository::addEntry( const DataKey& key, UINT val ) +{ + DataEntry entry( val ); + mMap[key] = entry; +} + +const DataEntry& DataRepository::getEntry( const DataKey& key ) +{ + static DataEntry nullEntry(0); + + auto iter = mMap.find( key ); + if( iter != mMap.end() ) + { + return iter->second; + } + else + { + return nullEntry; + } +} + +bool DataRepository::hasEntry(const DataKey& key) +{ + auto iter = mMap.find(key); + if (iter != mMap.end()) + return true; + else + return false; +} + diff --git a/common/DeanLib/DeanLib.sln b/common/DeanLib/DeanLib.sln new file mode 100644 index 00000000..4f944383 --- /dev/null +++ b/common/DeanLib/DeanLib.sln @@ -0,0 +1,25 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.29102.190 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DeanLib", "DeanLib.vcxproj", "{DB900E08-5331-46D6-B450-6775A2C7C856}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Win32 = Debug|Win32 + Release|Win32 = Release|Win32 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {DB900E08-5331-46D6-B450-6775A2C7C856}.Debug|Win32.ActiveCfg = Debug|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Debug|Win32.Build.0 = Debug|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Release|Win32.ActiveCfg = Release|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Release|Win32.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {03C61B9A-23B1-4AE3-B273-100743DFB149} + EndGlobalSection +EndGlobal diff --git a/common/DeanLib/DeanLib.vcxproj b/common/DeanLib/DeanLib.vcxproj new file mode 100644 index 00000000..81a716b2 --- /dev/null +++ b/common/DeanLib/DeanLib.vcxproj @@ -0,0 +1,82 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + + {DB900E08-5331-46D6-B450-6775A2C7C856} + DeanLib + 10.0 + + + + StaticLibrary + true + v142 + MultiByte + + + StaticLibrary + false + v142 + true + MultiByte + + + + + + + + + + + + + $(ProjectDir)lib\ + $(ProjectName)$(Configuration) + + + $(ProjectDir)lib\ + $(ProjectName)$(Configuration) + + + + Level3 + Disabled + true + include + + + true + + + + + Level3 + MaxSpeed + true + true + true + include + + + true + true + true + + + + + + + + + \ No newline at end of file diff --git a/common/DeanLib/DeanLibUtilities.cpp b/common/DeanLib/DeanLibUtilities.cpp new file mode 100644 index 00000000..0b004164 --- /dev/null +++ b/common/DeanLib/DeanLibUtilities.cpp @@ -0,0 +1,42 @@ +#include "../../common/DeanLib/include/DeanLibUtilities.h" + +using namespace std; + +string peekString(ifstream& stream) +{ + if (!stream.good() || stream.eof()) + { + return ""; + } + + int charCnt = 0; + auto currPos = stream.cur; + + string theString; + while (!stream.eof()) + { + char c; + stream >> c; + if (c != ' ') + { + charCnt++; + theString += c; + } + } + + if (charCnt > 0) + { + stream.seekg(currPos + charCnt); + return theString; + } + else + { + return ""; + } +} + +int peekInt(std::ifstream& stream) +{ + return 0; +} + diff --git a/common/DeanLib/DeanMath.cpp b/common/DeanLib/DeanMath.cpp new file mode 100644 index 00000000..08a27bcf --- /dev/null +++ b/common/DeanLib/DeanMath.cpp @@ -0,0 +1,21 @@ +#include "../../common/DeanLib/include/DeanMath.h" +#include "../../common/DeanLib/include/Vector2D.h" + +double calcDotProduct(const Vector2D& vector1, const Vector2D& vector2) +{ + return vector1.dotProduct(vector2); +} + +double mapToRangeMinusPiToPi(double val) +{ + while (val < -PI) + { + val += DOUBLE_PI; + } + + while (val > PI) + { + val -= DOUBLE_PI; + } + return val; +} diff --git a/common/DeanLib/MemoryPool.cpp b/common/DeanLib/MemoryPool.cpp new file mode 100644 index 00000000..5294ce72 --- /dev/null +++ b/common/DeanLib/MemoryPool.cpp @@ -0,0 +1,121 @@ +#include "../../common/DeanLib/include/MemoryPool.h" +#include +#include +#include + +using namespace std; + +//got this algorithm from: http://www.exploringbinary.com/ten-ways-to-check-if-an-integer-is-a-power-of-two-in-c/ +int isPowerOfTwo(unsigned int x) +{ + return ((x != 0) && !(x & (x - 1))); +} + +unsigned int getClosestPowerOf2LargerThan(unsigned int num) +{ + static Uint32 powersOf2[32]; + static bool arrayInitted = false; + + //init an array containing all the powers of 2 + //(as it is static this should only run the first time this function is called) + if (!arrayInitted) + { + for (Uint32 i = 0; i < 32; i++) + { + powersOf2[i] = 1 << i; + } + } + + //find the 1st power of 2 which is bigger than or equal to num + for (Uint32 i = 0; i < 32; i++) + { + if ( powersOf2[i] >= num ) + return powersOf2[i]; + } + + //failsafe + return 0; + +} + +MemoryPool::MemoryPool(unsigned int maxNumObjects, unsigned int objectSize) +{ + //make objectSize a power of 2 - used for padding + objectSize = getClosestPowerOf2LargerThan(objectSize); + if (objectSize < 4) + { + objectSize = 4; + } + + //allocate the memory + mMemory = (Byte*)malloc(objectSize * maxNumObjects); + + //set member variables + mMaxNumObjects = maxNumObjects; + mNumAllocatedObjects = 0; + mObjectSize = objectSize; + mHighestValidAddress = mMemory + ((maxNumObjects - 1) * objectSize); + + //allocate the free list + mpFreeList = new CircularQueue(mMaxNumObjects); + + //create the free list + createFreeList(); +} + +void MemoryPool::reset() +{ + //clear the free list + mpFreeList->reset(); + //create the free list again + createFreeList(); + //reset count of allocated objects + mNumAllocatedObjects = 0; +} + +Byte* MemoryPool::allocateObject() +{ + if (mNumAllocatedObjects >= mMaxNumObjects) + { + return NULL; + } + + mNumAllocatedObjects++; + Byte* ptr; + bool success = mpFreeList->popFront(ptr); + if (success) + { + return ptr; + } + else + { + assert(false); + return NULL; + } +} + +void MemoryPool::freeObject(Byte* ptr) +{ + //make sure that the address passed in is actually one managed by this pool + if (ptr >= mMemory && ptr <= mHighestValidAddress) + { + //add address back to free list + mpFreeList->pushBack(ptr); + + mNumAllocatedObjects--; + } + else + { + cout << "ERROR: object freed from a pool that doesn't manage it\n"; + assert(ptr >= mMemory && ptr <= mHighestValidAddress); + } +} + +void MemoryPool::createFreeList() +{ + for (Uint32 i = 0; ipushBack(mMemory + (i * mObjectSize)); + } + +} diff --git a/common/DeanLib/MemoryTracker.cpp b/common/DeanLib/MemoryTracker.cpp new file mode 100644 index 00000000..b2dcdc77 --- /dev/null +++ b/common/DeanLib/MemoryTracker.cpp @@ -0,0 +1,70 @@ +#include +#include +#include "../../common/DeanLib/include/MemoryTracker.h" +#include "../../common/DeanLib/include/Trackable.h" + +using namespace std; + +int MemoryTracker::msAllocationNum = 0; +MemoryTracker* MemoryTracker::mspInstance = NULL; + +MemoryTracker* MemoryTracker::getInstance() +{ + if (mspInstance == NULL) + { + mspInstance = new MemoryTracker; + } + return mspInstance; +} + +MemoryTracker::MemoryTracker() +{ +} + +MemoryTracker::~MemoryTracker() +{ + cout << "MemoryTracker being deleted: final allocations follow:\n"; + reportAllocations( cout ); +} + +void MemoryTracker::addAllocation( void* ptr, size_t size ) +{ + //make sure it's not already in the map + unordered_map::iterator iter = mAllocations.find( ptr ); + if( iter != mAllocations.end() ) + { + //already exists - problem! + } + else + { + AllocationRecord theRec( msAllocationNum, size ); + pair thePair(ptr,theRec); + mAllocations.insert( thePair ); + msAllocationNum++; + } +} + +void MemoryTracker::removeAllocation( void* ptr ) +{ + //find it in the map! + unordered_map::iterator iter = mAllocations.find( ptr ); + if( iter == mAllocations.end() ) + { + //problem!!!! + } + else + { + mAllocations.erase( iter ); + } +} + +void MemoryTracker::reportAllocations( std::ostream& stream ) +{ + stream << "Current memory allocations:\n"; + + unordered_map::iterator iter; + for( iter = mAllocations.begin(); iter != mAllocations.end(); ++iter ) + { + stream << "address:" << iter->first << " size:" << iter->second.size << " num:" << iter->second.num << " debug:" <<((Trackable*)(iter->first))->getDebugSource().c_str() << endl; + } +} diff --git a/common/DeanLib/PerformanceTracker.cpp b/common/DeanLib/PerformanceTracker.cpp new file mode 100644 index 00000000..8a93959a --- /dev/null +++ b/common/DeanLib/PerformanceTracker.cpp @@ -0,0 +1,81 @@ +#include "../../common/DeanLib/include/PerformanceTracker.h" + +using namespace std; + +PerformanceTracker::PerformanceTracker() +{ +} + +PerformanceTracker::~PerformanceTracker() +{ + map::iterator iter; + for( iter = mTimers.begin(); iter != mTimers.end(); ++iter ) + { + delete iter->second; + } +} + +void PerformanceTracker::startTracking( const string& trackerName ) +{ + Timer* pTimer = NULL; + + //find if tracker already exists + map::iterator iter = mTimers.find( trackerName ); + if( iter != mTimers.end() ) + { + pTimer = iter->second; + } + else + { + pTimer = new Timer(); + pTimer->start(); + mTimers[trackerName] = pTimer; + } + + pTimer->pause(false); +} + +void PerformanceTracker::stopTracking( const string& trackerName ) +{ + //make sure timer already exists + map::iterator iter = mTimers.find( trackerName ); + if( iter != mTimers.end() ) + { + iter->second->pause(true); + } + +} + +double PerformanceTracker::getElapsedTime( const string& trackerName ) +{ + //make sure timer already exists + map::iterator iter = mTimers.find( trackerName ); + if( iter != mTimers.end() ) + { + return iter->second->getElapsedTime(); + } + else + return 0.0; +} + +void PerformanceTracker::removeTracker( const std::string& trackerName ) +{ + //find the existing timer + map::iterator iter = mTimers.find( trackerName ); + if( iter != mTimers.end() ) + { + delete iter->second; + mTimers.erase( iter ); + } + +} + +void PerformanceTracker::clearTracker( const std::string& trackerName ) +{ + //find if tracker already exists + map::iterator iter = mTimers.find( trackerName ); + if( iter != mTimers.end() ) + { + iter->second->start(); + } +} \ No newline at end of file diff --git a/common/DeanLib/RayCaster.cpp b/common/DeanLib/RayCaster.cpp new file mode 100644 index 00000000..e18e8196 --- /dev/null +++ b/common/DeanLib/RayCaster.cpp @@ -0,0 +1,18 @@ +#include "../../common/DeanLib/include/RayCaster.h" + +std::vector RayCaster::getPoints(const Vector2D& start, const Vector2D& end, float interval) +{ + std::vector thePoints; + + Vector2D diff = end - start; + Vector2D normalizedDiff = diff; + normalizedDiff.normalize(); + + int numIterations = (int)(diff.getLength() / interval)-1; + for (int i = 1; i < numIterations; i++) + { + Vector2D point = (normalizedDiff * interval * (float)i) + start; + thePoints.push_back(point); + } + return thePoints; +} diff --git a/common/DeanLib/Timer.cpp b/common/DeanLib/Timer.cpp new file mode 100644 index 00000000..31b39b18 --- /dev/null +++ b/common/DeanLib/Timer.cpp @@ -0,0 +1,87 @@ +#include "../../common/DeanLib/include/Timer.h" + +Timer::Timer() +:mElapsedTime(0.0) +,mPaused(true) +{ + QueryPerformanceFrequency( &mTimerFrequency ); + mStartTime.QuadPart = 0; + mEndTime.QuadPart = 0; +} + +Timer::~Timer() +{ +} + +void Timer::start() +{ + QueryPerformanceCounter( &mStartTime ); + + //reset end time as well + mEndTime.QuadPart = 0; + + mElapsedTime = 0.0; + + pause( false );//unpause +} + +void Timer::stop() +{ + QueryPerformanceCounter( &mEndTime ); + mElapsedTime = calcDifferenceInMS( mStartTime, mEndTime ); +} + +void Timer::pause( bool shouldPause ) +{ + if( shouldPause && !mPaused )//want to pause and we are not currently paused + { + mPaused = true; + QueryPerformanceCounter( &mEndTime ); + mElapsedTime += calcDifferenceInMS( mStartTime, mEndTime ); + } + else if( !shouldPause && mPaused )//want to unpause and we are paused + { + mPaused = false; + QueryPerformanceCounter( &mStartTime ); + } +} + +double Timer::getElapsedTime() const +{ + //if we have an end time then the timer isn't running and we can just return the elapsed time + if( mEndTime.QuadPart != 0 ) + { + return mElapsedTime; + } + else //otherwise we need to get the current time, do the math and return that + { + LARGE_INTEGER currentTime; + QueryPerformanceCounter( ¤tTime ); + return calcDifferenceInMS( mStartTime, currentTime ); + } +} + +void Timer::sleepUntilElapsed( double ms ) +{ + LARGE_INTEGER currentTime, lastTime; + QueryPerformanceCounter( ¤tTime ); + double timeToSleep = ms - calcDifferenceInMS( mStartTime, currentTime ); + + while( timeToSleep > 0.0 ) + { + lastTime = currentTime; + QueryPerformanceCounter( ¤tTime ); + double timeElapsed = calcDifferenceInMS( lastTime, currentTime ); + timeToSleep -= timeElapsed; + if( timeToSleep > 10.0 )//if we are going to be in this loop for a long time - + { //Sleep to relinquish back to Windows + Sleep(10); + } + } +} + +double Timer::calcDifferenceInMS( LARGE_INTEGER from, LARGE_INTEGER to ) const +{ + double difference = (double)(to.QuadPart - from.QuadPart) / (double)mTimerFrequency.QuadPart; + return difference * 1000; +} diff --git a/common/DeanLib/Trackable.cpp b/common/DeanLib/Trackable.cpp new file mode 100644 index 00000000..2edb1031 --- /dev/null +++ b/common/DeanLib/Trackable.cpp @@ -0,0 +1,28 @@ +#include "../../common/DeanLib/include/Trackable.h" +#include "../../common/DeanLib/include/MemoryTracker.h" + +void* Trackable::operator new( std::size_t size ) +{ + void* ptr = malloc(size); + MemoryTracker::getInstance()->addAllocation( ptr, size ); + return ptr; +} + +void Trackable::operator delete( void *ptr ) +{ + MemoryTracker::getInstance()->removeAllocation(ptr); + free(ptr); +} + +void* Trackable::operator new[]( std::size_t size ) +{ + void* ptr = malloc(size); + MemoryTracker::getInstance()->addAllocation( ptr, size ); + return ptr; +} + +void Trackable::operator delete[]( void *ptr ) +{ + MemoryTracker::getInstance()->removeAllocation(ptr); + free(ptr); +} \ No newline at end of file diff --git a/common/DeanLib/Vector2D.cpp b/common/DeanLib/Vector2D.cpp new file mode 100644 index 00000000..67fb7daa --- /dev/null +++ b/common/DeanLib/Vector2D.cpp @@ -0,0 +1,175 @@ +#include "../../common/DeanLib/include/Vector2D.h" +#include +#include +#include +#include "include\DeanMath.h" + +Vector2D::Vector2D(float x, float y) +:mX(x) +,mY(y) +{ +} + +Vector2D::Vector2D( const Vector2D& rhs ) +:mX( rhs.mX ) +,mY( rhs.mY ) +{ +} + +Vector2D::Vector2D(int x, int y ) + :mX((float)x) + ,mY((float)y) +{ +} + +Vector2D::~Vector2D() +{ +} + +Vector2D& Vector2D::operator += ( const Vector2D& rhs ) +{ + mX += rhs.mX; + mY += rhs.mY; + return *this; +} + +Vector2D& Vector2D::operator -= ( const Vector2D& rhs ) +{ + mX -= rhs.mX; + mY -= rhs.mY; + return *this; +} + +Vector2D& Vector2D::operator = ( const Vector2D& rhs ) +{ + mX = rhs.mX; + mY = rhs.mY; + return *this; +} + +Vector2D& Vector2D::operator *= ( float mult ) +{ + mX *= mult; + mY *= mult; + return *this; +} + +Vector2D& Vector2D::operator /= ( float div ) +{ + mX /= div; + mY /= div; + return *this; +} + +Vector2D Vector2D::operator+(const Vector2D &other) const +{ + Vector2D result = *this; + result += other; + return result; +} + +Vector2D Vector2D::operator-(const Vector2D &other) const +{ + Vector2D result = *this; + result -= other; + return result; +} + +Vector2D Vector2D::operator*(float mult) const +{ + Vector2D result = *this; + result.mX *= mult; + result.mY *= mult; + + return result; +} + +Vector2D Vector2D::operator/(float div) const +{ + Vector2D result = *this; + result.mX /= div; + result.mY /= div; + + return result; +} + +bool Vector2D::operator==( const Vector2D& rhs ) const +{ + if ((getX() == rhs.getX()) && (getY() == rhs.getY())) + return true; + else return false; +} + +bool Vector2D::operator!=( const Vector2D& rhs ) const +{ + if ((getX() == rhs.getX()) && (getY() == rhs.getY())) + return false; + else return true; +} + +bool Vector2D::hasNonZeroLength() const +{ + if( mX != 0.0f || mY != 0.0f ) + { + return true; + } + else + { + return false; + } +} + +float Vector2D::getLength() const +{ + float lengthSquared = getLengthSquared(); + return sqrt( lengthSquared ); +} + +float Vector2D::getLengthSquared() const +{ + float lengthSquared = ( mX * mX ) + ( mY * mY ); + return lengthSquared; +} + +void Vector2D::normalize() +{ + float invLength = 1.0f / (getLength() + FLT_MIN); + mX *= invLength; + mY *= invLength; +} + +Vector2D Vector2D::getNormalizedVector() const +{ + Vector2D newVector(*this); + newVector.normalize(); + return newVector; +} + +float Vector2D::dotProduct(const Vector2D& other) const +{ + return mX * other.mX + mY * other.mY; +} + +Vector2D Vector2D::getRightVector() const +{ + return Vector2D(-mY, mX); +} + +double Vector2D::calcFacing() const +{ + return atan2(mX, -mY); +} + +Vector2D Vector2D::getVectorInDirection(double direction) +{ + return Vector2D((float)cos(direction), (float)sin(direction)); +} + +std::ostream & operator<<(std::ostream& out, const Vector2D& vector) +{ + out << "(" << vector.getX() << "," << vector.getY() << ")"; + return out; +} + + + diff --git a/common/DeanLib/include/CircularQueue.h b/common/DeanLib/include/CircularQueue.h new file mode 100644 index 00000000..3cb2259e --- /dev/null +++ b/common/DeanLib/include/CircularQueue.h @@ -0,0 +1,70 @@ +#pragma once +#include <../../common/DeanLib/include/Trackable.h> +#include <../../common/DeanLib/include/DeanLibDefines.h> + +template < class T > +class CircularQueue : public Trackable +{ +public: + explicit CircularQueue(Uint32 size) + : mCapacity(size) + , mFront(0) + , mBack(0) + , mNumEntries(0) + { + mArray = new T[size]; + } + + ~CircularQueue() + { + delete[] mArray; + } + + void reset() + { + mFront = 0; + mBack = 0; + mNumEntries = 0; + } + + bool pushBack(const T& item)//return false if not successfully added (not enough space) + { + if (mNumEntries >= mCapacity)//no room left + return false; + + mArray[mBack] = item; + mBack++; + mNumEntries++; + + if (mBack >= mCapacity) + { + mBack = 0; + } + + return true; + } + + bool popFront(T& item)//returns false if queue is empty + { + if (mNumEntries == 0)//empty + return false; + + item = mArray[mFront]; + mFront++; + mNumEntries--; + + if (mFront >= mCapacity) + { + mFront = 0; + } + + return true; + } +private: + T* mArray; + Uint32 mCapacity; + Uint32 mBack; + Uint32 mFront; + Uint32 mNumEntries; +}; + diff --git a/common/DeanLib/include/ConditionalCallback.h b/common/DeanLib/include/ConditionalCallback.h new file mode 100644 index 00000000..a159bc77 --- /dev/null +++ b/common/DeanLib/include/ConditionalCallback.h @@ -0,0 +1,45 @@ +#pragma once + +#pragma once + +#include + +/*template +void callbackFunc(T var) +{ + F(var); +}*/ + +template +class ConditionalCallback :public Trackable +{ +public: + ConditionalCallback(bool(*condFunc)(), void(*func)(T), T val) + :mpCallbackFunc(func) + , mpConditionalFunc(condFunc) + , mValue(val) + { + }; + + bool update(double dtInMS)//returns true after calling callback, false otherwise + { + if (mpConditionalFunc()) + { + call(mValue); + return true; + } + else + return false; + } + +private: + void(*mpCallbackFunc)(T) = nullptr; + bool(*mpConditionalFunc)() = nullptr; + T mValue; + + void call(T var) + { + mpCallbackFunc(var); + }; + +}; diff --git a/common/DeanLib/include/DataRepository.h b/common/DeanLib/include/DataRepository.h new file mode 100644 index 00000000..d0803710 --- /dev/null +++ b/common/DeanLib/include/DataRepository.h @@ -0,0 +1,76 @@ +#pragma once +#include <../../common/DeanLib/include/Trackable.h> + +#include +#include +#include +#include + +const UINT MAX_STRING_VAL_SIZE = 128; + +union DataUnion +{ + int intVal; + float floatVal; + double doubleVal; + char stringVal[MAX_STRING_VAL_SIZE]; + UINT uintVal; + +}; + +enum DataType +{ + INT_VAL, + FLOAT_VAL, + DOUBLE_VAL, + STRING_VAL, + UINT_VAL +}; + +class DataEntry: public Trackable +{ +public: + DataEntry( int val ); + DataEntry( float val ); + DataEntry( double val ); + DataEntry( const std::string& val ); + DataEntry( UINT val ); + DataEntry() :mType(UINT_VAL) { mData.uintVal = 0; }; + + ~DataEntry(){}; + + inline int getIntVal() const { assert( mType == INT_VAL ); return mData.intVal; }; + inline float getFloatVal() const { assert( mType == FLOAT_VAL ); return mData.floatVal; }; + inline double getDoubleVal() const { assert( mType == DOUBLE_VAL ); return mData.doubleVal; }; + inline std::string getStringVal() const { assert( mType == STRING_VAL ); return std::string(mData.stringVal); }; + inline UINT getUIntVal() const { assert( mType == UINT_VAL ); return mData.uintVal; }; +private: + DataType mType; + DataUnion mData; + +}; + +typedef int DataKey; + +class DataRepository : public Trackable +{ + +public: + DataRepository(){}; + ~DataRepository(){}; + + void addEntry( const DataKey& key, int val ); + void addEntry( const DataKey& key, float val ); + void addEntry( const DataKey& key, double val ); + void addEntry( const DataKey& key, const std::string& val ); + void addEntry( const DataKey& key, UINT val ); + + const DataEntry& getEntry( const DataKey& key ); + + bool hasEntry(const DataKey& key); +private: + std::unordered_map mMap; +}; + + + diff --git a/common/DeanLib/include/DeanLibDefines.h b/common/DeanLib/include/DeanLibDefines.h new file mode 100644 index 00000000..2e235717 --- /dev/null +++ b/common/DeanLib/include/DeanLibDefines.h @@ -0,0 +1,4 @@ +#pragma once + +typedef unsigned char Byte; +typedef unsigned int Uint32; \ No newline at end of file diff --git a/common/DeanLib/include/DeanLibUtilities.h b/common/DeanLib/include/DeanLibUtilities.h new file mode 100644 index 00000000..8956a7b3 --- /dev/null +++ b/common/DeanLib/include/DeanLibUtilities.h @@ -0,0 +1,9 @@ +#pragma once + +#include +#include + +std::string peekString(std::ifstream& stream); +int peekInt(std::ifstream& stream); + + diff --git a/common/DeanLib/include/DeanMath.h b/common/DeanLib/include/DeanMath.h new file mode 100644 index 00000000..4c2c7077 --- /dev/null +++ b/common/DeanLib/include/DeanMath.h @@ -0,0 +1,13 @@ +#pragma once + +class Vector2D; + +const double PI = 3.14159265358979323846; +const double DOUBLE_PI = PI*2; +const double HALF_PI = PI / 2; +const double QUARTER_PI = PI / 2; + +double mapToRangeMinusPiToPi(double val); + +double calcDotProduct(const Vector2D& vector1, const Vector2D& vector2); + diff --git a/common/DeanLib/include/MemoryPool.h b/common/DeanLib/include/MemoryPool.h new file mode 100644 index 00000000..1b81ff7f --- /dev/null +++ b/common/DeanLib/include/MemoryPool.h @@ -0,0 +1,31 @@ +#pragma once + +#include "DeanLibDefines.h" +#include "CircularQueue.h" +#include "Trackable.h" + + +class MemoryPool: public Trackable +{ +public: + MemoryPool(unsigned int maxNumObjects, unsigned int objectSize); + ~MemoryPool() { free(mMemory); delete mpFreeList; }; + + void reset();//doesn't reallocate memory but does reset free list and num allocated objects + + Byte* allocateObject(); + void freeObject(Byte* ptr); + + inline Uint32 getMaxObjectSize(){ return mObjectSize; }; + inline Uint32 getNumFreeObjects(){ return mMaxNumObjects - mNumAllocatedObjects; }; + +private: + Byte* mMemory; + Byte* mHighestValidAddress; + Uint32 mMaxNumObjects; + Uint32 mNumAllocatedObjects; + Uint32 mObjectSize; + CircularQueue* mpFreeList; + + void createFreeList(); +}; \ No newline at end of file diff --git a/common/DeanLib/include/MemoryTracker.h b/common/DeanLib/include/MemoryTracker.h new file mode 100644 index 00000000..4c3bac84 --- /dev/null +++ b/common/DeanLib/include/MemoryTracker.h @@ -0,0 +1,38 @@ +#pragma once + +#include +#include + + +class MemoryTracker +{ +public: + static MemoryTracker* getInstance(); + + void addAllocation( void* ptr, size_t size ); + void removeAllocation( void* ptr ); + + void reportAllocations( std::ostream& stream ); + +private: + struct AllocationRecord + { + AllocationRecord(int theNum, size_t theSize) : num(theNum), size(theSize) {}; + int num; + size_t size; + }; + + + MemoryTracker(); + ~MemoryTracker(); + + //copying not allowed + MemoryTracker( const MemoryTracker& ); + MemoryTracker& operator=( const MemoryTracker& ); + + std::unordered_map mAllocations; + + static int msAllocationNum; + static MemoryTracker* mspInstance; +}; + diff --git a/common/DeanLib/include/MultiDimensionalArray.h b/common/DeanLib/include/MultiDimensionalArray.h new file mode 100644 index 00000000..040f1dde --- /dev/null +++ b/common/DeanLib/include/MultiDimensionalArray.h @@ -0,0 +1,62 @@ +#pragma once + +#include "Trackable.h" + +template < class T > +class MultiDimensionalArray :public Trackable +{ +public: + explicit MultiDimensionalArray(unsigned int numRows, unsigned int numCols, const T& initialValue) + :mNumRows(numRows) + ,mNumCols(numCols) + { + mArray = new T[mNumRows*mNumCols]; + for (unsigned int i = 0; i < mNumRows*mNumCols; i++) + { + mArray[i] = initialValue; + } + + } + + ~MultiDimensionalArray() + { + delete [] mArray; + } + + T* get(unsigned int index) + { + if (index < mNumRows * mNumCols) + { + return &(mArray[index]); + } + else + return NULL; + } + + T* get(unsigned int colNum, unsigned int rowNum) + { + return get(convertCoordsToIndex(colNum,rowNum)); + } + + void set(unsigned int index, const T& val) { *(get(index)) = val; } + void set(unsigned int colNum, unsigned int rowNum, const T& val) { *(get(colNum,rowNum)) = val; } + + void convertIndexToCoords(unsigned int index, unsigned int& xOut, unsigned int& yOut) + { + xOut = index % mNumCols; + yOut = index / mNumCols; + } + + unsigned int convertCoordsToIndex(const unsigned int& xIn, const unsigned int& yIn) + { + unsigned int index = yIn * mNumCols + xIn; + return index; + } + +private: + T* mArray; + unsigned int mNumRows; + unsigned int mNumCols; + + +}; diff --git a/common/DeanLib/include/PerformanceTracker.h b/common/DeanLib/include/PerformanceTracker.h new file mode 100644 index 00000000..bfb5dc41 --- /dev/null +++ b/common/DeanLib/include/PerformanceTracker.h @@ -0,0 +1,24 @@ +#pragma once + +#include "Timer.h" + +#include +#include +#include "Trackable.h" + +class PerformanceTracker: public Trackable +{ +public: + PerformanceTracker(); + ~PerformanceTracker(); + + void startTracking( const std::string& trackerName ); + void stopTracking( const std::string& trackerName ); + double getElapsedTime( const std::string& trackerName ); + void removeTracker( const std::string& trackerName ); + void clearTracker( const std::string& trackerName ); + +private: + std::map mTimers; +}; + diff --git a/common/DeanLib/include/RayCaster.h b/common/DeanLib/include/RayCaster.h new file mode 100644 index 00000000..d17e76d5 --- /dev/null +++ b/common/DeanLib/include/RayCaster.h @@ -0,0 +1,12 @@ +#pragma once + +#include "Trackable.h" +#include "Vector2D.h" + +#include + +class RayCaster :public Trackable +{ +public: + static std::vector getPoints(const Vector2D& start, const Vector2D& end, float interval); +}; \ No newline at end of file diff --git a/common/DeanLib/include/TimedCallback.h b/common/DeanLib/include/TimedCallback.h new file mode 100644 index 00000000..db5f020b --- /dev/null +++ b/common/DeanLib/include/TimedCallback.h @@ -0,0 +1,51 @@ +#pragma once + +#include + +/*template +void callbackFunc(T var) +{ + F(var); +}*/ + +template +class TimedCallback :public Trackable +{ +public: + TimedCallback(double delayInMS, void(*func)(T), T val) + :mDelayInMS(delayInMS) + ,mTimeLeft(delayInMS) + ,mpCallbackFunc(func) + ,mValue(val) + { + }; + + bool update(double dtInMS)//returns true after calling callback, false otherwise + { + mTimeLeft -= dtInMS; + if (mTimeLeft <= 0.0) + { + call(mValue); + return true; + } + else + return false; + } + + void reset(double delayInMS) + { + mDelayInMS = delayInMS; + mTimeLeft = delayInMS; + } +private: + void(*mpCallbackFunc)(T) = nullptr; + double mDelayInMS = 0.0; + double mTimeLeft = 0.0; + T mValue; + + void call(T var) + { + mpCallbackFunc(var); + }; + +}; diff --git a/common/DeanLib/include/Timer.h b/common/DeanLib/include/Timer.h new file mode 100644 index 00000000..b6b95f81 --- /dev/null +++ b/common/DeanLib/include/Timer.h @@ -0,0 +1,34 @@ +#pragma once +#include +#include "Trackable.h" + +/* Timer - high accuracy timer - uses Large Integer to prevent rollover + +Dean Lawson +Champlain College +2011 +*/ + +class Timer:public Trackable +{ +public: + Timer(); + ~Timer(); + + void start(); + void stop(); + double getElapsedTime() const;//returns how much time has elapsed since start + void sleepUntilElapsed( double ms ); + void pause( bool shouldPause ); + +private: + LARGE_INTEGER mStartTime; + LARGE_INTEGER mEndTime; + LARGE_INTEGER mTimerFrequency; + double mElapsedTime; + bool mPaused; + + //helper function - uses current frequency for the Timer + double calcDifferenceInMS( LARGE_INTEGER from, LARGE_INTEGER to ) const; + +}; \ No newline at end of file diff --git a/common/DeanLib/include/Trackable.h b/common/DeanLib/include/Trackable.h new file mode 100644 index 00000000..74d2e34f --- /dev/null +++ b/common/DeanLib/include/Trackable.h @@ -0,0 +1,24 @@ +#pragma once + +#include + +class Trackable +{ +public: + Trackable(std::string info) : mDebugSource(info) {} + Trackable() {} + void* operator new(std::size_t size); + void operator delete(void *ptr); + void* operator new[](std::size_t size); + void operator delete[](void *ptr); + + //for use with placement new + void* operator new(std::size_t size, void* ptr){ return ptr; }; + void operator delete(void *ptr, void*ptr2){}; + void* operator new[](std::size_t size, void* ptr){ return ptr; }; + void operator delete[](void *ptr, void* ptr2){}; + + const std::string& getDebugSource() { return mDebugSource; } +private: + std::string mDebugSource = ""; +}; diff --git a/common/DeanLib/include/Vector2D.h b/common/DeanLib/include/Vector2D.h new file mode 100644 index 00000000..cdfc2b7b --- /dev/null +++ b/common/DeanLib/include/Vector2D.h @@ -0,0 +1,70 @@ +#pragma once + +/* Vector2D is a generally usable 2D vector. Most of the operator overloading code is patterned after the notes from + California Institue of Technology site: http://www.cs.caltech.edu/courses/cs11/material/cpp/donnie/cpp-ops.html . + Exact author unknown. + May be missing some important functions but this should be enough to do most things. + + by Dean Lawson + Champlain College + 2011 +*/ + +#include "Trackable.h" +#include "DeanMath.h" +#include +#include + + +class Vector2D:public Trackable +{ + friend std::ostream & operator<< (std::ostream& out, const Vector2D& vector); + +public: + explicit Vector2D(float x = 0.0f, float y = 0.0f);//constructor + explicit Vector2D(int x, int y);//constructor + Vector2D( const Vector2D& rhs );//copy constructor + ~Vector2D();//destructor + + //math operators + Vector2D& operator += ( const Vector2D& rhs ); + Vector2D& operator -= ( const Vector2D& rhs ); + Vector2D& operator *= ( float mult ); + Vector2D& operator /= ( float div ); + Vector2D& operator = ( const Vector2D& rhs ); + + bool operator == ( const Vector2D& rhs )const; + bool operator != ( const Vector2D& rhs )const; + + Vector2D operator+(const Vector2D &other) const; + Vector2D operator-(const Vector2D &other) const; + Vector2D operator*(float mult) const; + Vector2D operator/(float div) const; + + //getters and setters + inline float getX() const { return mX; }; + inline float getY() const { return mY; }; + inline void setX( float x ) { mX = x; }; + inline void setY( float y ) { mY = y; }; + + //length functions + bool hasNonZeroLength() const; + float getLength() const; + float getLengthSquared() const;//more efficient than get length - use when comparing distances and actual distance is not needed + + void normalize();//makes vector a unit vector (length of 1) + Vector2D getNormalizedVector() const;//returns a vector of length 1 but leaves the original vector unchanged + float dotProduct(const Vector2D& other) const; + Vector2D getRightVector() const;//right vector is a vector perpendicular and on the right side + double calcFacing() const; + static Vector2D getVectorInDirection(double direction); + +private: + float mX; + float mY; +}; + +std::ostream & operator<< (std::ostream& out, const Vector2D& vector); + +const Vector2D ZERO_VECTOR2D(0.0f, 0.0f);//useful when we need to return a pointer to a default vector from a function + diff --git a/common/DeanLib/lib/DeanLibDebug.idb b/common/DeanLib/lib/DeanLibDebug.idb new file mode 100644 index 00000000..c5f8480a Binary files /dev/null and b/common/DeanLib/lib/DeanLibDebug.idb differ diff --git a/common/DeanLib/lib/DeanLibDebug.lib b/common/DeanLib/lib/DeanLibDebug.lib new file mode 100644 index 00000000..0fbf5c3e Binary files /dev/null and b/common/DeanLib/lib/DeanLibDebug.lib differ diff --git a/common/DeanLib/lib/DeanLibRelease.lib b/common/DeanLib/lib/DeanLibRelease.lib new file mode 100644 index 00000000..4248a25b Binary files /dev/null and b/common/DeanLib/lib/DeanLibRelease.lib differ diff --git a/common/allegro/include/allegro5/alcompat.h b/common/allegro/include/allegro5/alcompat.h new file mode 100644 index 00000000..e0f6cef3 --- /dev/null +++ b/common/allegro/include/allegro5/alcompat.h @@ -0,0 +1,24 @@ +#ifndef __al_included_allegro5_alcompat_h +#define __al_included_allegro5_alcompat_h + +#ifdef __cplusplus + extern "C" { +#endif + + +#define ALLEGRO_DST_COLOR (ALLEGRO_DEST_COLOR) +#define ALLEGRO_INVERSE_DST_COLOR (ALLEGRO_INVERSE_DEST_COLOR) + +#define al_convert_bitmaps() (al_convert_memory_bitmaps()) +#define al_current_time() (al_get_time()) +#define al_event_queue_is_empty(q) (al_is_event_queue_empty(q)) +#define al_toggle_display_flag(d, f, o) (al_set_display_flag((d), (f), (o))) + + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/allegro.h b/common/allegro/include/allegro5/allegro.h new file mode 100644 index 00000000..06d40987 --- /dev/null +++ b/common/allegro/include/allegro5/allegro.h @@ -0,0 +1,79 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Main header file for the entire Allegro library. + * (separate modules can be included from the allegro/ directory) + * + * By Shawn Hargreaves. + * + * Vincent Penquerc'h split the original allegro.h into separate headers. + * + * See readme.txt for copyright information. + */ + + +#ifndef __al_included_allegro5_allegro_h +#define __al_included_allegro5_allegro_h + + +#include "allegro5/base.h" + +#include "allegro5/altime.h" +#include "allegro5/bitmap.h" +#include "allegro5/bitmap_draw.h" +#include "allegro5/bitmap_io.h" +#include "allegro5/bitmap_lock.h" +#include "allegro5/blender.h" +#include "allegro5/clipboard.h" +#include "allegro5/color.h" +#include "allegro5/config.h" +#include "allegro5/cpu.h" +#include "allegro5/debug.h" +#include "allegro5/display.h" +#include "allegro5/drawing.h" +#include "allegro5/error.h" +#include "allegro5/events.h" +#include "allegro5/file.h" +#include "allegro5/fixed.h" +#include "allegro5/fmaths.h" +#include "allegro5/fshook.h" +#include "allegro5/fullscreen_mode.h" +#include "allegro5/haptic.h" +#include "allegro5/joystick.h" +#include "allegro5/keyboard.h" +#include "allegro5/memory.h" +#include "allegro5/monitor.h" +#include "allegro5/mouse.h" +#include "allegro5/mouse_cursor.h" +#include "allegro5/path.h" +#include "allegro5/render_state.h" +#include "allegro5/shader.h" +#include "allegro5/system.h" +#include "allegro5/threads.h" +#include "allegro5/timer.h" +#include "allegro5/tls.h" +#include "allegro5/touch_input.h" +#include "allegro5/transformations.h" +#include "allegro5/utf8.h" + + +#ifndef ALLEGRO_NO_COMPATIBILITY + #include "allegro5/alcompat.h" +#endif + + +#ifdef ALLEGRO_EXTRA_HEADER + #include ALLEGRO_EXTRA_HEADER +#endif + + +#endif + + diff --git a/common/allegro/include/allegro5/allegro5.h b/common/allegro/include/allegro5/allegro5.h new file mode 100644 index 00000000..8e604c69 --- /dev/null +++ b/common/allegro/include/allegro5/allegro5.h @@ -0,0 +1,2 @@ +#include "allegro.h" + diff --git a/common/allegro/include/allegro5/allegro_acodec.h b/common/allegro/include/allegro5/allegro_acodec.h new file mode 100644 index 00000000..a107ad61 --- /dev/null +++ b/common/allegro/include/allegro5/allegro_acodec.h @@ -0,0 +1,40 @@ +#ifndef __al_included_allegro5_allegro_acodec_h +#define __al_included_allegro5_allegro_acodec_h + +#include "allegro5/allegro.h" +#include "allegro5/allegro_audio.h" + +#ifdef __cplusplus +extern "C" { +#endif + +#if (defined ALLEGRO_MINGW32) || (defined ALLEGRO_MSVC) + #ifndef ALLEGRO_STATICLINK + #ifdef ALLEGRO_ACODEC_SRC + #define _ALLEGRO_ACODEC_DLL __declspec(dllexport) + #else + #define _ALLEGRO_ACODEC_DLL __declspec(dllimport) + #endif + #else + #define _ALLEGRO_ACODEC_DLL + #endif +#endif + +#if defined ALLEGRO_MSVC + #define ALLEGRO_ACODEC_FUNC(type, name, args) _ALLEGRO_ACODEC_DLL type __cdecl name args +#elif defined ALLEGRO_MINGW32 + #define ALLEGRO_ACODEC_FUNC(type, name, args) extern type name args +#else + #define ALLEGRO_ACODEC_FUNC AL_FUNC +#endif + + +ALLEGRO_ACODEC_FUNC(bool, al_init_acodec_addon, (void)); +ALLEGRO_ACODEC_FUNC(uint32_t, al_get_allegro_acodec_version, (void)); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/common/allegro/include/allegro5/allegro_audio.h b/common/allegro/include/allegro5/allegro_audio.h new file mode 100644 index 00000000..d57d078e --- /dev/null +++ b/common/allegro/include/allegro5/allegro_audio.h @@ -0,0 +1,427 @@ +/* + * Updated for 4.9 api inclusion by Ryan Dickie + * Originally done by KC/Milan + */ + +#ifndef __al_included_allegro5_allegro_audio_h +#define __al_included_allegro5_allegro_audio_h + +#ifdef __cplusplus +extern "C" { +#endif + +/* Title: Audio types + */ + +#include "allegro5/allegro.h" + + +#if (defined ALLEGRO_MINGW32) || (defined ALLEGRO_MSVC) || (defined ALLEGRO_BCC32) + #ifndef ALLEGRO_STATICLINK + #ifdef ALLEGRO_KCM_AUDIO_SRC + #define _ALLEGRO_KCM_AUDIO_DLL __declspec(dllexport) + #else + #define _ALLEGRO_KCM_AUDIO_DLL __declspec(dllimport) + #endif + #else + #define _ALLEGRO_KCM_AUDIO_DLL + #endif +#endif + +#if defined ALLEGRO_MSVC + #define ALLEGRO_KCM_AUDIO_FUNC(type, name, args) _ALLEGRO_KCM_AUDIO_DLL type __cdecl name args +#elif defined ALLEGRO_MINGW32 + #define ALLEGRO_KCM_AUDIO_FUNC(type, name, args) extern type name args +#elif defined ALLEGRO_BCC32 + #define ALLEGRO_KCM_AUDIO_FUNC(type, name, args) extern _ALLEGRO_KCM_AUDIO_DLL type name args +#else + #define ALLEGRO_KCM_AUDIO_FUNC AL_FUNC +#endif + +/* Enum: ALLEGRO_AUDIO_EVENT_TYPE + */ +enum ALLEGRO_AUDIO_EVENT_TYPE +{ + /* Internal, used to communicate with acodec. */ + /* Must be in 512 <= n < 1024 */ + _KCM_STREAM_FEEDER_QUIT_EVENT_TYPE = 512, + ALLEGRO_EVENT_AUDIO_STREAM_FRAGMENT = 513, + ALLEGRO_EVENT_AUDIO_STREAM_FINISHED = 514, +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_KCM_AUDIO_SRC) + ALLEGRO_EVENT_AUDIO_RECORDER_FRAGMENT = 515, +#endif +}; + +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_KCM_AUDIO_SRC) +/* Type: ALLEGRO_AUDIO_RECORDER_EVENT + */ +typedef struct ALLEGRO_AUDIO_RECORDER_EVENT ALLEGRO_AUDIO_RECORDER_EVENT; +struct ALLEGRO_AUDIO_RECORDER_EVENT +{ + _AL_EVENT_HEADER(struct ALLEGRO_AUDIO_RECORDER) + struct ALLEGRO_USER_EVENT_DESCRIPTOR *__internal__descr; + void *buffer; + unsigned int samples; +}; +#endif + + +/* Enum: ALLEGRO_AUDIO_DEPTH + */ +enum ALLEGRO_AUDIO_DEPTH +{ + /* Sample depth and type, and signedness. Mixers only use 32-bit signed + * float (-1..+1). The unsigned value is a bit-flag applied to the depth + * value. + */ + ALLEGRO_AUDIO_DEPTH_INT8 = 0x00, + ALLEGRO_AUDIO_DEPTH_INT16 = 0x01, + ALLEGRO_AUDIO_DEPTH_INT24 = 0x02, + ALLEGRO_AUDIO_DEPTH_FLOAT32 = 0x03, + + ALLEGRO_AUDIO_DEPTH_UNSIGNED = 0x08, + + /* For convenience */ + ALLEGRO_AUDIO_DEPTH_UINT8 = ALLEGRO_AUDIO_DEPTH_INT8 | + ALLEGRO_AUDIO_DEPTH_UNSIGNED, + ALLEGRO_AUDIO_DEPTH_UINT16 = ALLEGRO_AUDIO_DEPTH_INT16 | + ALLEGRO_AUDIO_DEPTH_UNSIGNED, + ALLEGRO_AUDIO_DEPTH_UINT24 = ALLEGRO_AUDIO_DEPTH_INT24 | + ALLEGRO_AUDIO_DEPTH_UNSIGNED +}; + + +/* Enum: ALLEGRO_CHANNEL_CONF + */ +enum ALLEGRO_CHANNEL_CONF +{ + /* Speaker configuration (mono, stereo, 2.1, 3, etc). With regards to + * behavior, most of this code makes no distinction between, say, 4.1 and + * 5 speaker setups.. they both have 5 "channels". However, users would + * like the distinction, and later when the higher-level stuff is added, + * the differences will become more important. (v>>4)+(v&0xF) should yield + * the total channel count. + */ + ALLEGRO_CHANNEL_CONF_1 = 0x10, + ALLEGRO_CHANNEL_CONF_2 = 0x20, + ALLEGRO_CHANNEL_CONF_3 = 0x30, + ALLEGRO_CHANNEL_CONF_4 = 0x40, + ALLEGRO_CHANNEL_CONF_5_1 = 0x51, + ALLEGRO_CHANNEL_CONF_6_1 = 0x61, + ALLEGRO_CHANNEL_CONF_7_1 = 0x71 +#define ALLEGRO_MAX_CHANNELS 8 +}; + + +/* Enum: ALLEGRO_PLAYMODE + */ +enum ALLEGRO_PLAYMODE +{ + ALLEGRO_PLAYMODE_ONCE = 0x100, + ALLEGRO_PLAYMODE_LOOP = 0x101, + ALLEGRO_PLAYMODE_BIDIR = 0x102, + _ALLEGRO_PLAYMODE_STREAM_ONCE = 0x103, /* internal */ + _ALLEGRO_PLAYMODE_STREAM_ONEDIR = 0x104 /* internal */ +}; + + +/* Enum: ALLEGRO_MIXER_QUALITY + */ +enum ALLEGRO_MIXER_QUALITY +{ + ALLEGRO_MIXER_QUALITY_POINT = 0x110, + ALLEGRO_MIXER_QUALITY_LINEAR = 0x111, + ALLEGRO_MIXER_QUALITY_CUBIC = 0x112 +}; + + +/* Enum: ALLEGRO_AUDIO_PAN_NONE + */ +#define ALLEGRO_AUDIO_PAN_NONE (-1000.0f) + +/* Type: ALLEGRO_SAMPLE + */ +typedef struct ALLEGRO_SAMPLE ALLEGRO_SAMPLE; + + +/* Type: ALLEGRO_SAMPLE_ID + */ +typedef struct ALLEGRO_SAMPLE_ID ALLEGRO_SAMPLE_ID; + +struct ALLEGRO_SAMPLE_ID { + int _index; + int _id; +}; + + +/* Type: ALLEGRO_SAMPLE_INSTANCE + */ +typedef struct ALLEGRO_SAMPLE_INSTANCE ALLEGRO_SAMPLE_INSTANCE; + + +/* Type: ALLEGRO_AUDIO_STREAM + */ +typedef struct ALLEGRO_AUDIO_STREAM ALLEGRO_AUDIO_STREAM; + + +/* Type: ALLEGRO_MIXER + */ +typedef struct ALLEGRO_MIXER ALLEGRO_MIXER; + + +/* Type: ALLEGRO_VOICE + */ +typedef struct ALLEGRO_VOICE ALLEGRO_VOICE; + + +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_KCM_AUDIO_SRC) +/* Type: ALLEGRO_AUDIO_RECORDER + */ +typedef struct ALLEGRO_AUDIO_RECORDER ALLEGRO_AUDIO_RECORDER; +#endif + + +#ifndef __cplusplus +typedef enum ALLEGRO_AUDIO_DEPTH ALLEGRO_AUDIO_DEPTH; +typedef enum ALLEGRO_CHANNEL_CONF ALLEGRO_CHANNEL_CONF; +typedef enum ALLEGRO_PLAYMODE ALLEGRO_PLAYMODE; +typedef enum ALLEGRO_MIXER_QUALITY ALLEGRO_MIXER_QUALITY; +#endif + + +/* Sample functions */ + +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_SAMPLE *, al_create_sample, (void *buf, + unsigned int samples, unsigned int freq, ALLEGRO_AUDIO_DEPTH depth, + ALLEGRO_CHANNEL_CONF chan_conf, bool free_buf)); +ALLEGRO_KCM_AUDIO_FUNC(void, al_destroy_sample, (ALLEGRO_SAMPLE *spl)); + + +/* Sample instance functions */ +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_SAMPLE_INSTANCE*, al_create_sample_instance, ( + ALLEGRO_SAMPLE *data)); +ALLEGRO_KCM_AUDIO_FUNC(void, al_destroy_sample_instance, ( + ALLEGRO_SAMPLE_INSTANCE *spl)); + +ALLEGRO_KCM_AUDIO_FUNC(unsigned int, al_get_sample_frequency, (const ALLEGRO_SAMPLE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(unsigned int, al_get_sample_length, (const ALLEGRO_SAMPLE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_AUDIO_DEPTH, al_get_sample_depth, (const ALLEGRO_SAMPLE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_CHANNEL_CONF, al_get_sample_channels, (const ALLEGRO_SAMPLE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(void *, al_get_sample_data, (const ALLEGRO_SAMPLE *spl)); + +ALLEGRO_KCM_AUDIO_FUNC(unsigned int, al_get_sample_instance_frequency, (const ALLEGRO_SAMPLE_INSTANCE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(unsigned int, al_get_sample_instance_length, (const ALLEGRO_SAMPLE_INSTANCE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(unsigned int, al_get_sample_instance_position, (const ALLEGRO_SAMPLE_INSTANCE *spl)); + +ALLEGRO_KCM_AUDIO_FUNC(float, al_get_sample_instance_speed, (const ALLEGRO_SAMPLE_INSTANCE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(float, al_get_sample_instance_gain, (const ALLEGRO_SAMPLE_INSTANCE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(float, al_get_sample_instance_pan, (const ALLEGRO_SAMPLE_INSTANCE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(float, al_get_sample_instance_time, (const ALLEGRO_SAMPLE_INSTANCE *spl)); + +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_AUDIO_DEPTH, al_get_sample_instance_depth, (const ALLEGRO_SAMPLE_INSTANCE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_CHANNEL_CONF, al_get_sample_instance_channels, (const ALLEGRO_SAMPLE_INSTANCE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_PLAYMODE, al_get_sample_instance_playmode, (const ALLEGRO_SAMPLE_INSTANCE *spl)); + +ALLEGRO_KCM_AUDIO_FUNC(bool, al_get_sample_instance_playing, (const ALLEGRO_SAMPLE_INSTANCE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_get_sample_instance_attached, (const ALLEGRO_SAMPLE_INSTANCE *spl)); + +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_sample_instance_position, (ALLEGRO_SAMPLE_INSTANCE *spl, unsigned int val)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_sample_instance_length, (ALLEGRO_SAMPLE_INSTANCE *spl, unsigned int val)); + +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_sample_instance_speed, (ALLEGRO_SAMPLE_INSTANCE *spl, float val)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_sample_instance_gain, (ALLEGRO_SAMPLE_INSTANCE *spl, float val)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_sample_instance_pan, (ALLEGRO_SAMPLE_INSTANCE *spl, float val)); + +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_sample_instance_playmode, (ALLEGRO_SAMPLE_INSTANCE *spl, ALLEGRO_PLAYMODE val)); + +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_sample_instance_playing, (ALLEGRO_SAMPLE_INSTANCE *spl, bool val)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_detach_sample_instance, (ALLEGRO_SAMPLE_INSTANCE *spl)); + +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_sample, (ALLEGRO_SAMPLE_INSTANCE *spl, ALLEGRO_SAMPLE *data)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_SAMPLE *, al_get_sample, (ALLEGRO_SAMPLE_INSTANCE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_play_sample_instance, (ALLEGRO_SAMPLE_INSTANCE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_stop_sample_instance, (ALLEGRO_SAMPLE_INSTANCE *spl)); +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_KCM_AUDIO_SRC) +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_sample_instance_channel_matrix, (ALLEGRO_SAMPLE_INSTANCE *spl, const float *matrix)); +#endif + + +/* Stream functions */ +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_AUDIO_STREAM*, al_create_audio_stream, (size_t buffer_count, + unsigned int samples, unsigned int freq, + ALLEGRO_AUDIO_DEPTH depth, ALLEGRO_CHANNEL_CONF chan_conf)); +ALLEGRO_KCM_AUDIO_FUNC(void, al_destroy_audio_stream, (ALLEGRO_AUDIO_STREAM *stream)); +ALLEGRO_KCM_AUDIO_FUNC(void, al_drain_audio_stream, (ALLEGRO_AUDIO_STREAM *stream)); + +ALLEGRO_KCM_AUDIO_FUNC(unsigned int, al_get_audio_stream_frequency, (const ALLEGRO_AUDIO_STREAM *stream)); +ALLEGRO_KCM_AUDIO_FUNC(unsigned int, al_get_audio_stream_length, (const ALLEGRO_AUDIO_STREAM *stream)); +ALLEGRO_KCM_AUDIO_FUNC(unsigned int, al_get_audio_stream_fragments, (const ALLEGRO_AUDIO_STREAM *stream)); +ALLEGRO_KCM_AUDIO_FUNC(unsigned int, al_get_available_audio_stream_fragments, (const ALLEGRO_AUDIO_STREAM *stream)); + +ALLEGRO_KCM_AUDIO_FUNC(float, al_get_audio_stream_speed, (const ALLEGRO_AUDIO_STREAM *stream)); +ALLEGRO_KCM_AUDIO_FUNC(float, al_get_audio_stream_gain, (const ALLEGRO_AUDIO_STREAM *stream)); +ALLEGRO_KCM_AUDIO_FUNC(float, al_get_audio_stream_pan, (const ALLEGRO_AUDIO_STREAM *stream)); + +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_CHANNEL_CONF, al_get_audio_stream_channels, (const ALLEGRO_AUDIO_STREAM *stream)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_AUDIO_DEPTH, al_get_audio_stream_depth, (const ALLEGRO_AUDIO_STREAM *stream)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_PLAYMODE, al_get_audio_stream_playmode, (const ALLEGRO_AUDIO_STREAM *stream)); + +ALLEGRO_KCM_AUDIO_FUNC(bool, al_get_audio_stream_playing, (const ALLEGRO_AUDIO_STREAM *spl)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_get_audio_stream_attached, (const ALLEGRO_AUDIO_STREAM *spl)); +ALLEGRO_KCM_AUDIO_FUNC(uint64_t, al_get_audio_stream_played_samples, (const ALLEGRO_AUDIO_STREAM *stream)); + +ALLEGRO_KCM_AUDIO_FUNC(void *, al_get_audio_stream_fragment, (const ALLEGRO_AUDIO_STREAM *stream)); + +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_audio_stream_speed, (ALLEGRO_AUDIO_STREAM *stream, float val)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_audio_stream_gain, (ALLEGRO_AUDIO_STREAM *stream, float val)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_audio_stream_pan, (ALLEGRO_AUDIO_STREAM *stream, float val)); + +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_audio_stream_playmode, (ALLEGRO_AUDIO_STREAM *stream, ALLEGRO_PLAYMODE val)); + +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_audio_stream_playing, (ALLEGRO_AUDIO_STREAM *stream, bool val)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_detach_audio_stream, (ALLEGRO_AUDIO_STREAM *stream)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_audio_stream_fragment, (ALLEGRO_AUDIO_STREAM *stream, void *val)); + +ALLEGRO_KCM_AUDIO_FUNC(bool, al_rewind_audio_stream, (ALLEGRO_AUDIO_STREAM *stream)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_seek_audio_stream_secs, (ALLEGRO_AUDIO_STREAM *stream, double time)); +ALLEGRO_KCM_AUDIO_FUNC(double, al_get_audio_stream_position_secs, (ALLEGRO_AUDIO_STREAM *stream)); +ALLEGRO_KCM_AUDIO_FUNC(double, al_get_audio_stream_length_secs, (ALLEGRO_AUDIO_STREAM *stream)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_audio_stream_loop_secs, (ALLEGRO_AUDIO_STREAM *stream, double start, double end)); + +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_EVENT_SOURCE *, al_get_audio_stream_event_source, (ALLEGRO_AUDIO_STREAM *stream)); + +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_KCM_AUDIO_SRC) +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_audio_stream_channel_matrix, (ALLEGRO_AUDIO_STREAM *stream, const float *matrix)); +#endif + +/* Mixer functions */ +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_MIXER*, al_create_mixer, (unsigned int freq, + ALLEGRO_AUDIO_DEPTH depth, ALLEGRO_CHANNEL_CONF chan_conf)); +ALLEGRO_KCM_AUDIO_FUNC(void, al_destroy_mixer, (ALLEGRO_MIXER *mixer)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_attach_sample_instance_to_mixer, ( + ALLEGRO_SAMPLE_INSTANCE *stream, ALLEGRO_MIXER *mixer)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_attach_audio_stream_to_mixer, (ALLEGRO_AUDIO_STREAM *stream, + ALLEGRO_MIXER *mixer)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_attach_mixer_to_mixer, (ALLEGRO_MIXER *stream, + ALLEGRO_MIXER *mixer)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_mixer_postprocess_callback, ( + ALLEGRO_MIXER *mixer, + void (*cb)(void *buf, unsigned int samples, void *data), + void *data)); + +ALLEGRO_KCM_AUDIO_FUNC(unsigned int, al_get_mixer_frequency, (const ALLEGRO_MIXER *mixer)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_CHANNEL_CONF, al_get_mixer_channels, (const ALLEGRO_MIXER *mixer)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_AUDIO_DEPTH, al_get_mixer_depth, (const ALLEGRO_MIXER *mixer)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_MIXER_QUALITY, al_get_mixer_quality, (const ALLEGRO_MIXER *mixer)); +ALLEGRO_KCM_AUDIO_FUNC(float, al_get_mixer_gain, (const ALLEGRO_MIXER *mixer)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_get_mixer_playing, (const ALLEGRO_MIXER *mixer)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_get_mixer_attached, (const ALLEGRO_MIXER *mixer)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_mixer_frequency, (ALLEGRO_MIXER *mixer, unsigned int val)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_mixer_quality, (ALLEGRO_MIXER *mixer, ALLEGRO_MIXER_QUALITY val)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_mixer_gain, (ALLEGRO_MIXER *mixer, float gain)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_mixer_playing, (ALLEGRO_MIXER *mixer, bool val)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_detach_mixer, (ALLEGRO_MIXER *mixer)); + +/* Voice functions */ +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_VOICE*, al_create_voice, (unsigned int freq, + ALLEGRO_AUDIO_DEPTH depth, + ALLEGRO_CHANNEL_CONF chan_conf)); +ALLEGRO_KCM_AUDIO_FUNC(void, al_destroy_voice, (ALLEGRO_VOICE *voice)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_attach_sample_instance_to_voice, ( + ALLEGRO_SAMPLE_INSTANCE *stream, ALLEGRO_VOICE *voice)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_attach_audio_stream_to_voice, ( + ALLEGRO_AUDIO_STREAM *stream, ALLEGRO_VOICE *voice )); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_attach_mixer_to_voice, (ALLEGRO_MIXER *mixer, + ALLEGRO_VOICE *voice)); +ALLEGRO_KCM_AUDIO_FUNC(void, al_detach_voice, (ALLEGRO_VOICE *voice)); + +ALLEGRO_KCM_AUDIO_FUNC(unsigned int, al_get_voice_frequency, (const ALLEGRO_VOICE *voice)); +ALLEGRO_KCM_AUDIO_FUNC(unsigned int, al_get_voice_position, (const ALLEGRO_VOICE *voice)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_CHANNEL_CONF, al_get_voice_channels, (const ALLEGRO_VOICE *voice)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_AUDIO_DEPTH, al_get_voice_depth, (const ALLEGRO_VOICE *voice)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_get_voice_playing, (const ALLEGRO_VOICE *voice)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_voice_position, (ALLEGRO_VOICE *voice, unsigned int val)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_voice_playing, (ALLEGRO_VOICE *voice, bool val)); + +/* Misc. audio functions */ +ALLEGRO_KCM_AUDIO_FUNC(bool, al_install_audio, (void)); +ALLEGRO_KCM_AUDIO_FUNC(void, al_uninstall_audio, (void)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_is_audio_installed, (void)); +ALLEGRO_KCM_AUDIO_FUNC(uint32_t, al_get_allegro_audio_version, (void)); + +ALLEGRO_KCM_AUDIO_FUNC(size_t, al_get_channel_count, (ALLEGRO_CHANNEL_CONF conf)); +ALLEGRO_KCM_AUDIO_FUNC(size_t, al_get_audio_depth_size, (ALLEGRO_AUDIO_DEPTH conf)); + +ALLEGRO_KCM_AUDIO_FUNC(void, al_fill_silence, (void *buf, unsigned int samples, + ALLEGRO_AUDIO_DEPTH depth, ALLEGRO_CHANNEL_CONF chan_conf)); + +/* Simple audio layer */ +ALLEGRO_KCM_AUDIO_FUNC(bool, al_reserve_samples, (int reserve_samples)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_MIXER *, al_get_default_mixer, (void)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_set_default_mixer, (ALLEGRO_MIXER *mixer)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_restore_default_mixer, (void)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_play_sample, (ALLEGRO_SAMPLE *data, + float gain, float pan, float speed, ALLEGRO_PLAYMODE loop, ALLEGRO_SAMPLE_ID *ret_id)); +ALLEGRO_KCM_AUDIO_FUNC(void, al_stop_sample, (ALLEGRO_SAMPLE_ID *spl_id)); +ALLEGRO_KCM_AUDIO_FUNC(void, al_stop_samples, (void)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_VOICE *, al_get_default_voice, (void)); +ALLEGRO_KCM_AUDIO_FUNC(void, al_set_default_voice, (ALLEGRO_VOICE *voice)); + +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_KCM_AUDIO_SRC) +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_SAMPLE_INSTANCE*, al_lock_sample_id, (ALLEGRO_SAMPLE_ID *spl_id)); +ALLEGRO_KCM_AUDIO_FUNC(void, al_unlock_sample_id, (ALLEGRO_SAMPLE_ID *spl_id)); +#endif + +/* File type handlers */ +ALLEGRO_KCM_AUDIO_FUNC(bool, al_register_sample_loader, (const char *ext, + ALLEGRO_SAMPLE *(*loader)(const char *filename))); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_register_sample_saver, (const char *ext, + bool (*saver)(const char *filename, ALLEGRO_SAMPLE *spl))); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_register_audio_stream_loader, (const char *ext, + ALLEGRO_AUDIO_STREAM *(*stream_loader)(const char *filename, + size_t buffer_count, unsigned int samples))); + +ALLEGRO_KCM_AUDIO_FUNC(bool, al_register_sample_loader_f, (const char *ext, + ALLEGRO_SAMPLE *(*loader)(ALLEGRO_FILE *fp))); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_register_sample_saver_f, (const char *ext, + bool (*saver)(ALLEGRO_FILE *fp, ALLEGRO_SAMPLE *spl))); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_register_audio_stream_loader_f, (const char *ext, + ALLEGRO_AUDIO_STREAM *(*stream_loader)(ALLEGRO_FILE *fp, + size_t buffer_count, unsigned int samples))); + +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_SAMPLE *, al_load_sample, (const char *filename)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_save_sample, (const char *filename, + ALLEGRO_SAMPLE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_AUDIO_STREAM *, al_load_audio_stream, (const char *filename, + size_t buffer_count, unsigned int samples)); + +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_SAMPLE *, al_load_sample_f, (ALLEGRO_FILE* fp, const char *ident)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_save_sample_f, (ALLEGRO_FILE* fp, const char *ident, + ALLEGRO_SAMPLE *spl)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_AUDIO_STREAM *, al_load_audio_stream_f, (ALLEGRO_FILE* fp, const char *ident, + size_t buffer_count, unsigned int samples)); + + +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_KCM_AUDIO_SRC) + +/* Recording functions */ +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_AUDIO_RECORDER *, al_create_audio_recorder, (size_t fragment_count, + unsigned int samples, unsigned int freq, ALLEGRO_AUDIO_DEPTH depth, ALLEGRO_CHANNEL_CONF chan_conf)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_start_audio_recorder, (ALLEGRO_AUDIO_RECORDER *r)); +ALLEGRO_KCM_AUDIO_FUNC(void, al_stop_audio_recorder, (ALLEGRO_AUDIO_RECORDER *r)); +ALLEGRO_KCM_AUDIO_FUNC(bool, al_is_audio_recorder_recording, (ALLEGRO_AUDIO_RECORDER *r)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_EVENT_SOURCE *, al_get_audio_recorder_event_source, + (ALLEGRO_AUDIO_RECORDER *r)); +ALLEGRO_KCM_AUDIO_FUNC(ALLEGRO_AUDIO_RECORDER_EVENT *, al_get_audio_recorder_event, (ALLEGRO_EVENT *event)); +ALLEGRO_KCM_AUDIO_FUNC(void, al_destroy_audio_recorder, (ALLEGRO_AUDIO_RECORDER *r)); + +#endif + +#ifdef __cplusplus +} /* End extern "C" */ +#endif + +#endif + + +/* vim: set sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/allegro_color.h b/common/allegro/include/allegro5/allegro_color.h new file mode 100644 index 00000000..c690b876 --- /dev/null +++ b/common/allegro/include/allegro5/allegro_color.h @@ -0,0 +1,90 @@ +#ifndef __al_included_allegro5_allegro_color_h +#define __al_included_allegro5_allegro_color_h + +#include "allegro5/allegro.h" + +#if (defined ALLEGRO_MINGW32) || (defined ALLEGRO_MSVC) || (defined ALLEGRO_BCC32) + #ifndef ALLEGRO_STATICLINK + #ifdef ALLEGRO_COLOR_SRC + #define _ALLEGRO_COLOR_DLL __declspec(dllexport) + #else + #define _ALLEGRO_COLOR_DLL __declspec(dllimport) + #endif + #else + #define _ALLEGRO_COLOR_DLL + #endif +#endif + +#if defined ALLEGRO_MSVC + #define ALLEGRO_COLOR_FUNC(type, name, args) _ALLEGRO_COLOR_DLL type __cdecl name args +#elif defined ALLEGRO_MINGW32 + #define ALLEGRO_COLOR_FUNC(type, name, args) extern type name args +#elif defined ALLEGRO_BCC32 + #define ALLEGRO_COLOR_FUNC(type, name, args) extern _ALLEGRO_COLOR_DLL type name args +#else + #define ALLEGRO_COLOR_FUNC AL_FUNC +#endif + +#ifdef __cplusplus + extern "C" { +#endif + +ALLEGRO_COLOR_FUNC(uint32_t, al_get_allegro_color_version, (void)); + +ALLEGRO_COLOR_FUNC(void, al_color_hsv_to_rgb, (float hue, float saturation, + float value, float *red, float *green, float *blue)); +ALLEGRO_COLOR_FUNC(void, al_color_rgb_to_hsl, (float red, float green, float blue, + float *hue, float *saturation, float *lightness)); +ALLEGRO_COLOR_FUNC(void, al_color_rgb_to_hsv, (float red, float green, float blue, + float *hue, float *saturation, float *value)); +ALLEGRO_COLOR_FUNC(void, al_color_hsl_to_rgb, (float hue, float saturation, float lightness, + float *red, float *green, float *blue)); +ALLEGRO_COLOR_FUNC(bool, al_color_name_to_rgb, (char const *name, float *r, float *g, + float *b)); +ALLEGRO_COLOR_FUNC(const char*, al_color_rgb_to_name, (float r, float g, float b)); +ALLEGRO_COLOR_FUNC(void, al_color_cmyk_to_rgb, (float cyan, float magenta, float yellow, + float key, float *red, float *green, float *blue)); +ALLEGRO_COLOR_FUNC(void, al_color_rgb_to_cmyk, (float red, float green, float blue, + float *cyan, float *magenta, float *yellow, float *key)); +ALLEGRO_COLOR_FUNC(void, al_color_yuv_to_rgb, (float y, float u, float v, + float *red, float *green, float *blue)); +ALLEGRO_COLOR_FUNC(void, al_color_rgb_to_yuv, (float red, float green, float blue, + float *y, float *u, float *v)); +ALLEGRO_COLOR_FUNC(void, al_color_rgb_to_html, (float red, float green, float blue, + char *string)); +ALLEGRO_COLOR_FUNC(bool, al_color_html_to_rgb, (char const *string, + float *red, float *green, float *blue)); +ALLEGRO_COLOR_FUNC(ALLEGRO_COLOR, al_color_yuv, (float y, float u, float v)); +ALLEGRO_COLOR_FUNC(ALLEGRO_COLOR, al_color_cmyk, (float c, float m, float y, float k)); +ALLEGRO_COLOR_FUNC(ALLEGRO_COLOR, al_color_hsl, (float h, float s, float l)); +ALLEGRO_COLOR_FUNC(ALLEGRO_COLOR, al_color_hsv, (float h, float s, float v)); +ALLEGRO_COLOR_FUNC(ALLEGRO_COLOR, al_color_name, (char const *name)); +ALLEGRO_COLOR_FUNC(ALLEGRO_COLOR, al_color_html, (char const *string)); +ALLEGRO_COLOR_FUNC(void, al_color_xyz_to_rgb, (float x, float y, float z, + float *red, float *green, float *blue)); +ALLEGRO_COLOR_FUNC(void, al_color_rgb_to_xyz, (float red, float green, float blue, + float *x, float *y, float *z)); +ALLEGRO_COLOR_FUNC(ALLEGRO_COLOR, al_color_xyz, (float x, float y, float z)); +ALLEGRO_COLOR_FUNC(void, al_color_lab_to_rgb, (float l, float a, float b, + float *red, float *green, float *blue)); +ALLEGRO_COLOR_FUNC(void, al_color_rgb_to_lab, (float red, float green, float blue, + float *l, float *a, float *b)); +ALLEGRO_COLOR_FUNC(ALLEGRO_COLOR, al_color_lab, (float l, float a, float b)); +ALLEGRO_COLOR_FUNC(void, al_color_xyy_to_rgb, (float x, float y, float y2, + float *red, float *green, float *blue)); +ALLEGRO_COLOR_FUNC(void, al_color_rgb_to_xyy, (float red, float green, float blue, + float *x, float *y, float *y2)); +ALLEGRO_COLOR_FUNC(ALLEGRO_COLOR, al_color_xyy, (float x, float y, float y2)); +ALLEGRO_COLOR_FUNC(double, al_color_distance_ciede2000, (ALLEGRO_COLOR c1, ALLEGRO_COLOR c2)); +ALLEGRO_COLOR_FUNC(void, al_color_lch_to_rgb, (float l, float c, float h, + float *red, float *green, float *blue)); +ALLEGRO_COLOR_FUNC(void, al_color_rgb_to_lch, (float red, float green, float blue, + float *l, float *c, float *h)); +ALLEGRO_COLOR_FUNC(ALLEGRO_COLOR, al_color_lch, (float l, float c, float h)); +ALLEGRO_COLOR_FUNC(bool, al_is_color_valid, (ALLEGRO_COLOR colo)); + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/allegro_direct3d.h b/common/allegro/include/allegro5/allegro_direct3d.h new file mode 100644 index 00000000..7a21bc71 --- /dev/null +++ b/common/allegro/include/allegro5/allegro_direct3d.h @@ -0,0 +1,54 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Header file for Direct3D specific API. + * + * By Milan Mimica. + * + */ + +#ifndef __al_included_allegro5_allegro_direct3d_h +#define __al_included_allegro5_allegro_direct3d_h + +#include +#if defined ALLEGRO_CFG_SHADER_HLSL && defined __cplusplus +#include +#endif +#include "allegro5/platform/alplatf.h" + +/* Display creation flag. */ +#define ALLEGRO_DIRECT3D ALLEGRO_DIRECT3D_INTERNAL + +#ifdef __cplusplus + extern "C" { +#endif + +/* + * Public Direct3D-related API + */ + +AL_FUNC(LPDIRECT3DDEVICE9, al_get_d3d_device, (ALLEGRO_DISPLAY *)); +AL_FUNC(LPDIRECT3DTEXTURE9, al_get_d3d_system_texture, (ALLEGRO_BITMAP *)); +AL_FUNC(LPDIRECT3DTEXTURE9, al_get_d3d_video_texture, (ALLEGRO_BITMAP *)); +AL_FUNC(bool, al_have_d3d_non_pow2_texture_support, (void)); +AL_FUNC(bool, al_have_d3d_non_square_texture_support, (void)); +AL_FUNC(void, al_get_d3d_texture_position, (ALLEGRO_BITMAP *bitmap, int *u, int *v)); +AL_FUNC(bool, al_get_d3d_texture_size, (ALLEGRO_BITMAP *bitmap, int *width, int *height)); +AL_FUNC(bool, al_is_d3d_device_lost, (ALLEGRO_DISPLAY *display)); +AL_FUNC(void, al_set_d3d_device_release_callback, (void (*callback)(ALLEGRO_DISPLAY *display))); +AL_FUNC(void, al_set_d3d_device_restore_callback, (void (*callback)(ALLEGRO_DISPLAY *display))); + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set ts=8 sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/allegro_font.h b/common/allegro/include/allegro5/allegro_font.h new file mode 100644 index 00000000..68f7bc04 --- /dev/null +++ b/common/allegro/include/allegro5/allegro_font.h @@ -0,0 +1,145 @@ +#ifndef __al_included_allegro5_allegro_font_h +#define __al_included_allegro5_allegro_font_h + +#include "allegro5/allegro.h" + +#if (defined ALLEGRO_MINGW32) || (defined ALLEGRO_MSVC) || (defined ALLEGRO_BCC32) + #ifndef ALLEGRO_STATICLINK + #ifdef ALLEGRO_FONT_SRC + #define _ALLEGRO_FONT_DLL __declspec(dllexport) + #else + #define _ALLEGRO_FONT_DLL __declspec(dllimport) + #endif + #else + #define _ALLEGRO_FONT_DLL + #endif +#endif + +#if defined ALLEGRO_MSVC + #define ALLEGRO_FONT_FUNC(type, name, args) _ALLEGRO_FONT_DLL type __cdecl name args + #define ALLEGRO_FONT_METHOD(type, name, args) type (__cdecl *name) args + #define ALLEGRO_FONT_FUNCPTR(type, name, args) extern _ALLEGRO_FONT_DLL type (__cdecl *name) args + #define ALLEGRO_FONT_PRINTFUNC(type, name, args, a, b) ALLEGRO_FONT_FUNC(type, name, args) +#elif defined ALLEGRO_MINGW32 + #define ALLEGRO_FONT_FUNC(type, name, args) extern type name args + #define ALLEGRO_FONT_METHOD(type, name, args) type (*name) args + #define ALLEGRO_FONT_FUNCPTR(type, name, args) extern _ALLEGRO_FONT_DLL type (*name) args + #define ALLEGRO_FONT_PRINTFUNC(type, name, args, a, b) ALLEGRO_FONT_FUNC(type, name, args) __attribute__ ((format (printf, a, b))) +#elif defined ALLEGRO_BCC32 + #define ALLEGRO_FONT_FUNC(type, name, args) extern _ALLEGRO_FONT_DLL type name args + #define ALLEGRO_FONT_METHOD(type, name, args) type (*name) args + #define ALLEGRO_FONT_FUNCPTR(type, name, args) extern _ALLEGRO_FONT_DLL type (*name) args + #define ALLEGRO_FONT_PRINTFUNC(type, name, args, a, b) ALLEGRO_FONT_FUNC(type, name, args) +#else + #define ALLEGRO_FONT_FUNC AL_FUNC + #define ALLEGRO_FONT_METHOD AL_METHOD + #define ALLEGRO_FONT_FUNCPTR AL_FUNCPTR + #define ALLEGRO_FONT_PRINTFUNC AL_PRINTFUNC +#endif + + +#ifdef __cplusplus + extern "C" { +#endif + + +/* Type: ALLEGRO_FONT +*/ +typedef struct ALLEGRO_FONT ALLEGRO_FONT; +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_FONT_SRC) + +/* Type: ALLEGRO_GLYPH +*/ +typedef struct ALLEGRO_GLYPH ALLEGRO_GLYPH; + +struct ALLEGRO_GLYPH +{ + ALLEGRO_BITMAP *bitmap; + int x; + int y; + int w; + int h; + int kerning; + int offset_x; + int offset_y; + int advance; +}; +#endif + +enum { + ALLEGRO_NO_KERNING = -1, + ALLEGRO_ALIGN_LEFT = 0, + ALLEGRO_ALIGN_CENTRE = 1, + ALLEGRO_ALIGN_CENTER = 1, + ALLEGRO_ALIGN_RIGHT = 2, + ALLEGRO_ALIGN_INTEGER = 4, +}; + +ALLEGRO_FONT_FUNC(bool, al_register_font_loader, (const char *ext, ALLEGRO_FONT *(*load)(const char *filename, int size, int flags))); +ALLEGRO_FONT_FUNC(ALLEGRO_FONT *, al_load_bitmap_font, (const char *filename)); +ALLEGRO_FONT_FUNC(ALLEGRO_FONT *, al_load_bitmap_font_flags, (const char *filename, int flags)); +ALLEGRO_FONT_FUNC(ALLEGRO_FONT *, al_load_font, (const char *filename, int size, int flags)); + +ALLEGRO_FONT_FUNC(ALLEGRO_FONT *, al_grab_font_from_bitmap, (ALLEGRO_BITMAP *bmp, int n, const int ranges[])); +ALLEGRO_FONT_FUNC(ALLEGRO_FONT *, al_create_builtin_font, (void)); + +ALLEGRO_FONT_FUNC(void, al_draw_ustr, (const ALLEGRO_FONT *font, ALLEGRO_COLOR color, float x, float y, int flags, ALLEGRO_USTR const *ustr)); +ALLEGRO_FONT_FUNC(void, al_draw_text, (const ALLEGRO_FONT *font, ALLEGRO_COLOR color, float x, float y, int flags, char const *text)); +ALLEGRO_FONT_FUNC(void, al_draw_justified_text, (const ALLEGRO_FONT *font, ALLEGRO_COLOR color, float x1, float x2, float y, float diff, int flags, char const *text)); +ALLEGRO_FONT_FUNC(void, al_draw_justified_ustr, (const ALLEGRO_FONT *font, ALLEGRO_COLOR color, float x1, float x2, float y, float diff, int flags, ALLEGRO_USTR const *text)); +ALLEGRO_FONT_PRINTFUNC(void, al_draw_textf, (const ALLEGRO_FONT *font, ALLEGRO_COLOR color, float x, float y, int flags, char const *format, ...), 6, 7); +ALLEGRO_FONT_PRINTFUNC(void, al_draw_justified_textf, (const ALLEGRO_FONT *font, ALLEGRO_COLOR color, float x1, float x2, float y, float diff, int flags, char const *format, ...), 8, 9); +ALLEGRO_FONT_FUNC(int, al_get_text_width, (const ALLEGRO_FONT *f, const char *str)); +ALLEGRO_FONT_FUNC(int, al_get_ustr_width, (const ALLEGRO_FONT *f, const ALLEGRO_USTR *ustr)); +ALLEGRO_FONT_FUNC(int, al_get_font_line_height, (const ALLEGRO_FONT *f)); +ALLEGRO_FONT_FUNC(int, al_get_font_ascent, (const ALLEGRO_FONT *f)); +ALLEGRO_FONT_FUNC(int, al_get_font_descent, (const ALLEGRO_FONT *f)); +ALLEGRO_FONT_FUNC(void, al_destroy_font, (ALLEGRO_FONT *f)); +ALLEGRO_FONT_FUNC(void, al_get_ustr_dimensions, (const ALLEGRO_FONT *f, + ALLEGRO_USTR const *text, + int *bbx, int *bby, int *bbw, int *bbh)); +ALLEGRO_FONT_FUNC(void, al_get_text_dimensions, (const ALLEGRO_FONT *f, + char const *text, + int *bbx, int *bby, int *bbw, int *bbh)); +ALLEGRO_FONT_FUNC(bool, al_init_font_addon, (void)); +ALLEGRO_FONT_FUNC(void, al_shutdown_font_addon, (void)); +ALLEGRO_FONT_FUNC(uint32_t, al_get_allegro_font_version, (void)); +ALLEGRO_FONT_FUNC(int, al_get_font_ranges, (ALLEGRO_FONT *font, + int ranges_count, int *ranges)); + +ALLEGRO_FONT_FUNC(void, al_draw_glyph, (const ALLEGRO_FONT *font, + ALLEGRO_COLOR color, float x, float y, int codepoint)); +ALLEGRO_FONT_FUNC(int, al_get_glyph_width, (const ALLEGRO_FONT *f, + int codepoint)); +ALLEGRO_FONT_FUNC(bool, al_get_glyph_dimensions, (const ALLEGRO_FONT *f, + int codepoint, int *bbx, int *bby, int *bbw, int *bbh)); +ALLEGRO_FONT_FUNC(int, al_get_glyph_advance, (const ALLEGRO_FONT *f, + int codepoint1, int codepoint2)); +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_FONT_SRC) +ALLEGRO_FONT_FUNC(bool, al_get_glyph, (const ALLEGRO_FONT *f, int prev_codepoint, int codepoint, ALLEGRO_GLYPH *glyph)); +#endif + +ALLEGRO_FONT_FUNC(void, al_draw_multiline_text, (const ALLEGRO_FONT *font, ALLEGRO_COLOR color, float x, float y, float max_width, float line_height, int flags, const char *text)); +ALLEGRO_FONT_FUNC(void, al_draw_multiline_textf, (const ALLEGRO_FONT *font, ALLEGRO_COLOR color, float x, float y, float max_width, float line_height, int flags, const char *format, ...)); +ALLEGRO_FONT_FUNC(void, al_draw_multiline_ustr, (const ALLEGRO_FONT *font, ALLEGRO_COLOR color, float x, float y, float max_width, float line_height, int flags, const ALLEGRO_USTR *text)); + +ALLEGRO_FONT_FUNC(void, al_do_multiline_text, (const ALLEGRO_FONT *font, + float max_width, const char *text, + bool (*cb)(int line_num, const char *line, int size, void *extra), + void *extra)); + +ALLEGRO_FONT_FUNC(void, al_do_multiline_ustr, (const ALLEGRO_FONT *font, + float max_width, const ALLEGRO_USTR *ustr, + bool (*cb)(int line_num, const ALLEGRO_USTR *line, void *extra), + void *extra)); + +ALLEGRO_FONT_FUNC(void, al_set_fallback_font, (ALLEGRO_FONT *font, + ALLEGRO_FONT *fallback)); +ALLEGRO_FONT_FUNC(ALLEGRO_FONT *, al_get_fallback_font, ( + ALLEGRO_FONT *font)); + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/allegro_image.h b/common/allegro/include/allegro5/allegro_image.h new file mode 100644 index 00000000..75d6f5ef --- /dev/null +++ b/common/allegro/include/allegro5/allegro_image.h @@ -0,0 +1,44 @@ +#ifndef __al_included_allegro5_allegro_image_h +#define __al_included_allegro5_allegro_image_h + +#include "allegro5/base.h" + +#if (defined ALLEGRO_MINGW32) || (defined ALLEGRO_MSVC) || (defined ALLEGRO_BCC32) + #ifndef ALLEGRO_STATICLINK + #ifdef ALLEGRO_IIO_SRC + #define _ALLEGRO_IIO_DLL __declspec(dllexport) + #else + #define _ALLEGRO_IIO_DLL __declspec(dllimport) + #endif + #else + #define _ALLEGRO_IIO_DLL + #endif +#endif + +#if defined ALLEGRO_MSVC + #define ALLEGRO_IIO_FUNC(type, name, args) _ALLEGRO_IIO_DLL type __cdecl name args +#elif defined ALLEGRO_MINGW32 + #define ALLEGRO_IIO_FUNC(type, name, args) extern type name args +#elif defined ALLEGRO_BCC32 + #define ALLEGRO_IIO_FUNC(type, name, args) extern _ALLEGRO_IIO_DLL type name args +#else + #define ALLEGRO_IIO_FUNC AL_FUNC +#endif + + +#ifdef __cplusplus +extern "C" { +#endif + + +ALLEGRO_IIO_FUNC(bool, al_init_image_addon, (void)); +ALLEGRO_IIO_FUNC(void, al_shutdown_image_addon, (void)); +ALLEGRO_IIO_FUNC(uint32_t, al_get_allegro_image_version, (void)); + + +#ifdef __cplusplus +} +#endif + +#endif + diff --git a/common/allegro/include/allegro5/allegro_memfile.h b/common/allegro/include/allegro5/allegro_memfile.h new file mode 100644 index 00000000..5d8f6c48 --- /dev/null +++ b/common/allegro/include/allegro5/allegro_memfile.h @@ -0,0 +1,40 @@ +#ifndef __al_included_allegro5_memfile_h +#define __al_included_allegro5_memfile_h + +#include "allegro5/allegro.h" + +#ifdef __cplusplus +extern "C" { +#endif + +#if (defined ALLEGRO_MINGW32) || (defined ALLEGRO_MSVC) || (defined ALLEGRO_BCC32) + #ifndef ALLEGRO_STATICLINK + #ifdef ALLEGRO_MEMFILE_SRC + #define _ALLEGRO_MEMFILE_DLL __declspec(dllexport) + #else + #define _ALLEGRO_MEMFILE_DLL __declspec(dllimport) + #endif + #else + #define _ALLEGRO_MEMFILE_DLL + #endif +#endif + +#if defined ALLEGRO_MSVC + #define ALLEGRO_MEMFILE_FUNC(type, name, args) _ALLEGRO_MEMFILE_DLL type __cdecl name args +#elif defined ALLEGRO_MINGW32 + #define ALLEGRO_MEMFILE_FUNC(type, name, args) extern type name args +#elif defined ALLEGRO_BCC32 + #define ALLEGRO_MEMFILE_FUNC(type, name, args) extern _ALLEGRO_MEMFILE_DLL type name args +#else + #define ALLEGRO_MEMFILE_FUNC AL_FUNC +#endif + + +ALLEGRO_MEMFILE_FUNC(ALLEGRO_FILE *, al_open_memfile, (void *mem, int64_t size, const char *mode)); +ALLEGRO_MEMFILE_FUNC(uint32_t, al_get_allegro_memfile_version, (void)); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/common/allegro/include/allegro5/allegro_native_dialog.h b/common/allegro/include/allegro5/allegro_native_dialog.h new file mode 100644 index 00000000..e6eaecf7 --- /dev/null +++ b/common/allegro/include/allegro5/allegro_native_dialog.h @@ -0,0 +1,163 @@ +#ifndef __al_included_allegro5_allegro_native_dialog_h +#define __al_included_allegro5_allegro_native_dialog_h + +#include "allegro5/allegro.h" + +#ifdef __cplusplus + extern "C" { +#endif + +#if (defined ALLEGRO_MINGW32) || (defined ALLEGRO_MSVC) || (defined ALLEGRO_BCC32) + #ifndef ALLEGRO_STATICLINK + #ifdef ALLEGRO_NATIVE_DIALOG_SRC + #define _ALLEGRO_DIALOG_DLL __declspec(dllexport) + #else + #define _ALLEGRO_DIALOG_DLL __declspec(dllimport) + #endif + #else + #define _ALLEGRO_DIALOG_DLL + #endif +#endif + +#if defined ALLEGRO_MSVC + #define ALLEGRO_DIALOG_FUNC(type, name, args) _ALLEGRO_DIALOG_DLL type __cdecl name args +#elif defined ALLEGRO_MINGW32 + #define ALLEGRO_DIALOG_FUNC(type, name, args) extern type name args +#elif defined ALLEGRO_BCC32 + #define ALLEGRO_DIALOG_FUNC(type, name, args) extern _ALLEGRO_DIALOG_DLL type name args +#else + #define ALLEGRO_DIALOG_FUNC AL_FUNC +#endif + +#ifdef ALLEGRO_WITH_XWINDOWS + #define ALLEGRO_GTK_TOPLEVEL ALLEGRO_GTK_TOPLEVEL_INTERNAL +#endif + +/* Type: ALLEGRO_FILECHOOSER + */ +typedef struct ALLEGRO_FILECHOOSER ALLEGRO_FILECHOOSER; + +/* Type: ALLEGRO_TEXTLOG + */ +typedef struct ALLEGRO_TEXTLOG ALLEGRO_TEXTLOG; + +/* Type: ALLEGRO_MENU + */ +typedef struct ALLEGRO_MENU ALLEGRO_MENU; + +/* Type: ALLEGRO_MENU_INFO + */ +typedef struct ALLEGRO_MENU_INFO { + const char *caption; + uint16_t id; + int flags; + ALLEGRO_BITMAP *icon; +} ALLEGRO_MENU_INFO; + +#define ALLEGRO_MENU_SEPARATOR { NULL, -1, 0, NULL } +#define ALLEGRO_START_OF_MENU(caption, id) { caption "->", id, 0, NULL } +#define ALLEGRO_END_OF_MENU { NULL, 0, 0, NULL } + +ALLEGRO_DIALOG_FUNC(bool, al_init_native_dialog_addon, (void)); +ALLEGRO_DIALOG_FUNC(void, al_shutdown_native_dialog_addon, (void)); + +ALLEGRO_DIALOG_FUNC(ALLEGRO_FILECHOOSER *, al_create_native_file_dialog, (char const *initial_path, + char const *title, char const *patterns, int mode)); +ALLEGRO_DIALOG_FUNC(bool, al_show_native_file_dialog, (ALLEGRO_DISPLAY *display, ALLEGRO_FILECHOOSER *dialog)); +ALLEGRO_DIALOG_FUNC(int, al_get_native_file_dialog_count, (const ALLEGRO_FILECHOOSER *dialog)); +ALLEGRO_DIALOG_FUNC(const char *, al_get_native_file_dialog_path, (const ALLEGRO_FILECHOOSER *dialog, + size_t index)); +ALLEGRO_DIALOG_FUNC(void, al_destroy_native_file_dialog, (ALLEGRO_FILECHOOSER *dialog)); + +ALLEGRO_DIALOG_FUNC(int, al_show_native_message_box, (ALLEGRO_DISPLAY *display, char const *title, + char const *heading, char const *text, char const *buttons, int flags)); + +ALLEGRO_DIALOG_FUNC(ALLEGRO_TEXTLOG *, al_open_native_text_log, (char const *title, int flags)); +ALLEGRO_DIALOG_FUNC(void, al_close_native_text_log, (ALLEGRO_TEXTLOG *textlog)); +ALLEGRO_DIALOG_FUNC(void, al_append_native_text_log, (ALLEGRO_TEXTLOG *textlog, char const *format, ...)); +ALLEGRO_DIALOG_FUNC(ALLEGRO_EVENT_SOURCE *, al_get_native_text_log_event_source, (ALLEGRO_TEXTLOG *textlog)); + +/* creating/modifying menus */ +ALLEGRO_DIALOG_FUNC(ALLEGRO_MENU *, al_create_menu, (void)); +ALLEGRO_DIALOG_FUNC(ALLEGRO_MENU *, al_create_popup_menu, (void)); +ALLEGRO_DIALOG_FUNC(ALLEGRO_MENU *, al_build_menu, (ALLEGRO_MENU_INFO *info)); +ALLEGRO_DIALOG_FUNC(int, al_append_menu_item, (ALLEGRO_MENU *parent, char const *title, uint16_t id, int flags, + ALLEGRO_BITMAP *icon, ALLEGRO_MENU *submenu)); +ALLEGRO_DIALOG_FUNC(int, al_insert_menu_item, (ALLEGRO_MENU *parent, int pos, char const *title, uint16_t id, + int flags, ALLEGRO_BITMAP *icon, ALLEGRO_MENU *submenu)); +ALLEGRO_DIALOG_FUNC(bool, al_remove_menu_item, (ALLEGRO_MENU *menu, int pos)); +ALLEGRO_DIALOG_FUNC(ALLEGRO_MENU *, al_clone_menu, (ALLEGRO_MENU *menu)); +ALLEGRO_DIALOG_FUNC(ALLEGRO_MENU *, al_clone_menu_for_popup, (ALLEGRO_MENU *menu)); +ALLEGRO_DIALOG_FUNC(void, al_destroy_menu, (ALLEGRO_MENU *menu)); + +/* properties */ +ALLEGRO_DIALOG_FUNC(const char *, al_get_menu_item_caption, (ALLEGRO_MENU *menu, int pos)); +ALLEGRO_DIALOG_FUNC(void, al_set_menu_item_caption, (ALLEGRO_MENU *menu, int pos, const char *caption)); +ALLEGRO_DIALOG_FUNC(int, al_get_menu_item_flags, (ALLEGRO_MENU *menu, int pos)); +ALLEGRO_DIALOG_FUNC(void, al_set_menu_item_flags, (ALLEGRO_MENU *menu, int pos, int flags)); +ALLEGRO_DIALOG_FUNC(ALLEGRO_BITMAP *, al_get_menu_item_icon, (ALLEGRO_MENU *menu, int pos)); +ALLEGRO_DIALOG_FUNC(void, al_set_menu_item_icon, (ALLEGRO_MENU *menu, int pos, ALLEGRO_BITMAP *icon)); + +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_NATIVE_DIALOG_SRC) +ALLEGRO_DIALOG_FUNC(int, al_toggle_menu_item_flags, (ALLEGRO_MENU *menu, int pos, int flags)); +#endif + +/* querying menus */ +ALLEGRO_DIALOG_FUNC(ALLEGRO_MENU *, al_find_menu, (ALLEGRO_MENU *haystack, uint16_t id)); +ALLEGRO_DIALOG_FUNC(bool, al_find_menu_item, (ALLEGRO_MENU *haystack, uint16_t id, ALLEGRO_MENU **menu, int *index)); + +/* menu events */ +ALLEGRO_DIALOG_FUNC(ALLEGRO_EVENT_SOURCE *, al_get_default_menu_event_source, (void)); +ALLEGRO_DIALOG_FUNC(ALLEGRO_EVENT_SOURCE *, al_enable_menu_event_source, (ALLEGRO_MENU *menu)); +ALLEGRO_DIALOG_FUNC(void, al_disable_menu_event_source, (ALLEGRO_MENU *menu)); + +/* displaying menus */ +ALLEGRO_DIALOG_FUNC(ALLEGRO_MENU *, al_get_display_menu, (ALLEGRO_DISPLAY *display)); +ALLEGRO_DIALOG_FUNC(bool, al_set_display_menu, (ALLEGRO_DISPLAY *display, ALLEGRO_MENU *menu)); +ALLEGRO_DIALOG_FUNC(bool, al_popup_menu, (ALLEGRO_MENU *popup, ALLEGRO_DISPLAY *display)); +ALLEGRO_DIALOG_FUNC(ALLEGRO_MENU *, al_remove_display_menu, (ALLEGRO_DISPLAY *display)); + +ALLEGRO_DIALOG_FUNC(uint32_t, al_get_allegro_native_dialog_version, (void)); + +enum { + ALLEGRO_FILECHOOSER_FILE_MUST_EXIST = 1, + ALLEGRO_FILECHOOSER_SAVE = 2, + ALLEGRO_FILECHOOSER_FOLDER = 4, + ALLEGRO_FILECHOOSER_PICTURES = 8, + ALLEGRO_FILECHOOSER_SHOW_HIDDEN = 16, + ALLEGRO_FILECHOOSER_MULTIPLE = 32 +}; + +enum { + ALLEGRO_MESSAGEBOX_WARN = 1<<0, + ALLEGRO_MESSAGEBOX_ERROR = 1<<1, + ALLEGRO_MESSAGEBOX_OK_CANCEL = 1<<2, + ALLEGRO_MESSAGEBOX_YES_NO = 1<<3, + ALLEGRO_MESSAGEBOX_QUESTION = 1<<4 +}; + +enum { + ALLEGRO_TEXTLOG_NO_CLOSE = 1<<0, + ALLEGRO_TEXTLOG_MONOSPACE = 1<<1 +}; + +enum { + ALLEGRO_EVENT_NATIVE_DIALOG_CLOSE = 600, + ALLEGRO_EVENT_MENU_CLICK = 601 +}; + +enum { + ALLEGRO_MENU_ITEM_ENABLED = 0, + ALLEGRO_MENU_ITEM_CHECKBOX = 1, + ALLEGRO_MENU_ITEM_CHECKED = 2, + ALLEGRO_MENU_ITEM_DISABLED = 4 +}; + + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/allegro_opengl.h b/common/allegro/include/allegro5/allegro_opengl.h new file mode 100644 index 00000000..0f86a676 --- /dev/null +++ b/common/allegro/include/allegro5/allegro_opengl.h @@ -0,0 +1,186 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Main header file for all OpenGL drivers. + * + * By Milan Mimica. + * + */ + + +#ifndef __al_included_allegro5_allegro_opengl_h +#define __al_included_allegro5_allegro_opengl_h + +#ifdef __cplusplus + extern "C" { +#endif + +#if defined(ALLEGRO_WINDOWS) +#include +#endif + +#if defined ALLEGRO_IPHONE + +#include +#include +#include +#include +#include +#include + +/* Apple defines OES versions for these - however the separated alpha ones + * don't seem to work on the device and just crash. + */ +#define glBlendEquation glBlendEquationOES +#define glBlendFuncSeparate glBlendFuncSeparateOES +#define glBlendEquationSeparate glBlendEquationSeparateOES +#define glRenderbufferStorageMultisampleEXT glRenderbufferStorageMultisampleAPPLE +#ifdef GL_FUNC_ADD +#undef GL_FUNC_ADD +#undef GL_FUNC_SUBTRACT +#undef GL_FUNC_REVERSE_SUBTRACT +#endif +#define GL_FUNC_ADD GL_FUNC_ADD_OES +#define GL_FUNC_SUBTRACT GL_FUNC_SUBTRACT_OES +#define GL_FUNC_REVERSE_SUBTRACT GL_FUNC_REVERSE_SUBTRACT_OES + +#elif defined ALLEGRO_MACOSX + +#include +#include +#include + +#ifndef GL_GLEXT_PROTOTYPES +#define GL_GLEXT_PROTOTYPES +#endif + +#elif defined ALLEGRO_ANDROID || defined ALLEGRO_RASPBERRYPI + +#include +#include + +#ifdef ALLEGRO_CFG_OPENGLES2 +#include +#include +#else +#define GL_FUNC_ADD GL_FUNC_ADD_OES +#define GL_FUNC_SUBTRACT GL_FUNC_SUBTRACT_OES +#define GL_FUNC_REVERSE_SUBTRACT GL_FUNC_REVERSE_SUBTRACT_OES +#endif + +#define GL_RGBA8 GL_RGBA8_OES + +#ifndef ALLEGRO_RASPBERRYPI +#define GL_FRAMEBUFFER_BINDING_EXT GL_FRAMEBUFFER_BINDING_OES +#define GL_FRAMEBUFFER_EXT GL_FRAMEBUFFER_OES +#define GL_RENDERBUFFER_EXT GL_RENDERBUFFER_OES +#define glBlendEquation glBlendEquationOES +#define glBlendFuncSeparate glBlendFuncSeparateOES +#define glBlendEquationSeparate glBlendEquationSeparateOES +#define glGenerateMipmapEXT glGenerateMipmapOES +#define glBindFramebufferEXT glBindFramebufferOES +#define glDeleteFramebuffersEXT glDeleteFramebuffersOES +#define GL_DEPTH_COMPONENT24 GL_DEPTH_COMPONENT24_OES +#else +#define GL_FRAMEBUFFER_BINDING_EXT GL_FRAMEBUFFER_BINDING +#define GL_FRAMEBUFFER_EXT GL_FRAMEBUFFER +#define glBlendEquation glBlendEquation +#define glBlendFuncSeparate glBlendFuncSeparate +#define glBlendEquationSeparate glBlendEquationSeparate +#define glGenerateMipmapEXT glGenerateMipmap +#define glBindFramebufferEXT glBindFramebuffer +#define glDeleteFramebuffersEXT glDeleteFramebuffers +#endif + +#else /* ALLEGRO_MACOSX */ + +/* HACK: Prevent both Mesa and SGI's broken headers from screwing us */ +#define __glext_h_ +#define __glxext_h_ +#include +#undef __glext_h_ +#undef __glxext_h_ + +#endif /* ALLEGRO_MACOSX */ + +#ifdef ALLEGRO_RASPBERRYPI +#include +#include +#endif + +#include "allegro5/bitmap.h" +#include "allegro5/display.h" +#include "allegro5/shader.h" +#include "allegro5/opengl/gl_ext.h" + +#ifdef ALLEGRO_WINDOWS + +/* Missing #defines from Mingw */ +#ifndef PFD_SWAP_LAYER_BUFFERS +#define PFD_SWAP_LAYER_BUFFERS 0x00000800 +#endif + +#ifndef PFD_GENERIC_ACCELERATED +#define PFD_GENERIC_ACCELERATED 0x00001000 +#endif + +#ifndef PFD_SUPPORT_DIRECTDRAW +#define PFD_SUPPORT_DIRECTDRAW 0x00002000 +#endif + +#ifndef CDS_FULLSCREEN +#define CDS_FULLSCREEN 0x00000004 +#endif + +#ifndef ENUM_CURRENT_SETTINGS +#define ENUM_CURRENT_SETTINGS ((DWORD)-1) +#endif + +#endif /* ALLEGRO_WINDOWS */ + +#if defined ALLEGRO_WINDOWS + #define ALLEGRO_DEFINE_PROC_TYPE(type, name, args) \ + typedef type (APIENTRY * name) args; +#else + #define ALLEGRO_DEFINE_PROC_TYPE(type, name, args) \ + typedef type (*name) args; +#endif + +/* + * Public OpenGL-related API + */ + +/* ALLEGRO_OPENGL_VARIANT + */ +typedef enum ALLEGRO_OPENGL_VARIANT { + ALLEGRO_DESKTOP_OPENGL = 0, + ALLEGRO_OPENGL_ES +} ALLEGRO_OPENGL_VARIANT; + +AL_FUNC(uint32_t, al_get_opengl_version, (void)); +AL_FUNC(bool, al_have_opengl_extension, (const char *extension)); +AL_FUNC(void*, al_get_opengl_proc_address, (const char *name)); +AL_FUNC(ALLEGRO_OGL_EXT_LIST*, al_get_opengl_extension_list, (void)); +AL_FUNC(GLuint, al_get_opengl_texture, (ALLEGRO_BITMAP *bitmap)); +AL_FUNC(void, al_remove_opengl_fbo, (ALLEGRO_BITMAP *bitmap)); +AL_FUNC(GLuint, al_get_opengl_fbo, (ALLEGRO_BITMAP *bitmap)); +AL_FUNC(bool, al_get_opengl_texture_size, (ALLEGRO_BITMAP *bitmap, + int *w, int *h)); +AL_FUNC(void, al_get_opengl_texture_position, (ALLEGRO_BITMAP *bitmap, + int *u, int *v)); +AL_FUNC(GLuint, al_get_opengl_program_object, (ALLEGRO_SHADER *shader)); +AL_FUNC(void, al_set_current_opengl_context, (ALLEGRO_DISPLAY *display)); +AL_FUNC(int, al_get_opengl_variant, (void)); + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/allegro_physfs.h b/common/allegro/include/allegro5/allegro_physfs.h new file mode 100644 index 00000000..494da6a4 --- /dev/null +++ b/common/allegro/include/allegro5/allegro_physfs.h @@ -0,0 +1,41 @@ +#ifndef __al_included_allegro5_allegro_physfs_h +#define __al_included_allegro5_allegro_physfs_h + +#include "allegro5/allegro.h" + +#ifdef __cplusplus +extern "C" { +#endif + +#if (defined ALLEGRO_MINGW32) || (defined ALLEGRO_MSVC) || (defined ALLEGRO_BCC32) + #ifndef ALLEGRO_STATICLINK + #ifdef ALLEGRO_PHYSFS_SRC + #define _ALLEGRO_PHYSFS_DLL __declspec(dllexport) + #else + #define _ALLEGRO_PHYSFS_DLL __declspec(dllimport) + #endif + #else + #define _ALLEGRO_PHYSFS_DLL + #endif +#endif + +#if defined ALLEGRO_MSVC + #define ALLEGRO_PHYSFS_FUNC(type, name, args) _ALLEGRO_PHYSFS_DLL type __cdecl name args +#elif defined ALLEGRO_MINGW32 + #define ALLEGRO_PHYSFS_FUNC(type, name, args) extern type name args +#elif defined ALLEGRO_BCC32 + #define ALLEGRO_PHYSFS_FUNC(type, name, args) extern _ALLEGRO_PHYSFS_DLL type name args +#else + #define ALLEGRO_PHYSFS_FUNC AL_FUNC +#endif + + +ALLEGRO_PHYSFS_FUNC(void, al_set_physfs_file_interface, (void)); +ALLEGRO_PHYSFS_FUNC(uint32_t, al_get_allegro_physfs_version, (void)); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/common/allegro/include/allegro5/allegro_primitives.h b/common/allegro/include/allegro5/allegro_primitives.h new file mode 100644 index 00000000..fe31440c --- /dev/null +++ b/common/allegro/include/allegro5/allegro_primitives.h @@ -0,0 +1,253 @@ +#ifndef __al_included_allegro5_allegro_primitives_h +#define __al_included_allegro5_allegro_primitives_h + +#include + +#if (defined ALLEGRO_MINGW32) || (defined ALLEGRO_MSVC) || (defined ALLEGRO_BCC32) +#ifndef ALLEGRO_STATICLINK +#ifdef ALLEGRO_PRIMITIVES_SRC +#define _ALLEGRO_PRIM_DLL __declspec(dllexport) +#else +#define _ALLEGRO_PRIM_DLL __declspec(dllimport) +#endif +#else +#define _ALLEGRO_PRIM_DLL +#endif +#endif + +#if defined ALLEGRO_MSVC +#define ALLEGRO_PRIM_FUNC(type, name, args) _ALLEGRO_PRIM_DLL type __cdecl name args +#elif defined ALLEGRO_MINGW32 +#define ALLEGRO_PRIM_FUNC(type, name, args) extern type name args +#elif defined ALLEGRO_BCC32 +#define ALLEGRO_PRIM_FUNC(type, name, args) extern _ALLEGRO_PRIM_DLL type name args +#else +#define ALLEGRO_PRIM_FUNC AL_FUNC +#endif + +#ifdef __cplusplus +extern "C" +{ +#endif + + +/* Enum: ALLEGRO_PRIM_TYPE + */ +typedef enum ALLEGRO_PRIM_TYPE +{ + ALLEGRO_PRIM_LINE_LIST, + ALLEGRO_PRIM_LINE_STRIP, + ALLEGRO_PRIM_LINE_LOOP, + ALLEGRO_PRIM_TRIANGLE_LIST, + ALLEGRO_PRIM_TRIANGLE_STRIP, + ALLEGRO_PRIM_TRIANGLE_FAN, + ALLEGRO_PRIM_POINT_LIST, + ALLEGRO_PRIM_NUM_TYPES +} ALLEGRO_PRIM_TYPE; + +enum +{ + ALLEGRO_PRIM_MAX_USER_ATTR = _ALLEGRO_PRIM_MAX_USER_ATTR +}; + +/* Enum: ALLEGRO_PRIM_ATTR + */ +typedef enum ALLEGRO_PRIM_ATTR +{ + ALLEGRO_PRIM_POSITION = 1, + ALLEGRO_PRIM_COLOR_ATTR, + ALLEGRO_PRIM_TEX_COORD, + ALLEGRO_PRIM_TEX_COORD_PIXEL, + ALLEGRO_PRIM_USER_ATTR, + ALLEGRO_PRIM_ATTR_NUM = ALLEGRO_PRIM_USER_ATTR + ALLEGRO_PRIM_MAX_USER_ATTR +} ALLEGRO_PRIM_ATTR; + +/* Enum: ALLEGRO_PRIM_STORAGE + */ +typedef enum ALLEGRO_PRIM_STORAGE +{ + ALLEGRO_PRIM_FLOAT_2, + ALLEGRO_PRIM_FLOAT_3, + ALLEGRO_PRIM_SHORT_2, + ALLEGRO_PRIM_FLOAT_1, + ALLEGRO_PRIM_FLOAT_4, + ALLEGRO_PRIM_UBYTE_4, + ALLEGRO_PRIM_SHORT_4, + ALLEGRO_PRIM_NORMALIZED_UBYTE_4, + ALLEGRO_PRIM_NORMALIZED_SHORT_2, + ALLEGRO_PRIM_NORMALIZED_SHORT_4, + ALLEGRO_PRIM_NORMALIZED_USHORT_2, + ALLEGRO_PRIM_NORMALIZED_USHORT_4, + ALLEGRO_PRIM_HALF_FLOAT_2, + ALLEGRO_PRIM_HALF_FLOAT_4 +} ALLEGRO_PRIM_STORAGE; + +/* Enum: ALLEGRO_LINE_JOIN + */ +typedef enum ALLEGRO_LINE_JOIN +{ + ALLEGRO_LINE_JOIN_NONE, + ALLEGRO_LINE_JOIN_BEVEL, + ALLEGRO_LINE_JOIN_ROUND, + ALLEGRO_LINE_JOIN_MITER, + ALLEGRO_LINE_JOIN_MITRE = ALLEGRO_LINE_JOIN_MITER +} ALLEGRO_LINE_JOIN; + +/* Enum: ALLEGRO_LINE_CAP + */ +typedef enum ALLEGRO_LINE_CAP +{ + ALLEGRO_LINE_CAP_NONE, + ALLEGRO_LINE_CAP_SQUARE, + ALLEGRO_LINE_CAP_ROUND, + ALLEGRO_LINE_CAP_TRIANGLE, + ALLEGRO_LINE_CAP_CLOSED +} ALLEGRO_LINE_CAP; + +/* Enum: ALLEGRO_PRIM_BUFFER_FLAGS + */ +typedef enum ALLEGRO_PRIM_BUFFER_FLAGS +{ + ALLEGRO_PRIM_BUFFER_STREAM = 0x01, + ALLEGRO_PRIM_BUFFER_STATIC = 0x02, + ALLEGRO_PRIM_BUFFER_DYNAMIC = 0x04, + ALLEGRO_PRIM_BUFFER_READWRITE = 0x08 +} ALLEGRO_PRIM_BUFFER_FLAGS; + +/* Enum: ALLEGRO_VERTEX_CACHE_SIZE + */ +#define ALLEGRO_VERTEX_CACHE_SIZE 256 + +/* Enum: ALLEGRO_PRIM_QUALITY + */ +#define ALLEGRO_PRIM_QUALITY 10 + +/* Type: ALLEGRO_VERTEX_ELEMENT + */ +typedef struct ALLEGRO_VERTEX_ELEMENT ALLEGRO_VERTEX_ELEMENT; + +struct ALLEGRO_VERTEX_ELEMENT { + int attribute; + int storage; + int offset; +}; + +/* Type: ALLEGRO_VERTEX_DECL + */ +typedef struct ALLEGRO_VERTEX_DECL ALLEGRO_VERTEX_DECL; + +/* Duplicated in allegro5/internal/aintern_tri_soft.h */ +#ifndef _ALLEGRO_VERTEX_DEFINED +#define _ALLEGRO_VERTEX_DEFINED + +/* Type: ALLEGRO_VERTEX + */ +typedef struct ALLEGRO_VERTEX ALLEGRO_VERTEX; + +struct ALLEGRO_VERTEX { + float x, y, z; + float u, v; + ALLEGRO_COLOR color; +}; +#endif + +/* Type: ALLEGRO_VERTEX_BUFFER + */ +typedef struct ALLEGRO_VERTEX_BUFFER ALLEGRO_VERTEX_BUFFER; + +/* Type: ALLEGRO_INDEX_BUFFER + */ +typedef struct ALLEGRO_INDEX_BUFFER ALLEGRO_INDEX_BUFFER; + +ALLEGRO_PRIM_FUNC(uint32_t, al_get_allegro_primitives_version, (void)); + +/* +* Primary Functions +*/ +ALLEGRO_PRIM_FUNC(bool, al_init_primitives_addon, (void)); +ALLEGRO_PRIM_FUNC(void, al_shutdown_primitives_addon, (void)); +ALLEGRO_PRIM_FUNC(int, al_draw_prim, (const void* vtxs, const ALLEGRO_VERTEX_DECL* decl, ALLEGRO_BITMAP* texture, int start, int end, int type)); +ALLEGRO_PRIM_FUNC(int, al_draw_indexed_prim, (const void* vtxs, const ALLEGRO_VERTEX_DECL* decl, ALLEGRO_BITMAP* texture, const int* indices, int num_vtx, int type)); +ALLEGRO_PRIM_FUNC(int, al_draw_vertex_buffer, (ALLEGRO_VERTEX_BUFFER* vertex_buffer, ALLEGRO_BITMAP* texture, int start, int end, int type)); +ALLEGRO_PRIM_FUNC(int, al_draw_indexed_buffer, (ALLEGRO_VERTEX_BUFFER* vertex_buffer, ALLEGRO_BITMAP* texture, ALLEGRO_INDEX_BUFFER* index_buffer, int start, int end, int type)); + +ALLEGRO_PRIM_FUNC(ALLEGRO_VERTEX_DECL*, al_create_vertex_decl, (const ALLEGRO_VERTEX_ELEMENT* elements, int stride)); +ALLEGRO_PRIM_FUNC(void, al_destroy_vertex_decl, (ALLEGRO_VERTEX_DECL* decl)); + +/* + * Vertex buffers + */ +ALLEGRO_PRIM_FUNC(ALLEGRO_VERTEX_BUFFER*, al_create_vertex_buffer, (ALLEGRO_VERTEX_DECL* decl, const void* initial_data, int num_vertices, int flags)); +ALLEGRO_PRIM_FUNC(void, al_destroy_vertex_buffer, (ALLEGRO_VERTEX_BUFFER* buffer)); +ALLEGRO_PRIM_FUNC(void*, al_lock_vertex_buffer, (ALLEGRO_VERTEX_BUFFER* buffer, int offset, int length, int flags)); +ALLEGRO_PRIM_FUNC(void, al_unlock_vertex_buffer, (ALLEGRO_VERTEX_BUFFER* buffer)); +ALLEGRO_PRIM_FUNC(int, al_get_vertex_buffer_size, (ALLEGRO_VERTEX_BUFFER* buffer)); + +/* + * Index buffers + */ +ALLEGRO_PRIM_FUNC(ALLEGRO_INDEX_BUFFER*, al_create_index_buffer, (int index_size, const void* initial_data, int num_indices, int flags)); +ALLEGRO_PRIM_FUNC(void, al_destroy_index_buffer, (ALLEGRO_INDEX_BUFFER* buffer)); +ALLEGRO_PRIM_FUNC(void*, al_lock_index_buffer, (ALLEGRO_INDEX_BUFFER* buffer, int offset, int length, int flags)); +ALLEGRO_PRIM_FUNC(void, al_unlock_index_buffer, (ALLEGRO_INDEX_BUFFER* buffer)); +ALLEGRO_PRIM_FUNC(int, al_get_index_buffer_size, (ALLEGRO_INDEX_BUFFER* buffer)); + +/* +* Utilities for high level primitives. +*/ +ALLEGRO_PRIM_FUNC(bool, al_triangulate_polygon, (const float* vertices, size_t vertex_stride, const int* vertex_counts, void (*emit_triangle)(int, int, int, void*), void* userdata)); + + +/* +* Custom primitives +*/ +ALLEGRO_PRIM_FUNC(void, al_draw_soft_triangle, (ALLEGRO_VERTEX* v1, ALLEGRO_VERTEX* v2, ALLEGRO_VERTEX* v3, uintptr_t state, + void (*init)(uintptr_t, ALLEGRO_VERTEX*, ALLEGRO_VERTEX*, ALLEGRO_VERTEX*), + void (*first)(uintptr_t, int, int, int, int), + void (*step)(uintptr_t, int), + void (*draw)(uintptr_t, int, int, int))); +ALLEGRO_PRIM_FUNC(void, al_draw_soft_line, (ALLEGRO_VERTEX* v1, ALLEGRO_VERTEX* v2, uintptr_t state, + void (*first)(uintptr_t, int, int, ALLEGRO_VERTEX*, ALLEGRO_VERTEX*), + void (*step)(uintptr_t, int), + void (*draw)(uintptr_t, int, int))); + +/* +*High level primitives +*/ +ALLEGRO_PRIM_FUNC(void, al_draw_line, (float x1, float y1, float x2, float y2, ALLEGRO_COLOR color, float thickness)); +ALLEGRO_PRIM_FUNC(void, al_draw_triangle, (float x1, float y1, float x2, float y2, float x3, float y3, ALLEGRO_COLOR color, float thickness)); +ALLEGRO_PRIM_FUNC(void, al_draw_rectangle, (float x1, float y1, float x2, float y2, ALLEGRO_COLOR color, float thickness)); +ALLEGRO_PRIM_FUNC(void, al_draw_rounded_rectangle, (float x1, float y1, float x2, float y2, float rx, float ry, ALLEGRO_COLOR color, float thickness)); + +ALLEGRO_PRIM_FUNC(void, al_calculate_arc, (float* dest, int stride, float cx, float cy, float rx, float ry, float start_theta, float delta_theta, float thickness, int num_points)); +ALLEGRO_PRIM_FUNC(void, al_draw_circle, (float cx, float cy, float r, ALLEGRO_COLOR color, float thickness)); +ALLEGRO_PRIM_FUNC(void, al_draw_ellipse, (float cx, float cy, float rx, float ry, ALLEGRO_COLOR color, float thickness)); +ALLEGRO_PRIM_FUNC(void, al_draw_arc, (float cx, float cy, float r, float start_theta, float delta_theta, ALLEGRO_COLOR color, float thickness)); +ALLEGRO_PRIM_FUNC(void, al_draw_elliptical_arc, (float cx, float cy, float rx, float ry, float start_theta, float delta_theta, ALLEGRO_COLOR color, float thickness)); +ALLEGRO_PRIM_FUNC(void, al_draw_pieslice, (float cx, float cy, float r, float start_theta, float delta_theta, ALLEGRO_COLOR color, float thickness)); + +ALLEGRO_PRIM_FUNC(void, al_calculate_spline, (float* dest, int stride, float points[8], float thickness, int num_segments)); +ALLEGRO_PRIM_FUNC(void, al_draw_spline, (float points[8], ALLEGRO_COLOR color, float thickness)); + +ALLEGRO_PRIM_FUNC(void, al_calculate_ribbon, (float* dest, int dest_stride, const float *points, int points_stride, float thickness, int num_segments)); +ALLEGRO_PRIM_FUNC(void, al_draw_ribbon, (const float *points, int points_stride, ALLEGRO_COLOR color, float thickness, int num_segments)); + +ALLEGRO_PRIM_FUNC(void, al_draw_filled_triangle, (float x1, float y1, float x2, float y2, float x3, float y3, ALLEGRO_COLOR color)); +ALLEGRO_PRIM_FUNC(void, al_draw_filled_rectangle, (float x1, float y1, float x2, float y2, ALLEGRO_COLOR color)); +ALLEGRO_PRIM_FUNC(void, al_draw_filled_ellipse, (float cx, float cy, float rx, float ry, ALLEGRO_COLOR color)); +ALLEGRO_PRIM_FUNC(void, al_draw_filled_circle, (float cx, float cy, float r, ALLEGRO_COLOR color)); +ALLEGRO_PRIM_FUNC(void, al_draw_filled_pieslice, (float cx, float cy, float r, float start_theta, float delta_theta, ALLEGRO_COLOR color)); +ALLEGRO_PRIM_FUNC(void, al_draw_filled_rounded_rectangle, (float x1, float y1, float x2, float y2, float rx, float ry, ALLEGRO_COLOR color)); + +ALLEGRO_PRIM_FUNC(void, al_draw_polyline, (const float* vertices, int vertex_stride, int vertex_count, int join_style, int cap_style, ALLEGRO_COLOR color, float thickness, float miter_limit)); + +ALLEGRO_PRIM_FUNC(void, al_draw_polygon, (const float* vertices, int vertex_count, int join_style, ALLEGRO_COLOR color, float thickness, float miter_limit)); +ALLEGRO_PRIM_FUNC(void, al_draw_filled_polygon, (const float* vertices, int vertex_count, ALLEGRO_COLOR color)); +ALLEGRO_PRIM_FUNC(void, al_draw_filled_polygon_with_holes, (const float* vertices, const int* vertex_counts, ALLEGRO_COLOR color)); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/common/allegro/include/allegro5/allegro_ttf.h b/common/allegro/include/allegro5/allegro_ttf.h new file mode 100644 index 00000000..92af6f1f --- /dev/null +++ b/common/allegro/include/allegro5/allegro_ttf.h @@ -0,0 +1,49 @@ +#ifndef __al_included_allegro5_allegro_ttf_h +#define __al_included_allegro5_allegro_ttf_h + +#include "allegro5/allegro.h" +#include "allegro5/allegro_font.h" + +#ifdef __cplusplus + extern "C" { +#endif + +#define ALLEGRO_TTF_NO_KERNING 1 +#define ALLEGRO_TTF_MONOCHROME 2 +#define ALLEGRO_TTF_NO_AUTOHINT 4 + +#if (defined ALLEGRO_MINGW32) || (defined ALLEGRO_MSVC) || (defined ALLEGRO_BCC32) + #ifndef ALLEGRO_STATICLINK + #ifdef ALLEGRO_TTF_SRC + #define _ALLEGRO_TTF_DLL __declspec(dllexport) + #else + #define _ALLEGRO_TTF_DLL __declspec(dllimport) + #endif + #else + #define _ALLEGRO_TTF_DLL + #endif +#endif + +#if defined ALLEGRO_MSVC + #define ALLEGRO_TTF_FUNC(type, name, args) _ALLEGRO_TTF_DLL type __cdecl name args +#elif defined ALLEGRO_MINGW32 + #define ALLEGRO_TTF_FUNC(type, name, args) extern type name args +#elif defined ALLEGRO_BCC32 + #define ALLEGRO_TTF_FUNC(type, name, args) extern _ALLEGRO_TTF_DLL type name args +#else + #define ALLEGRO_TTF_FUNC AL_FUNC +#endif + +ALLEGRO_TTF_FUNC(ALLEGRO_FONT *, al_load_ttf_font, (char const *filename, int size, int flags)); +ALLEGRO_TTF_FUNC(ALLEGRO_FONT *, al_load_ttf_font_f, (ALLEGRO_FILE *file, char const *filename, int size, int flags)); +ALLEGRO_TTF_FUNC(ALLEGRO_FONT *, al_load_ttf_font_stretch, (char const *filename, int w, int h, int flags)); +ALLEGRO_TTF_FUNC(ALLEGRO_FONT *, al_load_ttf_font_stretch_f, (ALLEGRO_FILE *file, char const *filename, int w, int h, int flags)); +ALLEGRO_TTF_FUNC(bool, al_init_ttf_addon, (void)); +ALLEGRO_TTF_FUNC(void, al_shutdown_ttf_addon, (void)); +ALLEGRO_TTF_FUNC(uint32_t, al_get_allegro_ttf_version, (void)); + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/allegro_video.h b/common/allegro/include/allegro5/allegro_video.h new file mode 100644 index 00000000..f2cb3473 --- /dev/null +++ b/common/allegro/include/allegro5/allegro_video.h @@ -0,0 +1,77 @@ +#ifndef __al_included_allegro_video_h +#define __al_included_allegro_video_h + +#ifdef __cplusplus + extern "C" { +#endif + +#include "allegro5/allegro5.h" +#include "allegro5/allegro_audio.h" + +#if (defined ALLEGRO_MINGW32) || (defined ALLEGRO_MSVC) || (defined ALLEGRO_BCC32) + #ifndef ALLEGRO_STATICLINK + #ifdef ALLEGRO_VIDEO_SRC + #define _ALLEGRO_VIDEO_DLL __declspec(dllexport) + #else + #define _ALLEGRO_VIDEO_DLL __declspec(dllimport) + #endif + #else + #define _ALLEGRO_VIDEO_DLL + #endif +#endif + +#if defined ALLEGRO_MSVC + #define ALLEGRO_VIDEO_FUNC(type, name, args) _ALLEGRO_VIDEO_DLL type __cdecl name args +#elif defined ALLEGRO_MINGW32 + #define ALLEGRO_VIDEO_FUNC(type, name, args) extern type name args +#elif defined ALLEGRO_BCC32 + #define ALLEGRO_VIDEO_FUNC(type, name, args) extern _ALLEGRO_VIDEO_DLL type name args +#else + #define ALLEGRO_VIDEO_FUNC AL_FUNC +#endif + +/* Enum: ALLEGRO_VIDEO_EVENT_TYPE + */ +enum ALLEGRO_VIDEO_EVENT_TYPE +{ + ALLEGRO_EVENT_VIDEO_FRAME_SHOW = 550, + ALLEGRO_EVENT_VIDEO_FINISHED = 551, + _ALLEGRO_EVENT_VIDEO_SEEK = 552 /* internal */ +}; + +enum ALLEGRO_VIDEO_POSITION_TYPE +{ + ALLEGRO_VIDEO_POSITION_ACTUAL = 0, + ALLEGRO_VIDEO_POSITION_VIDEO_DECODE = 1, + ALLEGRO_VIDEO_POSITION_AUDIO_DECODE = 2 +}; + +/* Enum: ALLEGRO_VIDEO_POSITION_TYPE + */ +typedef enum ALLEGRO_VIDEO_POSITION_TYPE ALLEGRO_VIDEO_POSITION_TYPE; + +typedef struct ALLEGRO_VIDEO ALLEGRO_VIDEO; + +ALLEGRO_VIDEO_FUNC(ALLEGRO_VIDEO *, al_open_video, (char const *filename)); +ALLEGRO_VIDEO_FUNC(void, al_close_video, (ALLEGRO_VIDEO *video)); +ALLEGRO_VIDEO_FUNC(void, al_start_video, (ALLEGRO_VIDEO *video, ALLEGRO_MIXER *mixer)); +ALLEGRO_VIDEO_FUNC(void, al_start_video_with_voice, (ALLEGRO_VIDEO *video, ALLEGRO_VOICE *voice)); +ALLEGRO_VIDEO_FUNC(ALLEGRO_EVENT_SOURCE *, al_get_video_event_source, (ALLEGRO_VIDEO *video)); +ALLEGRO_VIDEO_FUNC(void, al_set_video_playing, (ALLEGRO_VIDEO *video, bool playing)); +ALLEGRO_VIDEO_FUNC(bool, al_is_video_playing, (ALLEGRO_VIDEO *video)); +ALLEGRO_VIDEO_FUNC(double, al_get_video_audio_rate, (ALLEGRO_VIDEO *video)); +ALLEGRO_VIDEO_FUNC(double, al_get_video_fps, (ALLEGRO_VIDEO *video)); +ALLEGRO_VIDEO_FUNC(float, al_get_video_scaled_width, (ALLEGRO_VIDEO *video)); +ALLEGRO_VIDEO_FUNC(float, al_get_video_scaled_height, (ALLEGRO_VIDEO *video)); +ALLEGRO_VIDEO_FUNC(ALLEGRO_BITMAP *, al_get_video_frame, (ALLEGRO_VIDEO *video)); +ALLEGRO_VIDEO_FUNC(double, al_get_video_position, (ALLEGRO_VIDEO *video, ALLEGRO_VIDEO_POSITION_TYPE which)); +ALLEGRO_VIDEO_FUNC(bool, al_seek_video, (ALLEGRO_VIDEO *video, double pos_in_seconds)); +ALLEGRO_VIDEO_FUNC(bool, al_init_video_addon, (void)); +ALLEGRO_VIDEO_FUNC(void, al_shutdown_video_addon, (void)); +ALLEGRO_VIDEO_FUNC(uint32_t, al_get_allegro_video_version, (void)); + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/allegro_windows.h b/common/allegro/include/allegro5/allegro_windows.h new file mode 100644 index 00000000..f87d4754 --- /dev/null +++ b/common/allegro/include/allegro5/allegro_windows.h @@ -0,0 +1,44 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Header file for Windows specific API. + * + * By Trent Gamblin. + * + */ + +#ifndef __al_included_allegro5_allegro_windows_h +#define __al_included_allegro5_allegro_windows_h + +#include + +#ifdef __cplusplus + extern "C" { +#endif + +/* + * Public Windows-related API + */ + +AL_FUNC(HWND, al_get_win_window_handle, (ALLEGRO_DISPLAY *display)); +AL_FUNC(bool, al_win_add_window_callback, (ALLEGRO_DISPLAY *display, + bool (*callback)(ALLEGRO_DISPLAY *display, UINT message, WPARAM wparam, + LPARAM lparam, LRESULT *result, void *userdata), void *userdata)); +AL_FUNC(bool, al_win_remove_window_callback, (ALLEGRO_DISPLAY *display, + bool (*callback)(ALLEGRO_DISPLAY *display, UINT message, WPARAM wparam, + LPARAM lparam, LRESULT *result, void *userdata), void *userdata)); + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set ts=8 sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/altime.h b/common/allegro/include/allegro5/altime.h new file mode 100644 index 00000000..bb0e520d --- /dev/null +++ b/common/allegro/include/allegro5/altime.h @@ -0,0 +1,30 @@ +#ifndef __al_included_allegro5_altime_h +#define __al_included_allegro5_altime_h + +#include "allegro5/base.h" + +#ifdef __cplusplus + extern "C" { +#endif + +/* Type: ALLEGRO_TIMEOUT + */ +typedef struct ALLEGRO_TIMEOUT ALLEGRO_TIMEOUT; +struct ALLEGRO_TIMEOUT { + uint64_t __pad1__; + uint64_t __pad2__; +}; + + + +AL_FUNC(double, al_get_time, (void)); +AL_FUNC(void, al_rest, (double seconds)); +AL_FUNC(void, al_init_timeout, (ALLEGRO_TIMEOUT *timeout, double seconds)); + + + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/base.h b/common/allegro/include/allegro5/base.h new file mode 100644 index 00000000..344cd8a2 --- /dev/null +++ b/common/allegro/include/allegro5/base.h @@ -0,0 +1,103 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Base header, defines basic stuff needed by pretty much + * everything else. + * + * By Shawn Hargreaves. + * + * See readme.txt for copyright information. + */ + +#ifndef __al_included_allegro5_base_h +#define __al_included_allegro5_base_h + +#ifndef ALLEGRO_NO_STD_HEADERS + #include + #ifdef _MSC_VER + /* enable posix for limits.h and only limits.h + enabling it for all msvc headers will potentially + disable a lot of commonly used msvcrt functions */ + #define _POSIX_ + #include + #undef _POSIX_ + #else + #include + #endif + #include + #include + #include + #include + #include + #include +#endif + +#if (defined DEBUGMODE) && (defined FORTIFY) + #include +#endif + +#if (defined DEBUGMODE) && (defined DMALLOC) + #include +#endif + +#include "allegro5/internal/alconfig.h" + +#ifdef __cplusplus + extern "C" { +#endif + +#define ALLEGRO_VERSION 5 +#define ALLEGRO_SUB_VERSION 2 +#define ALLEGRO_WIP_VERSION 3 + +#ifdef ALLEGRO_UNSTABLE + #define ALLEGRO_UNSTABLE_BIT 1 << 31 +#else + #define ALLEGRO_UNSTABLE_BIT 0 +#endif + +/* Not sure we need it, but since ALLEGRO_VERSION_STR contains it: + * 0 = GIT + * 1 = first release + * 2... = hotfixes? + * + * Note x.y.z (= x.y.z.0) has release number 1, and x.y.z.1 has release + * number 2, just to confuse you. + */ +#define ALLEGRO_RELEASE_NUMBER 1 + +#define ALLEGRO_VERSION_STR "5.2.3" +#define ALLEGRO_DATE_STR "2017" +#define ALLEGRO_DATE 20171008 /* yyyymmdd */ +#define ALLEGRO_VERSION_INT \ + ((ALLEGRO_VERSION << 24) | (ALLEGRO_SUB_VERSION << 16) | \ + (ALLEGRO_WIP_VERSION << 8) | ALLEGRO_RELEASE_NUMBER | \ + ALLEGRO_UNSTABLE_BIT) + +AL_FUNC(uint32_t, al_get_allegro_version, (void)); +AL_FUNC(int, al_run_main, (int argc, char **argv, int (*)(int, char **))); + +/*******************************************/ +/************ Some global stuff ************/ +/*******************************************/ + +/* Type: ALLEGRO_PI + */ +#define ALLEGRO_PI 3.14159265358979323846 + +#define AL_ID(a,b,c,d) (((a)<<24) | ((b)<<16) | ((c)<<8) | (d)) + + + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/bitmap.h b/common/allegro/include/allegro5/bitmap.h new file mode 100644 index 00000000..02e44b3a --- /dev/null +++ b/common/allegro/include/allegro5/bitmap.h @@ -0,0 +1,93 @@ +#ifndef __al_included_allegro5_bitmap_h +#define __al_included_allegro5_bitmap_h + +#include "allegro5/color.h" + +#ifdef __cplusplus + extern "C" { +#endif + +/* Type: ALLEGRO_BITMAP + */ +typedef struct ALLEGRO_BITMAP ALLEGRO_BITMAP; + + +/* + * Bitmap flags + */ +enum { + ALLEGRO_MEMORY_BITMAP = 0x0001, + _ALLEGRO_KEEP_BITMAP_FORMAT = 0x0002, /* now a bitmap loader flag */ + ALLEGRO_FORCE_LOCKING = 0x0004, /* no longer honoured */ + ALLEGRO_NO_PRESERVE_TEXTURE = 0x0008, + _ALLEGRO_ALPHA_TEST = 0x0010, /* now a render state flag */ + _ALLEGRO_INTERNAL_OPENGL = 0x0020, + ALLEGRO_MIN_LINEAR = 0x0040, + ALLEGRO_MAG_LINEAR = 0x0080, + ALLEGRO_MIPMAP = 0x0100, + _ALLEGRO_NO_PREMULTIPLIED_ALPHA = 0x0200, /* now a bitmap loader flag */ + ALLEGRO_VIDEO_BITMAP = 0x0400, + ALLEGRO_CONVERT_BITMAP = 0x1000 +}; + + +AL_FUNC(void, al_set_new_bitmap_format, (int format)); +AL_FUNC(void, al_set_new_bitmap_flags, (int flags)); +AL_FUNC(int, al_get_new_bitmap_format, (void)); +AL_FUNC(int, al_get_new_bitmap_flags, (void)); +AL_FUNC(void, al_add_new_bitmap_flag, (int flag)); + +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_SRC) +AL_FUNC(int, al_get_new_bitmap_depth, (void)); +AL_FUNC(void, al_set_new_bitmap_depth, (int depth)); +AL_FUNC(int, al_get_new_bitmap_samples, (void)); +AL_FUNC(void, al_set_new_bitmap_samples, (int samples)); +#endif + +AL_FUNC(int, al_get_bitmap_width, (ALLEGRO_BITMAP *bitmap)); +AL_FUNC(int, al_get_bitmap_height, (ALLEGRO_BITMAP *bitmap)); +AL_FUNC(int, al_get_bitmap_format, (ALLEGRO_BITMAP *bitmap)); +AL_FUNC(int, al_get_bitmap_flags, (ALLEGRO_BITMAP *bitmap)); + +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_SRC) +AL_FUNC(int, al_get_bitmap_depth, (ALLEGRO_BITMAP *bitmap)); +AL_FUNC(int, al_get_bitmap_samples, (ALLEGRO_BITMAP *bitmap)); +#endif + +AL_FUNC(ALLEGRO_BITMAP*, al_create_bitmap, (int w, int h)); +AL_FUNC(void, al_destroy_bitmap, (ALLEGRO_BITMAP *bitmap)); + +AL_FUNC(void, al_put_pixel, (int x, int y, ALLEGRO_COLOR color)); +AL_FUNC(void, al_put_blended_pixel, (int x, int y, ALLEGRO_COLOR color)); +AL_FUNC(ALLEGRO_COLOR, al_get_pixel, (ALLEGRO_BITMAP *bitmap, int x, int y)); + +/* Masking */ +AL_FUNC(void, al_convert_mask_to_alpha, (ALLEGRO_BITMAP *bitmap, ALLEGRO_COLOR mask_color)); + +/* Clipping */ +AL_FUNC(void, al_set_clipping_rectangle, (int x, int y, int width, int height)); +AL_FUNC(void, al_reset_clipping_rectangle, (void)); +AL_FUNC(void, al_get_clipping_rectangle, (int *x, int *y, int *w, int *h)); + +/* Sub bitmaps */ +AL_FUNC(ALLEGRO_BITMAP *, al_create_sub_bitmap, (ALLEGRO_BITMAP *parent, int x, int y, int w, int h)); +AL_FUNC(bool, al_is_sub_bitmap, (ALLEGRO_BITMAP *bitmap)); +AL_FUNC(ALLEGRO_BITMAP *, al_get_parent_bitmap, (ALLEGRO_BITMAP *bitmap)); +AL_FUNC(int, al_get_bitmap_x, (ALLEGRO_BITMAP *bitmap)); +AL_FUNC(int, al_get_bitmap_y, (ALLEGRO_BITMAP *bitmap)); +AL_FUNC(void, al_reparent_bitmap, (ALLEGRO_BITMAP *bitmap, + ALLEGRO_BITMAP *parent, int x, int y, int w, int h)); + +/* Miscellaneous */ +AL_FUNC(ALLEGRO_BITMAP *, al_clone_bitmap, (ALLEGRO_BITMAP *bitmap)); +AL_FUNC(void, al_convert_bitmap, (ALLEGRO_BITMAP *bitmap)); +AL_FUNC(void, al_convert_memory_bitmaps, (void)); +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_SRC) +AL_FUNC(void, al_backup_dirty_bitmap, (ALLEGRO_BITMAP *bitmap)); +#endif + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/bitmap_draw.h b/common/allegro/include/allegro5/bitmap_draw.h new file mode 100644 index 00000000..83e3e144 --- /dev/null +++ b/common/allegro/include/allegro5/bitmap_draw.h @@ -0,0 +1,42 @@ +#ifndef __al_included_allegro5_bitmap_draw_h +#define __al_included_allegro5_bitmap_draw_h + +#include "allegro5/bitmap.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +/* Flags for the blitting functions */ +enum { + ALLEGRO_FLIP_HORIZONTAL = 0x00001, + ALLEGRO_FLIP_VERTICAL = 0x00002 +}; + +/* Blitting */ +AL_FUNC(void, al_draw_bitmap, (ALLEGRO_BITMAP *bitmap, float dx, float dy, int flags)); +AL_FUNC(void, al_draw_bitmap_region, (ALLEGRO_BITMAP *bitmap, float sx, float sy, float sw, float sh, float dx, float dy, int flags)); +AL_FUNC(void, al_draw_scaled_bitmap, (ALLEGRO_BITMAP *bitmap, float sx, float sy, float sw, float sh, float dx, float dy, float dw, float dh, int flags)); +AL_FUNC(void, al_draw_rotated_bitmap, (ALLEGRO_BITMAP *bitmap, float cx, float cy, float dx, float dy, float angle, int flags)); +AL_FUNC(void, al_draw_scaled_rotated_bitmap, (ALLEGRO_BITMAP *bitmap, float cx, float cy, float dx, float dy, float xscale, float yscale, float angle, int flags)); + +/* Tinted blitting */ +AL_FUNC(void, al_draw_tinted_bitmap, (ALLEGRO_BITMAP *bitmap, ALLEGRO_COLOR tint, float dx, float dy, int flags)); +AL_FUNC(void, al_draw_tinted_bitmap_region, (ALLEGRO_BITMAP *bitmap, ALLEGRO_COLOR tint, float sx, float sy, float sw, float sh, float dx, float dy, int flags)); +AL_FUNC(void, al_draw_tinted_scaled_bitmap, (ALLEGRO_BITMAP *bitmap, ALLEGRO_COLOR tint, float sx, float sy, float sw, float sh, float dx, float dy, float dw, float dh, int flags)); +AL_FUNC(void, al_draw_tinted_rotated_bitmap, (ALLEGRO_BITMAP *bitmap, ALLEGRO_COLOR tint, float cx, float cy, float dx, float dy, float angle, int flags)); +AL_FUNC(void, al_draw_tinted_scaled_rotated_bitmap, (ALLEGRO_BITMAP *bitmap, ALLEGRO_COLOR tint, float cx, float cy, float dx, float dy, float xscale, float yscale, float angle, int flags)); +AL_FUNC(void, al_draw_tinted_scaled_rotated_bitmap_region, ( + ALLEGRO_BITMAP *bitmap, + float sx, float sy, float sw, float sh, + ALLEGRO_COLOR tint, + float cx, float cy, float dx, float dy, float xscale, float yscale, + float angle, int flags)); + + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/bitmap_io.h b/common/allegro/include/allegro5/bitmap_io.h new file mode 100644 index 00000000..70ff94cd --- /dev/null +++ b/common/allegro/include/allegro5/bitmap_io.h @@ -0,0 +1,47 @@ +#ifndef __al_included_allegro5_bitmap_io_h +#define __al_included_allegro5_bitmap_io_h + +#include "allegro5/bitmap.h" +#include "allegro5/file.h" + +#ifdef __cplusplus + extern "C" { +#endif + +/* + * Bitmap loader flag + */ +enum { + ALLEGRO_KEEP_BITMAP_FORMAT = 0x0002, /* was a bitmap flag in 5.0 */ + ALLEGRO_NO_PREMULTIPLIED_ALPHA = 0x0200, /* was a bitmap flag in 5.0 */ + ALLEGRO_KEEP_INDEX = 0x0800 +}; + +typedef ALLEGRO_BITMAP *(*ALLEGRO_IIO_LOADER_FUNCTION)(const char *filename, int flags); +typedef ALLEGRO_BITMAP *(*ALLEGRO_IIO_FS_LOADER_FUNCTION)(ALLEGRO_FILE *fp, int flags); +typedef bool (*ALLEGRO_IIO_SAVER_FUNCTION)(const char *filename, ALLEGRO_BITMAP *bitmap); +typedef bool (*ALLEGRO_IIO_FS_SAVER_FUNCTION)(ALLEGRO_FILE *fp, ALLEGRO_BITMAP *bitmap); +typedef bool (*ALLEGRO_IIO_IDENTIFIER_FUNCTION)(ALLEGRO_FILE *f); + +AL_FUNC(bool, al_register_bitmap_loader, (const char *ext, ALLEGRO_IIO_LOADER_FUNCTION loader)); +AL_FUNC(bool, al_register_bitmap_saver, (const char *ext, ALLEGRO_IIO_SAVER_FUNCTION saver)); +AL_FUNC(bool, al_register_bitmap_loader_f, (const char *ext, ALLEGRO_IIO_FS_LOADER_FUNCTION fs_loader)); +AL_FUNC(bool, al_register_bitmap_saver_f, (const char *ext, ALLEGRO_IIO_FS_SAVER_FUNCTION fs_saver)); +AL_FUNC(bool, al_register_bitmap_identifier, (const char *ext, + ALLEGRO_IIO_IDENTIFIER_FUNCTION identifier)); +AL_FUNC(ALLEGRO_BITMAP *, al_load_bitmap, (const char *filename)); +AL_FUNC(ALLEGRO_BITMAP *, al_load_bitmap_flags, (const char *filename, int flags)); +AL_FUNC(ALLEGRO_BITMAP *, al_load_bitmap_f, (ALLEGRO_FILE *fp, const char *ident)); +AL_FUNC(ALLEGRO_BITMAP *, al_load_bitmap_flags_f, (ALLEGRO_FILE *fp, const char *ident, int flags)); +AL_FUNC(bool, al_save_bitmap, (const char *filename, ALLEGRO_BITMAP *bitmap)); +AL_FUNC(bool, al_save_bitmap_f, (ALLEGRO_FILE *fp, const char *ident, ALLEGRO_BITMAP *bitmap)); +AL_FUNC(char const *, al_identify_bitmap_f, (ALLEGRO_FILE *fp)); +AL_FUNC(char const *, al_identify_bitmap, (char const *filename)); + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/bitmap_lock.h b/common/allegro/include/allegro5/bitmap_lock.h new file mode 100644 index 00000000..198e58a0 --- /dev/null +++ b/common/allegro/include/allegro5/bitmap_lock.h @@ -0,0 +1,45 @@ +#ifndef __al_included_allegro5_bitmap_lock_h +#define __al_included_allegro5_bitmap_lock_h + +#include "allegro5/bitmap.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +/* + * Locking flags + */ +enum { + ALLEGRO_LOCK_READWRITE = 0, + ALLEGRO_LOCK_READONLY = 1, + ALLEGRO_LOCK_WRITEONLY = 2 +}; + + +/* Type: ALLEGRO_LOCKED_REGION + */ +typedef struct ALLEGRO_LOCKED_REGION ALLEGRO_LOCKED_REGION; +struct ALLEGRO_LOCKED_REGION { + void *data; + int format; + int pitch; + int pixel_size; +}; + + +AL_FUNC(ALLEGRO_LOCKED_REGION*, al_lock_bitmap, (ALLEGRO_BITMAP *bitmap, int format, int flags)); +AL_FUNC(ALLEGRO_LOCKED_REGION*, al_lock_bitmap_region, (ALLEGRO_BITMAP *bitmap, int x, int y, int width, int height, int format, int flags)); +AL_FUNC(ALLEGRO_LOCKED_REGION*, al_lock_bitmap_blocked, (ALLEGRO_BITMAP *bitmap, int flags)); +AL_FUNC(ALLEGRO_LOCKED_REGION*, al_lock_bitmap_region_blocked, (ALLEGRO_BITMAP *bitmap, int x_block, int y_block, + int width_block, int height_block, int flags)); +AL_FUNC(void, al_unlock_bitmap, (ALLEGRO_BITMAP *bitmap)); +AL_FUNC(bool, al_is_bitmap_locked, (ALLEGRO_BITMAP *bitmap)); + + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/blender.h b/common/allegro/include/allegro5/blender.h new file mode 100644 index 00000000..a36a3a3a --- /dev/null +++ b/common/allegro/include/allegro5/blender.h @@ -0,0 +1,51 @@ +#ifndef __al_included_allegro5_blender_h +#define __al_included_allegro5_blender_h + +#include "allegro5/base.h" +#include "allegro5/color.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +/* + * Blending modes + */ +enum ALLEGRO_BLEND_MODE { + ALLEGRO_ZERO = 0, + ALLEGRO_ONE = 1, + ALLEGRO_ALPHA = 2, + ALLEGRO_INVERSE_ALPHA = 3, + ALLEGRO_SRC_COLOR = 4, + ALLEGRO_DEST_COLOR = 5, + ALLEGRO_INVERSE_SRC_COLOR = 6, + ALLEGRO_INVERSE_DEST_COLOR = 7, + ALLEGRO_CONST_COLOR = 8, + ALLEGRO_INVERSE_CONST_COLOR = 9, + ALLEGRO_NUM_BLEND_MODES +}; + +enum ALLEGRO_BLEND_OPERATIONS { + ALLEGRO_ADD = 0, + ALLEGRO_SRC_MINUS_DEST = 1, + ALLEGRO_DEST_MINUS_SRC = 2, + ALLEGRO_NUM_BLEND_OPERATIONS +}; + + +AL_FUNC(void, al_set_blender, (int op, int source, int dest)); +AL_FUNC(void, al_set_blend_color, (ALLEGRO_COLOR color)); +AL_FUNC(void, al_get_blender, (int *op, int *source, int *dest)); +AL_FUNC(ALLEGRO_COLOR, al_get_blend_color, (void)); +AL_FUNC(void, al_set_separate_blender, (int op, int source, int dest, + int alpha_op, int alpha_source, int alpha_dest)); +AL_FUNC(void, al_get_separate_blender, (int *op, int *source, int *dest, + int *alpha_op, int *alpha_src, int *alpha_dest)); + + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/clipboard.h b/common/allegro/include/allegro5/clipboard.h new file mode 100644 index 00000000..46851fe4 --- /dev/null +++ b/common/allegro/include/allegro5/clipboard.h @@ -0,0 +1,42 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Clipboard handling. + * + * See readme.txt for copyright information. + */ + +#ifndef __al_included_allegro5_clipboard_h +#define __al_included_allegro5_clipboard_h + +#include "allegro5/base.h" +#include "allegro5/display.h" +#include "allegro5/utf8.h" + +#ifdef __cplusplus + extern "C" { +#endif + +AL_FUNC(char *, al_get_clipboard_text, (ALLEGRO_DISPLAY *display)); +AL_FUNC(bool, al_set_clipboard_text, (ALLEGRO_DISPLAY *display, const char *text)); +AL_FUNC(bool, al_clipboard_has_text, (ALLEGRO_DISPLAY *display)); + +#ifdef __cplusplus + } +#endif + +#endif + +/* + * Local Variables: + * c-basic-offset: 3 + * indent-tabs-mode: nil + * End: + */ diff --git a/common/allegro/include/allegro5/color.h b/common/allegro/include/allegro5/color.h new file mode 100644 index 00000000..41b94bfb --- /dev/null +++ b/common/allegro/include/allegro5/color.h @@ -0,0 +1,89 @@ +#ifndef __al_included_allegro5_color_h +#define __al_included_allegro5_color_h + +#include "allegro5/base.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +/* Type: ALLEGRO_COLOR + */ +typedef struct ALLEGRO_COLOR ALLEGRO_COLOR; + +struct ALLEGRO_COLOR +{ + float r, g, b, a; +}; + + +/* Enum: ALLEGRO_PIXEL_FORMAT + */ +typedef enum ALLEGRO_PIXEL_FORMAT +{ + ALLEGRO_PIXEL_FORMAT_ANY = 0, + ALLEGRO_PIXEL_FORMAT_ANY_NO_ALPHA = 1, + ALLEGRO_PIXEL_FORMAT_ANY_WITH_ALPHA = 2, + ALLEGRO_PIXEL_FORMAT_ANY_15_NO_ALPHA = 3, + ALLEGRO_PIXEL_FORMAT_ANY_16_NO_ALPHA = 4, + ALLEGRO_PIXEL_FORMAT_ANY_16_WITH_ALPHA = 5, + ALLEGRO_PIXEL_FORMAT_ANY_24_NO_ALPHA = 6, + ALLEGRO_PIXEL_FORMAT_ANY_32_NO_ALPHA = 7, + ALLEGRO_PIXEL_FORMAT_ANY_32_WITH_ALPHA = 8, + ALLEGRO_PIXEL_FORMAT_ARGB_8888 = 9, + ALLEGRO_PIXEL_FORMAT_RGBA_8888 = 10, + ALLEGRO_PIXEL_FORMAT_ARGB_4444 = 11, + ALLEGRO_PIXEL_FORMAT_RGB_888 = 12, /* 24 bit format */ + ALLEGRO_PIXEL_FORMAT_RGB_565 = 13, + ALLEGRO_PIXEL_FORMAT_RGB_555 = 14, + ALLEGRO_PIXEL_FORMAT_RGBA_5551 = 15, + ALLEGRO_PIXEL_FORMAT_ARGB_1555 = 16, + ALLEGRO_PIXEL_FORMAT_ABGR_8888 = 17, + ALLEGRO_PIXEL_FORMAT_XBGR_8888 = 18, + ALLEGRO_PIXEL_FORMAT_BGR_888 = 19, /* 24 bit format */ + ALLEGRO_PIXEL_FORMAT_BGR_565 = 20, + ALLEGRO_PIXEL_FORMAT_BGR_555 = 21, + ALLEGRO_PIXEL_FORMAT_RGBX_8888 = 22, + ALLEGRO_PIXEL_FORMAT_XRGB_8888 = 23, + ALLEGRO_PIXEL_FORMAT_ABGR_F32 = 24, + ALLEGRO_PIXEL_FORMAT_ABGR_8888_LE = 25, + ALLEGRO_PIXEL_FORMAT_RGBA_4444 = 26, + ALLEGRO_PIXEL_FORMAT_SINGLE_CHANNEL_8 = 27, + ALLEGRO_PIXEL_FORMAT_COMPRESSED_RGBA_DXT1 = 28, + ALLEGRO_PIXEL_FORMAT_COMPRESSED_RGBA_DXT3 = 29, + ALLEGRO_PIXEL_FORMAT_COMPRESSED_RGBA_DXT5 = 30, + ALLEGRO_NUM_PIXEL_FORMATS +} ALLEGRO_PIXEL_FORMAT; + + +/* Pixel mapping */ +AL_FUNC(ALLEGRO_COLOR, al_map_rgb, (unsigned char r, unsigned char g, unsigned char b)); +AL_FUNC(ALLEGRO_COLOR, al_map_rgba, (unsigned char r, unsigned char g, unsigned char b, unsigned char a)); +AL_FUNC(ALLEGRO_COLOR, al_map_rgb_f, (float r, float g, float b)); +AL_FUNC(ALLEGRO_COLOR, al_map_rgba_f, (float r, float g, float b, float a)); +AL_FUNC(ALLEGRO_COLOR, al_premul_rgba, + (unsigned char r, unsigned char g, unsigned char b, unsigned char a)); +AL_FUNC(ALLEGRO_COLOR, al_premul_rgba_f, + (float r, float g, float b, float a)); + +/* Pixel unmapping */ +AL_FUNC(void, al_unmap_rgb, (ALLEGRO_COLOR color, unsigned char *r, unsigned char *g, unsigned char *b)); +AL_FUNC(void, al_unmap_rgba, (ALLEGRO_COLOR color, unsigned char *r, unsigned char *g, unsigned char *b, unsigned char *a)); +AL_FUNC(void, al_unmap_rgb_f, (ALLEGRO_COLOR color, float *r, float *g, float *b)); +AL_FUNC(void, al_unmap_rgba_f, (ALLEGRO_COLOR color, float *r, float *g, float *b, float *a)); + +/* Pixel formats */ +AL_FUNC(int, al_get_pixel_size, (int format)); +AL_FUNC(int, al_get_pixel_format_bits, (int format)); +AL_FUNC(int, al_get_pixel_block_size, (int format)); +AL_FUNC(int, al_get_pixel_block_width, (int format)); +AL_FUNC(int, al_get_pixel_block_height, (int format)); + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set ts=8 sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/config.h b/common/allegro/include/allegro5/config.h new file mode 100644 index 00000000..9402b00d --- /dev/null +++ b/common/allegro/include/allegro5/config.h @@ -0,0 +1,49 @@ +#ifndef __al_included_allegro5_config_h +#define __al_included_allegro5_config_h + +#include "allegro5/file.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/* Type: ALLEGRO_CONFIG + */ +typedef struct ALLEGRO_CONFIG ALLEGRO_CONFIG; + +/* Type: ALLEGRO_CONFIG_SECTION + */ +typedef struct ALLEGRO_CONFIG_SECTION ALLEGRO_CONFIG_SECTION; + +/* Type: ALLEGRO_CONFIG_ENTRY + */ +typedef struct ALLEGRO_CONFIG_ENTRY ALLEGRO_CONFIG_ENTRY; + +AL_FUNC(ALLEGRO_CONFIG *, al_create_config, (void)); +AL_FUNC(void, al_add_config_section, (ALLEGRO_CONFIG *config, const char *name)); +AL_FUNC(void, al_set_config_value, (ALLEGRO_CONFIG *config, const char *section, const char *key, const char *value)); +AL_FUNC(void, al_add_config_comment, (ALLEGRO_CONFIG *config, const char *section, const char *comment)); +AL_FUNC(const char*, al_get_config_value, (const ALLEGRO_CONFIG *config, const char *section, const char *key)); +AL_FUNC(ALLEGRO_CONFIG*, al_load_config_file, (const char *filename)); +AL_FUNC(ALLEGRO_CONFIG*, al_load_config_file_f, (ALLEGRO_FILE *filename)); +AL_FUNC(bool, al_save_config_file, (const char *filename, const ALLEGRO_CONFIG *config)); +AL_FUNC(bool, al_save_config_file_f, (ALLEGRO_FILE *file, const ALLEGRO_CONFIG *config)); +AL_FUNC(void, al_merge_config_into, (ALLEGRO_CONFIG *master, const ALLEGRO_CONFIG *add)); +AL_FUNC(ALLEGRO_CONFIG *, al_merge_config, (const ALLEGRO_CONFIG *cfg1, const ALLEGRO_CONFIG *cfg2)); +AL_FUNC(void, al_destroy_config, (ALLEGRO_CONFIG *config)); +AL_FUNC(bool, al_remove_config_section, (ALLEGRO_CONFIG *config, + char const *section)); +AL_FUNC(bool, al_remove_config_key, (ALLEGRO_CONFIG *config, + char const *section, char const *key)); + +AL_FUNC(char const *, al_get_first_config_section, (ALLEGRO_CONFIG const *config, ALLEGRO_CONFIG_SECTION **iterator)); +AL_FUNC(char const *, al_get_next_config_section, (ALLEGRO_CONFIG_SECTION **iterator)); +AL_FUNC(char const *, al_get_first_config_entry, (ALLEGRO_CONFIG const *config, char const *section, + ALLEGRO_CONFIG_ENTRY **iterator)); +AL_FUNC(char const *, al_get_next_config_entry, (ALLEGRO_CONFIG_ENTRY **iterator)); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/common/allegro/include/allegro5/cpu.h b/common/allegro/include/allegro5/cpu.h new file mode 100644 index 00000000..512d76c4 --- /dev/null +++ b/common/allegro/include/allegro5/cpu.h @@ -0,0 +1,39 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * CPU and system information handling. + * + * See readme.txt for copyright information. + */ + +#ifndef __al_included_allegro5_cpu_h +#define __al_included_allegro5_cpu_h + +#include "allegro5/base.h" + +#ifdef __cplusplus + extern "C" { +#endif + +AL_FUNC(int, al_get_cpu_count, (void)); +AL_FUNC(int, al_get_ram_size, (void)); + +#ifdef __cplusplus + } +#endif + +#endif + +/* + * Local Variables: + * c-basic-offset: 3 + * indent-tabs-mode: nil + * End: + */ diff --git a/common/allegro/include/allegro5/debug.h b/common/allegro/include/allegro5/debug.h new file mode 100644 index 00000000..4ce403df --- /dev/null +++ b/common/allegro/include/allegro5/debug.h @@ -0,0 +1,100 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Debug facilities. + * + * By Shawn Hargreaves. + * + * See readme.txt for copyright information. + */ + + +#ifndef __al_included_allegro5_debug_h +#define __al_included_allegro5_debug_h + +#include +#include "allegro5/base.h" + +#ifdef __cplusplus + extern "C" { +#endif + +AL_FUNC(bool, _al_trace_prefix, (char const *channel, int level, + char const *file, int line, char const *function)); + +AL_PRINTFUNC(void, _al_trace_suffix, (const char *msg, ...), 1, 2); + +#if defined(DEBUGMODE) || defined(ALLEGRO_CFG_RELEASE_LOGGING) + /* Must not be used with a trailing semicolon. */ + #ifdef ALLEGRO_GCC + #define ALLEGRO_DEBUG_CHANNEL(x) \ + static char const *__al_debug_channel __attribute__((unused)) = x; + #else + #define ALLEGRO_DEBUG_CHANNEL(x) \ + static char const *__al_debug_channel = x; + #endif + #define ALLEGRO_TRACE_CHANNEL_LEVEL(channel, level) \ + !_al_trace_prefix(channel, level, __FILE__, __LINE__, __func__) \ + ? (void)0 : _al_trace_suffix +#else + #define ALLEGRO_TRACE_CHANNEL_LEVEL(channel, x) 1 ? (void) 0 : _al_trace_suffix + #define ALLEGRO_DEBUG_CHANNEL(x) +#endif + +#define ALLEGRO_TRACE_LEVEL(x) ALLEGRO_TRACE_CHANNEL_LEVEL(__al_debug_channel, x) +#define ALLEGRO_DEBUG ALLEGRO_TRACE_LEVEL(0) +#define ALLEGRO_INFO ALLEGRO_TRACE_LEVEL(1) +#define ALLEGRO_WARN ALLEGRO_TRACE_LEVEL(2) +#define ALLEGRO_ERROR ALLEGRO_TRACE_LEVEL(3) + +/* Run-time assertions. */ +AL_FUNCPTR(void, _al_user_assert_handler, (char const *expr, char const *file, + int line, char const *func)); + +AL_FUNC(void, al_register_assert_handler, (void (*handler)(char const *expr, + char const *file, int line, char const *func))); + +AL_FUNC(void, al_register_trace_handler, (void (*handler)(char const *))); + +#ifdef __clang_analyzer__ + /* Clang doesn't understand _al_user_assert_handler, so we simplify the + * definition for analysis purposes. */ + #define ALLEGRO_ASSERT(e) assert(e) +#else + #ifdef NDEBUG + #define ALLEGRO_ASSERT(e) ((void)(0 && (e))) + #else + #define ALLEGRO_ASSERT(e) \ + ((e) ? (void) 0 \ + : (_al_user_assert_handler) ? \ + _al_user_assert_handler(#e, __FILE__, __LINE__, __func__) \ + : assert(e)) + #endif +#endif + +/* Compile time assertions. */ +#define ALLEGRO_ASSERT_CONCAT_(a, b) a##b +#define ALLEGRO_ASSERT_CONCAT(a, b) ALLEGRO_ASSERT_CONCAT_(a, b) +#define ALLEGRO_STATIC_ASSERT(module, e) \ + struct ALLEGRO_ASSERT_CONCAT(static_assert_##module##_line_, __LINE__) \ + { unsigned int bf : !!(e); } + +/* We are lazy and use just ASSERT while Allegro itself is compiled. */ +#ifdef ALLEGRO_LIB_BUILD + #define ASSERT(x) ALLEGRO_ASSERT(x) +#endif + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/display.h b/common/allegro/include/allegro5/display.h new file mode 100644 index 00000000..84a9ccfe --- /dev/null +++ b/common/allegro/include/allegro5/display.h @@ -0,0 +1,189 @@ +#ifndef __al_included_allegro5_display_h +#define __al_included_allegro5_display_h + +#include "allegro5/bitmap.h" +#include "allegro5/color.h" +#include "allegro5/events.h" + +#ifdef __cplusplus + extern "C" { +#endif + +/* Possible bit combinations for the flags parameter of al_create_display. */ +enum { + ALLEGRO_WINDOWED = 1 << 0, + ALLEGRO_FULLSCREEN = 1 << 1, + ALLEGRO_OPENGL = 1 << 2, + ALLEGRO_DIRECT3D_INTERNAL = 1 << 3, + ALLEGRO_RESIZABLE = 1 << 4, + ALLEGRO_FRAMELESS = 1 << 5, + ALLEGRO_NOFRAME = ALLEGRO_FRAMELESS, /* older synonym */ + ALLEGRO_GENERATE_EXPOSE_EVENTS = 1 << 6, + ALLEGRO_OPENGL_3_0 = 1 << 7, + ALLEGRO_OPENGL_FORWARD_COMPATIBLE = 1 << 8, + ALLEGRO_FULLSCREEN_WINDOW = 1 << 9, + ALLEGRO_MINIMIZED = 1 << 10, + ALLEGRO_PROGRAMMABLE_PIPELINE = 1 << 11, + ALLEGRO_GTK_TOPLEVEL_INTERNAL = 1 << 12, + ALLEGRO_MAXIMIZED = 1 << 13, + ALLEGRO_OPENGL_ES_PROFILE = 1 << 14, +}; + +/* Possible parameters for al_set_display_option. + * Make sure to update ALLEGRO_EXTRA_DISPLAY_SETTINGS if you modify + * anything here. + */ +enum ALLEGRO_DISPLAY_OPTIONS { + ALLEGRO_RED_SIZE = 0, + ALLEGRO_GREEN_SIZE = 1, + ALLEGRO_BLUE_SIZE = 2, + ALLEGRO_ALPHA_SIZE = 3, + ALLEGRO_RED_SHIFT = 4, + ALLEGRO_GREEN_SHIFT = 5, + ALLEGRO_BLUE_SHIFT = 6, + ALLEGRO_ALPHA_SHIFT = 7, + ALLEGRO_ACC_RED_SIZE = 8, + ALLEGRO_ACC_GREEN_SIZE = 9, + ALLEGRO_ACC_BLUE_SIZE = 10, + ALLEGRO_ACC_ALPHA_SIZE = 11, + ALLEGRO_STEREO = 12, + ALLEGRO_AUX_BUFFERS = 13, + ALLEGRO_COLOR_SIZE = 14, + ALLEGRO_DEPTH_SIZE = 15, + ALLEGRO_STENCIL_SIZE = 16, + ALLEGRO_SAMPLE_BUFFERS = 17, + ALLEGRO_SAMPLES = 18, + ALLEGRO_RENDER_METHOD = 19, + ALLEGRO_FLOAT_COLOR = 20, + ALLEGRO_FLOAT_DEPTH = 21, + ALLEGRO_SINGLE_BUFFER = 22, + ALLEGRO_SWAP_METHOD = 23, + ALLEGRO_COMPATIBLE_DISPLAY = 24, + ALLEGRO_UPDATE_DISPLAY_REGION = 25, + ALLEGRO_VSYNC = 26, + ALLEGRO_MAX_BITMAP_SIZE = 27, + ALLEGRO_SUPPORT_NPOT_BITMAP = 28, + ALLEGRO_CAN_DRAW_INTO_BITMAP = 29, + ALLEGRO_SUPPORT_SEPARATE_ALPHA = 30, + ALLEGRO_AUTO_CONVERT_BITMAPS = 31, + ALLEGRO_SUPPORTED_ORIENTATIONS = 32, + ALLEGRO_OPENGL_MAJOR_VERSION = 33, + ALLEGRO_OPENGL_MINOR_VERSION = 34, + ALLEGRO_DISPLAY_OPTIONS_COUNT +}; + +enum +{ + ALLEGRO_DONTCARE, + ALLEGRO_REQUIRE, + ALLEGRO_SUGGEST +}; + + +/* Bitflags so they can be used for the ALLEGRO_SUPPORTED_ORIENTATIONS option. */ +enum ALLEGRO_DISPLAY_ORIENTATION +{ + ALLEGRO_DISPLAY_ORIENTATION_UNKNOWN = 0, + ALLEGRO_DISPLAY_ORIENTATION_0_DEGREES = 1, + ALLEGRO_DISPLAY_ORIENTATION_90_DEGREES = 2, + ALLEGRO_DISPLAY_ORIENTATION_180_DEGREES = 4, + ALLEGRO_DISPLAY_ORIENTATION_270_DEGREES = 8, + ALLEGRO_DISPLAY_ORIENTATION_PORTRAIT = 5, + ALLEGRO_DISPLAY_ORIENTATION_LANDSCAPE = 10, + ALLEGRO_DISPLAY_ORIENTATION_ALL = 15, + ALLEGRO_DISPLAY_ORIENTATION_FACE_UP = 16, + ALLEGRO_DISPLAY_ORIENTATION_FACE_DOWN = 32 +}; + + +/* Formally part of the primitives addon. */ +enum +{ + _ALLEGRO_PRIM_MAX_USER_ATTR = 10 +}; + + +/* Type: ALLEGRO_DISPLAY + */ +typedef struct ALLEGRO_DISPLAY ALLEGRO_DISPLAY; + + +/* Enum: ALLEGRO_NEW_WINDOW_TITLE_MAX_SIZE +*/ +#define ALLEGRO_NEW_WINDOW_TITLE_MAX_SIZE 255 + +AL_FUNC(void, al_set_new_display_refresh_rate, (int refresh_rate)); +AL_FUNC(void, al_set_new_display_flags, (int flags)); +AL_FUNC(int, al_get_new_display_refresh_rate, (void)); +AL_FUNC(int, al_get_new_display_flags, (void)); + +AL_FUNC(void, al_set_new_window_title, (const char *title)); +AL_FUNC(const char *, al_get_new_window_title, (void)); + +AL_FUNC(int, al_get_display_width, (ALLEGRO_DISPLAY *display)); +AL_FUNC(int, al_get_display_height, (ALLEGRO_DISPLAY *display)); +AL_FUNC(int, al_get_display_format, (ALLEGRO_DISPLAY *display)); +AL_FUNC(int, al_get_display_refresh_rate, (ALLEGRO_DISPLAY *display)); +AL_FUNC(int, al_get_display_flags, (ALLEGRO_DISPLAY *display)); +AL_FUNC(int, al_get_display_orientation, (ALLEGRO_DISPLAY* display)); +AL_FUNC(bool, al_set_display_flag, (ALLEGRO_DISPLAY *display, int flag, bool onoff)); + +AL_FUNC(ALLEGRO_DISPLAY*, al_create_display, (int w, int h)); +AL_FUNC(void, al_destroy_display, (ALLEGRO_DISPLAY *display)); +AL_FUNC(ALLEGRO_DISPLAY*, al_get_current_display, (void)); +AL_FUNC(void, al_set_target_bitmap, (ALLEGRO_BITMAP *bitmap)); +AL_FUNC(void, al_set_target_backbuffer, (ALLEGRO_DISPLAY *display)); +AL_FUNC(ALLEGRO_BITMAP*, al_get_backbuffer, (ALLEGRO_DISPLAY *display)); +AL_FUNC(ALLEGRO_BITMAP*, al_get_target_bitmap, (void)); + +AL_FUNC(bool, al_acknowledge_resize, (ALLEGRO_DISPLAY *display)); +AL_FUNC(bool, al_resize_display, (ALLEGRO_DISPLAY *display, int width, int height)); +AL_FUNC(void, al_flip_display, (void)); +AL_FUNC(void, al_update_display_region, (int x, int y, int width, int height)); +AL_FUNC(bool, al_is_compatible_bitmap, (ALLEGRO_BITMAP *bitmap)); + +AL_FUNC(bool, al_wait_for_vsync, (void)); + +AL_FUNC(ALLEGRO_EVENT_SOURCE *, al_get_display_event_source, (ALLEGRO_DISPLAY *display)); + +AL_FUNC(void, al_set_display_icon, (ALLEGRO_DISPLAY *display, ALLEGRO_BITMAP *icon)); +AL_FUNC(void, al_set_display_icons, (ALLEGRO_DISPLAY *display, int num_icons, ALLEGRO_BITMAP *icons[])); + +/* Stuff for multihead/window management */ +AL_FUNC(int, al_get_new_display_adapter, (void)); +AL_FUNC(void, al_set_new_display_adapter, (int adapter)); +AL_FUNC(void, al_set_new_window_position, (int x, int y)); +AL_FUNC(void, al_get_new_window_position, (int *x, int *y)); +AL_FUNC(void, al_set_window_position, (ALLEGRO_DISPLAY *display, int x, int y)); +AL_FUNC(void, al_get_window_position, (ALLEGRO_DISPLAY *display, int *x, int *y)); +AL_FUNC(bool, al_set_window_constraints, (ALLEGRO_DISPLAY *display, int min_w, int min_h, int max_w, int max_h)); +AL_FUNC(bool, al_get_window_constraints, (ALLEGRO_DISPLAY *display, int *min_w, int *min_h, int *max_w, int *max_h)); +AL_FUNC(void, al_apply_window_constraints, (ALLEGRO_DISPLAY *display, bool onoff)); + +AL_FUNC(void, al_set_window_title, (ALLEGRO_DISPLAY *display, const char *title)); + +/* Defined in display_settings.c */ +AL_FUNC(void, al_set_new_display_option, (int option, int value, int importance)); +AL_FUNC(int, al_get_new_display_option, (int option, int *importance)); +AL_FUNC(void, al_reset_new_display_options, (void)); +AL_FUNC(void, al_set_display_option, (ALLEGRO_DISPLAY *display, int option, int value)); +AL_FUNC(int, al_get_display_option, (ALLEGRO_DISPLAY *display, int option)); + +/*Deferred drawing*/ +AL_FUNC(void, al_hold_bitmap_drawing, (bool hold)); +AL_FUNC(bool, al_is_bitmap_drawing_held, (void)); + +/* Miscellaneous */ +AL_FUNC(void, al_acknowledge_drawing_halt, (ALLEGRO_DISPLAY *display)); +AL_FUNC(void, al_acknowledge_drawing_resume, (ALLEGRO_DISPLAY *display)); +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_SRC) +AL_FUNC(void, al_backup_dirty_bitmaps, (ALLEGRO_DISPLAY *display)); +#endif + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set ts=8 sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/drawing.h b/common/allegro/include/allegro5/drawing.h new file mode 100644 index 00000000..dd21dc6c --- /dev/null +++ b/common/allegro/include/allegro5/drawing.h @@ -0,0 +1,22 @@ +#ifndef __al_included_allegro5_drawing_h +#define __al_included_allegro5_drawing_h + +#include "allegro5/color.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +/* Drawing primitives */ +AL_FUNC(void, al_clear_to_color, (ALLEGRO_COLOR color)); +AL_FUNC(void, al_clear_depth_buffer, (float x)); +AL_FUNC(void, al_draw_pixel, (float x, float y, ALLEGRO_COLOR color)); + + +#ifdef __cplusplus + } +#endif + +#endif +/* vim: set ts=8 sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/error.h b/common/allegro/include/allegro5/error.h new file mode 100644 index 00000000..306c7aa0 --- /dev/null +++ b/common/allegro/include/allegro5/error.h @@ -0,0 +1,39 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Error handling. + * + * See readme.txt for copyright information. + */ + +#ifndef __al_included_allegro5_error_h +#define __al_included_allegro5_error_h + +#include "allegro5/base.h" + +#ifdef __cplusplus + extern "C" { +#endif + +AL_FUNC(int, al_get_errno, (void)); +AL_FUNC(void, al_set_errno, (int errnum)); + +#ifdef __cplusplus + } +#endif + +#endif + +/* + * Local Variables: + * c-basic-offset: 3 + * indent-tabs-mode: nil + * End: + */ diff --git a/common/allegro/include/allegro5/events.h b/common/allegro/include/allegro5/events.h new file mode 100644 index 00000000..0188c627 --- /dev/null +++ b/common/allegro/include/allegro5/events.h @@ -0,0 +1,273 @@ +#ifndef __al_included_allegro5_events_h +#define __al_included_allegro5_events_h + +#include "allegro5/altime.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +/* Type: ALLEGRO_EVENT_TYPE + */ +typedef unsigned int ALLEGRO_EVENT_TYPE; + +enum +{ + ALLEGRO_EVENT_JOYSTICK_AXIS = 1, + ALLEGRO_EVENT_JOYSTICK_BUTTON_DOWN = 2, + ALLEGRO_EVENT_JOYSTICK_BUTTON_UP = 3, + ALLEGRO_EVENT_JOYSTICK_CONFIGURATION = 4, + + ALLEGRO_EVENT_KEY_DOWN = 10, + ALLEGRO_EVENT_KEY_CHAR = 11, + ALLEGRO_EVENT_KEY_UP = 12, + + ALLEGRO_EVENT_MOUSE_AXES = 20, + ALLEGRO_EVENT_MOUSE_BUTTON_DOWN = 21, + ALLEGRO_EVENT_MOUSE_BUTTON_UP = 22, + ALLEGRO_EVENT_MOUSE_ENTER_DISPLAY = 23, + ALLEGRO_EVENT_MOUSE_LEAVE_DISPLAY = 24, + ALLEGRO_EVENT_MOUSE_WARPED = 25, + + ALLEGRO_EVENT_TIMER = 30, + + ALLEGRO_EVENT_DISPLAY_EXPOSE = 40, + ALLEGRO_EVENT_DISPLAY_RESIZE = 41, + ALLEGRO_EVENT_DISPLAY_CLOSE = 42, + ALLEGRO_EVENT_DISPLAY_LOST = 43, + ALLEGRO_EVENT_DISPLAY_FOUND = 44, + ALLEGRO_EVENT_DISPLAY_SWITCH_IN = 45, + ALLEGRO_EVENT_DISPLAY_SWITCH_OUT = 46, + ALLEGRO_EVENT_DISPLAY_ORIENTATION = 47, + ALLEGRO_EVENT_DISPLAY_HALT_DRAWING = 48, + ALLEGRO_EVENT_DISPLAY_RESUME_DRAWING = 49, + + ALLEGRO_EVENT_TOUCH_BEGIN = 50, + ALLEGRO_EVENT_TOUCH_END = 51, + ALLEGRO_EVENT_TOUCH_MOVE = 52, + ALLEGRO_EVENT_TOUCH_CANCEL = 53, + + ALLEGRO_EVENT_DISPLAY_CONNECTED = 60, + ALLEGRO_EVENT_DISPLAY_DISCONNECTED = 61 +}; + + +/* Function: ALLEGRO_EVENT_TYPE_IS_USER + * + * 1 <= n < 512 - builtin events + * 512 <= n < 1024 - reserved user events (for addons) + * 1024 <= n - unreserved user events + */ +#define ALLEGRO_EVENT_TYPE_IS_USER(t) ((t) >= 512) + + +/* Function: ALLEGRO_GET_EVENT_TYPE + */ +#define ALLEGRO_GET_EVENT_TYPE(a, b, c, d) AL_ID(a, b, c, d) + + +/* Type: ALLEGRO_EVENT_SOURCE + */ +typedef struct ALLEGRO_EVENT_SOURCE ALLEGRO_EVENT_SOURCE; + +struct ALLEGRO_EVENT_SOURCE +{ + int __pad[32]; +}; + + + +/* + * Event structures + * + * All event types have the following fields in common. + * + * type -- the type of event this is + * timestamp -- when this event was generated + * source -- which event source generated this event + * + * For people writing event sources: The common fields must be at the + * very start of each event structure, i.e. put _AL_EVENT_HEADER at the + * front. + */ + +#define _AL_EVENT_HEADER(srctype) \ + ALLEGRO_EVENT_TYPE type; \ + srctype *source; \ + double timestamp; + + +typedef struct ALLEGRO_ANY_EVENT +{ + _AL_EVENT_HEADER(ALLEGRO_EVENT_SOURCE) +} ALLEGRO_ANY_EVENT; + + +typedef struct ALLEGRO_DISPLAY_EVENT +{ + _AL_EVENT_HEADER(struct ALLEGRO_DISPLAY) + int x, y; + int width, height; + int orientation; +} ALLEGRO_DISPLAY_EVENT; + + +typedef struct ALLEGRO_JOYSTICK_EVENT +{ + _AL_EVENT_HEADER(struct ALLEGRO_JOYSTICK) + struct ALLEGRO_JOYSTICK *id; + int stick; + int axis; + float pos; + int button; +} ALLEGRO_JOYSTICK_EVENT; + + + +typedef struct ALLEGRO_KEYBOARD_EVENT +{ + _AL_EVENT_HEADER(struct ALLEGRO_KEYBOARD) + struct ALLEGRO_DISPLAY *display; /* the window the key was pressed in */ + int keycode; /* the physical key pressed */ + int unichar; /* unicode character or negative */ + unsigned int modifiers; /* bitfield */ + bool repeat; /* auto-repeated or not */ +} ALLEGRO_KEYBOARD_EVENT; + + + +typedef struct ALLEGRO_MOUSE_EVENT +{ + _AL_EVENT_HEADER(struct ALLEGRO_MOUSE) + struct ALLEGRO_DISPLAY *display; + /* (display) Window the event originate from + * (x, y) Primary mouse position + * (z) Mouse wheel position (1D 'wheel'), or, + * (w, z) Mouse wheel position (2D 'ball') + * (pressure) The pressure applied, for stylus (0 or 1 for normal mouse) + */ + int x, y, z, w; + int dx, dy, dz, dw; + unsigned int button; + float pressure; +} ALLEGRO_MOUSE_EVENT; + + + +typedef struct ALLEGRO_TIMER_EVENT +{ + _AL_EVENT_HEADER(struct ALLEGRO_TIMER) + int64_t count; + double error; +} ALLEGRO_TIMER_EVENT; + + + +typedef struct ALLEGRO_TOUCH_EVENT +{ + _AL_EVENT_HEADER(struct ALLEGRO_TOUCH_INPUT) + struct ALLEGRO_DISPLAY *display; + /* (id) Identifier of the event, always positive number. + * (x, y) Touch position on the screen in 1:1 resolution. + * (dx, dy) Relative touch position. + * (primary) True, if touch is a primary one (usually first one). + */ + int id; + float x, y; + float dx, dy; + bool primary; +} ALLEGRO_TOUCH_EVENT; + + + +/* Type: ALLEGRO_USER_EVENT + */ +typedef struct ALLEGRO_USER_EVENT ALLEGRO_USER_EVENT; + +struct ALLEGRO_USER_EVENT +{ + _AL_EVENT_HEADER(struct ALLEGRO_EVENT_SOURCE) + struct ALLEGRO_USER_EVENT_DESCRIPTOR *__internal__descr; + intptr_t data1; + intptr_t data2; + intptr_t data3; + intptr_t data4; +}; + + + +/* Type: ALLEGRO_EVENT + */ +typedef union ALLEGRO_EVENT ALLEGRO_EVENT; + +union ALLEGRO_EVENT +{ + /* This must be the same as the first field of _AL_EVENT_HEADER. */ + ALLEGRO_EVENT_TYPE type; + /* `any' is to allow the user to access the other fields which are + * common to all event types, without using some specific type + * structure. + */ + ALLEGRO_ANY_EVENT any; + ALLEGRO_DISPLAY_EVENT display; + ALLEGRO_JOYSTICK_EVENT joystick; + ALLEGRO_KEYBOARD_EVENT keyboard; + ALLEGRO_MOUSE_EVENT mouse; + ALLEGRO_TIMER_EVENT timer; + ALLEGRO_TOUCH_EVENT touch; + ALLEGRO_USER_EVENT user; +}; + + + +/* Event sources */ + +AL_FUNC(void, al_init_user_event_source, (ALLEGRO_EVENT_SOURCE *)); +AL_FUNC(void, al_destroy_user_event_source, (ALLEGRO_EVENT_SOURCE *)); +/* The second argument is ALLEGRO_EVENT instead of ALLEGRO_USER_EVENT + * to prevent users passing a pointer to a too-short structure. + */ +AL_FUNC(bool, al_emit_user_event, (ALLEGRO_EVENT_SOURCE *, ALLEGRO_EVENT *, + void (*dtor)(ALLEGRO_USER_EVENT *))); +AL_FUNC(void, al_unref_user_event, (ALLEGRO_USER_EVENT *)); +AL_FUNC(void, al_set_event_source_data, (ALLEGRO_EVENT_SOURCE*, intptr_t data)); +AL_FUNC(intptr_t, al_get_event_source_data, (const ALLEGRO_EVENT_SOURCE*)); + + + +/* Event queues */ + +/* Type: ALLEGRO_EVENT_QUEUE + */ +typedef struct ALLEGRO_EVENT_QUEUE ALLEGRO_EVENT_QUEUE; + +AL_FUNC(ALLEGRO_EVENT_QUEUE*, al_create_event_queue, (void)); +AL_FUNC(void, al_destroy_event_queue, (ALLEGRO_EVENT_QUEUE*)); +AL_FUNC(bool, al_is_event_source_registered, (ALLEGRO_EVENT_QUEUE *, + ALLEGRO_EVENT_SOURCE *)); +AL_FUNC(void, al_register_event_source, (ALLEGRO_EVENT_QUEUE*, ALLEGRO_EVENT_SOURCE*)); +AL_FUNC(void, al_unregister_event_source, (ALLEGRO_EVENT_QUEUE*, ALLEGRO_EVENT_SOURCE*)); +AL_FUNC(void, al_pause_event_queue, (ALLEGRO_EVENT_QUEUE*, bool)); +AL_FUNC(bool, al_is_event_queue_paused, (const ALLEGRO_EVENT_QUEUE*)); +AL_FUNC(bool, al_is_event_queue_empty, (ALLEGRO_EVENT_QUEUE*)); +AL_FUNC(bool, al_get_next_event, (ALLEGRO_EVENT_QUEUE*, ALLEGRO_EVENT *ret_event)); +AL_FUNC(bool, al_peek_next_event, (ALLEGRO_EVENT_QUEUE*, ALLEGRO_EVENT *ret_event)); +AL_FUNC(bool, al_drop_next_event, (ALLEGRO_EVENT_QUEUE*)); +AL_FUNC(void, al_flush_event_queue, (ALLEGRO_EVENT_QUEUE*)); +AL_FUNC(void, al_wait_for_event, (ALLEGRO_EVENT_QUEUE*, + ALLEGRO_EVENT *ret_event)); +AL_FUNC(bool, al_wait_for_event_timed, (ALLEGRO_EVENT_QUEUE*, + ALLEGRO_EVENT *ret_event, + float secs)); +AL_FUNC(bool, al_wait_for_event_until, (ALLEGRO_EVENT_QUEUE *queue, + ALLEGRO_EVENT *ret_event, + ALLEGRO_TIMEOUT *timeout)); + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/file.h b/common/allegro/include/allegro5/file.h new file mode 100644 index 00000000..b1873e8e --- /dev/null +++ b/common/allegro/include/allegro5/file.h @@ -0,0 +1,107 @@ +#ifndef __al_included_allegro5_file_h +#define __al_included_allegro5_file_h + +#include "allegro5/base.h" +#include "allegro5/path.h" +#include "allegro5/utf8.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +/* Type: ALLEGRO_FILE + */ +typedef struct ALLEGRO_FILE ALLEGRO_FILE; + + +/* Type: ALLEGRO_FILE_INTERFACE + */ +typedef struct ALLEGRO_FILE_INTERFACE +{ + AL_METHOD(void *, fi_fopen, (const char *path, const char *mode)); + AL_METHOD(bool, fi_fclose, (ALLEGRO_FILE *handle)); + AL_METHOD(size_t, fi_fread, (ALLEGRO_FILE *f, void *ptr, size_t size)); + AL_METHOD(size_t, fi_fwrite, (ALLEGRO_FILE *f, const void *ptr, size_t size)); + AL_METHOD(bool, fi_fflush, (ALLEGRO_FILE *f)); + AL_METHOD(int64_t, fi_ftell, (ALLEGRO_FILE *f)); + AL_METHOD(bool, fi_fseek, (ALLEGRO_FILE *f, int64_t offset, int whence)); + AL_METHOD(bool, fi_feof, (ALLEGRO_FILE *f)); + AL_METHOD(int, fi_ferror, (ALLEGRO_FILE *f)); + AL_METHOD(const char *, fi_ferrmsg, (ALLEGRO_FILE *f)); + AL_METHOD(void, fi_fclearerr, (ALLEGRO_FILE *f)); + AL_METHOD(int, fi_fungetc, (ALLEGRO_FILE *f, int c)); + AL_METHOD(off_t, fi_fsize, (ALLEGRO_FILE *f)); +} ALLEGRO_FILE_INTERFACE; + + +/* Enum: ALLEGRO_SEEK + */ +typedef enum ALLEGRO_SEEK +{ + ALLEGRO_SEEK_SET = 0, + ALLEGRO_SEEK_CUR, + ALLEGRO_SEEK_END +} ALLEGRO_SEEK; + + +/* The basic operations. */ +AL_FUNC(ALLEGRO_FILE*, al_fopen, (const char *path, const char *mode)); +AL_FUNC(ALLEGRO_FILE*, al_fopen_interface, (const ALLEGRO_FILE_INTERFACE *vt, const char *path, const char *mode)); +AL_FUNC(ALLEGRO_FILE*, al_create_file_handle, (const ALLEGRO_FILE_INTERFACE *vt, void *userdata)); +AL_FUNC(bool, al_fclose, (ALLEGRO_FILE *f)); +AL_FUNC(size_t, al_fread, (ALLEGRO_FILE *f, void *ptr, size_t size)); +AL_FUNC(size_t, al_fwrite, (ALLEGRO_FILE *f, const void *ptr, size_t size)); +AL_FUNC(bool, al_fflush, (ALLEGRO_FILE *f)); +AL_FUNC(int64_t, al_ftell, (ALLEGRO_FILE *f)); +AL_FUNC(bool, al_fseek, (ALLEGRO_FILE *f, int64_t offset, int whence)); +AL_FUNC(bool, al_feof, (ALLEGRO_FILE *f)); +AL_FUNC(int, al_ferror, (ALLEGRO_FILE *f)); +AL_FUNC(const char *, al_ferrmsg, (ALLEGRO_FILE *f)); +AL_FUNC(void, al_fclearerr, (ALLEGRO_FILE *f)); +AL_FUNC(int, al_fungetc, (ALLEGRO_FILE *f, int c)); +AL_FUNC(int64_t, al_fsize, (ALLEGRO_FILE *f)); + +/* Convenience functions. */ +AL_FUNC(int, al_fgetc, (ALLEGRO_FILE *f)); +AL_FUNC(int, al_fputc, (ALLEGRO_FILE *f, int c)); +AL_FUNC(int16_t, al_fread16le, (ALLEGRO_FILE *f)); +AL_FUNC(int16_t, al_fread16be, (ALLEGRO_FILE *f)); +AL_FUNC(size_t, al_fwrite16le, (ALLEGRO_FILE *f, int16_t w)); +AL_FUNC(size_t, al_fwrite16be, (ALLEGRO_FILE *f, int16_t w)); +AL_FUNC(int32_t, al_fread32le, (ALLEGRO_FILE *f)); +AL_FUNC(int32_t, al_fread32be, (ALLEGRO_FILE *f)); +AL_FUNC(size_t, al_fwrite32le, (ALLEGRO_FILE *f, int32_t l)); +AL_FUNC(size_t, al_fwrite32be, (ALLEGRO_FILE *f, int32_t l)); +AL_FUNC(char*, al_fgets, (ALLEGRO_FILE *f, char * const p, size_t max)); +AL_FUNC(ALLEGRO_USTR *, al_fget_ustr, (ALLEGRO_FILE *f)); +AL_FUNC(int, al_fputs, (ALLEGRO_FILE *f, const char *p)); +AL_FUNC(int, al_fprintf, (ALLEGRO_FILE *f, const char *format, ...)); +AL_FUNC(int, al_vfprintf, (ALLEGRO_FILE *f, const char* format, va_list args)); + +/* Specific to stdio backend. */ +AL_FUNC(ALLEGRO_FILE*, al_fopen_fd, (int fd, const char *mode)); +AL_FUNC(ALLEGRO_FILE*, al_make_temp_file, (const char *tmpl, + ALLEGRO_PATH **ret_path)); + +/* Specific to slices. */ +AL_FUNC(ALLEGRO_FILE*, al_fopen_slice, (ALLEGRO_FILE *fp, + size_t initial_size, const char *mode)); + +/* Thread-local state. */ +AL_FUNC(const ALLEGRO_FILE_INTERFACE *, al_get_new_file_interface, (void)); +AL_FUNC(void, al_set_new_file_interface, (const ALLEGRO_FILE_INTERFACE * + file_interface)); +AL_FUNC(void, al_set_standard_file_interface, (void)); + +/* ALLEGRO_FILE field accessors */ +AL_FUNC(void *, al_get_file_userdata, (ALLEGRO_FILE *f)); + + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/fixed.h b/common/allegro/include/allegro5/fixed.h new file mode 100644 index 00000000..7ecc79e7 --- /dev/null +++ b/common/allegro/include/allegro5/fixed.h @@ -0,0 +1,41 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Fixed point type. + * + * By Shawn Hargreaves. + * + * See readme.txt for copyright information. + */ + + +#ifndef __al_included_allegro5_fixed_h +#define __al_included_allegro5_fixed_h + +#include "allegro5/base.h" + +#ifdef __cplusplus + extern "C" { +#endif + +/* Type: al_fixed + */ +typedef int32_t al_fixed; + +AL_VAR(const al_fixed, al_fixtorad_r); +AL_VAR(const al_fixed, al_radtofix_r); + +#ifdef __cplusplus + } +#endif + +#endif + + diff --git a/common/allegro/include/allegro5/fmaths.h b/common/allegro/include/allegro5/fmaths.h new file mode 100644 index 00000000..e94e4cab --- /dev/null +++ b/common/allegro/include/allegro5/fmaths.h @@ -0,0 +1,46 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Fixed point math routines. + * + * By Shawn Hargreaves. + * + * See readme.txt for copyright information. + */ + + +#ifndef __al_included_allegro5_fmaths_h +#define __al_included_allegro5_fmaths_h + +#include "allegro5/base.h" +#include "allegro5/fixed.h" + +#ifdef __cplusplus + extern "C" { +#endif + +AL_FUNC(al_fixed, al_fixsqrt, (al_fixed x)); +AL_FUNC(al_fixed, al_fixhypot, (al_fixed x, al_fixed y)); +AL_FUNC(al_fixed, al_fixatan, (al_fixed x)); +AL_FUNC(al_fixed, al_fixatan2, (al_fixed y, al_fixed x)); + +AL_ARRAY(al_fixed, _al_fix_cos_tbl); +AL_ARRAY(al_fixed, _al_fix_tan_tbl); +AL_ARRAY(al_fixed, _al_fix_acos_tbl); + +#ifdef __cplusplus + } +#endif + +#include "allegro5/inline/fmaths.inl" + +#endif + + diff --git a/common/allegro/include/allegro5/fshook.h b/common/allegro/include/allegro5/fshook.h new file mode 100644 index 00000000..dcd35b68 --- /dev/null +++ b/common/allegro/include/allegro5/fshook.h @@ -0,0 +1,148 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * File System Hooks. + * + * See readme.txt for copyright information. + */ + +#ifndef __al_included_allegro5_fshook_h +#define __al_included_allegro5_fshook_h + +#include "allegro5/base.h" +#include "allegro5/file.h" +#include "allegro5/path.h" + +#ifdef ALLEGRO_HAVE_SYS_TYPES_H + #include +#else +/* 4 Gig max offsets if sys/types doesn't exist. */ +typedef unsigned int off_t; +#endif + +#ifdef __cplusplus + extern "C" { +#endif + + +/* Type: ALLEGRO_FS_ENTRY + */ +typedef struct ALLEGRO_FS_ENTRY ALLEGRO_FS_ENTRY; + +struct ALLEGRO_FS_ENTRY { + struct ALLEGRO_FS_INTERFACE const *vtable; +}; + + +/* Enum: ALLEGRO_FILE_MODE + */ +typedef enum ALLEGRO_FILE_MODE +{ + ALLEGRO_FILEMODE_READ = 1, + ALLEGRO_FILEMODE_WRITE = 1 << 1, + ALLEGRO_FILEMODE_EXECUTE = 1 << 2, + ALLEGRO_FILEMODE_HIDDEN = 1 << 3, + ALLEGRO_FILEMODE_ISFILE = 1 << 4, + ALLEGRO_FILEMODE_ISDIR = 1 << 5 +} ALLEGRO_FILE_MODE; + + +#ifndef EOF + #define EOF (-1) +#endif + + +/* Type: ALLEGRO_FS_INTERFACE + */ +typedef struct ALLEGRO_FS_INTERFACE ALLEGRO_FS_INTERFACE; + +struct ALLEGRO_FS_INTERFACE { + AL_METHOD(ALLEGRO_FS_ENTRY *, fs_create_entry, (const char *path)); + AL_METHOD(void, fs_destroy_entry, (ALLEGRO_FS_ENTRY *e)); + AL_METHOD(const char *, fs_entry_name, (ALLEGRO_FS_ENTRY *e)); + AL_METHOD(bool, fs_update_entry, (ALLEGRO_FS_ENTRY *e)); + AL_METHOD(uint32_t, fs_entry_mode, (ALLEGRO_FS_ENTRY *e)); + AL_METHOD(time_t, fs_entry_atime, (ALLEGRO_FS_ENTRY *e)); + AL_METHOD(time_t, fs_entry_mtime, (ALLEGRO_FS_ENTRY *e)); + AL_METHOD(time_t, fs_entry_ctime, (ALLEGRO_FS_ENTRY *e)); + AL_METHOD(off_t, fs_entry_size, (ALLEGRO_FS_ENTRY *e)); + AL_METHOD(bool, fs_entry_exists, (ALLEGRO_FS_ENTRY *e)); + AL_METHOD(bool, fs_remove_entry, (ALLEGRO_FS_ENTRY *e)); + + AL_METHOD(bool, fs_open_directory, (ALLEGRO_FS_ENTRY *e)); + AL_METHOD(ALLEGRO_FS_ENTRY *, fs_read_directory,(ALLEGRO_FS_ENTRY *e)); + AL_METHOD(bool, fs_close_directory, (ALLEGRO_FS_ENTRY *e)); + + AL_METHOD(bool, fs_filename_exists, (const char *path)); + AL_METHOD(bool, fs_remove_filename, (const char *path)); + AL_METHOD(char *, fs_get_current_directory, (void)); + AL_METHOD(bool, fs_change_directory, (const char *path)); + AL_METHOD(bool, fs_make_directory, (const char *path)); + + AL_METHOD(ALLEGRO_FILE *, fs_open_file, (ALLEGRO_FS_ENTRY *e, + const char *mode)); +}; + +AL_FUNC(ALLEGRO_FS_ENTRY *, al_create_fs_entry, (const char *path)); +AL_FUNC(void, al_destroy_fs_entry, (ALLEGRO_FS_ENTRY *e)); +AL_FUNC(const char *, al_get_fs_entry_name,(ALLEGRO_FS_ENTRY *e)); +AL_FUNC(bool, al_update_fs_entry, (ALLEGRO_FS_ENTRY *e)); +AL_FUNC(uint32_t, al_get_fs_entry_mode,(ALLEGRO_FS_ENTRY *e)); +AL_FUNC(time_t, al_get_fs_entry_atime,(ALLEGRO_FS_ENTRY *e)); +AL_FUNC(time_t, al_get_fs_entry_mtime,(ALLEGRO_FS_ENTRY *e)); +AL_FUNC(time_t, al_get_fs_entry_ctime,(ALLEGRO_FS_ENTRY *e)); +AL_FUNC(off_t, al_get_fs_entry_size,(ALLEGRO_FS_ENTRY *e)); +AL_FUNC(bool, al_fs_entry_exists, (ALLEGRO_FS_ENTRY *e)); +AL_FUNC(bool, al_remove_fs_entry, (ALLEGRO_FS_ENTRY *e)); + +AL_FUNC(bool, al_open_directory, (ALLEGRO_FS_ENTRY *e)); +AL_FUNC(ALLEGRO_FS_ENTRY *, al_read_directory, (ALLEGRO_FS_ENTRY *e)); +AL_FUNC(bool, al_close_directory, (ALLEGRO_FS_ENTRY *e)); + +AL_FUNC(bool, al_filename_exists, (const char *path)); +AL_FUNC(bool, al_remove_filename, (const char *path)); +AL_FUNC(char *, al_get_current_directory, (void)); +AL_FUNC(bool, al_change_directory, (const char *path)); +AL_FUNC(bool, al_make_directory, (const char *path)); + +AL_FUNC(ALLEGRO_FILE *, al_open_fs_entry, (ALLEGRO_FS_ENTRY *e, + const char *mode)); + + + +/* Helper function for iterating over a directory using a callback. */ + +/* Type: ALLEGRO_FOR_EACH_FS_ENTRY_RESULT + */ +typedef enum ALLEGRO_FOR_EACH_FS_ENTRY_RESULT { + ALLEGRO_FOR_EACH_FS_ENTRY_ERROR = -1, + ALLEGRO_FOR_EACH_FS_ENTRY_OK = 0, + ALLEGRO_FOR_EACH_FS_ENTRY_SKIP = 1, + ALLEGRO_FOR_EACH_FS_ENTRY_STOP = 2 +} ALLEGRO_FOR_EACH_FS_ENTRY_RESULT; + +AL_FUNC(int, al_for_each_fs_entry, (ALLEGRO_FS_ENTRY *dir, + int (*callback)(ALLEGRO_FS_ENTRY *entry, void *extra), + void *extra)); + + +/* Thread-local state. */ +AL_FUNC(const ALLEGRO_FS_INTERFACE *, al_get_fs_interface, (void)); +AL_FUNC(void, al_set_fs_interface, (const ALLEGRO_FS_INTERFACE *vtable)); +AL_FUNC(void, al_set_standard_fs_interface, (void)); + + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/fullscreen_mode.h b/common/allegro/include/allegro5/fullscreen_mode.h new file mode 100644 index 00000000..c158ce91 --- /dev/null +++ b/common/allegro/include/allegro5/fullscreen_mode.h @@ -0,0 +1,33 @@ +#ifndef __al_included_allegro5_fullscreen_mode_h +#define __al_included_allegro5_fullscreen_mode_h + +#include "allegro5/base.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +/* Type: ALLEGRO_DISPLAY_MODE + */ +typedef struct ALLEGRO_DISPLAY_MODE +{ + int width; + int height; + int format; + int refresh_rate; +} ALLEGRO_DISPLAY_MODE; + + +AL_FUNC(int, al_get_num_display_modes, (void)); +AL_FUNC(ALLEGRO_DISPLAY_MODE*, al_get_display_mode, (int index, + ALLEGRO_DISPLAY_MODE *mode)); + + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set ts=8 sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/haptic.h b/common/allegro/include/allegro5/haptic.h new file mode 100644 index 00000000..5de93967 --- /dev/null +++ b/common/allegro/include/allegro5/haptic.h @@ -0,0 +1,247 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Haptic (that is, force feedback) routines for Allegro. + * + * By Beoran. + * + * See LICENSE.txt for copyright information. + */ + +#ifndef __al_included_allegro5_haptic_h +#define __al_included_allegro5_haptic_h + +#include "allegro5/base.h" +#include "allegro5/display.h" +#include "allegro5/events.h" +#include "allegro5/joystick.h" +#include "allegro5/keyboard.h" +#include "allegro5/mouse.h" +#include "allegro5/touch_input.h" + +#ifdef __cplusplus + extern "C" { +#endif + +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_SRC) + +/* Enum: ALLEGRO_HAPTIC_CONSTANTS + */ +enum ALLEGRO_HAPTIC_CONSTANTS +{ + ALLEGRO_HAPTIC_RUMBLE = 1 << 0, + ALLEGRO_HAPTIC_PERIODIC = 1 << 1, + ALLEGRO_HAPTIC_CONSTANT = 1 << 2, + ALLEGRO_HAPTIC_SPRING = 1 << 3, + ALLEGRO_HAPTIC_FRICTION = 1 << 4, + ALLEGRO_HAPTIC_DAMPER = 1 << 5, + ALLEGRO_HAPTIC_INERTIA = 1 << 6, + ALLEGRO_HAPTIC_RAMP = 1 << 7, + ALLEGRO_HAPTIC_SQUARE = 1 << 8, + ALLEGRO_HAPTIC_TRIANGLE = 1 << 9, + ALLEGRO_HAPTIC_SINE = 1 << 10, + ALLEGRO_HAPTIC_SAW_UP = 1 << 11, + ALLEGRO_HAPTIC_SAW_DOWN = 1 << 12, + ALLEGRO_HAPTIC_CUSTOM = 1 << 13, + ALLEGRO_HAPTIC_GAIN = 1 << 14, + ALLEGRO_HAPTIC_ANGLE = 1 << 15, + ALLEGRO_HAPTIC_RADIUS = 1 << 16, + ALLEGRO_HAPTIC_AZIMUTH = 1 << 17, + ALLEGRO_HAPTIC_AUTOCENTER= 1 << 18, +}; + + + +/* Type: ALLEGRO_HAPTIC + */ +typedef struct ALLEGRO_HAPTIC ALLEGRO_HAPTIC; + +/* Direction of a haptic effect. Angle is a value between 0 and 2*M_PI. + * An angle 0 means oriented towards the user, M_PI is away from the user + * (towards the screen). Angle is only supported if the device capabilities + * include ALLEGRO_HAPTIC_ANGLE. + * + * Radius (if supported) is the distance of the effect from the user as a + * value between 0 and 1. Normally it is zero. Radius is only supported if the + * device capabilities include ALLEGRO_HAPTIC_RADIUS. + * + * Azimuth is the angle of elevation, between -M_PI/2 and M_PI/2. + * Zero points to the horizontal plane, -M_PI/2 points down, and M_PI/2 points + * up. Azimuth is only supported if the device capabilities include + * ALLEGRO_HAPTIC_AZIMUTH. + */ +struct ALLEGRO_HAPTIC_DIRECTION +{ + double angle; + double radius; + double azimuth; +}; + +/* In all of the following structs, the doubles that express duration + * represent time in seconds. The double that represent levels of intensity + * are between 0.0 and 1.0. + */ + +/* Delay to start the replay and duration of the replay, expressed in seconds. */ +struct ALLEGRO_HAPTIC_REPLAY +{ + double length; + double delay; +}; + +/* Envelope of the effect. */ +struct ALLEGRO_HAPTIC_ENVELOPE +{ + double attack_length; + double attack_level; + double fade_length; + double fade_level; +}; + +/* Constant effect. Level is between 0.0 and 1.0. */ +struct ALLEGRO_HAPTIC_CONSTANT_EFFECT +{ + double level; + struct ALLEGRO_HAPTIC_ENVELOPE envelope; +}; + +/* Ramp effect. Both start_level and end level are between 0.0 and 1.0. */ +struct ALLEGRO_HAPTIC_RAMP_EFFECT +{ + double start_level; + double end_level; + struct ALLEGRO_HAPTIC_ENVELOPE envelope; +}; + +/* Condition effect. */ +struct ALLEGRO_HAPTIC_CONDITION_EFFECT +{ + double right_saturation; + double left_saturation; + double right_coeff; + double left_coeff; + double deadband; + double center; +}; + +/* Periodic (wave) effect. */ +struct ALLEGRO_HAPTIC_PERIODIC_EFFECT +{ + int waveform; + double period; + double magnitude; + double offset; + double phase; + + struct ALLEGRO_HAPTIC_ENVELOPE envelope; + int custom_len; + double *custom_data; +}; + +/* Simple rumble effect with a magnitude between 0.0 and 1.0 for both + * the strong and the weak rumble motors in the haptic device. + */ +struct ALLEGRO_HAPTIC_RUMBLE_EFFECT +{ + double strong_magnitude; + double weak_magnitude; +}; + +union ALLEGRO_HAPTIC_EFFECT_UNION +{ + struct ALLEGRO_HAPTIC_CONSTANT_EFFECT constant; + struct ALLEGRO_HAPTIC_RAMP_EFFECT ramp; + struct ALLEGRO_HAPTIC_PERIODIC_EFFECT periodic; + struct ALLEGRO_HAPTIC_CONDITION_EFFECT condition; + struct ALLEGRO_HAPTIC_RUMBLE_EFFECT rumble; +}; + + +/* Type: ALLEGRO_HAPTIC_EFFECT + */ +struct ALLEGRO_HAPTIC_EFFECT +{ + + int type; + struct ALLEGRO_HAPTIC_DIRECTION direction; + struct ALLEGRO_HAPTIC_REPLAY replay; + union ALLEGRO_HAPTIC_EFFECT_UNION data; +}; + +typedef struct ALLEGRO_HAPTIC_EFFECT ALLEGRO_HAPTIC_EFFECT; + + +/* Type: ALLEGRO_HAPTIC_EFFECT_ID + */ +typedef struct ALLEGRO_HAPTIC_EFFECT_ID ALLEGRO_HAPTIC_EFFECT_ID; + +struct ALLEGRO_HAPTIC_EFFECT_ID +{ + ALLEGRO_HAPTIC *_haptic; + int _id; + int _handle; + void * _pointer; + double _effect_duration; + bool _playing; + double _start_time; + double _end_time; + void * driver; +}; + + +AL_FUNC(bool, al_install_haptic, (void)); +AL_FUNC(void, al_uninstall_haptic, (void)); +AL_FUNC(bool, al_is_haptic_installed, (void)); + +AL_FUNC(bool, al_is_mouse_haptic, (ALLEGRO_MOUSE *)); +AL_FUNC(bool, al_is_joystick_haptic, (ALLEGRO_JOYSTICK *)); +AL_FUNC(bool, al_is_keyboard_haptic, (ALLEGRO_KEYBOARD *)); +AL_FUNC(bool, al_is_display_haptic, (ALLEGRO_DISPLAY *)); +AL_FUNC(bool, al_is_touch_input_haptic, (ALLEGRO_TOUCH_INPUT *)); + +AL_FUNC(ALLEGRO_HAPTIC *, al_get_haptic_from_mouse, (ALLEGRO_MOUSE *)); +AL_FUNC(ALLEGRO_HAPTIC *, al_get_haptic_from_joystick, (ALLEGRO_JOYSTICK *)); +AL_FUNC(ALLEGRO_HAPTIC *, al_get_haptic_from_keyboard, (ALLEGRO_KEYBOARD *)); +AL_FUNC(ALLEGRO_HAPTIC *, al_get_haptic_from_display, (ALLEGRO_DISPLAY *)); +AL_FUNC(ALLEGRO_HAPTIC *, al_get_haptic_from_touch_input, (ALLEGRO_TOUCH_INPUT *)); + +AL_FUNC(bool, al_release_haptic, (ALLEGRO_HAPTIC *)); + +AL_FUNC(bool, al_is_haptic_active, (ALLEGRO_HAPTIC *)); +AL_FUNC(int, al_get_haptic_capabilities, (ALLEGRO_HAPTIC *)); +AL_FUNC(bool, al_is_haptic_capable, (ALLEGRO_HAPTIC *, int)); + +AL_FUNC(bool, al_set_haptic_gain, (ALLEGRO_HAPTIC *, double)); +AL_FUNC(double, al_get_haptic_gain, (ALLEGRO_HAPTIC *)); + +AL_FUNC(bool, al_set_haptic_autocenter, (ALLEGRO_HAPTIC *, double)); +AL_FUNC(double, al_get_haptic_autocenter, (ALLEGRO_HAPTIC *)); + + +AL_FUNC(int, al_get_max_haptic_effects, (ALLEGRO_HAPTIC *)); +AL_FUNC(bool, al_is_haptic_effect_ok, (ALLEGRO_HAPTIC *, ALLEGRO_HAPTIC_EFFECT *)); +AL_FUNC(bool, al_upload_haptic_effect, (ALLEGRO_HAPTIC *, ALLEGRO_HAPTIC_EFFECT *, ALLEGRO_HAPTIC_EFFECT_ID *)); +AL_FUNC(bool, al_play_haptic_effect, (ALLEGRO_HAPTIC_EFFECT_ID *, int)); +AL_FUNC(bool, al_upload_and_play_haptic_effect, (ALLEGRO_HAPTIC *, ALLEGRO_HAPTIC_EFFECT *, ALLEGRO_HAPTIC_EFFECT_ID *, int)); +AL_FUNC(bool, al_stop_haptic_effect, (ALLEGRO_HAPTIC_EFFECT_ID *)); +AL_FUNC(bool, al_is_haptic_effect_playing, (ALLEGRO_HAPTIC_EFFECT_ID *)); +AL_FUNC(bool, al_release_haptic_effect, (ALLEGRO_HAPTIC_EFFECT_ID *)); +AL_FUNC(double, al_get_haptic_effect_duration, (ALLEGRO_HAPTIC_EFFECT *)); +AL_FUNC(bool, al_rumble_haptic, (ALLEGRO_HAPTIC *, double, double, ALLEGRO_HAPTIC_EFFECT_ID *)); + +#endif + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/inline/fmaths.inl b/common/allegro/include/allegro5/inline/fmaths.inl new file mode 100644 index 00000000..6f178945 --- /dev/null +++ b/common/allegro/include/allegro5/inline/fmaths.inl @@ -0,0 +1,254 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Fixed point math inline functions (generic C). + * + * By Shawn Hargreaves. + * + * See readme.txt for copyright information. + */ + + +#ifndef __al_included_allegro5_inline_fmaths_inl +#define __al_included_allegro5_inline_fmaths_inl + +#include "allegro5/error.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +/* al_ftofix and al_fixtof are used in generic C versions of al_fixmul and al_fixdiv */ +AL_INLINE(al_fixed, al_ftofix, (double x), +{ + if (x > 32767.0) { + al_set_errno(ERANGE); + return 0x7FFFFFFF; + } + + if (x < -32767.0) { + al_set_errno(ERANGE); + return -0x7FFFFFFF; + } + + return (al_fixed)(x * 65536.0 + (x < 0 ? -0.5 : 0.5)); +}) + + +AL_INLINE(double, al_fixtof, (al_fixed x), +{ + return (double)x / 65536.0; +}) + + +AL_INLINE(al_fixed, al_fixadd, (al_fixed x, al_fixed y), +{ + al_fixed result = x + y; + + if (result >= 0) { + if ((x < 0) && (y < 0)) { + al_set_errno(ERANGE); + return -0x7FFFFFFF; + } + else + return result; + } + else { + if ((x > 0) && (y > 0)) { + al_set_errno(ERANGE); + return 0x7FFFFFFF; + } + else + return result; + } +}) + + +AL_INLINE(al_fixed, al_fixsub, (al_fixed x, al_fixed y), +{ + al_fixed result = x - y; + + if (result >= 0) { + if ((x < 0) && (y > 0)) { + al_set_errno(ERANGE); + return -0x7FFFFFFF; + } + else + return result; + } + else { + if ((x > 0) && (y < 0)) { + al_set_errno(ERANGE); + return 0x7FFFFFFF; + } + else + return result; + } +}) + + +/* In benchmarks conducted circa May 2005 we found that, in the main: + * - IA32 machines performed faster with one implementation; + * - AMD64 and G4 machines performed faster with another implementation. + * + * Benchmarks were mainly done with differing versions of gcc. + * Results varied with other compilers, optimisation levels, etc. + * so this is not optimal, though a tenable compromise. + * + * Note that the following implementation are NOT what were benchmarked. + * We had forgotten to put in overflow detection in those versions. + * If you don't need overflow detection then previous versions in the + * CVS tree might be worth looking at. + * + * PS. Don't move the #ifs inside the AL_INLINE; BCC doesn't like it. + */ +#if defined ALLEGRO_I386 + AL_INLINE(al_fixed, al_fixmul, (al_fixed x, al_fixed y), + { + return al_ftofix(al_fixtof(x) * al_fixtof(y)); + }) +#else + AL_INLINE(al_fixed, al_fixmul, (al_fixed x, al_fixed y), + { + int64_t lx = x; + int64_t ly = y; + int64_t lres = (lx*ly); + + if (lres > 0x7FFFFFFF0000LL) { + al_set_errno(ERANGE); + return 0x7FFFFFFF; + } + else if (lres < -0x7FFFFFFF0000LL) { + al_set_errno(ERANGE); + return 0x80000000; + } + else { + int res = lres >> 16; + return res; + } + }) +#endif /* al_fixmul() C implementations */ + + +#if defined ALLEGRO_CFG_NO_FPU +AL_INLINE(al_fixed, al_fixdiv, (al_fixed x, al_fixed y), +{ + int64_t lres = x; + if (y == 0) { + al_set_errno(ERANGE); + return (x < 0) ? -0x7FFFFFFF : 0x7FFFFFFF; + } + lres <<= 16; + lres /= y; + if (lres > 0x7FFFFFFF) { + al_set_errno(ERANGE); + return 0x7FFFFFFF; + } + else if (lres < -0x7FFFFFFF) { + al_set_errno(ERANGE); + return 0x80000000; + } + else { + return (al_fixed)(lres); + } +}) +#else +AL_INLINE(al_fixed, al_fixdiv, (al_fixed x, al_fixed y), +{ + if (y == 0) { + al_set_errno(ERANGE); + return (x < 0) ? -0x7FFFFFFF : 0x7FFFFFFF; + } + else + return al_ftofix(al_fixtof(x) / al_fixtof(y)); +}) +#endif + + +AL_INLINE(int, al_fixfloor, (al_fixed x), +{ + /* (x >> 16) is not portable */ + if (x >= 0) + return (x >> 16); + else + return ~((~x) >> 16); +}) + + +AL_INLINE(int, al_fixceil, (al_fixed x), +{ + if (x > 0x7FFF0000) { + al_set_errno(ERANGE); + return 0x7FFF; + } + + return al_fixfloor(x + 0xFFFF); +}) + + +AL_INLINE(al_fixed, al_itofix, (int x), +{ + return x << 16; +}) + + +AL_INLINE(int, al_fixtoi, (al_fixed x), +{ + return al_fixfloor(x) + ((x & 0x8000) >> 15); +}) + + +AL_INLINE(al_fixed, al_fixcos, (al_fixed x), +{ + return _al_fix_cos_tbl[((x + 0x4000) >> 15) & 0x1FF]; +}) + + +AL_INLINE(al_fixed, al_fixsin, (al_fixed x), +{ + return _al_fix_cos_tbl[((x - 0x400000 + 0x4000) >> 15) & 0x1FF]; +}) + + +AL_INLINE(al_fixed, al_fixtan, (al_fixed x), +{ + return _al_fix_tan_tbl[((x + 0x4000) >> 15) & 0xFF]; +}) + + +AL_INLINE(al_fixed, al_fixacos, (al_fixed x), +{ + if ((x < -65536) || (x > 65536)) { + al_set_errno(EDOM); + return 0; + } + + return _al_fix_acos_tbl[(x+65536+127)>>8]; +}) + + +AL_INLINE(al_fixed, al_fixasin, (al_fixed x), +{ + if ((x < -65536) || (x > 65536)) { + al_set_errno(EDOM); + return 0; + } + + return 0x00400000 - _al_fix_acos_tbl[(x+65536+127)>>8]; +}) + +#ifdef __cplusplus + } +#endif + +#endif + + diff --git a/common/allegro/include/allegro5/internal/alconfig.h b/common/allegro/include/allegro5/internal/alconfig.h new file mode 100644 index 00000000..19274e11 --- /dev/null +++ b/common/allegro/include/allegro5/internal/alconfig.h @@ -0,0 +1,253 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Configuration defines. + * + * By Shawn Hargreaves. + * + * See readme.txt for copyright information. + */ + + +/* for backward compatibility */ +#ifdef USE_CONSOLE + #define ALLEGRO_NO_MAGIC_MAIN + #define ALLEGRO_USE_CONSOLE +#endif + + +/* include platform-specific stuff */ + +#include "allegro5/platform/alplatf.h" + + + +#if defined ALLEGRO_WATCOM + #include "allegro5/platform/alwatcom.h" +#elif defined ALLEGRO_MINGW32 + #include "allegro5/platform/almngw32.h" +#elif defined ALLEGRO_BCC32 + #include "allegro5/platform/albcc32.h" +#elif defined ALLEGRO_MSVC + #include "allegro5/platform/almsvc.h" +#elif defined ALLEGRO_IPHONE + #include "allegro5/platform/aliphonecfg.h" +#elif defined ALLEGRO_MACOSX + #include "allegro5/platform/alosxcfg.h" +#elif defined ALLEGRO_ANDROID + #include "allegro5/platform/alandroidcfg.h" +#elif defined ALLEGRO_RASPBERRYPI + #include "allegro5/platform/alraspberrypicfg.h" +#elif defined ALLEGRO_UNIX + #include "allegro5/platform/alucfg.h" +#elif defined ALLEGRO_SDL + #include "allegro5/platform/allegro_sdl_config.h" +#else + #error platform not supported +#endif + + +#include "allegro5/platform/astdint.h" +#include "allegro5/platform/astdbool.h" + + + +/* special definitions for the GCC compiler */ +#ifdef __GNUC__ + #define ALLEGRO_GCC + + #ifndef AL_INLINE + #ifdef __cplusplus + #define AL_INLINE(type, name, args, code) \ + static inline type name args; \ + static inline type name args code + /* Needed if this header is included by C99 code, as + * "extern __inline__" in C99 exports a new global function. + */ + #elif __GNUC_STDC_INLINE__ + #define AL_INLINE(type, name, args, code) \ + extern __inline__ __attribute__((__gnu_inline__)) type name args; \ + extern __inline__ __attribute__((__gnu_inline__)) type name args code + #else + #define AL_INLINE(type, name, args, code) \ + extern __inline__ type name args; \ + extern __inline__ type name args code + #endif + #endif + + #ifndef AL_INLINE_STATIC + #ifdef __cplusplus + #define AL_INLINE_STATIC(type, name, args, code) \ + AL_INLINE(type, name, args, code) + #else + #define AL_INLINE_STATIC(type, name, args, code) \ + static __inline__ type name args; \ + static __inline__ type name args code + #endif + #endif + + #define AL_PRINTFUNC(type, name, args, a, b) AL_FUNC(type, name, args) __attribute__ ((format (printf, a, b))) + + #ifndef INLINE + #define INLINE __inline__ + #endif + + #ifndef ZERO_SIZE_ARRAY + #if __GNUC__ < 3 + #define ZERO_SIZE_ARRAY(type, name) __extension__ type name[0] + #else + #define ZERO_SIZE_ARRAY(type, name) type name[] /* ISO C99 flexible array members */ + #endif + #endif + + #ifdef ALLEGRO_GUESS_INTTYPES_OK + #define int64_t signed long long + #define uint64_t unsigned long long + #endif + + #ifdef __i386__ + #define ALLEGRO_I386 + #endif + + #ifdef __amd64__ + #define ALLEGRO_AMD64 + #endif + + #ifdef __arm__ + #define ALLEGRO_ARM + #endif + + #ifndef AL_FUNC_DEPRECATED + #if (__GNUC__ > 3) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 1)) + #define AL_FUNC_DEPRECATED(type, name, args) AL_FUNC(__attribute__ ((deprecated)) type, name, args) + #define AL_PRINTFUNC_DEPRECATED(type, name, args, a, b) AL_PRINTFUNC(__attribute__ ((deprecated)) type, name, args, a, b) + #define AL_INLINE_DEPRECATED(type, name, args, code) AL_INLINE(__attribute__ ((deprecated)) type, name, args, code) + #endif + #endif + + #ifndef AL_ALIAS + #define AL_ALIAS(DECL, CALL) \ + static __attribute__((unused)) __inline__ DECL \ + { \ + return CALL; \ + } + #endif + + #ifndef AL_ALIAS_VOID_RET + #define AL_ALIAS_VOID_RET(DECL, CALL) \ + static __attribute__((unused)) __inline__ void DECL \ + { \ + CALL; \ + } + #endif +#endif + + +/* the rest of this file fills in some default definitions of language + * features and helper functions, which are conditionalised so they will + * only be included if none of the above headers defined custom versions. + */ + +#ifndef INLINE + #define INLINE +#endif + +#ifndef ZERO_SIZE_ARRAY + #define ZERO_SIZE_ARRAY(type, name) type name[] +#endif + +#ifndef AL_VAR + #define AL_VAR(type, name) extern type name +#endif + +#ifndef AL_ARRAY + #define AL_ARRAY(type, name) extern type name[] +#endif + +#ifndef AL_FUNC + #define AL_FUNC(type, name, args) type name args +#endif + +#ifndef AL_PRINTFUNC + #define AL_PRINTFUNC(type, name, args, a, b) AL_FUNC(type, name, args) +#endif + +#ifndef AL_METHOD + #define AL_METHOD(type, name, args) type (*name) args +#endif + +#ifndef AL_FUNCPTR + #define AL_FUNCPTR(type, name, args) extern type (*name) args +#endif + +#ifndef AL_FUNCPTRARRAY + #define AL_FUNCPTRARRAY(type, name, args) extern type (*name[]) args +#endif + +#ifndef AL_INLINE + #define AL_INLINE(type, name, args, code) type name args; +#endif + +#ifndef AL_FUNC_DEPRECATED + #define AL_FUNC_DEPRECATED(type, name, args) AL_FUNC(type, name, args) + #define AL_PRINTFUNC_DEPRECATED(type, name, args, a, b) AL_PRINTFUNC(type, name, args, a, b) + #define AL_INLINE_DEPRECATED(type, name, args, code) AL_INLINE(type, name, args, code) +#endif + +#ifndef AL_ALIAS + #define AL_ALIAS(DECL, CALL) \ + static INLINE DECL \ + { \ + return CALL; \ + } +#endif + +#ifndef AL_ALIAS_VOID_RET + #define AL_ALIAS_VOID_RET(DECL, CALL) \ + static INLINE void DECL \ + { \ + CALL; \ + } +#endif + + +#ifdef __cplusplus + extern "C" { +#endif + +/* endian-independent 3-byte accessor macros */ +#ifdef ALLEGRO_LITTLE_ENDIAN + + #define _AL_READ3BYTES(p) ((*(unsigned char *)(p)) \ + | (*((unsigned char *)(p) + 1) << 8) \ + | (*((unsigned char *)(p) + 2) << 16)) + + #define _AL_WRITE3BYTES(p,c) ((*(unsigned char *)(p) = (c)), \ + (*((unsigned char *)(p) + 1) = (c) >> 8), \ + (*((unsigned char *)(p) + 2) = (c) >> 16)) + +#elif defined ALLEGRO_BIG_ENDIAN + + #define _AL_READ3BYTES(p) ((*(unsigned char *)(p) << 16) \ + | (*((unsigned char *)(p) + 1) << 8) \ + | (*((unsigned char *)(p) + 2))) + + #define _AL_WRITE3BYTES(p,c) ((*(unsigned char *)(p) = (c) >> 16), \ + (*((unsigned char *)(p) + 1) = (c) >> 8), \ + (*((unsigned char *)(p) + 2) = (c))) + +#else + #error endianess not defined +#endif + +#ifdef __cplusplus + } +#endif + diff --git a/common/allegro/include/allegro5/joystick.h b/common/allegro/include/allegro5/joystick.h new file mode 100644 index 00000000..4b3e648b --- /dev/null +++ b/common/allegro/include/allegro5/joystick.h @@ -0,0 +1,91 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Joystick routines. + * + * See readme.txt for copyright information. + */ + +#ifndef __al_included_allegro5_joystick_h +#define __al_included_allegro5_joystick_h + +#include "allegro5/base.h" +#include "allegro5/events.h" + +#ifdef __cplusplus + extern "C" { +#endif + +/* internal values */ +#define _AL_MAX_JOYSTICK_AXES 3 +#define _AL_MAX_JOYSTICK_STICKS 16 +#define _AL_MAX_JOYSTICK_BUTTONS 32 + + + +/* Type: ALLEGRO_JOYSTICK + */ +typedef struct ALLEGRO_JOYSTICK ALLEGRO_JOYSTICK; + + + +/* Type: ALLEGRO_JOYSTICK_STATE + */ +typedef struct ALLEGRO_JOYSTICK_STATE ALLEGRO_JOYSTICK_STATE; + +struct ALLEGRO_JOYSTICK_STATE +{ + struct { + float axis[_AL_MAX_JOYSTICK_AXES]; /* -1.0 to 1.0 */ + } stick[_AL_MAX_JOYSTICK_STICKS]; + int button[_AL_MAX_JOYSTICK_BUTTONS]; /* 0 to 32767 */ +}; + + +/* Enum: ALLEGRO_JOYFLAGS + */ +enum ALLEGRO_JOYFLAGS +{ + ALLEGRO_JOYFLAG_DIGITAL = 0x01, + ALLEGRO_JOYFLAG_ANALOGUE = 0x02 +}; + + + +AL_FUNC(bool, al_install_joystick, (void)); +AL_FUNC(void, al_uninstall_joystick, (void)); +AL_FUNC(bool, al_is_joystick_installed, (void)); +AL_FUNC(bool, al_reconfigure_joysticks, (void)); + +AL_FUNC(int, al_get_num_joysticks, (void)); +AL_FUNC(ALLEGRO_JOYSTICK *, al_get_joystick, (int joyn)); +AL_FUNC(void, al_release_joystick, (ALLEGRO_JOYSTICK *)); +AL_FUNC(bool, al_get_joystick_active, (ALLEGRO_JOYSTICK *)); +AL_FUNC(const char*, al_get_joystick_name, (ALLEGRO_JOYSTICK *)); + +AL_FUNC(int, al_get_joystick_num_sticks, (ALLEGRO_JOYSTICK *)); +AL_FUNC(int, al_get_joystick_stick_flags, (ALLEGRO_JOYSTICK *, int stick)); /* junk? */ +AL_FUNC(const char*, al_get_joystick_stick_name, (ALLEGRO_JOYSTICK *, int stick)); + +AL_FUNC(int, al_get_joystick_num_axes, (ALLEGRO_JOYSTICK *, int stick)); +AL_FUNC(const char*, al_get_joystick_axis_name, (ALLEGRO_JOYSTICK *, int stick, int axis)); + +AL_FUNC(int, al_get_joystick_num_buttons, (ALLEGRO_JOYSTICK *)); +AL_FUNC(const char*, al_get_joystick_button_name, (ALLEGRO_JOYSTICK *, int buttonn)); + +AL_FUNC(void, al_get_joystick_state, (ALLEGRO_JOYSTICK *, ALLEGRO_JOYSTICK_STATE *ret_state)); + +AL_FUNC(ALLEGRO_EVENT_SOURCE *, al_get_joystick_event_source, (void)); + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/keyboard.h b/common/allegro/include/allegro5/keyboard.h new file mode 100644 index 00000000..17cd274b --- /dev/null +++ b/common/allegro/include/allegro5/keyboard.h @@ -0,0 +1,70 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Keyboard routines. + * + * See readme.txt for copyright information. + */ + +#ifndef __al_included_allegro5_keyboard_h +#define __al_included_allegro5_keyboard_h + +#include "allegro5/base.h" +#include "allegro5/events.h" +#include "allegro5/keycodes.h" + +#ifdef __cplusplus + extern "C" { +#endif + +typedef struct ALLEGRO_KEYBOARD ALLEGRO_KEYBOARD; + + + +/* Type: ALLEGRO_KEYBOARD_STATE + */ +typedef struct ALLEGRO_KEYBOARD_STATE ALLEGRO_KEYBOARD_STATE; + +struct ALLEGRO_KEYBOARD_STATE +{ + struct ALLEGRO_DISPLAY *display; /* public */ + /* internal */ + unsigned int __key_down__internal__[(ALLEGRO_KEY_MAX + 31) / 32]; +}; + + +AL_FUNC(bool, al_is_keyboard_installed, (void)); +AL_FUNC(bool, al_install_keyboard, (void)); +AL_FUNC(void, al_uninstall_keyboard, (void)); + +AL_FUNC(bool, al_set_keyboard_leds, (int leds)); + +AL_FUNC(const char *, al_keycode_to_name, (int keycode)); + +AL_FUNC(void, al_get_keyboard_state, (ALLEGRO_KEYBOARD_STATE *ret_state)); +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_SRC) +AL_FUNC(void, al_clear_keyboard_state, (ALLEGRO_DISPLAY *display)); +#endif +AL_FUNC(bool, al_key_down, (const ALLEGRO_KEYBOARD_STATE *, int keycode)); + +AL_FUNC(ALLEGRO_EVENT_SOURCE *, al_get_keyboard_event_source, (void)); + +#ifdef __cplusplus + } +#endif + +#endif + +/* + * Local Variables: + * c-basic-offset: 3 + * indent-tabs-mode: nil + * End: + */ diff --git a/common/allegro/include/allegro5/keycodes.h b/common/allegro/include/allegro5/keycodes.h new file mode 100644 index 00000000..0a899017 --- /dev/null +++ b/common/allegro/include/allegro5/keycodes.h @@ -0,0 +1,214 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Keycode constants. + * + * See readme.txt for copyright information. + */ + + +#ifndef __al_included_allegro5_keycodes_h +#define __al_included_allegro5_keycodes_h + + + +/* Note these values are deliberately the same as in Allegro 4.1.x */ +enum +{ + ALLEGRO_KEY_A = 1, + ALLEGRO_KEY_B = 2, + ALLEGRO_KEY_C = 3, + ALLEGRO_KEY_D = 4, + ALLEGRO_KEY_E = 5, + ALLEGRO_KEY_F = 6, + ALLEGRO_KEY_G = 7, + ALLEGRO_KEY_H = 8, + ALLEGRO_KEY_I = 9, + ALLEGRO_KEY_J = 10, + ALLEGRO_KEY_K = 11, + ALLEGRO_KEY_L = 12, + ALLEGRO_KEY_M = 13, + ALLEGRO_KEY_N = 14, + ALLEGRO_KEY_O = 15, + ALLEGRO_KEY_P = 16, + ALLEGRO_KEY_Q = 17, + ALLEGRO_KEY_R = 18, + ALLEGRO_KEY_S = 19, + ALLEGRO_KEY_T = 20, + ALLEGRO_KEY_U = 21, + ALLEGRO_KEY_V = 22, + ALLEGRO_KEY_W = 23, + ALLEGRO_KEY_X = 24, + ALLEGRO_KEY_Y = 25, + ALLEGRO_KEY_Z = 26, + + ALLEGRO_KEY_0 = 27, + ALLEGRO_KEY_1 = 28, + ALLEGRO_KEY_2 = 29, + ALLEGRO_KEY_3 = 30, + ALLEGRO_KEY_4 = 31, + ALLEGRO_KEY_5 = 32, + ALLEGRO_KEY_6 = 33, + ALLEGRO_KEY_7 = 34, + ALLEGRO_KEY_8 = 35, + ALLEGRO_KEY_9 = 36, + + ALLEGRO_KEY_PAD_0 = 37, + ALLEGRO_KEY_PAD_1 = 38, + ALLEGRO_KEY_PAD_2 = 39, + ALLEGRO_KEY_PAD_3 = 40, + ALLEGRO_KEY_PAD_4 = 41, + ALLEGRO_KEY_PAD_5 = 42, + ALLEGRO_KEY_PAD_6 = 43, + ALLEGRO_KEY_PAD_7 = 44, + ALLEGRO_KEY_PAD_8 = 45, + ALLEGRO_KEY_PAD_9 = 46, + + ALLEGRO_KEY_F1 = 47, + ALLEGRO_KEY_F2 = 48, + ALLEGRO_KEY_F3 = 49, + ALLEGRO_KEY_F4 = 50, + ALLEGRO_KEY_F5 = 51, + ALLEGRO_KEY_F6 = 52, + ALLEGRO_KEY_F7 = 53, + ALLEGRO_KEY_F8 = 54, + ALLEGRO_KEY_F9 = 55, + ALLEGRO_KEY_F10 = 56, + ALLEGRO_KEY_F11 = 57, + ALLEGRO_KEY_F12 = 58, + + ALLEGRO_KEY_ESCAPE = 59, + ALLEGRO_KEY_TILDE = 60, + ALLEGRO_KEY_MINUS = 61, + ALLEGRO_KEY_EQUALS = 62, + ALLEGRO_KEY_BACKSPACE = 63, + ALLEGRO_KEY_TAB = 64, + ALLEGRO_KEY_OPENBRACE = 65, + ALLEGRO_KEY_CLOSEBRACE = 66, + ALLEGRO_KEY_ENTER = 67, + ALLEGRO_KEY_SEMICOLON = 68, + ALLEGRO_KEY_QUOTE = 69, + ALLEGRO_KEY_BACKSLASH = 70, + ALLEGRO_KEY_BACKSLASH2 = 71, /* DirectInput calls this DIK_OEM_102: "< > | on UK/Germany keyboards" */ + ALLEGRO_KEY_COMMA = 72, + ALLEGRO_KEY_FULLSTOP = 73, + ALLEGRO_KEY_SLASH = 74, + ALLEGRO_KEY_SPACE = 75, + + ALLEGRO_KEY_INSERT = 76, + ALLEGRO_KEY_DELETE = 77, + ALLEGRO_KEY_HOME = 78, + ALLEGRO_KEY_END = 79, + ALLEGRO_KEY_PGUP = 80, + ALLEGRO_KEY_PGDN = 81, + ALLEGRO_KEY_LEFT = 82, + ALLEGRO_KEY_RIGHT = 83, + ALLEGRO_KEY_UP = 84, + ALLEGRO_KEY_DOWN = 85, + + ALLEGRO_KEY_PAD_SLASH = 86, + ALLEGRO_KEY_PAD_ASTERISK = 87, + ALLEGRO_KEY_PAD_MINUS = 88, + ALLEGRO_KEY_PAD_PLUS = 89, + ALLEGRO_KEY_PAD_DELETE = 90, + ALLEGRO_KEY_PAD_ENTER = 91, + + ALLEGRO_KEY_PRINTSCREEN = 92, + ALLEGRO_KEY_PAUSE = 93, + + ALLEGRO_KEY_ABNT_C1 = 94, + ALLEGRO_KEY_YEN = 95, + ALLEGRO_KEY_KANA = 96, + ALLEGRO_KEY_CONVERT = 97, + ALLEGRO_KEY_NOCONVERT = 98, + ALLEGRO_KEY_AT = 99, + ALLEGRO_KEY_CIRCUMFLEX = 100, + ALLEGRO_KEY_COLON2 = 101, + ALLEGRO_KEY_KANJI = 102, + + ALLEGRO_KEY_PAD_EQUALS = 103, /* MacOS X */ + ALLEGRO_KEY_BACKQUOTE = 104, /* MacOS X */ + ALLEGRO_KEY_SEMICOLON2 = 105, /* MacOS X -- TODO: ask lillo what this should be */ + ALLEGRO_KEY_COMMAND = 106, /* MacOS X */ + + ALLEGRO_KEY_BACK = 107, /* Android back key */ + ALLEGRO_KEY_VOLUME_UP = 108, + ALLEGRO_KEY_VOLUME_DOWN = 109, + + /* Android game keys */ + ALLEGRO_KEY_SEARCH = 110, + ALLEGRO_KEY_DPAD_CENTER = 111, + ALLEGRO_KEY_BUTTON_X = 112, + ALLEGRO_KEY_BUTTON_Y = 113, + ALLEGRO_KEY_DPAD_UP = 114, + ALLEGRO_KEY_DPAD_DOWN = 115, + ALLEGRO_KEY_DPAD_LEFT = 116, + ALLEGRO_KEY_DPAD_RIGHT = 117, + ALLEGRO_KEY_SELECT = 118, + ALLEGRO_KEY_START = 119, + ALLEGRO_KEY_BUTTON_L1 = 120, + ALLEGRO_KEY_BUTTON_R1 = 121, + ALLEGRO_KEY_BUTTON_L2 = 122, + ALLEGRO_KEY_BUTTON_R2 = 123, + ALLEGRO_KEY_BUTTON_A = 124, + ALLEGRO_KEY_BUTTON_B = 125, + ALLEGRO_KEY_THUMBL = 126, + ALLEGRO_KEY_THUMBR = 127, + + ALLEGRO_KEY_UNKNOWN = 128, + + /* All codes up to before ALLEGRO_KEY_MODIFIERS can be freely + * assignedas additional unknown keys, like various multimedia + * and application keys keyboards may have. + */ + + ALLEGRO_KEY_MODIFIERS = 215, + + ALLEGRO_KEY_LSHIFT = 215, + ALLEGRO_KEY_RSHIFT = 216, + ALLEGRO_KEY_LCTRL = 217, + ALLEGRO_KEY_RCTRL = 218, + ALLEGRO_KEY_ALT = 219, + ALLEGRO_KEY_ALTGR = 220, + ALLEGRO_KEY_LWIN = 221, + ALLEGRO_KEY_RWIN = 222, + ALLEGRO_KEY_MENU = 223, + ALLEGRO_KEY_SCROLLLOCK = 224, + ALLEGRO_KEY_NUMLOCK = 225, + ALLEGRO_KEY_CAPSLOCK = 226, + + ALLEGRO_KEY_MAX +}; + + + +enum +{ + ALLEGRO_KEYMOD_SHIFT = 0x00001, + ALLEGRO_KEYMOD_CTRL = 0x00002, + ALLEGRO_KEYMOD_ALT = 0x00004, + ALLEGRO_KEYMOD_LWIN = 0x00008, + ALLEGRO_KEYMOD_RWIN = 0x00010, + ALLEGRO_KEYMOD_MENU = 0x00020, + ALLEGRO_KEYMOD_ALTGR = 0x00040, + ALLEGRO_KEYMOD_COMMAND = 0x00080, + ALLEGRO_KEYMOD_SCROLLLOCK = 0x00100, + ALLEGRO_KEYMOD_NUMLOCK = 0x00200, + ALLEGRO_KEYMOD_CAPSLOCK = 0x00400, + ALLEGRO_KEYMOD_INALTSEQ = 0x00800, + ALLEGRO_KEYMOD_ACCENT1 = 0x01000, + ALLEGRO_KEYMOD_ACCENT2 = 0x02000, + ALLEGRO_KEYMOD_ACCENT3 = 0x04000, + ALLEGRO_KEYMOD_ACCENT4 = 0x08000 +}; + + + +#endif diff --git a/common/allegro/include/allegro5/memory.h b/common/allegro/include/allegro5/memory.h new file mode 100644 index 00000000..869f6c26 --- /dev/null +++ b/common/allegro/include/allegro5/memory.h @@ -0,0 +1,75 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Memory management routines. + * + * See readme.txt for copyright information. + */ + +#ifndef __al_included_allegro5_memory_h +#define __al_included_allegro5_memory_h + +#include "allegro5/base.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +/* Type: ALLEGRO_MEMORY_INTERFACE + */ +typedef struct ALLEGRO_MEMORY_INTERFACE ALLEGRO_MEMORY_INTERFACE; + +struct ALLEGRO_MEMORY_INTERFACE { + void *(*mi_malloc)(size_t n, int line, const char *file, const char *func); + void (*mi_free)(void *ptr, int line, const char *file, const char *func); + void *(*mi_realloc)(void *ptr, size_t n, int line, const char *file, const char *func); + void *(*mi_calloc)(size_t count, size_t n, int line, const char *file, const char *func); +}; + +AL_FUNC(void, al_set_memory_interface, (ALLEGRO_MEMORY_INTERFACE *iface)); + + +/* Function: al_malloc + */ +#define al_malloc(n) \ + (al_malloc_with_context((n), __LINE__, __FILE__, __func__)) + +/* Function: al_free + */ +#define al_free(p) \ + (al_free_with_context((p), __LINE__, __FILE__, __func__)) + +/* Function: al_realloc + */ +#define al_realloc(p, n) \ + (al_realloc_with_context((p), (n), __LINE__, __FILE__, __func__)) + +/* Function: al_calloc + */ +#define al_calloc(c, n) \ + (al_calloc_with_context((c), (n), __LINE__, __FILE__, __func__)) + + +AL_FUNC(void *, al_malloc_with_context, (size_t n, + int line, const char *file, const char *func)); +AL_FUNC(void, al_free_with_context, (void *ptr, + int line, const char *file, const char *func)); +AL_FUNC(void *, al_realloc_with_context, (void *ptr, size_t n, + int line, const char *file, const char *func)); +AL_FUNC(void *, al_calloc_with_context, (size_t count, size_t n, + int line, const char *file, const char *func)); + + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/monitor.h b/common/allegro/include/allegro5/monitor.h new file mode 100644 index 00000000..fcbb5270 --- /dev/null +++ b/common/allegro/include/allegro5/monitor.h @@ -0,0 +1,35 @@ +#ifndef __al_included_allegro5_monitor_h +#define __al_included_allegro5_monitor_h + +#include "allegro5/base.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +/* Type: ALLEGRO_MONITOR_INFO + */ +typedef struct ALLEGRO_MONITOR_INFO +{ + int x1; + int y1; + int x2; + int y2; +} ALLEGRO_MONITOR_INFO; + +enum { + ALLEGRO_DEFAULT_DISPLAY_ADAPTER = -1 +}; + +AL_FUNC(int, al_get_num_video_adapters, (void)); +AL_FUNC(bool, al_get_monitor_info, (int adapter, ALLEGRO_MONITOR_INFO *info)); + + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set ts=8 sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/mouse.h b/common/allegro/include/allegro5/mouse.h new file mode 100644 index 00000000..307d6902 --- /dev/null +++ b/common/allegro/include/allegro5/mouse.h @@ -0,0 +1,82 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Mouse routines. + * + * See readme.txt for copyright information. + */ + +#ifndef __al_included_allegro5_mouse_h +#define __al_included_allegro5_mouse_h + +#include "allegro5/base.h" +#include "allegro5/events.h" + +#ifdef __cplusplus + extern "C" { +#endif + +/* Allow up to four extra axes for future expansion. */ +#define ALLEGRO_MOUSE_MAX_EXTRA_AXES 4 + + +typedef struct ALLEGRO_MOUSE ALLEGRO_MOUSE; + + +/* Type: ALLEGRO_MOUSE_STATE + */ +typedef struct ALLEGRO_MOUSE_STATE ALLEGRO_MOUSE_STATE; + +struct ALLEGRO_MOUSE_STATE +{ + /* (x, y) Primary mouse position + * (z) Mouse wheel position (1D 'wheel'), or, + * (w, z) Mouse wheel position (2D 'ball') + * display - the display the mouse is on (coordinates are relative to this) + * pressure - the pressure applied to the mouse (for stylus/tablet) + */ + int x; + int y; + int z; + int w; + int more_axes[ALLEGRO_MOUSE_MAX_EXTRA_AXES]; + int buttons; + float pressure; + struct ALLEGRO_DISPLAY *display; +}; + + +AL_FUNC(bool, al_is_mouse_installed, (void)); +AL_FUNC(bool, al_install_mouse, (void)); +AL_FUNC(void, al_uninstall_mouse, (void)); +AL_FUNC(unsigned int, al_get_mouse_num_buttons, (void)); +AL_FUNC(unsigned int, al_get_mouse_num_axes, (void)); +AL_FUNC(bool, al_set_mouse_xy, (struct ALLEGRO_DISPLAY *display, int x, int y)); +AL_FUNC(bool, al_set_mouse_z, (int z)); +AL_FUNC(bool, al_set_mouse_w, (int w)); +AL_FUNC(bool, al_set_mouse_axis, (int axis, int value)); +AL_FUNC(void, al_get_mouse_state, (ALLEGRO_MOUSE_STATE *ret_state)); +AL_FUNC(bool, al_mouse_button_down, (const ALLEGRO_MOUSE_STATE *state, int button)); +AL_FUNC(int, al_get_mouse_state_axis, (const ALLEGRO_MOUSE_STATE *state, int axis)); +AL_FUNC(bool, al_get_mouse_cursor_position, (int *ret_x, int *ret_y)); +AL_FUNC(bool, al_grab_mouse, (struct ALLEGRO_DISPLAY *display)); +AL_FUNC(bool, al_ungrab_mouse, (void)); +AL_FUNC(void, al_set_mouse_wheel_precision, (int precision)); +AL_FUNC(int, al_get_mouse_wheel_precision, (void)); + +AL_FUNC(ALLEGRO_EVENT_SOURCE *, al_get_mouse_event_source, (void)); + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/mouse_cursor.h b/common/allegro/include/allegro5/mouse_cursor.h new file mode 100644 index 00000000..69c7043c --- /dev/null +++ b/common/allegro/include/allegro5/mouse_cursor.h @@ -0,0 +1,58 @@ +#ifndef __al_included_allegro5_mouse_cursor_h +#define __al_included_allegro5_mouse_cursor_h + +#include "allegro5/base.h" + +#ifdef __cplusplus + extern "C" { +#endif + +typedef struct ALLEGRO_MOUSE_CURSOR ALLEGRO_MOUSE_CURSOR; + +typedef enum ALLEGRO_SYSTEM_MOUSE_CURSOR +{ + ALLEGRO_SYSTEM_MOUSE_CURSOR_NONE = 0, + ALLEGRO_SYSTEM_MOUSE_CURSOR_DEFAULT = 1, + ALLEGRO_SYSTEM_MOUSE_CURSOR_ARROW = 2, + ALLEGRO_SYSTEM_MOUSE_CURSOR_BUSY = 3, + ALLEGRO_SYSTEM_MOUSE_CURSOR_QUESTION = 4, + ALLEGRO_SYSTEM_MOUSE_CURSOR_EDIT = 5, + ALLEGRO_SYSTEM_MOUSE_CURSOR_MOVE = 6, + ALLEGRO_SYSTEM_MOUSE_CURSOR_RESIZE_N = 7, + ALLEGRO_SYSTEM_MOUSE_CURSOR_RESIZE_W = 8, + ALLEGRO_SYSTEM_MOUSE_CURSOR_RESIZE_S = 9, + ALLEGRO_SYSTEM_MOUSE_CURSOR_RESIZE_E = 10, + ALLEGRO_SYSTEM_MOUSE_CURSOR_RESIZE_NW = 11, + ALLEGRO_SYSTEM_MOUSE_CURSOR_RESIZE_SW = 12, + ALLEGRO_SYSTEM_MOUSE_CURSOR_RESIZE_SE = 13, + ALLEGRO_SYSTEM_MOUSE_CURSOR_RESIZE_NE = 14, + ALLEGRO_SYSTEM_MOUSE_CURSOR_PROGRESS = 15, + ALLEGRO_SYSTEM_MOUSE_CURSOR_PRECISION = 16, + ALLEGRO_SYSTEM_MOUSE_CURSOR_LINK = 17, + ALLEGRO_SYSTEM_MOUSE_CURSOR_ALT_SELECT = 18, + ALLEGRO_SYSTEM_MOUSE_CURSOR_UNAVAILABLE = 19, + ALLEGRO_NUM_SYSTEM_MOUSE_CURSORS +} ALLEGRO_SYSTEM_MOUSE_CURSOR; + +struct ALLEGRO_BITMAP; +struct ALLEGRO_DISPLAY; + + +AL_FUNC(ALLEGRO_MOUSE_CURSOR *, al_create_mouse_cursor, ( + struct ALLEGRO_BITMAP *sprite, int xfocus, int yfocus)); +AL_FUNC(void, al_destroy_mouse_cursor, (ALLEGRO_MOUSE_CURSOR *)); +AL_FUNC(bool, al_set_mouse_cursor, (struct ALLEGRO_DISPLAY *display, + ALLEGRO_MOUSE_CURSOR *cursor)); +AL_FUNC(bool, al_set_system_mouse_cursor, (struct ALLEGRO_DISPLAY *display, + ALLEGRO_SYSTEM_MOUSE_CURSOR cursor_id)); +AL_FUNC(bool, al_show_mouse_cursor, (struct ALLEGRO_DISPLAY *display)); +AL_FUNC(bool, al_hide_mouse_cursor, (struct ALLEGRO_DISPLAY *display)); + + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/opengl/GLext/gl_ext_alias.h b/common/allegro/include/allegro5/opengl/GLext/gl_ext_alias.h new file mode 100644 index 00000000..90f6b71f --- /dev/null +++ b/common/allegro/include/allegro5/opengl/GLext/gl_ext_alias.h @@ -0,0 +1,2565 @@ +/*Automatically generated by gl_mkalias.sh DO NOT EDIT!*/ +/**/ + +#ifdef _ALLEGRO_GL_VERSION_1_2 +#define glBlendColor _al_glBlendColor +#define glBlendEquation _al_glBlendEquation +#define glDrawRangeElements _al_glDrawRangeElements +#define glColorTable _al_glColorTable +#define glColorTableParameterfv _al_glColorTableParameterfv +#define glColorTableParameteriv _al_glColorTableParameteriv +#define glCopyColorTable _al_glCopyColorTable +#define glGetColorTable _al_glGetColorTable +#define glGetColorTableParameterfv _al_glGetColorTableParameterfv +#define glGetColorTableParameteriv _al_glGetColorTableParameteriv +#define glColorSubTable _al_glColorSubTable +#define glCopyColorSubTable _al_glCopyColorSubTable +#define glTexImage3D _al_glTexImage3D +#define glTexSubImage3D _al_glTexSubImage3D +#define glCopyTexSubImage3D _al_glCopyTexSubImage3D +#endif + +#if defined _ALLEGRO_GL_ARB_imaging +#define glConvolutionFilter1D _al_glConvolutionFilter1D +#define glConvolutionFilter2D _al_glConvolutionFilter2D +#define glConvolutionParameterf _al_glConvolutionParameterf +#define glConvolutionParameterfv _al_glConvolutionParameterfv +#define glConvolutionParameteri _al_glConvolutionParameteri +#define glConvolutionParameteriv _al_glConvolutionParameteriv +#define glCopyConvolutionFilter1D _al_glCopyConvolutionFilter1D +#define glCopyConvolutionFilter2D _al_glCopyConvolutionFilter2D +#define glGetConvolutionFilter _al_glGetConvolutionFilter +#define glGetConvolutionParameterfv _al_glGetConvolutionParameterfv +#define glGetConvolutionParameteriv _al_glGetConvolutionParameteriv +#define glGetSeparableFilter _al_glGetSeparableFilter +#define glSeparableFilter2D _al_glSeparableFilter2D +#define glGetHistogram _al_glGetHistogram +#define glGetHistogramParameterfv _al_glGetHistogramParameterfv +#define glGetHistogramParameteriv _al_glGetHistogramParameteriv +#define glGetMinmax _al_glGetMinmax +#define glGetMinmaxParameterfv _al_glGetMinmaxParameterfv +#define glGetMinmaxParameteriv _al_glGetMinmaxParameteriv +#define glHistogram _al_glHistogram +#define glMinmax _al_glMinmax +#define glResetHistogram _al_glResetHistogram +#define glResetMinmax _al_glResetMinmax +#endif + +#if defined _ALLEGRO_GL_VERSION_1_3 +#define glActiveTexture _al_glActiveTexture +#define glClientActiveTexture _al_glClientActiveTexture +#define glMultiTexCoord1d _al_glMultiTexCoord1d +#define glMultiTexCoord1dv _al_glMultiTexCoord1dv +#define glMultiTexCoord1f _al_glMultiTexCoord1f +#define glMultiTexCoord1fv _al_glMultiTexCoord1fv +#define glMultiTexCoord1i _al_glMultiTexCoord1i +#define glMultiTexCoord1iv _al_glMultiTexCoord1iv +#define glMultiTexCoord1s _al_glMultiTexCoord1s +#define glMultiTexCoord1sv _al_glMultiTexCoord1sv +#define glMultiTexCoord2d _al_glMultiTexCoord2d +#define glMultiTexCoord2dv _al_glMultiTexCoord2dv +#define glMultiTexCoord2f _al_glMultiTexCoord2f +#define glMultiTexCoord2fv _al_glMultiTexCoord2fv +#define glMultiTexCoord2i _al_glMultiTexCoord2i +#define glMultiTexCoord2iv _al_glMultiTexCoord2iv +#define glMultiTexCoord2s _al_glMultiTexCoord2s +#define glMultiTexCoord2sv _al_glMultiTexCoord2sv +#define glMultiTexCoord3d _al_glMultiTexCoord3d +#define glMultiTexCoord3dv _al_glMultiTexCoord3dv +#define glMultiTexCoord3f _al_glMultiTexCoord3f +#define glMultiTexCoord3fv _al_glMultiTexCoord3fv +#define glMultiTexCoord3i _al_glMultiTexCoord3i +#define glMultiTexCoord3iv _al_glMultiTexCoord3iv +#define glMultiTexCoord3s _al_glMultiTexCoord3s +#define glMultiTexCoord3sv _al_glMultiTexCoord3sv +#define glMultiTexCoord4d _al_glMultiTexCoord4d +#define glMultiTexCoord4dv _al_glMultiTexCoord4dv +#define glMultiTexCoord4f _al_glMultiTexCoord4f +#define glMultiTexCoord4fv _al_glMultiTexCoord4fv +#define glMultiTexCoord4i _al_glMultiTexCoord4i +#define glMultiTexCoord4iv _al_glMultiTexCoord4iv +#define glMultiTexCoord4s _al_glMultiTexCoord4s +#define glMultiTexCoord4sv _al_glMultiTexCoord4sv +#define glLoadTransposeMatrixf _al_glLoadTransposeMatrixf +#define glLoadTransposeMatrixd _al_glLoadTransposeMatrixd +#define glMultTransposeMatrixf _al_glMultTransposeMatrixf +#define glMultTransposeMatrixd _al_glMultTransposeMatrixd +#define glSampleCoverage _al_glSampleCoverage +#define glCompressedTexImage3D _al_glCompressedTexImage3D +#define glCompressedTexImage2D _al_glCompressedTexImage2D +#define glCompressedTexImage1D _al_glCompressedTexImage1D +#define glCompressedTexSubImage3D _al_glCompressedTexSubImage3D +#define glCompressedTexSubImage2D _al_glCompressedTexSubImage2D +#define glCompressedTexSubImage1D _al_glCompressedTexSubImage1D +#define glGetCompressedTexImage _al_glGetCompressedTexImage +#endif + +#if defined _ALLEGRO_GL_VERSION_1_4 +#define glBlendFuncSeparate _al_glBlendFuncSeparate +#define glFogCoordf _al_glFogCoordf +#define glFogCoordfv _al_glFogCoordfv +#define glFogCoordd _al_glFogCoordd +#define glFogCoorddv _al_glFogCoorddv +#define glFogCoordPointer _al_glFogCoordPointer +#define glMultiDrawArrays _al_glMultiDrawArrays +#define glMultiDrawElements _al_glMultiDrawElements +#define glPointParameterf _al_glPointParameterf +#define glPointParameterfv _al_glPointParameterfv +#define glPointParameteri _al_glPointParameteri +#define glPointParameteriv _al_glPointParameteriv +#define glSecondaryColor3b _al_glSecondaryColor3b +#define glSecondaryColor3bv _al_glSecondaryColor3bv +#define glSecondaryColor3d _al_glSecondaryColor3d +#define glSecondaryColor3dv _al_glSecondaryColor3dv +#define glSecondaryColor3f _al_glSecondaryColor3f +#define glSecondaryColor3fv _al_glSecondaryColor3fv +#define glSecondaryColor3i _al_glSecondaryColor3i +#define glSecondaryColor3iv _al_glSecondaryColor3iv +#define glSecondaryColor3s _al_glSecondaryColor3s +#define glSecondaryColor3sv _al_glSecondaryColor3sv +#define glSecondaryColor3ub _al_glSecondaryColor3ub +#define glSecondaryColor3ubv _al_glSecondaryColor3ubv +#define glSecondaryColor3ui _al_glSecondaryColor3ui +#define glSecondaryColor3uiv _al_glSecondaryColor3uiv +#define glSecondaryColor3us _al_glSecondaryColor3us +#define glSecondaryColor3usv _al_glSecondaryColor3usv +#define glSecondaryColorPointer _al_glSecondaryColorPointer +#define glWindowPos2d _al_glWindowPos2d +#define glWindowPos2dv _al_glWindowPos2dv +#define glWindowPos2f _al_glWindowPos2f +#define glWindowPos2fv _al_glWindowPos2fv +#define glWindowPos2i _al_glWindowPos2i +#define glWindowPos2iv _al_glWindowPos2iv +#define glWindowPos2s _al_glWindowPos2s +#define glWindowPos2sv _al_glWindowPos2sv +#define glWindowPos3d _al_glWindowPos3d +#define glWindowPos3dv _al_glWindowPos3dv +#define glWindowPos3f _al_glWindowPos3f +#define glWindowPos3fv _al_glWindowPos3fv +#define glWindowPos3i _al_glWindowPos3i +#define glWindowPos3iv _al_glWindowPos3iv +#define glWindowPos3s _al_glWindowPos3s +#define glWindowPos3sv _al_glWindowPos3sv +#endif + + +#if defined _ALLEGRO_GL_VERSION_1_5 +#define glBindBuffer _al_glBindBuffer +#define glDeleteBuffers _al_glDeleteBuffers +#define glGenBuffers _al_glGenBuffers +#define glIsBuffer _al_glIsBuffer +#define glBufferData _al_glBufferData +#define glBufferSubData _al_glBufferSubData +#define glGetBufferSubData _al_glGetBufferSubData +#define glMapBuffer _al_glMapBuffer +#define glUnmapBuffer _al_glUnmapBuffer +#define glGetBufferParameteriv _al_glGetBufferParameteriv +#define glGetBufferPointerv _al_glGetBufferPointerv +#define glGenQueries _al_glGenQueries +#define glDeleteQueries _al_glDeleteQueries +#define glIsQuery _al_glIsQuery +#define glBeginQuery _al_glBeginQuery +#define glEndQuery _al_glEndQuery +#define glGetQueryiv _al_glGetQueryiv +#define glGetQueryObjectiv _al_glGetQueryObjectiv +#define glGetQueryObjectuiv _al_glGetQueryObjectuiv +#endif + + +#if defined _ALLEGRO_GL_VERSION_2_0 +#define glBlendEquationSeparate _al_glBlendEquationSeparate +#define glCreateProgram _al_glCreateProgram +#define glCreateShader _al_glCreateShader +#define glDeleteProgram _al_glDeleteProgram +#define glDeleteShader _al_glDeleteShader +#define glAttachShader _al_glAttachShader +#define glDetachShader _al_glDetachShader +#define glShaderSource _al_glShaderSource +#define glCompileShader _al_glCompileShader +#define glIsProgram _al_glIsProgram +#define glIsShader _al_glIsShader +#define glLinkProgram _al_glLinkProgram +#define glUseProgram _al_glUseProgram +#define glValidateProgram _al_glValidateProgram +#define glUniform1f _al_glUniform1f +#define glUniform2f _al_glUniform2f +#define glUniform3f _al_glUniform3f +#define glUniform4f _al_glUniform4f +#define glUniform1i _al_glUniform1i +#define glUniform2i _al_glUniform2i +#define glUniform3i _al_glUniform3i +#define glUniform4i _al_glUniform4i +#define glUniform1fv _al_glUniform1fv +#define glUniform2fv _al_glUniform2fv +#define glUniform3fv _al_glUniform3fv +#define glUniform4fv _al_glUniform4fv +#define glUniform1iv _al_glUniform1iv +#define glUniform2iv _al_glUniform2iv +#define glUniform3iv _al_glUniform3iv +#define glUniform4iv _al_glUniform4iv +#define glUniformMatrix2fv _al_glUniformMatrix2fv +#define glUniformMatrix3fv _al_glUniformMatrix3fv +#define glUniformMatrix4fv _al_glUniformMatrix4fv +#define glGetShaderfv _al_glGetShaderfv +#define glGetShaderiv _al_glGetShaderiv +#define glGetProgramfv _al_glGetProgramfv +#define glGetProgramiv _al_glGetProgramiv +#define glGetShaderInfoLog _al_glGetShaderInfoLog +#define glGetProgramInfoLog _al_glGetProgramInfoLog +#define glGetAttachedShaders _al_glGetAttachedShaders +#define glGetUniformLocation _al_glGetUniformLocation +#define glGetActiveUniform _al_glGetActiveUniform +#define glGetUniformfv _al_glGetUniformfv +#define glGetUniformiv _al_glGetUniformiv +#define glGetShaderSource _al_glGetShaderSource +#define glVertexAttrib1f _al_glVertexAttrib1f +#define glVertexAttrib1s _al_glVertexAttrib1s +#define glVertexAttrib1d _al_glVertexAttrib1d +#define glVertexAttrib2f _al_glVertexAttrib2f +#define glVertexAttrib2s _al_glVertexAttrib2s +#define glVertexAttrib2d _al_glVertexAttrib2d +#define glVertexAttrib3f _al_glVertexAttrib3f +#define glVertexAttrib3s _al_glVertexAttrib3s +#define glVertexAttrib3d _al_glVertexAttrib3d +#define glVertexAttrib4f _al_glVertexAttrib4f +#define glVertexAttrib4s _al_glVertexAttrib4s +#define glVertexAttrib4d _al_glVertexAttrib4d +#define glVertexAttrib4Nub _al_glVertexAttrib4Nub +#define glVertexAttrib1fv _al_glVertexAttrib1fv +#define glVertexAttrib1sv _al_glVertexAttrib1sv +#define glVertexAttrib1dv _al_glVertexAttrib1dv +#define glVertexAttrib2fv _al_glVertexAttrib2fv +#define glVertexAttrib2sv _al_glVertexAttrib2sv +#define glVertexAttrib2dv _al_glVertexAttrib2dv +#define glVertexAttrib3fv _al_glVertexAttrib3fv +#define glVertexAttrib3sv _al_glVertexAttrib3sv +#define glVertexAttrib3dv _al_glVertexAttrib3dv +#define glVertexAttrib4fv _al_glVertexAttrib4fv +#define glVertexAttrib4sv _al_glVertexAttrib4sv +#define glVertexAttrib4dv _al_glVertexAttrib4dv +#define glVertexAttrib4iv _al_glVertexAttrib4iv +#define glVertexAttrib4bv _al_glVertexAttrib4bv +#define glVertexAttrib4ubv _al_glVertexAttrib4ubv +#define glVertexAttrib4usv _al_glVertexAttrib4usv +#define glVertexAttrib4uiv _al_glVertexAttrib4uiv +#define glVertexAttrib4Nbv _al_glVertexAttrib4Nbv +#define glVertexAttrib4Nsv _al_glVertexAttrib4Nsv +#define glVertexAttrib4Niv _al_glVertexAttrib4Niv +#define glVertexAttrib4Nubv _al_glVertexAttrib4Nubv +#define glVertexAttrib4Nusv _al_glVertexAttrib4Nusv +#define glVertexAttrib4Nuiv _al_glVertexAttrib4Nuiv +#define glVertexAttribPointer _al_glVertexAttribPointer +#define glEnableVertexAttribArray _al_glEnableVertexAttribArray +#define glDisableVertexAttribArray _al_glDisableVertexAttribArray + +#define glBindAttribLocation _al_glBindAttribLocation +#define glGetActiveAttrib _al_glGetActiveAttrib +#define glGetAttribLocation _al_glGetAttribLocation +#define glGetVertexAttribdv _al_glGetVertexAttribdv +#define glGetVertexAttribfv _al_glGetVertexAttribfv +#define glGetVertexAttribiv _al_glGetVertexAttribiv +#define glGetVertexAttribPointerv _al_glGetVertexAttribPointerv + +#define glDrawBuffers _al_glDrawBuffers + +#define glStencilOpSeparate _al_glStencilOpSeparate +#define glStencilFuncSeparate _al_glStencilFuncSeparate +#define glStencilMaskSeparate _al_glStencilMaskSeparate + +#endif + + +#if defined _ALLEGRO_GL_VERSION_2_1 +#define glUniformMatrix2x3fv _al_glUniformMatrix2x3fv +#define glUniformMatrix3x2fv _al_glUniformMatrix3x2fv +#define glUniformMatrix2x4fv _al_glUniformMatrix2x4fv +#define glUniformMatrix4x2fv _al_glUniformMatrix4x2fv +#define glUniformMatrix3x4fv _al_glUniformMatrix3x4fv +#define glUniformMatrix4x3fv _al_glUniformMatrix4x3fv +#endif + +#if defined _ALLEGRO_GL_VERSION_3_0 +/*OpenGL3.0alsoreusesentrypointsfromtheseextensions:*/ +/*ARB_framebuffer_object*/ +/*ARB_map_buffer_range*/ +/*ARB_vertex_array_object*/ +#define glColorMaski _al_glColorMaski +#define glGetBooleani_v _al_glGetBooleani_v +#define glGetIntegeri_v _al_glGetIntegeri_v +#define glEnablei _al_glEnablei +#define glDisablei _al_glDisablei +#define glIsEnabledi _al_glIsEnabledi +#define glBeginTransformFeedback _al_glBeginTransformFeedback +#define glEndTransformFeedback _al_glEndTransformFeedback +#define glBindBufferRange _al_glBindBufferRange +#define glBindBufferBase _al_glBindBufferBase +#define glTransformFeedbackVaryings _al_glTransformFeedbackVaryings +#define glGetTransformFeedbackVarying _al_glGetTransformFeedbackVarying +#define glClampColor _al_glClampColor +#define glBeginConditionalRender _al_glBeginConditionalRender +#define glEndConditionalRender _al_glEndConditionalRender +#define glVertexAttribI1i _al_glVertexAttribI1i +#define glVertexAttribI2i _al_glVertexAttribI2i +#define glVertexAttribI3i _al_glVertexAttribI3i +#define glVertexAttribI4i _al_glVertexAttribI4i +#define glVertexAttribI1ui _al_glVertexAttribI1ui +#define glVertexAttribI2ui _al_glVertexAttribI2ui +#define glVertexAttribI3ui _al_glVertexAttribI3ui +#define glVertexAttribI4ui _al_glVertexAttribI4ui +#define glVertexAttribI1iv _al_glVertexAttribI1iv +#define glVertexAttribI2iv _al_glVertexAttribI2iv +#define glVertexAttribI3iv _al_glVertexAttribI3iv +#define glVertexAttribI4iv _al_glVertexAttribI4iv +#define glVertexAttribI1uiv _al_glVertexAttribI1uiv +#define glVertexAttribI2uiv _al_glVertexAttribI2uiv +#define glVertexAttribI3uiv _al_glVertexAttribI3uiv +#define glVertexAttribI4uiv _al_glVertexAttribI4uiv +#define glVertexAttribI4bv _al_glVertexAttribI4bv +#define glVertexAttribI4sv _al_glVertexAttribI4sv +#define glVertexAttribI4ubv _al_glVertexAttribI4ubv +#define glVertexAttribI4usv _al_glVertexAttribI4usv +#define glVertexAttribIPointer _al_glVertexAttribIPointer +#define glGetVertexAttribIiv _al_glGetVertexAttribIiv +#define glGetVertexAttribIuiv _al_glGetVertexAttribIuiv +#define glGetUniformuiv _al_glGetUniformuiv +#define glBindFragDataLocation _al_glBindFragDataLocation +#define glGetFragDataLocation _al_glGetFragDataLocation +#define glUniform1ui _al_glUniform1ui +#define glUniform2ui _al_glUniform2ui +#define glUniform3ui _al_glUniform3ui +#define glUniform4ui _al_glUniform4ui +#define glUniform1uiv _al_glUniform1uiv +#define glUniform2uiv _al_glUniform2uiv +#define glUniform3uiv _al_glUniform3uiv +#define glUniform4uiv _al_glUniform4uiv +#define glTexParameterIiv _al_glTexParameterIiv +#define glTexParameterIuiv _al_glTexParameterIuiv +#define glGetTexParameterIiv _al_glGetTexParameterIiv +#define glGetTexParameterIuiv _al_glGetTexParameterIuiv +#define glClearBufferiv _al_glClearBufferiv +#define glClearBufferuiv _al_glClearBufferuiv +#define glClearBufferfv _al_glClearBufferfv +#define glClearBufferfi _al_glClearBufferfi +#define glGetStringi _al_glGetStringi +#endif + + +#if defined _ALLEGRO_GL_VERSION_3_1 +/*OpenGL3.1alsoreusesentrypointsfromtheseextensions:*/ +/*ARB_copy_buffer*/ +/*ARB_uniform_buffer_object*/ +#define glDrawArraysInstanced _al_glDrawArraysInstanced +#define glDrawElementsInstanced _al_glDrawElementsInstanced +#define glTexBuffer _al_glTexBuffer +#define glPrimitiveRestartIndex _al_glPrimitiveRestartIndex +#endif + +#if defined _ALLEGRO_GL_VERSION_3_2 +/*OpenGL3.2alsoreusesentrypointsfromtheseextensions:*/ +/*ARB_draw_elements_base_vertex*/ +/*ARB_provoking_vertex*/ +/*ARB_sync*/ +/*ARB_texture_multisample*/ +#define glGetInteger64i_v _al_glGetInteger64i_v +#define glGetBufferParameteri64v _al_glGetBufferParameteri64v +#define glProgramParameteri _al_glProgramParameteri +#define glFramebufferTexture _al_glFramebufferTexture +#endif + +#if defined _ALLEGRO_GL_VERSION_3_3 +/*OpenGL3.3alsoreusesentrypointsfromtheseextensions:*/ +/*ARB_blend_func_extended*/ +/*ARB_sampler_objects*/ +/*ARB_explicit_attrib_location,butithasnone*/ +/*ARB_occlusion_query2(noentrypoints)*/ +/*ARB_shader_bit_encoding(noentrypoints)*/ +/*ARB_texture_rgb10_a2ui(noentrypoints)*/ +/*ARB_texture_swizzle(noentrypoints)*/ +/*ARB_timer_query*/ +/*ARB_vertex_type_2_10_10_10_rev*/ +#endif + + +/**/ +/**/ + +#ifdef _ALLEGRO_GL_ARB_multitexture +#define glActiveTextureARB _al_glActiveTextureARB +#define glClientActiveTextureARB _al_glClientActiveTextureARB +#define glMultiTexCoord1dARB _al_glMultiTexCoord1dARB +#define glMultiTexCoord1dvARB _al_glMultiTexCoord1dvARB +#define glMultiTexCoord1fARB _al_glMultiTexCoord1fARB +#define glMultiTexCoord1fvARB _al_glMultiTexCoord1fvARB +#define glMultiTexCoord1iARB _al_glMultiTexCoord1iARB +#define glMultiTexCoord1ivARB _al_glMultiTexCoord1ivARB +#define glMultiTexCoord1sARB _al_glMultiTexCoord1sARB +#define glMultiTexCoord1svARB _al_glMultiTexCoord1svARB +#define glMultiTexCoord2dARB _al_glMultiTexCoord2dARB +#define glMultiTexCoord2dvARB _al_glMultiTexCoord2dvARB +#define glMultiTexCoord2fARB _al_glMultiTexCoord2fARB +#define glMultiTexCoord2fvARB _al_glMultiTexCoord2fvARB +#define glMultiTexCoord2iARB _al_glMultiTexCoord2iARB +#define glMultiTexCoord2ivARB _al_glMultiTexCoord2ivARB +#define glMultiTexCoord2sARB _al_glMultiTexCoord2sARB +#define glMultiTexCoord2svARB _al_glMultiTexCoord2svARB +#define glMultiTexCoord3dARB _al_glMultiTexCoord3dARB +#define glMultiTexCoord3dvARB _al_glMultiTexCoord3dvARB +#define glMultiTexCoord3fARB _al_glMultiTexCoord3fARB +#define glMultiTexCoord3fvARB _al_glMultiTexCoord3fvARB +#define glMultiTexCoord3iARB _al_glMultiTexCoord3iARB +#define glMultiTexCoord3ivARB _al_glMultiTexCoord3ivARB +#define glMultiTexCoord3sARB _al_glMultiTexCoord3sARB +#define glMultiTexCoord3svARB _al_glMultiTexCoord3svARB +#define glMultiTexCoord4dARB _al_glMultiTexCoord4dARB +#define glMultiTexCoord4dvARB _al_glMultiTexCoord4dvARB +#define glMultiTexCoord4fARB _al_glMultiTexCoord4fARB +#define glMultiTexCoord4fvARB _al_glMultiTexCoord4fvARB +#define glMultiTexCoord4iARB _al_glMultiTexCoord4iARB +#define glMultiTexCoord4ivARB _al_glMultiTexCoord4ivARB +#define glMultiTexCoord4sARB _al_glMultiTexCoord4sARB +#define glMultiTexCoord4svARB _al_glMultiTexCoord4svARB +#endif + +#if defined _ALLEGRO_GL_ARB_transpose_matrix +#define glLoadTransposeMatrixfARB _al_glLoadTransposeMatrixfARB +#define glLoadTransposeMatrixdARB _al_glLoadTransposeMatrixdARB +#define glMultTransposeMatrixfARB _al_glMultTransposeMatrixfARB +#define glMultTransposeMatrixdARB _al_glMultTransposeMatrixdARB +#endif + +#if defined _ALLEGRO_GL_ARB_multisample +#define glSampleCoverageARB _al_glSampleCoverageARB +#endif + +#if defined _ALLEGRO_GL_ARB_texture_compression +#define glCompressedTexImage3DARB _al_glCompressedTexImage3DARB +#define glCompressedTexImage2DARB _al_glCompressedTexImage2DARB +#define glCompressedTexImage1DARB _al_glCompressedTexImage1DARB +#define glCompressedTexSubImage3DARB _al_glCompressedTexSubImage3DARB +#define glCompressedTexSubImage2DARB _al_glCompressedTexSubImage2DARB +#define glCompressedTexSubImage1DARB _al_glCompressedTexSubImage1DARB +#define glGetCompressedTexImageARB _al_glGetCompressedTexImageARB +#endif + +#if defined _ALLEGRO_GL_ARB_point_parameters +#define glPointParameterfARB _al_glPointParameterfARB +#define glPointParameterfvARB _al_glPointParameterfvARB +#endif + +#if defined _ALLEGRO_GL_ARB_vertex_blend +#define glWeightbvARB _al_glWeightbvARB +#define glWeightsvARB _al_glWeightsvARB +#define glWeightivARB _al_glWeightivARB +#define glWeightfvARB _al_glWeightfvARB +#define glWeightdvARB _al_glWeightdvARB +#define glWeightubvARB _al_glWeightubvARB +#define glWeightusvARB _al_glWeightusvARB +#define glWeightuivARB _al_glWeightuivARB +#define glWeightPointerARB _al_glWeightPointerARB +#define glVertexBlendARB _al_glVertexBlendARB +#endif + +#if defined _ALLEGRO_GL_ARB_matrix_palette +#define glCurrentPaletteMatrixARB _al_glCurrentPaletteMatrixARB +#define glMatrixIndexubvARB _al_glMatrixIndexubvARB +#define glMatrixIndexusvARB _al_glMatrixIndexusvARB +#define glMatrixIndexuivARB _al_glMatrixIndexuivARB +#define glMatrixIndexPointerARB _al_glMatrixIndexPointerARB +#endif + +#if defined _ALLEGRO_GL_ARB_window_pos +#define glWindowPos2dARB _al_glWindowPos2dARB +#define glWindowPos2dvARB _al_glWindowPos2dvARB +#define glWindowPos2fARB _al_glWindowPos2fARB +#define glWindowPos2fvARB _al_glWindowPos2fvARB +#define glWindowPos2iARB _al_glWindowPos2iARB +#define glWindowPos2ivARB _al_glWindowPos2ivARB +#define glWindowPos2sARB _al_glWindowPos2sARB +#define glWindowPos2svARB _al_glWindowPos2svARB +#define glWindowPos3dARB _al_glWindowPos3dARB +#define glWindowPos3dvARB _al_glWindowPos3dvARB +#define glWindowPos3fARB _al_glWindowPos3fARB +#define glWindowPos3fvARB _al_glWindowPos3fvARB +#define glWindowPos3iARB _al_glWindowPos3iARB +#define glWindowPos3ivARB _al_glWindowPos3ivARB +#define glWindowPos3sARB _al_glWindowPos3sARB +#define glWindowPos3svARB _al_glWindowPos3svARB +#endif + +#if defined _ALLEGRO_GL_ARB_vertex_program +#define glVertexAttrib1dARB _al_glVertexAttrib1dARB +#define glVertexAttrib1dvARB _al_glVertexAttrib1dvARB +#define glVertexAttrib1fARB _al_glVertexAttrib1fARB +#define glVertexAttrib1fvARB _al_glVertexAttrib1fvARB +#define glVertexAttrib1sARB _al_glVertexAttrib1sARB +#define glVertexAttrib1svARB _al_glVertexAttrib1svARB +#define glVertexAttrib2dARB _al_glVertexAttrib2dARB +#define glVertexAttrib2dvARB _al_glVertexAttrib2dvARB +#define glVertexAttrib2fARB _al_glVertexAttrib2fARB +#define glVertexAttrib2fvARB _al_glVertexAttrib2fvARB +#define glVertexAttrib2sARB _al_glVertexAttrib2sARB +#define glVertexAttrib2svARB _al_glVertexAttrib2svARB +#define glVertexAttrib3dARB _al_glVertexAttrib3dARB +#define glVertexAttrib3dvARB _al_glVertexAttrib3dvARB +#define glVertexAttrib3fARB _al_glVertexAttrib3fARB +#define glVertexAttrib3fvARB _al_glVertexAttrib3fvARB +#define glVertexAttrib3sARB _al_glVertexAttrib3sARB +#define glVertexAttrib3svARB _al_glVertexAttrib3svARB +#define glVertexAttrib4NbvARB _al_glVertexAttrib4NbvARB +#define glVertexAttrib4NivARB _al_glVertexAttrib4NivARB +#define glVertexAttrib4NsvARB _al_glVertexAttrib4NsvARB +#define glVertexAttrib4NubARB _al_glVertexAttrib4NubARB +#define glVertexAttrib4NubvARB _al_glVertexAttrib4NubvARB +#define glVertexAttrib4NuivARB _al_glVertexAttrib4NuivARB +#define glVertexAttrib4NusvARB _al_glVertexAttrib4NusvARB +#define glVertexAttrib4bvARB _al_glVertexAttrib4bvARB +#define glVertexAttrib4dARB _al_glVertexAttrib4dARB +#define glVertexAttrib4dvARB _al_glVertexAttrib4dvARB +#define glVertexAttrib4fARB _al_glVertexAttrib4fARB +#define glVertexAttrib4fvARB _al_glVertexAttrib4fvARB +#define glVertexAttrib4ivARB _al_glVertexAttrib4ivARB +#define glVertexAttrib4sARB _al_glVertexAttrib4sARB +#define glVertexAttrib4svARB _al_glVertexAttrib4svARB +#define glVertexAttrib4ubvARB _al_glVertexAttrib4ubvARB +#define glVertexAttrib4uivARB _al_glVertexAttrib4uivARB +#define glVertexAttrib4usvARB _al_glVertexAttrib4usvARB +#define glVertexAttribPointerARB _al_glVertexAttribPointerARB +#define glEnableVertexAttribArrayARB _al_glEnableVertexAttribArrayARB +#define glDisableVertexAttribArrayARB _al_glDisableVertexAttribArrayARB +#define glProgramStringARB _al_glProgramStringARB +#define glBindProgramARB _al_glBindProgramARB +#define glDeleteProgramsARB _al_glDeleteProgramsARB +#define glGenProgramsARB _al_glGenProgramsARB +#define glProgramEnvParameter4dARB _al_glProgramEnvParameter4dARB +#define glProgramEnvParameter4dvARB _al_glProgramEnvParameter4dvARB +#define glProgramEnvParameter4fARB _al_glProgramEnvParameter4fARB +#define glProgramEnvParameter4fvARB _al_glProgramEnvParameter4fvARB +#define glProgramLocalParameter4dARB _al_glProgramLocalParameter4dARB +#define glProgramLocalParameter4dvARB _al_glProgramLocalParameter4dvARB +#define glProgramLocalParameter4fARB _al_glProgramLocalParameter4fARB +#define glProgramLocalParameter4fvARB _al_glProgramLocalParameter4fvARB +#define glGetProgramEnvParameterdvARB _al_glGetProgramEnvParameterdvARB +#define glGetProgramEnvParameterfvARB _al_glGetProgramEnvParameterfvARB +#define glGetProgramLocalParameterdvARB _al_glGetProgramLocalParameterdvARB +#define glGetProgramLocalParameterfvARB _al_glGetProgramLocalParameterfvARB +#define glGetProgramivARB _al_glGetProgramivARB +#define glGetProgramStringARB _al_glGetProgramStringARB +#define glGetVertexAttribdvARB _al_glGetVertexAttribdvARB +#define glGetVertexAttribfvARB _al_glGetVertexAttribfvARB +#define glGetVertexAttribivARB _al_glGetVertexAttribivARB +#define glGetVertexAttribPointervARB _al_glGetVertexAttribPointervARB +#define glIsProgramARB _al_glIsProgramARB +#endif + +#if defined _ALLEGRO_GL_ARB_vertex_buffer_object +#define glBindBufferARB _al_glBindBufferARB +#define glDeleteBuffersARB _al_glDeleteBuffersARB +#define glGenBuffersARB _al_glGenBuffersARB +#define glIsBufferARB _al_glIsBufferARB +#define glBufferDataARB _al_glBufferDataARB +#define glBufferSubDataARB _al_glBufferSubDataARB +#define glGetBufferSubDataARB _al_glGetBufferSubDataARB +#define glMapBufferARB _al_glMapBufferARB +#define glUnmapBufferARB _al_glUnmapBufferARB +#define glGetBufferParameterivARB _al_glGetBufferParameterivARB +#define glGetBufferPointervARB _al_glGetBufferPointervARB +#endif + +#if defined _ALLEGRO_GL_ARB_occlusion_query +#define glGenQueriesARB _al_glGenQueriesARB +#define glDeleteQueriesARB _al_glDeleteQueriesARB +#define glIsQueryARB _al_glIsQueryARB +#define glBeginQueryARB _al_glBeginQueryARB +#define glEndQueryARB _al_glEndQueryARB +#define glGetQueryivARB _al_glGetQueryivARB +#define glGetQueryObjectivARB _al_glGetQueryObjectivARB +#define glGetQueryObjectuivARB _al_glGetQueryObjectuivARB +#endif + +#if defined _ALLEGRO_GL_ARB_shader_objects +#define glDeleteObjectARB _al_glDeleteObjectARB +#define glGetHandleARB _al_glGetHandleARB +#define glDetachObjectARB _al_glDetachObjectARB +#define glCreateShaderObjectARB _al_glCreateShaderObjectARB +#define glShaderSourceARB _al_glShaderSourceARB +#define glCompileShaderARB _al_glCompileShaderARB +#define glCreateProgramObjectARB _al_glCreateProgramObjectARB +#define glAttachObjectARB _al_glAttachObjectARB +#define glLinkProgramARB _al_glLinkProgramARB +#define glUseProgramObjectARB _al_glUseProgramObjectARB +#define glValidateProgramARB _al_glValidateProgramARB +#define glUniform1fARB _al_glUniform1fARB +#define glUniform2fARB _al_glUniform2fARB +#define glUniform3fARB _al_glUniform3fARB +#define glUniform4fARB _al_glUniform4fARB +#define glUniform1iARB _al_glUniform1iARB +#define glUniform2iARB _al_glUniform2iARB +#define glUniform3iARB _al_glUniform3iARB +#define glUniform4iARB _al_glUniform4iARB +#define glUniform1fvARB _al_glUniform1fvARB +#define glUniform2fvARB _al_glUniform2fvARB +#define glUniform3fvARB _al_glUniform3fvARB +#define glUniform4fvARB _al_glUniform4fvARB +#define glUniform1ivARB _al_glUniform1ivARB +#define glUniform2ivARB _al_glUniform2ivARB +#define glUniform3ivARB _al_glUniform3ivARB +#define glUniform4ivARB _al_glUniform4ivARB +#define glUniformMatrix2fvARB _al_glUniformMatrix2fvARB +#define glUniformMatrix3fvARB _al_glUniformMatrix3fvARB +#define glUniformMatrix4fvARB _al_glUniformMatrix4fvARB +#define glGetObjectParameterfvARB _al_glGetObjectParameterfvARB +#define glGetObjectParameterivARB _al_glGetObjectParameterivARB +#define glGetInfoLogARB _al_glGetInfoLogARB +#define glGetAttachedObjectsARB _al_glGetAttachedObjectsARB +#define glGetUniformLocationARB _al_glGetUniformLocationARB +#define glGetActiveUniformARB _al_glGetActiveUniformARB +#define glGetUniformfvARB _al_glGetUniformfvARB +#define glGetUniformivARB _al_glGetUniformivARB +#define glGetShaderSourceARB _al_glGetShaderSourceARB +#endif + +#ifdef _ALLEGRO_GL_ARB_vertex_shader +#ifndef GL_ARB_vertex_program +#define glVertexAttrib1fARB _al_glVertexAttrib1fARB +#define glVertexAttrib1sARB _al_glVertexAttrib1sARB +#define glVertexAttrib1dARB _al_glVertexAttrib1dARB +#define glVertexAttrib2fARB _al_glVertexAttrib2fARB +#define glVertexAttrib2sARB _al_glVertexAttrib2sARB +#define glVertexAttrib2dARB _al_glVertexAttrib2dARB +#define glVertexAttrib3fARB _al_glVertexAttrib3fARB +#define glVertexAttrib3sARB _al_glVertexAttrib3sARB +#define glVertexAttrib3dARB _al_glVertexAttrib3dARB +#define glVertexAttrib4fARB _al_glVertexAttrib4fARB +#define glVertexAttrib4sARB _al_glVertexAttrib4sARB +#define glVertexAttrib4dARB _al_glVertexAttrib4dARB +#define glVertexAttrib4NubARB _al_glVertexAttrib4NubARB +#define glVertexAttrib1fvARB _al_glVertexAttrib1fvARB +#define glVertexAttrib1svARB _al_glVertexAttrib1svARB +#define glVertexAttrib1dvARB _al_glVertexAttrib1dvARB +#define glVertexAttrib2fvARB _al_glVertexAttrib2fvARB +#define glVertexAttrib2svARB _al_glVertexAttrib2svARB +#define glVertexAttrib2dvARB _al_glVertexAttrib2dvARB +#define glVertexAttrib3fvARB _al_glVertexAttrib3fvARB +#define glVertexAttrib3svARB _al_glVertexAttrib3svARB +#define glVertexAttrib3dvARB _al_glVertexAttrib3dvARB +#define glVertexAttrib4fvARB _al_glVertexAttrib4fvARB +#define glVertexAttrib4svARB _al_glVertexAttrib4svARB +#define glVertexAttrib4dvARB _al_glVertexAttrib4dvARB +#define glVertexAttrib4ivARB _al_glVertexAttrib4ivARB +#define glVertexAttrib4bvARB _al_glVertexAttrib4bvARB +#define glVertexAttrib4ubvARB _al_glVertexAttrib4ubvARB +#define glVertexAttrib4usvARB _al_glVertexAttrib4usvARB +#define glVertexAttrib4uivARB _al_glVertexAttrib4uivARB +#define glVertexAttrib4NbvARB _al_glVertexAttrib4NbvARB +#define glVertexAttrib4NsvARB _al_glVertexAttrib4NsvARB +#define glVertexAttrib4NivARB _al_glVertexAttrib4NivARB +#define glVertexAttrib4NubvARB _al_glVertexAttrib4NubvARB +#define glVertexAttrib4NusvARB _al_glVertexAttrib4NusvARB +#define glVertexAttrib4NuivARB _al_glVertexAttrib4NuivARB +#define glVertexAttribPointerARB _al_glVertexAttribPointerARB +#define glEnableVertexAttribArrayARB _al_glEnableVertexAttribArrayARB +#define glDisableVertexAttribArrayARB _al_glDisableVertexAttribArrayARB +#endif +#define glBindAttribLocationARB _al_glBindAttribLocationARB +#define glGetActiveAttribARB _al_glGetActiveAttribARB +#define glGetAttribLocationARB _al_glGetAttribLocationARB +#ifndef GL_ARB_vertex_program +#define glGetVertexAttribdvARB _al_glGetVertexAttribdvARB +#define glGetVertexAttribfvARB _al_glGetVertexAttribfvARB +#define glGetVertexAttribivARB _al_glGetVertexAttribivARB +#define glGetVertexAttribPointervARB _al_glGetVertexAttribPointervARB +#endif +#endif + +#if defined _ALLEGRO_GL_ARB_draw_buffers +#define glDrawBuffersARB _al_glDrawBuffersARB +#endif + +#if defined _ALLEGRO_GL_ARB_color_buffer_float +#define glClampColorARB _al_glClampColorARB +#endif + +#if defined _ALLEGRO_GL_ARB_draw_instanced +#define glDrawArraysInstancedARB _al_glDrawArraysInstancedARB +#define glDrawElementsInstancedARB _al_glDrawElementsInstancedARB +#endif + +#if defined _ALLEGRO_GL_ARB_framebuffer_object +#define glIsRenderbuffer _al_glIsRenderbuffer +#define glBindRenderbuffer _al_glBindRenderbuffer +#define glDeleteRenderbuffers _al_glDeleteRenderbuffers +#define glGenRenderbuffers _al_glGenRenderbuffers +#define glRenderbufferStorage _al_glRenderbufferStorage +#define glGetRenderbufferParameteriv _al_glGetRenderbufferParameteriv +#define glIsFramebuffer _al_glIsFramebuffer +#define glBindFramebuffer _al_glBindFramebuffer +#define glDeleteFramebuffers _al_glDeleteFramebuffers +#define glGenFramebuffers _al_glGenFramebuffers +#define glCheckFramebufferStatus _al_glCheckFramebufferStatus +#define glFramebufferTexture1D _al_glFramebufferTexture1D +#define glFramebufferTexture2D _al_glFramebufferTexture2D +#define glFramebufferTexture3D _al_glFramebufferTexture3D +#define glFramebufferRenderbuffer _al_glFramebufferRenderbuffer +#define glGetFramebufferAttachmentParameteriv _al_glGetFramebufferAttachmentParameteriv +#define glGenerateMipmap _al_glGenerateMipmap +#define glBlitFramebuffer _al_glBlitFramebuffer +#define glRenderbufferStorageMultisample _al_glRenderbufferStorageMultisample +#define glFramebufferTextureLayer _al_glFramebufferTextureLayer +#endif + +#if defined _ALLEGRO_GL_ARB_geometry_shader4 +#define glProgramParameteriARB _al_glProgramParameteriARB +#define glFramebufferTextureARB _al_glFramebufferTextureARB +#define glFramebufferTextureLayerARB _al_glFramebufferTextureLayerARB +#define glFramebufferTextureFaceARB _al_glFramebufferTextureFaceARB +#endif + +#if defined _ALLEGRO_GL_ARB_instanced_arrays +#define glVertexAttribDivisor _al_glVertexAttribDivisor +#endif + +#if defined _ALLEGRO_GL_ARB_map_buffer_range +#define glMapBufferRange _al_glMapBufferRange +#define glFlushMappedBufferRange _al_glFlushMappedBufferRange +#endif + +#if defined _ALLEGRO_GL_ARB_texture_buffer_object +#define glTexBufferARB _al_glTexBufferARB +#endif + +#if defined _ALLEGRO_GL_ARB_vertex_array_object +#define glBindVertexArray _al_glBindVertexArray +#define glDeleteVertexArrays _al_glDeleteVertexArrays +#define glGenVertexArrays _al_glGenVertexArrays +#define glIsVertexArray _al_glIsVertexArray +#endif + +#if defined _ALLEGRO_GL_ARB_uniform_buffer_object +#define glGetUniformIndices _al_glGetUniformIndices +#define glGetActiveUniformsiv _al_glGetActiveUniformsiv +#define glGetActiveUniformName _al_glGetActiveUniformName +#define glGetUniformBlockIndex _al_glGetUniformBlockIndex +#define glGetActiveUniformBlockiv _al_glGetActiveUniformBlockiv +#define glGetActiveUniformBlockName _al_glGetActiveUniformBlockName +#define glUniformBlockBinding _al_glUniformBlockBinding +#endif + +#if defined _ALLEGRO_GL_ARB_copy_buffer +#define glCopyBufferSubData _al_glCopyBufferSubData +#endif + + +#if defined _ALLEGRO_GL_ARB_draw_elements_base_vertex +#define glDrawElementsBaseVertex _al_glDrawElementsBaseVertex +#define glDrawRangeElementsBaseVertex _al_glDrawRangeElementsBaseVertex +#define glDrawElementsInstancedBaseVertex _al_glDrawElementsInstancedBaseVertex +#define glMultiDrawElementsBaseVertex _al_glMultiDrawElementsBaseVertex +#endif + +#if defined _ALLEGRO_GL_ARB_provoking_vertex +#define glProvokingVertex _al_glProvokingVertex +#endif + +#if defined _ALLEGRO_GL_ARB_sync +#define glFenceSync _al_glFenceSync +#define glIsSync _al_glIsSync +#define glDeleteSync _al_glDeleteSync +#define glClientWaitSync _al_glClientWaitSync +#define glWaitSync _al_glWaitSync +#define glGetInteger64v _al_glGetInteger64v +#define glGetSynciv _al_glGetSynciv +#endif + +#if defined _ALLEGRO_GL_ARB_texture_multisample +#define glTexImage2DMultisample _al_glTexImage2DMultisample +#define glTexImage3DMultisample _al_glTexImage3DMultisample +#define glGetMultisamplefv _al_glGetMultisamplefv +#define glSampleMaski _al_glSampleMaski +#endif + +#if defined _ALLEGRO_GL_ARB_draw_buffers_blend +#define glBlendEquationi _al_glBlendEquationi +#define glBlendEquationSeparatei _al_glBlendEquationSeparatei +#define glBlendFunci _al_glBlendFunci +#define glBlendFuncSeparatei _al_glBlendFuncSeparatei +#endif + +#if defined _ALLEGRO_GL_ARB_sample_shading +#define glMinSampleShading _al_glMinSampleShading +#endif + +#if defined _ALLEGRO_GL_ARB_shading_language_include +#define glNamedStringARB _al_glNamedStringARB +#define glDeleteNamedStringARB _al_glDeleteNamedStringARB +#define glCompileShaderIncludeARB _al_glCompileShaderIncludeARB +#define glIsNamedStringARB _al_glIsNamedStringARB +#define glGetNamedStringARB _al_glGetNamedStringARB +#define glGetNamedStringivARB _al_glGetNamedStringivARB +#endif + +#if defined _ALLEGRO_GL_ARB_blend_func_extended +#define glBindFragDataLocationIndexed _al_glBindFragDataLocationIndexed +#define glGetFragDataIndex _al_glGetFragDataIndex +#endif + +#if defined _ALLEGRO_GL_ARB_sampler_objects +#define glGenSamplers _al_glGenSamplers +#define glDeleteSamplers _al_glDeleteSamplers +#define glIsSampler _al_glIsSampler +#define glBindSampler _al_glBindSampler +#define glSamplerParameteri _al_glSamplerParameteri +#define glSamplerParameteriv _al_glSamplerParameteriv +#define glSamplerParameterf _al_glSamplerParameterf +#define glSamplerParameterfv _al_glSamplerParameterfv +#define glSamplerParameterIiv _al_glSamplerParameterIiv +#define glSamplerParameterIuiv _al_glSamplerParameterIuiv +#define glGetSamplerParameteriv _al_glGetSamplerParameteriv +#define glGetSamplerParameterIiv _al_glGetSamplerParameterIiv +#define glGetSamplerParameterfv _al_glGetSamplerParameterfv +#define glGetSamplerParameterIfv _al_glGetSamplerParameterIfv +#endif + +#if defined _ALLEGRO_GL_ARB_timer_query +#define glQueryCounter _al_glQueryCounter +#define glGetQueryObjecti64v _al_glGetQueryObjecti64v +#define glGetQueryObjectui64v _al_glGetQueryObjectui64v +#endif + +#if defined _ALLEGRO_GL_ARB_vertex_type_2_10_10_10_rev +#define glVertexP2ui _al_glVertexP2ui +#define glVertexP2uiv _al_glVertexP2uiv +#define glVertexP3ui _al_glVertexP3ui +#define glVertexP3uiv _al_glVertexP3uiv +#define glVertexP4ui _al_glVertexP4ui +#define glVertexP4uiv _al_glVertexP4uiv +#define glTexCoordP1ui _al_glTexCoordP1ui +#define glTexCoordP1uiv _al_glTexCoordP1uiv +#define glTexCoordP2ui _al_glTexCoordP2ui +#define glTexCoordP2uiv _al_glTexCoordP2uiv +#define glTexCoordP3ui _al_glTexCoordP3ui +#define glTexCoordP3uiv _al_glTexCoordP3uiv +#define glTexCoordP4ui _al_glTexCoordP4ui +#define glTexCoordP4uiv _al_glTexCoordP4uiv +#define glMultiTexCoordP1ui _al_glMultiTexCoordP1ui +#define glMultiTexCoordP1uiv _al_glMultiTexCoordP1uiv +#define glMultiTexCoordP2ui _al_glMultiTexCoordP2ui +#define glMultiTexCoordP2uiv _al_glMultiTexCoordP2uiv +#define glMultiTexCoordP3ui _al_glMultiTexCoordP3ui +#define glMultiTexCoordP3uiv _al_glMultiTexCoordP3uiv +#define glMultiTexCoordP4ui _al_glMultiTexCoordP4ui +#define glMultiTexCoordP4uiv _al_glMultiTexCoordP4uiv +#define glNormalP3ui _al_glNormalP3ui +#define glNormalP3uiv _al_glNormalP3uiv +#define glColorP3ui _al_glColorP3ui +#define glColorP3uiv _al_glColorP3uiv +#define glColorP4ui _al_glColorP4ui +#define glColorP4uiv _al_glColorP4uiv +#define glSecondaryColorP3ui _al_glSecondaryColorP3ui +#define glSecondaryColorP3uiv _al_glSecondaryColorP3uiv +#define glVertexAttribP1ui _al_glVertexAttribP1ui +#define glVertexAttribP1uiv _al_glVertexAttribP1uiv +#define glVertexAttribP2ui _al_glVertexAttribP2ui +#define glVertexAttribP2uiv _al_glVertexAttribP2uiv +#define glVertexAttribP3ui _al_glVertexAttribP3ui +#define glVertexAttribP3uiv _al_glVertexAttribP3uiv +#define glVertexAttribP4ui _al_glVertexAttribP4ui +#define glVertexAttribP4uiv _al_glVertexAttribP4uiv +#endif + +#if defined _ALLEGRO_GL_ARB_draw_indirect +#define glDrawArraysIndirect _al_glDrawArraysIndirect +#define glDrawElementsIndirect _al_glDrawElementsIndirect +#endif + +#if defined _ALLEGRO_GL_ARB_gpu_shader_fp64 +#define glUniform1d _al_glUniform1d +#define glUniform2d _al_glUniform2d +#define glUniform3d _al_glUniform3d +#define glUniform4d _al_glUniform4d +#define glUniform1dv _al_glUniform1dv +#define glUniform2dv _al_glUniform2dv +#define glUniform3dv _al_glUniform3dv +#define glUniform4dv _al_glUniform4dv +#define glUniformMatrix2dv _al_glUniformMatrix2dv +#define glUniformMatrix3dv _al_glUniformMatrix3dv +#define glUniformMatrix4dv _al_glUniformMatrix4dv +#define glUniformMatrix2x3dv _al_glUniformMatrix2x3dv +#define glUniformMatrix2x4dv _al_glUniformMatrix2x4dv +#define glUniformMatrix3x2dv _al_glUniformMatrix3x2dv +#define glUniformMatrix3x4dv _al_glUniformMatrix3x4dv +#define glUniformMatrix4x2dv _al_glUniformMatrix4x2dv +#define glUniformMatrix4x3dv _al_glUniformMatrix4x3dv +#define glGetUniformdv _al_glGetUniformdv +#define glProgramUniform1dEXT _al_glProgramUniform1dEXT +#define glProgramUniform2dEXT _al_glProgramUniform2dEXT +#define glProgramUniform3dEXT _al_glProgramUniform3dEXT +#define glProgramUniform4dEXT _al_glProgramUniform4dEXT +#define glProgramUniform1dvEXT _al_glProgramUniform1dvEXT +#define glProgramUniform2dvEXT _al_glProgramUniform2dvEXT +#define glProgramUniform3dvEXT _al_glProgramUniform3dvEXT +#define glProgramUniform4dvEXT _al_glProgramUniform4dvEXT +#define glProgramUniformMatrix2dvEXT _al_glProgramUniformMatrix2dvEXT +#define glProgramUniformMatrix3dvEXT _al_glProgramUniformMatrix3dvEXT +#define glProgramUniformMatrix4dvEXT _al_glProgramUniformMatrix4dvEXT +#define glProgramUniformMatrix2x3dvEXT _al_glProgramUniformMatrix2x3dvEXT +#define glProgramUniformMatrix2x4dvEXT _al_glProgramUniformMatrix2x4dvEXT +#define glProgramUniformMatrix3x2dvEXT _al_glProgramUniformMatrix3x2dvEXT +#define glProgramUniformMatrix3x4dvEXT _al_glProgramUniformMatrix3x4dvEXT +#define glProgramUniformMatrix4x2dvEXT _al_glProgramUniformMatrix4x2dvEXT +#define glProgramUniformMatrix4x3dvEXT _al_glProgramUniformMatrix4x3dvEXT +#endif + +#if defined _ALLEGRO_GL_ARB_shader_subroutine +#define glGetSubroutineUniformLocation _al_glGetSubroutineUniformLocation +#define glGetSubroutineIndex _al_glGetSubroutineIndex +#define glGetActiveSubroutineUniformiv _al_glGetActiveSubroutineUniformiv +#define glGetActiveSubroutineUniformName _al_glGetActiveSubroutineUniformName +#define glGetActiveSubroutineName _al_glGetActiveSubroutineName +#define glUniformSubroutinesuiv _al_glUniformSubroutinesuiv +#define glGetUniformSubroutineuiv _al_glGetUniformSubroutineuiv +#define glGetProgramStageiv _al_glGetProgramStageiv +#endif + +#if defined _ALLEGRO_GL_ARB_tessellation_shader +#define glPatchParameteri _al_glPatchParameteri +#define glPatchParameterfv _al_glPatchParameterfv +#endif + +#if defined _ALLEGRO_GL_ARB_transform_feedback2 +#define glBindTransformFeedback _al_glBindTransformFeedback +#define glDeleteTransformFeedbacks _al_glDeleteTransformFeedbacks +#define glGenTransformFeedbacks _al_glGenTransformFeedbacks +#define glIsTransformFeedback _al_glIsTransformFeedback +#define glPauseTransformFeedback _al_glPauseTransformFeedback +#define glResumeTransformFeedback _al_glResumeTransformFeedback +#define glDrawTransformFeedback _al_glDrawTransformFeedback +#endif + +#if defined _ALLEGRO_GL_ARB_transform_feedback3 +#define glDrawTransformFeedbackStream _al_glDrawTransformFeedbackStream +#define glBeginQueryIndexed _al_glBeginQueryIndexed +#define glEndQueryIndexed _al_glEndQueryIndexed +#define glGetQueryIndexediv _al_glGetQueryIndexediv +#endif + + +/**/ + + +#if defined _ALLEGRO_GL_EXT_blend_color +#define glBlendColorEXT _al_glBlendColorEXT +#endif + +#if defined _ALLEGRO_GL_EXT_polygon_offset +#define glPolygonOffsetEXT _al_glPolygonOffsetEXT +#endif + +#if defined _ALLEGRO_GL_EXT_texture3D +#define glTexImage3DEXT _al_glTexImage3DEXT +#define glTexSubImage3DEXT _al_glTexSubImage3DEXT +#endif + +#if defined _ALLEGRO_GL_SGIS_texture_filter4 +#define glGetTexFilterFuncSGIS _al_glGetTexFilterFuncSGIS +#define glTexFilterFuncSGIS _al_glTexFilterFuncSGIS +#endif + +#if defined _ALLEGRO_GL_EXT_subtexture +#define glTexSubImage1DEXT _al_glTexSubImage1DEXT +#define glTexSubImage2DEXT _al_glTexSubImage2DEXT +#endif + +#if defined _ALLEGRO_GL_EXT_copy_texture +#define glCopyTexImage1DEXT _al_glCopyTexImage1DEXT +#define glCopyTexImage2DEXT _al_glCopyTexImage2DEXT +#define glCopyTexSubImage1DEXT _al_glCopyTexSubImage1DEXT +#define glCopyTexSubImage2DEXT _al_glCopyTexSubImage2DEXT +#define glCopyTexSubImage3DEXT _al_glCopyTexSubImage3DEXT +#endif + +#if defined _ALLEGRO_GL_EXT_histogram +#define glGetHistogramEXT _al_glGetHistogramEXT +#define glGetHistogramParameterfvEXT _al_glGetHistogramParameterfvEXT +#define glGetHistogramParameterivEXT _al_glGetHistogramParameterivEXT +#define glGetMinmaxEXT _al_glGetMinmaxEXT +#define glGetMinmaxParameterfvEXT _al_glGetMinmaxParameterfvEXT +#define glGetMinmaxParameterivEXT _al_glGetMinmaxParameterivEXT +#define glHistogramEXT _al_glHistogramEXT +#define glMinmaxEXT _al_glMinmaxEXT +#define glResetHistogramEXT _al_glResetHistogramEXT +#define glResetMinmaxEXT _al_glResetMinmaxEXT +#endif + +#if defined _ALLEGRO_GL_EXT_convolution +#define glConvolutionFilter1DEXT _al_glConvolutionFilter1DEXT +#define glConvolutionFilter2DEXT _al_glConvolutionFilter2DEXT +#define glConvolutionParameterfEXT _al_glConvolutionParameterfEXT +#define glConvolutionParameterfvEXT _al_glConvolutionParameterfvEXT +#define glConvolutionParameteriEXT _al_glConvolutionParameteriEXT +#define glConvolutionParameterivEXT _al_glConvolutionParameterivEXT +#define glCopyConvolutionFilter1DEXT _al_glCopyConvolutionFilter1DEXT +#define glCopyConvolutionFilter2DEXT _al_glCopyConvolutionFilter2DEXT +#define glGetConvolutionFilterEXT _al_glGetConvolutionFilterEXT +#define glGetConvolutionParameterfvEXT _al_glGetConvolutionParameterfvEXT +#define glGetConvolutionParameterivEXT _al_glGetConvolutionParameterivEXT +#define glGetSeparableFilterEXT _al_glGetSeparableFilterEXT +#define glSeparableFilter2DEXT _al_glSeparableFilter2DEXT +#endif + +#if defined _ALLEGRO_GL_SGI_color_table +#define glColorTableSGI _al_glColorTableSGI +#define glColorTableParameterfvSGI _al_glColorTableParameterfvSGI +#define glColorTableParameterivSGI _al_glColorTableParameterivSGI +#define glCopyColorTableSGI _al_glCopyColorTableSGI +#define glGetColorTableSGI _al_glGetColorTableSGI +#define glGetColorTableParameterfvSGI _al_glGetColorTableParameterfvSGI +#define glGetColorTableParameterivSGI _al_glGetColorTableParameterivSGI +#endif + +#if defined _ALLEGRO_GL_SGIX_pixel_texture +#define glPixelTexGenSGIX _al_glPixelTexGenSGIX +#endif + +#if defined _ALLEGRO_GL_SGIS_pixel_texture +#define glPixelTexGenParameteriSGIS _al_glPixelTexGenParameteriSGIS +#define glPixelTexGenParameterivSGIS _al_glPixelTexGenParameterivSGIS +#define glPixelTexGenParameterfSGIS _al_glPixelTexGenParameterfSGIS +#define glPixelTexGenParameterfvSGIS _al_glPixelTexGenParameterfvSGIS +#define glGetPixelTexGenParameterivSGIS _al_glGetPixelTexGenParameterivSGIS +#define glGetPixelTexGenParameterfvSGIS _al_glGetPixelTexGenParameterfvSGIS +#endif + +#if defined _ALLEGRO_GL_SGIS_texture4D +#define glTexImage4DSGIS _al_glTexImage4DSGIS +#define glTexSubImage4DSGIS _al_glTexSubImage4DSGIS +#endif + +#if defined _ALLEGRO_GL_EXT_texture_object +#define glAreTexturesResidentEXT _al_glAreTexturesResidentEXT +#define glBindTextureEXT _al_glBindTextureEXT +#define glDeleteTexturesEXT _al_glDeleteTexturesEXT +#define glGenTexturesEXT _al_glGenTexturesEXT +#define glIsTextureEXT _al_glIsTextureEXT +#define glPrioritizeTexturesEXT _al_glPrioritizeTexturesEXT +#endif + +#if defined _ALLEGRO_GL_SGIS_detail_texture +#define glDetailTexFuncSGIS _al_glDetailTexFuncSGIS +#define glGetDetailTexFuncSGIS _al_glGetDetailTexFuncSGIS +#endif + +#if defined _ALLEGRO_GL_SGIS_sharpen_texture +#define glSharpenTexFuncSGIS _al_glSharpenTexFuncSGIS +#define glGetSharpenTexFuncSGIS _al_glGetSharpenTexFuncSGIS +#endif + +#if defined _ALLEGRO_GL_SGIS_multisample +#define glSampleMaskSGIS _al_glSampleMaskSGIS +#define glSamplePatternSGIS _al_glSamplePatternSGIS +#endif + +#if defined _ALLEGRO_GL_EXT_vertex_array +#define glArrayElementEXT _al_glArrayElementEXT +#define glColorPointerEXT _al_glColorPointerEXT +#define glDrawArraysEXT _al_glDrawArraysEXT +#define glEdgeFlagPointerEXT _al_glEdgeFlagPointerEXT +#define glGetPointervEXT _al_glGetPointervEXT +#define glIndexPointerEXT _al_glIndexPointerEXT +#define glNormalPointerEXT _al_glNormalPointerEXT +#define glTexCoordPointerEXT _al_glTexCoordPointerEXT +#define glVertexPointerEXT _al_glVertexPointerEXT +#endif + +#if defined _ALLEGRO_GL_EXT_blend_minmax +#define glBlendEquationEXT _al_glBlendEquationEXT +#endif + +#if defined _ALLEGRO_GL_SGIX_sprite +#define glSpriteParameterfSGIX _al_glSpriteParameterfSGIX +#define glSpriteParameterfvSGIX _al_glSpriteParameterfvSGIX +#define glSpriteParameteriSGIX _al_glSpriteParameteriSGIX +#define glSpriteParameterivSGIX _al_glSpriteParameterivSGIX +#endif + +#if defined _ALLEGRO_GL_EXT_point_parameters +#define glPointParameterfEXT _al_glPointParameterfEXT +#define glPointParameterfvEXT _al_glPointParameterfvEXT +#endif + +#if defined _ALLEGRO_GL_SGIS_point_parameters +#define glPointParameterfSGIS _al_glPointParameterfSGIS +#define glPointParameterfvSGIS _al_glPointParameterfvSGIS +#endif + +#if defined _ALLEGRO_GL_SGIX_instruments +#define glGetInstrumentsSGIX _al_glGetInstrumentsSGIX +#define glInstrumentsBufferSGIX _al_glInstrumentsBufferSGIX +#define glPollInstrumentsSGIX _al_glPollInstrumentsSGIX +#define glReadInstrumentsSGIX _al_glReadInstrumentsSGIX +#define glStartInstrumentsSGIX _al_glStartInstrumentsSGIX +#define glStopInstrumentsSGIX _al_glStopInstrumentsSGIX +#endif + +#if defined _ALLEGRO_GL_SGIX_framezoom +#define glFrameZoomSGIX _al_glFrameZoomSGIX +#endif + +#if defined _ALLEGRO_GL_SGIX_tag_sample_buffer +#define glTagSampleBufferSGIX _al_glTagSampleBufferSGIX +#endif + +#if defined _ALLEGRO_GL_SGIX_polynomial_ffd +#define glDeformationMap3dSGIX _al_glDeformationMap3dSGIX +#define glDeformationMap3fSGIX _al_glDeformationMap3fSGIX +#define glDeformSGIX _al_glDeformSGIX +#define glLoadIdentityDeformationMapSGIX _al_glLoadIdentityDeformationMapSGIX +#endif + +#if defined _ALLEGRO_GL_SGIX_reference_plane +#define glReferencePlaneSGIX _al_glReferencePlaneSGIX +#endif + +#if defined _ALLEGRO_GL_SGIX_flush_raster +#define glFlushRasterSGIX _al_glFlushRasterSGIX +#endif + +#if defined _ALLEGRO_GL_SGIS_fog_function +#define glFogFuncSGIS _al_glFogFuncSGIS +#define glGetFogFuncSGIS _al_glGetFogFuncSGIS +#endif + +#if defined _ALLEGRO_GL_HP_image_transform +#define glImageTransformParameteriHP _al_glImageTransformParameteriHP +#define glImageTransformParameterfHP _al_glImageTransformParameterfHP +#define glImageTransformParameterivHP _al_glImageTransformParameterivHP +#define glImageTransformParameterfvHP _al_glImageTransformParameterfvHP +#define glGetImageTransformParameterivHP _al_glGetImageTransformParameterivHP +#define glGetImageTransformParameterfvHP _al_glGetImageTransformParameterfvHP +#endif + +#if defined _ALLEGRO_GL_EXT_color_subtable +#ifndef GL_EXT_paletted_texture +#define glColorSubTableEXT _al_glColorSubTableEXT +#endif +#define glCopyColorSubTableEXT _al_glCopyColorSubTableEXT +#endif + +#if defined _ALLEGRO_GL_PGI_misc_hints +#define glHintPGI _al_glHintPGI +#endif + +#if defined _ALLEGRO_GL_EXT_paletted_texture +#define glColorTableEXT _al_glColorTableEXT +#define glGetColorTableEXT _al_glGetColorTableEXT +#define glGetColorTableParameterivEXT _al_glGetColorTableParameterivEXT +#define glGetColorTableParameterfvEXT _al_glGetColorTableParameterfvEXT +#endif + +#if defined _ALLEGRO_GL_SGIX_list_priority +#define glGetListParameterfvSGIX _al_glGetListParameterfvSGIX +#define glGetListParameterivSGIX _al_glGetListParameterivSGIX +#define glListParameterfSGIX _al_glListParameterfSGIX +#define glListParameterfvSGIX _al_glListParameterfvSGIX +#define glListParameteriSGIX _al_glListParameteriSGIX +#define glListParameterivSGIX _al_glListParameterivSGIX +#endif + +#if defined _ALLEGRO_GL_EXT_index_material +#define glIndexMaterialEXT _al_glIndexMaterialEXT +#endif + +#if defined _ALLEGRO_GL_EXT_index_func +#define glIndexFuncEXT _al_glIndexFuncEXT +#endif + +#if defined _ALLEGRO_GL_EXT_compiled_vertex_array +#define glLockArraysEXT _al_glLockArraysEXT +#define glUnlockArraysEXT _al_glUnlockArraysEXT +#endif + +#if defined _ALLEGRO_GL_EXT_cull_vertex +#define glCullParameterdvEXT _al_glCullParameterdvEXT +#define glCullParameterfvEXT _al_glCullParameterfvEXT +#endif + +#if defined _ALLEGRO_GL_SGIX_fragment_lighting +#define glFragmentColorMaterialSGIX _al_glFragmentColorMaterialSGIX +#define glFragmentLightfSGIX _al_glFragmentLightfSGIX +#define glFragmentLightfvSGIX _al_glFragmentLightfvSGIX +#define glFragmentLightiSGIX _al_glFragmentLightiSGIX +#define glFragmentLightivSGIX _al_glFragmentLightivSGIX +#define glFragmentLightModelfSGIX _al_glFragmentLightModelfSGIX +#define glFragmentLightModelfvSGIX _al_glFragmentLightModelfvSGIX +#define glFragmentLightModeliSGIX _al_glFragmentLightModeliSGIX +#define glFragmentLightModelivSGIX _al_glFragmentLightModelivSGIX +#define glFragmentMaterialfSGIX _al_glFragmentMaterialfSGIX +#define glFragmentMaterialfvSGIX _al_glFragmentMaterialfvSGIX +#define glFragmentMaterialiSGIX _al_glFragmentMaterialiSGIX +#define glFragmentMaterialivSGIX _al_glFragmentMaterialivSGIX +#define glGetFragmentLightfvSGIX _al_glGetFragmentLightfvSGIX +#define glGetFragmentLightivSGIX _al_glGetFragmentLightivSGIX +#define glGetFragmentMaterialfvSGIX _al_glGetFragmentMaterialfvSGIX +#define glGetFragmentMaterialivSGIX _al_glGetFragmentMaterialivSGIX +#define glLightEnviSGIX _al_glLightEnviSGIX +#endif + +#if defined _ALLEGRO_GL_EXT_draw_range_elements +#define glDrawRangeElementsEXT _al_glDrawRangeElementsEXT +#endif + +#if defined _ALLEGRO_GL_EXT_light_texture +#define glApplyTextureEXT _al_glApplyTextureEXT +#define glTextureLightEXT _al_glTextureLightEXT +#define glTextureMaterialEXT _al_glTextureMaterialEXT +#endif + +#if defined _ALLEGRO_GL_SGIX_async +#define glAsyncMarkerSGIX _al_glAsyncMarkerSGIX +#define glFinishAsyncSGIX _al_glFinishAsyncSGIX +#define glPollAsyncSGIX _al_glPollAsyncSGIX +#define glGenAsyncMarkersSGIX _al_glGenAsyncMarkersSGIX +#define glDeleteAsyncMarkersSGIX _al_glDeleteAsyncMarkersSGIX +#define glIsAsyncMarkerSGIX _al_glIsAsyncMarkerSGIX +#endif + +#if defined _ALLEGRO_GL_INTEL_parallel_arrays +#define glVertexPointervINTEL _al_glVertexPointervINTEL +#define glNormalPointervINTEL _al_glNormalPointervINTEL +#define glColorPointervINTEL _al_glColorPointervINTEL +#define glTexCoordPointervINTEL _al_glTexCoordPointervINTEL +#endif + +#if defined _ALLEGRO_GL_EXT_pixel_transform +#define glPixelTransformParameteriEXT _al_glPixelTransformParameteriEXT +#define glPixelTransformParameterfEXT _al_glPixelTransformParameterfEXT +#define glPixelTransformParameterivEXT _al_glPixelTransformParameterivEXT +#define glPixelTransformParameterfvEXT _al_glPixelTransformParameterfvEXT +#endif + +#if defined _ALLEGRO_GL_EXT_secondary_color +#define glSecondaryColor3bEXT _al_glSecondaryColor3bEXT +#define glSecondaryColor3bvEXT _al_glSecondaryColor3bvEXT +#define glSecondaryColor3dEXT _al_glSecondaryColor3dEXT +#define glSecondaryColor3dvEXT _al_glSecondaryColor3dvEXT +#define glSecondaryColor3fEXT _al_glSecondaryColor3fEXT +#define glSecondaryColor3fvEXT _al_glSecondaryColor3fvEXT +#define glSecondaryColor3iEXT _al_glSecondaryColor3iEXT +#define glSecondaryColor3ivEXT _al_glSecondaryColor3ivEXT +#define glSecondaryColor3sEXT _al_glSecondaryColor3sEXT +#define glSecondaryColor3svEXT _al_glSecondaryColor3svEXT +#define glSecondaryColor3ubEXT _al_glSecondaryColor3ubEXT +#define glSecondaryColor3ubvEXT _al_glSecondaryColor3ubvEXT +#define glSecondaryColor3uiEXT _al_glSecondaryColor3uiEXT +#define glSecondaryColor3uivEXT _al_glSecondaryColor3uivEXT +#define glSecondaryColor3usEXT _al_glSecondaryColor3usEXT +#define glSecondaryColor3usvEXT _al_glSecondaryColor3usvEXT +#define glSecondaryColorPointerEXT _al_glSecondaryColorPointerEXT +#endif + +#if defined _ALLEGRO_GL_EXT_texture_perturb_normal +#define glTextureNormalEXT _al_glTextureNormalEXT +#endif + +#if defined _ALLEGRO_GL_EXT_multi_draw_arrays +#define glMultiDrawArraysEXT _al_glMultiDrawArraysEXT +#define glMultiDrawElementsEXT _al_glMultiDrawElementsEXT +#endif + +#if defined _ALLEGRO_GL_EXT_fog_coord +#define glFogCoordfEXT _al_glFogCoordfEXT +#define glFogCoordfvEXT _al_glFogCoordfvEXT +#define glFogCoorddEXT _al_glFogCoorddEXT +#define glFogCoorddvEXT _al_glFogCoorddvEXT +#define glFogCoordPointerEXT _al_glFogCoordPointerEXT +#endif + +#if defined _ALLEGRO_GL_EXT_coordinate_frame +#define glTangent3bEXT _al_glTangent3bEXT +#define glTangent3bvEXT _al_glTangent3bvEXT +#define glTangent3dEXT _al_glTangent3dEXT +#define glTangent3dvEXT _al_glTangent3dvEXT +#define glTangent3fEXT _al_glTangent3fEXT +#define glTangent3fvEXT _al_glTangent3fvEXT +#define glTangent3iEXT _al_glTangent3iEXT +#define glTangent3ivEXT _al_glTangent3ivEXT +#define glTangent3sEXT _al_glTangent3sEXT +#define glTangent3svEXT _al_glTangent3svEXT +#define glBinormal3bEXT _al_glBinormal3bEXT +#define glBinormal3bvEXT _al_glBinormal3bvEXT +#define glBinormal3dEXT _al_glBinormal3dEXT +#define glBinormal3dvEXT _al_glBinormal3dvEXT +#define glBinormal3fEXT _al_glBinormal3fEXT +#define glBinormal3fvEXT _al_glBinormal3fvEXT +#define glBinormal3iEXT _al_glBinormal3iEXT +#define glBinormal3ivEXT _al_glBinormal3ivEXT +#define glBinormal3sEXT _al_glBinormal3sEXT +#define glBinormal3svEXT _al_glBinormal3svEXT +#define glTangentPointerEXT _al_glTangentPointerEXT +#define glBinormalPointerEXT _al_glBinormalPointerEXT +#endif + +#if defined _ALLEGRO_GL_SUNX_constant_data +#define glFinishTextureSUNX _al_glFinishTextureSUNX +#endif + +#if defined _ALLEGRO_GL_SUN_global_alpha +#define glGlobalAlphaFactorbSUN _al_glGlobalAlphaFactorbSUN +#define glGlobalAlphaFactorsSUN _al_glGlobalAlphaFactorsSUN +#define glGlobalAlphaFactoriSUN _al_glGlobalAlphaFactoriSUN +#define glGlobalAlphaFactorfSUN _al_glGlobalAlphaFactorfSUN +#define glGlobalAlphaFactordSUN _al_glGlobalAlphaFactordSUN +#define glGlobalAlphaFactorubSUN _al_glGlobalAlphaFactorubSUN +#define glGlobalAlphaFactorusSUN _al_glGlobalAlphaFactorusSUN +#define glGlobalAlphaFactoruiSUN _al_glGlobalAlphaFactoruiSUN +#endif + +#if defined _ALLEGRO_GL_SUN_triangle_list +#define glReplacementCodeuiSUN _al_glReplacementCodeuiSUN +#define glReplacementCodeusSUN _al_glReplacementCodeusSUN +#define glReplacementCodeubSUN _al_glReplacementCodeubSUN +#define glReplacementCodeuivSUN _al_glReplacementCodeuivSUN +#define glReplacementCodeusvSUN _al_glReplacementCodeusvSUN +#define glReplacementCodeubvSUN _al_glReplacementCodeubvSUN +#define glReplacementCodePointerSUN _al_glReplacementCodePointerSUN +#endif + +#if defined _ALLEGRO_GL_SUN_vertex +#define glColor4ubVertex2fSUN _al_glColor4ubVertex2fSUN +#define glColor4ubVertex2fvSUN _al_glColor4ubVertex2fvSUN +#define glColor4ubVertex3fSUN _al_glColor4ubVertex3fSUN +#define glColor4ubVertex3fvSUN _al_glColor4ubVertex3fvSUN +#define glColor3fVertex3fSUN _al_glColor3fVertex3fSUN +#define glColor3fVertex3fvSUN _al_glColor3fVertex3fvSUN +#define glNormal3fVertex3fSUN _al_glNormal3fVertex3fSUN +#define glNormal3fVertex3fvSUN _al_glNormal3fVertex3fvSUN +#define glColor4fNormal3fVertex3fSUN _al_glColor4fNormal3fVertex3fSUN +#define glColor4fNormal3fVertex3fvSUN _al_glColor4fNormal3fVertex3fvSUN +#define glTexCoord2fVertex3fSUN _al_glTexCoord2fVertex3fSUN +#define glTexCoord2fVertex3fvSUN _al_glTexCoord2fVertex3fvSUN +#define glTexCoord4fVertex4fSUN _al_glTexCoord4fVertex4fSUN +#define glTexCoord4fVertex4fvSUN _al_glTexCoord4fVertex4fvSUN +#define glTexCoord2fColor4ubVertex3fSUN _al_glTexCoord2fColor4ubVertex3fSUN +#define glTexCoord2fColor4ubVertex3fvSUN _al_glTexCoord2fColor4ubVertex3fvSUN +#define glTexCoord2fColor3fVertex3fSUN _al_glTexCoord2fColor3fVertex3fSUN +#define glTexCoord2fColor3fVertex3fvSUN _al_glTexCoord2fColor3fVertex3fvSUN +#define glTexCoord2fNormal3fVertex3fSUN _al_glTexCoord2fNormal3fVertex3fSUN +#define glTexCoord2fNormal3fVertex3fvSUN _al_glTexCoord2fNormal3fVertex3fvSUN +#define glTexCoord2fColor4fNormal3fVertex3fSUN _al_glTexCoord2fColor4fNormal3fVertex3fSUN +#define glTexCoord2fColor4fNormal3fVertex3fvSUN _al_glTexCoord2fColor4fNormal3fVertex3fvSUN +#define glTexCoord4fColor4fNormal3fVertex4fSUN _al_glTexCoord4fColor4fNormal3fVertex4fSUN +#define glTexCoord4fColor4fNormal3fVertex4fvSUN _al_glTexCoord4fColor4fNormal3fVertex4fvSUN +#define glReplacementCodeuiVertex3fSUN _al_glReplacementCodeuiVertex3fSUN +#define glReplacementCodeuiVertex3fvSUN _al_glReplacementCodeuiVertex3fvSUN +#define glReplacementCodeuiColor4ubVertex3fSUN _al_glReplacementCodeuiColor4ubVertex3fSUN +#define glReplacementCodeuiColor4ubVertex3fvSUN _al_glReplacementCodeuiColor4ubVertex3fvSUN +#define glReplacementCodeuiColor3fVertex3fSUN _al_glReplacementCodeuiColor3fVertex3fSUN +#define glReplacementCodeuiColor3fVertex3fvSUN _al_glReplacementCodeuiColor3fVertex3fvSUN +#define glReplacementCodeuiNormal3fVertex3fSUN _al_glReplacementCodeuiNormal3fVertex3fSUN +#define glReplacementCodeuiNormal3fVertex3fvSUN _al_glReplacementCodeuiNormal3fVertex3fvSUN +#define glReplacementCodeuiColor4fNormal3fVertex3fSUN _al_glReplacementCodeuiColor4fNormal3fVertex3fSUN +#define glReplacementCodeuiColor4fNormal3fVertex3fvSUN _al_glReplacementCodeuiColor4fNormal3fVertex3fvSUN +#define glReplacementCodeuiTexCoord2fVertex3fSUN _al_glReplacementCodeuiTexCoord2fVertex3fSUN +#define glReplacementCodeuiTexCoord2fVertex3fvSUN _al_glReplacementCodeuiTexCoord2fVertex3fvSUN +#define glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN _al_glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN +#define glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN _al_glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN +#define glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN _al_glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN +#define glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN _al_glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN +#endif + +#if defined _ALLEGRO_GL_EXT_blend_func_separate +#define glBlendFuncSeparateEXT _al_glBlendFuncSeparateEXT +#endif + +#if defined _ALLEGRO_GL_INGR_blend_func_separate +#define glBlendFuncSeparateINGR _al_glBlendFuncSeparateINGR +#endif + +#if defined _ALLEGRO_GL_EXT_vertex_weighting +#define glVertexWeightfEXT _al_glVertexWeightfEXT +#define glVertexWeightfvEXT _al_glVertexWeightfvEXT +#define glVertexWeightPointerEXT _al_glVertexWeightPointerEXT +#endif + +#if defined _ALLEGRO_GL_NV_vertex_array_range +#define glFlushVertexArrayRangeNV _al_glFlushVertexArrayRangeNV +#define glVertexArrayRangeNV _al_glVertexArrayRangeNV +#endif + +#if defined _ALLEGRO_GL_NV_register_combiners +#define glCombinerParameterfvNV _al_glCombinerParameterfvNV +#define glCombinerParameterfNV _al_glCombinerParameterfNV +#define glCombinerParameterivNV _al_glCombinerParameterivNV +#define glCombinerParameteriNV _al_glCombinerParameteriNV +#define glCombinerInputNV _al_glCombinerInputNV +#define glCombinerOutputNV _al_glCombinerOutputNV +#define glFinalCombinerInputNV _al_glFinalCombinerInputNV +#define glGetCombinerInputParameterfvNV _al_glGetCombinerInputParameterfvNV +#define glGetCombinerInputParameterivNV _al_glGetCombinerInputParameterivNV +#define glGetCombinerOutputParameterfvNV _al_glGetCombinerOutputParameterfvNV +#define glGetCombinerOutputParameterivNV _al_glGetCombinerOutputParameterivNV +#define glGetFinalCombinerInputParameterfvNV _al_glGetFinalCombinerInputParameterfvNV +#define glGetFinalCombinerInputParameterivNV _al_glGetFinalCombinerInputParameterivNV +#endif + +#if defined _ALLEGRO_GL_MESA_resize_buffers +#define glResizeBuffersMESA _al_glResizeBuffersMESA +#endif + +#if defined _ALLEGRO_GL_MESA_window_pos +#define glWindowPos2dMESA _al_glWindowPos2dMESA +#define glWindowPos2dvMESA _al_glWindowPos2dvMESA +#define glWindowPos2fMESA _al_glWindowPos2fMESA +#define glWindowPos2fvMESA _al_glWindowPos2fvMESA +#define glWindowPos2iMESA _al_glWindowPos2iMESA +#define glWindowPos2ivMESA _al_glWindowPos2ivMESA +#define glWindowPos2sMESA _al_glWindowPos2sMESA +#define glWindowPos2svMESA _al_glWindowPos2svMESA +#define glWindowPos3dMESA _al_glWindowPos3dMESA +#define glWindowPos3dvMESA _al_glWindowPos3dvMESA +#define glWindowPos3fMESA _al_glWindowPos3fMESA +#define glWindowPos3fvMESA _al_glWindowPos3fvMESA +#define glWindowPos3iMESA _al_glWindowPos3iMESA +#define glWindowPos3ivMESA _al_glWindowPos3ivMESA +#define glWindowPos3sMESA _al_glWindowPos3sMESA +#define glWindowPos3svMESA _al_glWindowPos3svMESA +#define glWindowPos4dMESA _al_glWindowPos4dMESA +#define glWindowPos4dvMESA _al_glWindowPos4dvMESA +#define glWindowPos4fMESA _al_glWindowPos4fMESA +#define glWindowPos4fvMESA _al_glWindowPos4fvMESA +#define glWindowPos4iMESA _al_glWindowPos4iMESA +#define glWindowPos4ivMESA _al_glWindowPos4ivMESA +#define glWindowPos4sMESA _al_glWindowPos4sMESA +#define glWindowPos4svMESA _al_glWindowPos4svMESA +#endif + +#if defined _ALLEGRO_GL_IBM_multimode_draw_arrays +#define glMultiModeDrawArraysIBM _al_glMultiModeDrawArraysIBM +#define glMultiModeDrawElementsIBM _al_glMultiModeDrawElementsIBM +#endif + +#ifdef AGK_IBM_vertex_array_lists +#define glColorPointerListIBM _al_glColorPointerListIBM +#define glSecondaryColorPointerListIBM _al_glSecondaryColorPointerListIBM +#define glEdgeFlagPointerListIBM _al_glEdgeFlagPointerListIBM +#define glFogCoordPointerListIBM _al_glFogCoordPointerListIBM +#define glIndexPointerListIBM _al_glIndexPointerListIBM +#define glNormalPointerListIBM _al_glNormalPointerListIBM +#define glTexCoordPointerListIBM _al_glTexCoordPointerListIBM +#define glVertexPointerListIBM _al_glVertexPointerListIBM +#endif + +#if defined _ALLEGRO_GL_3DFX_tbuffer +#define glTbufferMask3DFX _al_glTbufferMask3DFX +#endif + +#if defined _ALLEGRO_GL_EXT_multisample +#define glSampleMaskEXT _al_glSampleMaskEXT +#define glSamplePatternEXT _al_glSamplePatternEXT +#endif + +#if defined _ALLEGRO_GL_SGIS_texture_color_mask +#define glTextureColorMaskSGIS _al_glTextureColorMaskSGIS +#endif + +#if defined _ALLEGRO_GL_SGIX_igloo_interface +#define glIglooInterfaceSGIX _al_glIglooInterfaceSGIX +#endif + +#if defined _ALLEGRO_GL_NV_fence +#define glDeleteFencesNV _al_glDeleteFencesNV +#define glGenFencesNV _al_glGenFencesNV +#define glIsFenceNV _al_glIsFenceNV +#define glTestFenceNV _al_glTestFenceNV +#define glGetFenceivNV _al_glGetFenceivNV +#define glFinishFenceNV _al_glFinishFenceNV +#define glSetFenceNV _al_glSetFenceNV +#endif + +#if defined _ALLEGRO_GL_NV_evaluators +#define glMapControlPointsNV _al_glMapControlPointsNV +#define glMapParameterivNV _al_glMapParameterivNV +#define glMapParameterfvNV _al_glMapParameterfvNV +#define glGetMapControlPointsNV _al_glGetMapControlPointsNV +#define glGetMapParameterivNV _al_glGetMapParameterivNV +#define glGetMapParameterfvNV _al_glGetMapParameterfvNV +#define glGetMapAttribParameterivNV _al_glGetMapAttribParameterivNV +#define glGetMapAttribParameterfvNV _al_glGetMapAttribParameterfvNV +#define glEvalMapsNV _al_glEvalMapsNV +#endif + +#if defined _ALLEGRO_GL_NV_register_combiners2 +#define glCombinerStageParameterfvNV _al_glCombinerStageParameterfvNV +#define glGetCombinerStageParameterfvNV _al_glGetCombinerStageParameterfvNV +#endif + +#if defined _ALLEGRO_GL_NV_vertex_program +#define glAreProgramsResidentNV _al_glAreProgramsResidentNV +#define glBindProgramNV _al_glBindProgramNV +#define glDeleteProgramsNV _al_glDeleteProgramsNV +#define glExecuteProgramNV _al_glExecuteProgramNV +#define glGenProgramsNV _al_glGenProgramsNV +#define glGetProgramParameterdvNV _al_glGetProgramParameterdvNV +#define glGetProgramParameterfvNV _al_glGetProgramParameterfvNV +#define glGetProgramivNV _al_glGetProgramivNV +#define glGetProgramStringNV _al_glGetProgramStringNV +#define glGetTrackMatrixivNV _al_glGetTrackMatrixivNV +#define glGetVertexAttribdvNV _al_glGetVertexAttribdvNV +#define glGetVertexAttribfvNV _al_glGetVertexAttribfvNV +#define glGetVertexAttribivNV _al_glGetVertexAttribivNV +#define glGetVertexAttribPointervNV _al_glGetVertexAttribPointervNV +#define glIsProgramNV _al_glIsProgramNV +#define glLoadProgramNV _al_glLoadProgramNV +#define glProgramParameter4dNV _al_glProgramParameter4dNV +#define glProgramParameter4dvNV _al_glProgramParameter4dvNV +#define glProgramParameter4fNV _al_glProgramParameter4fNV +#define glProgramParameter4fvNV _al_glProgramParameter4fvNV +#define glProgramParameters4dvNV _al_glProgramParameters4dvNV +#define glProgramParameters4fvNV _al_glProgramParameters4fvNV +#define glRequestResidentProgramsNV _al_glRequestResidentProgramsNV +#define glTrackMatrixNV _al_glTrackMatrixNV +#define glVertexAttribPointerNV _al_glVertexAttribPointerNV +#define glVertexAttrib1dNV _al_glVertexAttrib1dNV +#define glVertexAttrib1dvNV _al_glVertexAttrib1dvNV +#define glVertexAttrib1fNV _al_glVertexAttrib1fNV +#define glVertexAttrib1fvNV _al_glVertexAttrib1fvNV +#define glVertexAttrib1sNV _al_glVertexAttrib1sNV +#define glVertexAttrib1svNV _al_glVertexAttrib1svNV +#define glVertexAttrib2dNV _al_glVertexAttrib2dNV +#define glVertexAttrib2dvNV _al_glVertexAttrib2dvNV +#define glVertexAttrib2fNV _al_glVertexAttrib2fNV +#define glVertexAttrib2fvNV _al_glVertexAttrib2fvNV +#define glVertexAttrib2sNV _al_glVertexAttrib2sNV +#define glVertexAttrib2svNV _al_glVertexAttrib2svNV +#define glVertexAttrib3dNV _al_glVertexAttrib3dNV +#define glVertexAttrib3dvNV _al_glVertexAttrib3dvNV +#define glVertexAttrib3fNV _al_glVertexAttrib3fNV +#define glVertexAttrib3fvNV _al_glVertexAttrib3fvNV +#define glVertexAttrib3sNV _al_glVertexAttrib3sNV +#define glVertexAttrib3svNV _al_glVertexAttrib3svNV +#define glVertexAttrib4dNV _al_glVertexAttrib4dNV +#define glVertexAttrib4dvNV _al_glVertexAttrib4dvNV +#define glVertexAttrib4fNV _al_glVertexAttrib4fNV +#define glVertexAttrib4fvNV _al_glVertexAttrib4fvNV +#define glVertexAttrib4sNV _al_glVertexAttrib4sNV +#define glVertexAttrib4svNV _al_glVertexAttrib4svNV +#define glVertexAttrib4ubNV _al_glVertexAttrib4ubNV +#define glVertexAttrib4ubvNV _al_glVertexAttrib4ubvNV +#define glVertexAttribs1dvNV _al_glVertexAttribs1dvNV +#define glVertexAttribs1fvNV _al_glVertexAttribs1fvNV +#define glVertexAttribs1svNV _al_glVertexAttribs1svNV +#define glVertexAttribs2dvNV _al_glVertexAttribs2dvNV +#define glVertexAttribs2fvNV _al_glVertexAttribs2fvNV +#define glVertexAttribs2svNV _al_glVertexAttribs2svNV +#define glVertexAttribs3dvNV _al_glVertexAttribs3dvNV +#define glVertexAttribs3fvNV _al_glVertexAttribs3fvNV +#define glVertexAttribs3svNV _al_glVertexAttribs3svNV +#define glVertexAttribs4dvNV _al_glVertexAttribs4dvNV +#define glVertexAttribs4fvNV _al_glVertexAttribs4fvNV +#define glVertexAttribs4svNV _al_glVertexAttribs4svNV +#define glVertexAttribs4ubvNV _al_glVertexAttribs4ubvNV +#endif + +#if defined _ALLEGRO_GL_ATI_envmap_bumpmap +#define glTexBumpParameterivATI _al_glTexBumpParameterivATI +#define glTexBumpParameterfvATI _al_glTexBumpParameterfvATI +#define glGetTexBumpParameterivATI _al_glGetTexBumpParameterivATI +#define glGetTexBumpParameterfvATI _al_glGetTexBumpParameterfvATI +#endif + +#if defined _ALLEGRO_GL_ATI_fragment_shader +#define glGenFragmentShadersATI _al_glGenFragmentShadersATI +#define glBindFragmentShaderATI _al_glBindFragmentShaderATI +#define glDeleteFragmentShaderATI _al_glDeleteFragmentShaderATI +#define glBeginFragmentShaderATI _al_glBeginFragmentShaderATI +#define glEndFragmentShaderATI _al_glEndFragmentShaderATI +#define glPassTexCoordATI _al_glPassTexCoordATI +#define glSampleMapATI _al_glSampleMapATI +#define glColorFragmentOp1ATI _al_glColorFragmentOp1ATI +#define glColorFragmentOp2ATI _al_glColorFragmentOp2ATI +#define glColorFragmentOp3ATI _al_glColorFragmentOp3ATI +#define glAlphaFragmentOp1ATI _al_glAlphaFragmentOp1ATI +#define glAlphaFragmentOp2ATI _al_glAlphaFragmentOp2ATI +#define glAlphaFragmentOp3ATI _al_glAlphaFragmentOp3ATI +#define glSetFragmentShaderConstantATI _al_glSetFragmentShaderConstantATI +#endif + +#if defined _ALLEGRO_GL_ATI_pn_triangles +#define glPNTrianglesiATI _al_glPNTrianglesiATI +#define glPNTrianglesfATI _al_glPNTrianglesfATI +#endif + +#if defined _ALLEGRO_GL_ATI_vertex_array_object +#define glNewObjectBufferATI _al_glNewObjectBufferATI +#define glIsObjectBufferATI _al_glIsObjectBufferATI +#define glUpdateObjectBufferATI _al_glUpdateObjectBufferATI +#define glGetObjectBufferfvATI _al_glGetObjectBufferfvATI +#define glGetObjectBufferivATI _al_glGetObjectBufferivATI +#define glFreeObjectBufferATI _al_glFreeObjectBufferATI +#define glArrayObjectATI _al_glArrayObjectATI +#define glGetArrayObjectfvATI _al_glGetArrayObjectfvATI +#define glGetArrayObjectivATI _al_glGetArrayObjectivATI +#define glVariantArrayObjectATI _al_glVariantArrayObjectATI +#define glGetVariantArrayObjectfvATI _al_glGetVariantArrayObjectfvATI +#define glGetVariantArrayObjectivATI _al_glGetVariantArrayObjectivATI +#endif + +#if defined _ALLEGRO_GL_EXT_vertex_shader +#define glBeginVertexShaderEXT _al_glBeginVertexShaderEXT +#define glEndVertexShaderEXT _al_glEndVertexShaderEXT +#define glBindVertexShaderEXT _al_glBindVertexShaderEXT +#define glGenVertexShadersEXT _al_glGenVertexShadersEXT +#define glDeleteVertexShaderEXT _al_glDeleteVertexShaderEXT +#define glShaderOp1EXT _al_glShaderOp1EXT +#define glShaderOp2EXT _al_glShaderOp2EXT +#define glShaderOp3EXT _al_glShaderOp3EXT +#define glSwizzleEXT _al_glSwizzleEXT +#define glWriteMaskEXT _al_glWriteMaskEXT +#define glInsertComponentEXT _al_glInsertComponentEXT +#define glExtractComponentEXT _al_glExtractComponentEXT +#define glGenSymbolsEXT _al_glGenSymbolsEXT +#define glSetInvariantEXT _al_glSetInvariantEXT +#define glSetLocalConstantEXT _al_glSetLocalConstantEXT +#define glVariantbvEXT _al_glVariantbvEXT +#define glVariantsvEXT _al_glVariantsvEXT +#define glVariantivEXT _al_glVariantivEXT +#define glVariantfvEXT _al_glVariantfvEXT +#define glVariantdvEXT _al_glVariantdvEXT +#define glVariantubvEXT _al_glVariantubvEXT +#define glVariantusvEXT _al_glVariantusvEXT +#define glVariantuivEXT _al_glVariantuivEXT +#define glVariantPointerEXT _al_glVariantPointerEXT +#define glEnableVariantClientStateEXT _al_glEnableVariantClientStateEXT +#define glDisableVariantClientStateEXT _al_glDisableVariantClientStateEXT +#define glBindLightParameterEXT _al_glBindLightParameterEXT +#define glBindMaterialParameterEXT _al_glBindMaterialParameterEXT +#define glBindTexGenParameterEXT _al_glBindTexGenParameterEXT +#define glBindTextureUnitParameterEXT _al_glBindTextureUnitParameterEXT +#define glBindParameterEXT _al_glBindParameterEXT +#define glIsVariantEnabledEXT _al_glIsVariantEnabledEXT +#define glGetVariantBooleanvEXT _al_glGetVariantBooleanvEXT +#define glGetVariantIntegervEXT _al_glGetVariantIntegervEXT +#define glGetVariantFloatvEXT _al_glGetVariantFloatvEXT +#define glGetVariantPointervEXT _al_glGetVariantPointervEXT +#define glGetInvariantBooleanvEXT _al_glGetInvariantBooleanvEXT +#define glGetInvariantIntegervEXT _al_glGetInvariantIntegervEXT +#define glGetInvariantFloatvEXT _al_glGetInvariantFloatvEXT +#define glGetLocalConstantBooleanvEXT _al_glGetLocalConstantBooleanvEXT +#define glGetLocalConstantIntegervEXT _al_glGetLocalConstantIntegervEXT +#define glGetLocalConstantFloatvEXT _al_glGetLocalConstantFloatvEXT +#endif + +#if defined _ALLEGRO_GL_ATI_vertex_streams +#define glVertexStream1sATI _al_glVertexStream1sATI +#define glVertexStream1svATI _al_glVertexStream1svATI +#define glVertexStream1iATI _al_glVertexStream1iATI +#define glVertexStream1ivATI _al_glVertexStream1ivATI +#define glVertexStream1fATI _al_glVertexStream1fATI +#define glVertexStream1fvATI _al_glVertexStream1fvATI +#define glVertexStream1dATI _al_glVertexStream1dATI +#define glVertexStream1dvATI _al_glVertexStream1dvATI +#define glVertexStream2sATI _al_glVertexStream2sATI +#define glVertexStream2svATI _al_glVertexStream2svATI +#define glVertexStream2iATI _al_glVertexStream2iATI +#define glVertexStream2ivATI _al_glVertexStream2ivATI +#define glVertexStream2fATI _al_glVertexStream2fATI +#define glVertexStream2fvATI _al_glVertexStream2fvATI +#define glVertexStream2dATI _al_glVertexStream2dATI +#define glVertexStream2dvATI _al_glVertexStream2dvATI +#define glVertexStream3sATI _al_glVertexStream3sATI +#define glVertexStream3svATI _al_glVertexStream3svATI +#define glVertexStream3iATI _al_glVertexStream3iATI +#define glVertexStream3ivATI _al_glVertexStream3ivATI +#define glVertexStream3fATI _al_glVertexStream3fATI +#define glVertexStream3fvATI _al_glVertexStream3fvATI +#define glVertexStream3dATI _al_glVertexStream3dATI +#define glVertexStream3dvATI _al_glVertexStream3dvATI +#define glVertexStream4sATI _al_glVertexStream4sATI +#define glVertexStream4svATI _al_glVertexStream4svATI +#define glVertexStream4iATI _al_glVertexStream4iATI +#define glVertexStream4ivATI _al_glVertexStream4ivATI +#define glVertexStream4fATI _al_glVertexStream4fATI +#define glVertexStream4fvATI _al_glVertexStream4fvATI +#define glVertexStream4dATI _al_glVertexStream4dATI +#define glVertexStream4dvATI _al_glVertexStream4dvATI +#define glNormalStream3bATI _al_glNormalStream3bATI +#define glNormalStream3bvATI _al_glNormalStream3bvATI +#define glNormalStream3sATI _al_glNormalStream3sATI +#define glNormalStream3svATI _al_glNormalStream3svATI +#define glNormalStream3iATI _al_glNormalStream3iATI +#define glNormalStream3ivATI _al_glNormalStream3ivATI +#define glNormalStream3fATI _al_glNormalStream3fATI +#define glNormalStream3fvATI _al_glNormalStream3fvATI +#define glNormalStream3dATI _al_glNormalStream3dATI +#define glNormalStream3dvATI _al_glNormalStream3dvATI +#define glClientActiveVertexStreamATI _al_glClientActiveVertexStreamATI +#define glVertexBlendEnviATI _al_glVertexBlendEnviATI +#define glVertexBlendEnvfATI _al_glVertexBlendEnvfATI +#endif + +#if defined _ALLEGRO_GL_ATI_element_array +#define glElementPointerATI _al_glElementPointerATI +#define glDrawElementArrayATI _al_glDrawElementArrayATI +#define glDrawRangeElementArrayATI _al_glDrawRangeElementArrayATI +#endif + +#if defined _ALLEGRO_GL_SUN_mesh_array +#define glDrawMeshArraysSUN _al_glDrawMeshArraysSUN +#endif + +#if defined _ALLEGRO_GL_NV_occlusion_query +#define glGenOcclusionQueriesNV _al_glGenOcclusionQueriesNV +#define glDeleteOcclusionQueriesNV _al_glDeleteOcclusionQueriesNV +#define glIsOcclusionQueryNV _al_glIsOcclusionQueryNV +#define glBeginOcclusionQueryNV _al_glBeginOcclusionQueryNV +#define glEndOcclusionQueryNV _al_glEndOcclusionQueryNV +#define glGetOcclusionQueryivNV _al_glGetOcclusionQueryivNV +#define glGetOcclusionQueryuivNV _al_glGetOcclusionQueryuivNV +#endif + +#if defined _ALLEGRO_GL_NV_point_sprite +#define glPointParameteriNV _al_glPointParameteriNV +#define glPointParameterivNV _al_glPointParameterivNV +#endif + +#if defined _ALLEGRO_GL_EXT_stencil_two_side +#define glActiveStencilFaceEXT _al_glActiveStencilFaceEXT +#endif + +#if defined _ALLEGRO_GL_APPLE_element_array +#define glElementPointerAPPLE _al_glElementPointerAPPLE +#define glDrawElementArrayAPPLE _al_glDrawElementArrayAPPLE +#define glDrawRangeElementArrayAPPLE _al_glDrawRangeElementArrayAPPLE +#define glMultiDrawElementArrayAPPLE _al_glMultiDrawElementArrayAPPLE +#define glMultiDrawRangeElementArrayAPPLE _al_glMultiDrawRangeElementArrayAPPLE +#endif + +#if defined _ALLEGRO_GL_APPLE_fence +#define glGenFencesAPPLE _al_glGenFencesAPPLE +#define glDeleteFencesAPPLE _al_glDeleteFencesAPPLE +#define glSetFenceAPPLE _al_glSetFenceAPPLE +#define glIsFenceAPPLE _al_glIsFenceAPPLE +#define glTestFenceAPPLE _al_glTestFenceAPPLE +#define glFinishFenceAPPLE _al_glFinishFenceAPPLE +#define glTestObjectAPPLE _al_glTestObjectAPPLE +#define glFinishObjectAPPLE _al_glFinishObjectAPPLE +#endif + +#if defined _ALLEGRO_GL_APPLE_vertex_array_object +#define glBindVertexArrayAPPLE _al_glBindVertexArrayAPPLE +#define glDeleteVertexArraysAPPLE _al_glDeleteVertexArraysAPPLE +#define glGenVertexArraysAPPLE _al_glGenVertexArraysAPPLE +#define glIsVertexArrayAPPLE _al_glIsVertexArrayAPPLE +#endif + +#if defined _ALLEGRO_GL_APPLE_vertex_array_range +#define glVertexArrayRangeAPPLE _al_glVertexArrayRangeAPPLE +#define glFlushVertexArrayRangeAPPLE _al_glFlushVertexArrayRangeAPPLE +#define glVertexArrayParameteriAPPLE _al_glVertexArrayParameteriAPPLE +#endif + +#if defined _ALLEGRO_GL_ATI_draw_buffers +#define glDrawBuffersATI _al_glDrawBuffersATI +#endif + +#if defined _ALLEGRO_GL_NV_fragment_program +#define glProgramNamedParameter4fNV _al_glProgramNamedParameter4fNV +#define glProgramNamedParameter4dNV _al_glProgramNamedParameter4dNV +#define glProgramNamedParameter4fvNV _al_glProgramNamedParameter4fvNV +#define glProgramNamedParameter4dvNV _al_glProgramNamedParameter4dvNV +#define glGetProgramNamedParameterfvNV _al_glGetProgramNamedParameterfvNV +#define glGetProgramNamedParameterdvNV _al_glGetProgramNamedParameterdvNV +#endif + +#if defined _ALLEGRO_GL_NV_half_float +#define glVertex2hNV _al_glVertex2hNV +#define glVertex2hvNV _al_glVertex2hvNV +#define glVertex3hNV _al_glVertex3hNV +#define glVertex3hvNV _al_glVertex3hvNV +#define glVertex4hNV _al_glVertex4hNV +#define glVertex4hvNV _al_glVertex4hvNV +#define glNormal3hNV _al_glNormal3hNV +#define glNormal3hvNV _al_glNormal3hvNV +#define glColor3hNV _al_glColor3hNV +#define glColor3hvNV _al_glColor3hvNV +#define glColor4hNV _al_glColor4hNV +#define glColor4hvNV _al_glColor4hvNV +#define glTexCoord1hNV _al_glTexCoord1hNV +#define glTexCoord1hvNV _al_glTexCoord1hvNV +#define glTexCoord2hNV _al_glTexCoord2hNV +#define glTexCoord2hvNV _al_glTexCoord2hvNV +#define glTexCoord3hNV _al_glTexCoord3hNV +#define glTexCoord3hvNV _al_glTexCoord3hvNV +#define glTexCoord4hNV _al_glTexCoord4hNV +#define glTexCoord4hvNV _al_glTexCoord4hvNV +#define glMultiTexCoord1hNV _al_glMultiTexCoord1hNV +#define glMultiTexCoord1hvNV _al_glMultiTexCoord1hvNV +#define glMultiTexCoord2hNV _al_glMultiTexCoord2hNV +#define glMultiTexCoord2hvNV _al_glMultiTexCoord2hvNV +#define glMultiTexCoord3hNV _al_glMultiTexCoord3hNV +#define glMultiTexCoord3hvNV _al_glMultiTexCoord3hvNV +#define glMultiTexCoord4hNV _al_glMultiTexCoord4hNV +#define glMultiTexCoord4hvNV _al_glMultiTexCoord4hvNV +#define glFogCoordhNV _al_glFogCoordhNV +#define glFogCoordhvNV _al_glFogCoordhvNV +#define glSecondaryColor3hNV _al_glSecondaryColor3hNV +#define glSecondaryColor3hvNV _al_glSecondaryColor3hvNV +#define glVertexWeighthNV _al_glVertexWeighthNV +#define glVertexWeighthvNV _al_glVertexWeighthvNV +#define glVertexAttrib1hNV _al_glVertexAttrib1hNV +#define glVertexAttrib1hvNV _al_glVertexAttrib1hvNV +#define glVertexAttrib2hNV _al_glVertexAttrib2hNV +#define glVertexAttrib2hvNV _al_glVertexAttrib2hvNV +#define glVertexAttrib3hNV _al_glVertexAttrib3hNV +#define glVertexAttrib3hvNV _al_glVertexAttrib3hvNV +#define glVertexAttrib4hNV _al_glVertexAttrib4hNV +#define glVertexAttrib4hvNV _al_glVertexAttrib4hvNV +#define glVertexAttribs1hvNV _al_glVertexAttribs1hvNV +#define glVertexAttribs2hvNV _al_glVertexAttribs2hvNV +#define glVertexAttribs3hvNV _al_glVertexAttribs3hvNV +#define glVertexAttribs4hvNV _al_glVertexAttribs4hvNV +#endif + +#if defined _ALLEGRO_GL_NV_pixel_data_range +#define glPixelDataRangeNV _al_glPixelDataRangeNV +#define glFlushPixelDataRangeNV _al_glFlushPixelDataRangeNV +#endif + +#if defined _ALLEGRO_GL_NV_primitive_restart +#define glPrimitiveRestartNV _al_glPrimitiveRestartNV +#define glPrimitiveRestartIndexNV _al_glPrimitiveRestartIndexNV +#endif + +#if defined _ALLEGRO_GL_ATI_map_object_buffer +#define glMapObjectBufferATI _al_glMapObjectBufferATI +#define glUnmapObjectBufferATI _al_glUnmapObjectBufferATI +#endif + +#if defined _ALLEGRO_GL_ATI_separate_stencil +#define glStencilOpSeparateATI _al_glStencilOpSeparateATI +#define glStencilFuncSeparateATI _al_glStencilFuncSeparateATI +#endif + +#if defined _ALLEGRO_GL_ATI_vertex_attrib_array_object +#define glVertexAttribArrayObjectATI _al_glVertexAttribArrayObjectATI +#define glGetVertexAttribArrayObjectfvATI _al_glGetVertexAttribArrayObjectfvATI +#define glGetVertexAttribArrayObjectivATI _al_glGetVertexAttribArrayObjectivATI +#endif + +#if defined _ALLEGRO_GL_OES_byte_coordinates +#define glVertex2bOES _al_glVertex2bOES +#define glVertex3bOES _al_glVertex3bOES +#define glVertex4bOES _al_glVertex4bOES +#define glVertex2bvOES _al_glVertex2bvOES +#define glVertex3bvOES _al_glVertex3bvOES +#define glVertex4bvOES _al_glVertex4bvOES +#define glTexCoord1bOES _al_glTexCoord1bOES +#define glTexCoord2bOES _al_glTexCoord2bOES +#define glTexCoord3bOES _al_glTexCoord3bOES +#define glTexCoord4bOES _al_glTexCoord4bOES +#define glTexCoord1bvOES _al_glTexCoord1bvOES +#define glTexCoord2bvOES _al_glTexCoord2bvOES +#define glTexCoord3bvOES _al_glTexCoord3bvOES +#define glTexCoord4bvOES _al_glTexCoord4bvOES +#define glMultiTexCoord1bOES _al_glMultiTexCoord1bOES +#define glMultiTexCoord2bOES _al_glMultiTexCoord2bOES +#define glMultiTexCoord3bOES _al_glMultiTexCoord3bOES +#define glMultiTexCoord4bOES _al_glMultiTexCoord4bOES +#define glMultiTexCoord1bvOES _al_glMultiTexCoord1bvOES +#define glMultiTexCoord2bvOES _al_glMultiTexCoord2bvOES +#define glMultiTexCoord3bvOES _al_glMultiTexCoord3bvOES +#define glMultiTexCoord4bvOES _al_glMultiTexCoord4bvOES +#endif + +#if defined _ALLEGRO_GL_OES_fixed_point +#define glVertex2xOES _al_glVertex2xOES +#define glVertex3xOES _al_glVertex3xOES +#define glVertex4xOES _al_glVertex4xOES +#define glVertex2xvOES _al_glVertex2xvOES +#define glVertex3xvOES _al_glVertex3xvOES +#define glVertex4xvOES _al_glVertex4xvOES +#define glNormal3xOES _al_glNormal3xOES +#define glNormal3xvOES _al_glNormal3xvOES +#define glTexCoord1xOES _al_glTexCoord1xOES +#define glTexCoord2xOES _al_glTexCoord2xOES +#define glTexCoord3xOES _al_glTexCoord3xOES +#define glTexCoord4xOES _al_glTexCoord4xOES +#define glTexCoord1xvOES _al_glTexCoord1xvOES +#define glTexCoord2xvOES _al_glTexCoord2xvOES +#define glTexCoord3xvOES _al_glTexCoord3xvOES +#define glTexCoord4xvOES _al_glTexCoord4xvOES +#define glMultiTexCoord1xOES _al_glMultiTexCoord1xOES +#define glMultiTexCoord2xOES _al_glMultiTexCoord2xOES +#define glMultiTexCoord3xOES _al_glMultiTexCoord3xOES +#define glMultiTexCoord4xOES _al_glMultiTexCoord4xOES +#define glMultiTexCoord1xvOES _al_glMultiTexCoord1xvOES +#define glMultiTexCoord2xvOES _al_glMultiTexCoord2xvOES +#define glMultiTexCoord3xvOES _al_glMultiTexCoord3xvOES +#define glMultiTexCoord4xvOES _al_glMultiTexCoord4xvOES +#define glColor3xOES _al_glColor3xOES +#define glColor4xOES _al_glColor4xOES +#define glColor3xvOES _al_glColor3xvOES +#define glColor4xvOES _al_glColor4xvOES +#define glIndexxOES _al_glIndexxOES +#define glIndexxvOES _al_glIndexxvOES +#define glRectxOES _al_glRectxOES +#define glRectxvOES _al_glRectxvOES +#define glDepthRangexOES _al_glDepthRangexOES +#define glLoadMatrixxOES _al_glLoadMatrixxOES +#define glMultMatrixxOES _al_glMultMatrixxOES +#define glLoadTransposeMatrixxOES _al_glLoadTransposeMatrixxOES +#define glMultTransposeMatrixxOES _al_glMultTransposeMatrixxOES +#define glRotatexOES _al_glRotatexOES +#define glScalexOES _al_glScalexOES +#define glTranslatexOES _al_glTranslatexOES +#define glFrustumxOES _al_glFrustumxOES +#define glOrthoxOES _al_glOrthoxOES +#define glTexGenxOES _al_glTexGenxOES +#define glTexGenxvOES _al_glTexGenxvOES +#define glGetTexGenxvOES _al_glGetTexGenxvOES +#define glClipPlanexOES _al_glClipPlanexOES +#define glGetClipPlanexOES _al_glGetClipPlanexOES +#define glRasterPos2xOES _al_glRasterPos2xOES +#define glRasterPos3xOES _al_glRasterPos3xOES +#define glRasterPos4xOES _al_glRasterPos4xOES +#define glRasterPos2xvOES _al_glRasterPos2xvOES +#define glRasterPos3xvOES _al_glRasterPos3xvOES +#define glRasterPos4xvOES _al_glRasterPos4xvOES +#define glMaterialxOES _al_glMaterialxOES +#define glMaterialxvOES _al_glMaterialxvOES +#define glGetMaterialxOES _al_glGetMaterialxOES +#define glLightxOES _al_glLightxOES +#define glLightxvOES _al_glLightxvOES +#define glGetLightxOES _al_glGetLightxOES +#define glLightModelxOES _al_glLightModelxOES +#define glLightModelxvOES _al_glLightModelxvOES +#define glPointSizexOES _al_glPointSizexOES +#define glLineWidthxOES _al_glLineWidthxOES +#define glPolygonOffsetxOES _al_glPolygonOffsetxOES +#define glPixelStorex _al_glPixelStorex +#define glPixelTransferxOES _al_glPixelTransferxOES +#define glPixelMapx _al_glPixelMapx +#define glGetPixelMapxv _al_glGetPixelMapxv +#define glConvolutionParameterxOES _al_glConvolutionParameterxOES +#define glConvolutionParameterxvOES _al_glConvolutionParameterxvOES +#define glGetConvolutionParameterxvOES _al_glGetConvolutionParameterxvOES +#define glGetHistogramParameterxvOES _al_glGetHistogramParameterxvOES +#define glPixelZoomxOES _al_glPixelZoomxOES +#define glBitmapxOES _al_glBitmapxOES +#define glTexParameterxOES _al_glTexParameterxOES +#define glTexParameterxvOES _al_glTexParameterxvOES +#define glGetTexParameterxvOES _al_glGetTexParameterxvOES +#define glGetTexLevelParameterxvOES _al_glGetTexLevelParameterxvOES +#define glPrioritizeTexturesxOES _al_glPrioritizeTexturesxOES +#define glTexEnvxOES _al_glTexEnvxOES +#define glTexEnvxvOES _al_glTexEnvxvOES +#define glGetTexEnvxvOES _al_glGetTexEnvxvOES +#define glFogxOES _al_glFogxOES +#define glFogxvOES _al_glFogxvOES +#define glSampleCoverageOES _al_glSampleCoverageOES +#define glAlphaFuncxOES _al_glAlphaFuncxOES +#define glBlendColorxOES _al_glBlendColorxOES +#define glClearColorxOES _al_glClearColorxOES +#define glClearDepthxOES _al_glClearDepthxOES +#define glClearAccumxOES _al_glClearAccumxOES +#define glAccumxOES _al_glAccumxOES +#define glMap1xOES _al_glMap1xOES +#define glMap2xOES _al_glMap2xOES +#define glMapGrid1xOES _al_glMapGrid1xOES +#define glMapGrid2xOES _al_glMapGrid2xOES +#define glGetMapxvOES _al_glGetMapxvOES +#define glEvalCoord1xOES _al_glEvalCoord1xOES +#define glEvalCoord2xOES _al_glEvalCoord2xOES +#define glEvalCoord1xvOES _al_glEvalCoord1xvOES +#define glEvalCoord2xvOES _al_glEvalCoord2xvOES +#define glFeedbackBufferxOES _al_glFeedbackBufferxOES +#define glPassThroughxOES _al_glPassThroughxOES +#define glGetFixedvOES _al_glGetFixedvOES +#endif + +#if defined _ALLEGRO_GL_OES_single_precision +#define glDepthRangefOES _al_glDepthRangefOES +#define glFrustumfOES _al_glFrustumfOES +#define glOrthofOES _al_glOrthofOES +#define glClipPlanefOES _al_glClipPlanefOES +#define glGetClipPlanefOES _al_glGetClipPlanefOES +#define glClearDepthfOES _al_glClearDepthfOES +#endif + +#if defined _ALLEGRO_GL_OES_query_matrix +#define glQueryMatrixxOES _al_glQueryMatrixxOES +#endif + +#if defined _ALLEGRO_GL_EXT_depth_bounds_test +#define glDepthBoundsEXT _al_glDepthBoundsEXT +#endif + + +#if defined _ALLEGRO_GL_EXT_blend_equation_separate +#define glBlendEquationSeparateEXT _al_glBlendEquationSeparateEXT +#endif + + +#if defined _ALLEGRO_GL_EXT_framebuffer_object +#define glIsRenderbufferEXT _al_glIsRenderbufferEXT +#define glBindRenderbufferEXT _al_glBindRenderbufferEXT +#define glDeleteRenderbuffersEXT _al_glDeleteRenderbuffersEXT +#define glGenRenderbuffersEXT _al_glGenRenderbuffersEXT +#define glRenderbufferStorageEXT _al_glRenderbufferStorageEXT +#define glGetRenderbufferParameterivEXT _al_glGetRenderbufferParameterivEXT +#define glIsFramebufferEXT _al_glIsFramebufferEXT +#define glBindFramebufferEXT _al_glBindFramebufferEXT +#define glDeleteFramebuffersEXT _al_glDeleteFramebuffersEXT +#define glGenFramebuffersEXT _al_glGenFramebuffersEXT +#define glCheckFramebufferStatusEXT _al_glCheckFramebufferStatusEXT +#define glFramebufferTexture1DEXT _al_glFramebufferTexture1DEXT +#define glFramebufferTexture2DEXT _al_glFramebufferTexture2DEXT +#define glFramebufferTexture3DEXT _al_glFramebufferTexture3DEXT +#define glFramebufferRenderbufferEXT _al_glFramebufferRenderbufferEXT +#define glGetFramebufferAttachmentParameterivEXT _al_glGetFramebufferAttachmentParameterivEXT +#define glGenerateMipmapEXT _al_glGenerateMipmapEXT +#endif + +#if defined _ALLEGRO_GL_GREMEDY_string_marker +#define glStringMarkerGREMEDY _al_glStringMarkerGREMEDY +#endif + +#if defined _ALLEGRO_GL_EXT_stencil_clear_tag +#define glStencilClearTagEXT _al_glStencilClearTagEXT +#endif + +#if defined _ALLEGRO_GL_EXT_framebuffer_blit +#define glBlitFramebufferEXT _al_glBlitFramebufferEXT +#endif + +#if defined _ALLEGRO_GL_EXT_framebuffer_multisample +#define glRenderbufferStorageMultisampleEXT _al_glRenderbufferStorageMultisampleEXT +#endif + +#if defined _ALLEGRO_GL_EXT_timer_query +#define glGetQueryObjecti64vEXT _al_glGetQueryObjecti64vEXT +#define glGetQueryObjectui64vEXT _al_glGetQueryObjectui64vEXT +#endif + +#if defined _ALLEGRO_GL_EXT_gpu_program_parameters +#define glProgramEnvParameters4fvEXT _al_glProgramEnvParameters4fvEXT +#define glProgramLocalParameters4fvEXT _al_glProgramLocalParameters4fvEXT +#endif + +#if defined _ALLEGRO_GL_APPLE_flush_buffer_range +#define glBufferParameteriAPPLE _al_glBufferParameteriAPPLE +#define glFlushMappedBufferRangeAPPLE _al_glFlushMappedBufferRangeAPPLE +#endif + +#if defined _ALLEGRO_GL_EXT_bindable_uniform +#define glUniformBufferEXT _al_glUniformBufferEXT +#define glGetUniformBufferSizeEXT _al_glGetUniformBufferSizeEXT +#define glGetUniformOffsetEXT _al_glGetUniformOffsetEXT +#endif + +#if defined _ALLEGRO_GL_EXT_draw_buffers2 +#define glColorMaskIndexedEXT _al_glColorMaskIndexedEXT +#define glGetBooleanIndexedvEXT _al_glGetBooleanIndexedvEXT +#define glGetIntegerIndexedvEXT _al_glGetIntegerIndexedvEXT +#define glEnableIndexedEXT _al_glEnableIndexedEXT +#define glDisableIndexedEXT _al_glDisableIndexedEXT +#define glIsEnabledIndexedEXT _al_glIsEnabledIndexedEXT +#endif + +#if defined _ALLEGRO_GL_EXT_draw_instanced +#define glDrawArraysInstancedEXT _al_glDrawArraysInstancedEXT +#define glDrawElementsInstancedEXT _al_glDrawElementsInstancedEXT +#endif + +#if defined _ALLEGRO_GL_EXT_geometry_shader4 +#define glProgramParameteriEXT _al_glProgramParameteriEXT +#define glFramebufferTextureEXT _al_glFramebufferTextureEXT +#if !defined _ALLEGRO_GL_EXT_texture_array +#define glFramebufferTextureLayerEXT _al_glFramebufferTextureLayerEXT +#endif +#define glFramebufferTextureFaceEXT _al_glFramebufferTextureFaceEXT +#endif + +#if defined _ALLEGRO_GL_EXT_gpu_shader4 +#define glVertexAttribI1iEXT _al_glVertexAttribI1iEXT +#define glVertexAttribI2iEXT _al_glVertexAttribI2iEXT +#define glVertexAttribI3iEXT _al_glVertexAttribI3iEXT +#define glVertexAttribI4iEXT _al_glVertexAttribI4iEXT +#define glVertexAttribI1uiEXT _al_glVertexAttribI1uiEXT +#define glVertexAttribI2uiEXT _al_glVertexAttribI2uiEXT +#define glVertexAttribI3uiEXT _al_glVertexAttribI3uiEXT +#define glVertexAttribI4uiEXT _al_glVertexAttribI4uiEXT +#define glVertexAttribI1ivEXT _al_glVertexAttribI1ivEXT +#define glVertexAttribI2ivEXT _al_glVertexAttribI2ivEXT +#define glVertexAttribI3ivEXT _al_glVertexAttribI3ivEXT +#define glVertexAttribI4ivEXT _al_glVertexAttribI4ivEXT +#define glVertexAttribI1uivEXT _al_glVertexAttribI1uivEXT +#define glVertexAttribI2uivEXT _al_glVertexAttribI2uivEXT +#define glVertexAttribI3uivEXT _al_glVertexAttribI3uivEXT +#define glVertexAttribI4uivEXT _al_glVertexAttribI4uivEXT +#define glVertexAttribI4bvEXT _al_glVertexAttribI4bvEXT +#define glVertexAttribI4svEXT _al_glVertexAttribI4svEXT +#define glVertexAttribI4ubvEXT _al_glVertexAttribI4ubvEXT +#define glVertexAttribI4usvEXT _al_glVertexAttribI4usvEXT +#define glVertexAttribIPointerEXT _al_glVertexAttribIPointerEXT +#define glGetVertexAttribIivEXT _al_glGetVertexAttribIivEXT +#define glGetVertexAttribIuivEXT _al_glGetVertexAttribIuivEXT +#define glUniform1uiEXT _al_glUniform1uiEXT +#define glUniform2uiEXT _al_glUniform2uiEXT +#define glUniform3uiEXT _al_glUniform3uiEXT +#define glUniform4uiEXT _al_glUniform4uiEXT +#define glUniform1uivEXT _al_glUniform1uivEXT +#define glUniform2uivEXT _al_glUniform2uivEXT +#define glUniform3uivEXT _al_glUniform3uivEXT +#define glUniform4uivEXT _al_glUniform4uivEXT +#define glGetUniformuivEXT _al_glGetUniformuivEXT +#define glBindFragDataLocationEXT _al_glBindFragDataLocationEXT +#define glGetFragDataLocationEXT _al_glGetFragDataLocationEXT +#endif + +#if defined _ALLEGRO_GL_EXT_texture_array +#define glFramebufferTextureLayerEXT _al_glFramebufferTextureLayerEXT +#endif + +#if defined _ALLEGRO_GL_EXT_texture_buffer_object +#define glTexBufferEXT _al_glTexBufferEXT +#endif + +#if defined _ALLEGRO_GL_texture_integer +#define glClearColorIiEXT _al_glClearColorIiEXT +#define glClearColorIuiEXT _al_glClearColorIuiEXT +#define glTexParameterIivEXT _al_glTexParameterIivEXT +#define glTexParameterIuivEXT _al_glTexParameterIuivEXT +#define glGetTexParameterIivEXT _al_glGetTexParameterIivEXT +#define glGetTexParameterIiuvEXT _al_glGetTexParameterIiuvEXT +#endif + +#if defined _ALLEGRO_GL_NV_depth_buffer_float +#define glDepthRangedNV _al_glDepthRangedNV +#define glClearDepthdNV _al_glClearDepthdNV +#define glDepthBoundsdNV _al_glDepthBoundsdNV +#endif + +#if defined _ALLEGRO_GL_NV_framebuffer_multisample_coverage +#define glRenderbufferStorageMultsampleCoverageNV _al_glRenderbufferStorageMultsampleCoverageNV +#endif + +#if defined _ALLEGRO_GL_NV_geometry_program4 +#define glProgramVertexLimitNV _al_glProgramVertexLimitNV +#if !defined _ALLEGRO_GL_EXT_geometry_shader4 +#define glFramebufferTextureEXT _al_glFramebufferTextureEXT +#if !defined _ALLEGRO_GL_EXT_texture_array +#define glFramebufferTextureLayerEXT _al_glFramebufferTextureLayerEXT +#endif +#endif +#endif + +#if defined _ALLEGRO_GL_NV_gpu_program4 +#define glProgramLocalParameterI4iNV _al_glProgramLocalParameterI4iNV +#define glProgramLocalParameterI4ivNV _al_glProgramLocalParameterI4ivNV +#define glProgramLocalParametersI4ivNV _al_glProgramLocalParametersI4ivNV +#define glProgramLocalParameterI4uiNV _al_glProgramLocalParameterI4uiNV +#define glProgramLocalParameterI4uivNV _al_glProgramLocalParameterI4uivNV +#define glProgramLocalParametersI4uivNV _al_glProgramLocalParametersI4uivNV +#define glProgramEnvParameterI4iNV _al_glProgramEnvParameterI4iNV +#define glProgramEnvParameterI4ivNV _al_glProgramEnvParameterI4ivNV +#define glProgramEnvParametersI4ivNV _al_glProgramEnvParametersI4ivNV +#define glProgramEnvParameterI4uiNV _al_glProgramEnvParameterI4uiNV +#define glProgramEnvParameterI4uivNV _al_glProgramEnvParameterI4uivNV +#define glProgramEnvParametersI4uivNV _al_glProgramEnvParametersI4uivNV +#define glGetProgramLocalParameterIivNV _al_glGetProgramLocalParameterIivNV +#define glGetProgramLocalParameterIuivNV _al_glGetProgramLocalParameterIuivNV +#define glGetProgramEnvParameterIivNV _al_glGetProgramEnvParameterIivNV +#define glGetProgramEnvParameterIuivNV _al_glGetProgramEnvParameterIuivNV +#endif + +#if defined _ALLEGRO_GL_NV_parameter_buffer_object +#if !defined _ALLEGRO_GL_NV_transform_feedback +#define glBindBufferRangeNV _al_glBindBufferRangeNV +#define glBindBufferOffsetNV _al_glBindBufferOffsetNV +#define glBindBufferBaseNV _al_glBindBufferBaseNV +#endif +#define glProgramBufferParametersfvNV _al_glProgramBufferParametersfvNV +#define glProgramBufferParametersIivNV _al_glProgramBufferParametersIivNV +#define glProgramBufferParametersIuivNV _al_glProgramBufferParametersIuivNV +#if !defined _ALLEGRO_GL_EXT_draw_buffers2 +#define glGetIntegerIndexedvEXT _al_glGetIntegerIndexedvEXT +#endif +#endif + +#if defined _ALLEGRO_GL_NV_transform_feedback +#define glBindBufferRangeNV _al_glBindBufferRangeNV +#define glBindBufferOffsetNV _al_glBindBufferOffsetNV +#define glBindBufferBaseNV _al_glBindBufferBaseNV +#define glTransformFeedbackAttribsNV _al_glTransformFeedbackAttribsNV +#define glTransformFeedbackVaryingsNV _al_glTransformFeedbackVaryingsNV +#define glBeginTransformFeedbackNV _al_glBeginTransformFeedbackNV +#define glEndTransformFeedbackNV _al_glEndTransformFeedbackNV +#define glGetVaryingLocationNV _al_glGetVaryingLocationNV +#define glGetActiveVaryingNV _al_glGetActiveVaryingNV +#define glActiveVaryingNV _al_glActiveVaryingNV +#define glGetTransformFeedbackVaryingNV _al_glGetTransformFeedbackVaryingNV +#if !defined _ALLEGRO_GL_EXT_draw_buffers2 +#define glGetBooleanIndexedvEXT _al_glGetBooleanIndexedvEXT +/*AGL_API(void,GetIntegerIndexedvEXT,(GLenum,GLuint,GLint*))*/ +#endif +#endif + +#if defined _ALLEGRO_GL_NV_vertex_program4 +#ifndef _ALLEGRO_GL_EXT_gpu_shader4 +#define glVertexAttribI1iEXT _al_glVertexAttribI1iEXT +#define glVertexAttribI2iEXT _al_glVertexAttribI2iEXT +#define glVertexAttribI3iEXT _al_glVertexAttribI3iEXT +#define glVertexAttribI4iEXT _al_glVertexAttribI4iEXT +#define glVertexAttribI1uiEXT _al_glVertexAttribI1uiEXT +#define glVertexAttribI2uiEXT _al_glVertexAttribI2uiEXT +#define glVertexAttribI3uiEXT _al_glVertexAttribI3uiEXT +#define glVertexAttribI4uiEXT _al_glVertexAttribI4uiEXT +#define glVertexAttribI1ivEXT _al_glVertexAttribI1ivEXT +#define glVertexAttribI2ivEXT _al_glVertexAttribI2ivEXT +#define glVertexAttribI3ivEXT _al_glVertexAttribI3ivEXT +#define glVertexAttribI4ivEXT _al_glVertexAttribI4ivEXT +#define glVertexAttribI1uivEXT _al_glVertexAttribI1uivEXT +#define glVertexAttribI2uivEXT _al_glVertexAttribI2uivEXT +#define glVertexAttribI3uivEXT _al_glVertexAttribI3uivEXT +#define glVertexAttribI4uivEXT _al_glVertexAttribI4uivEXT +#define glVertexAttribI4bvEXT _al_glVertexAttribI4bvEXT +#define glVertexAttribI4svEXT _al_glVertexAttribI4svEXT +#define glVertexAttribI4ubvEXT _al_glVertexAttribI4ubvEXT +#define glVertexAttribI4usvEXT _al_glVertexAttribI4usvEXT +#define glVertexAttribIPointerEXT _al_glVertexAttribIPointerEXT +#define glGetVertexAttribIivEXT _al_glGetVertexAttribIivEXT +#define glGetVertexAttribIuivEXT _al_glGetVertexAttribIuivEXT +#endif +#endif + +#if defined _ALLEGRO_GL_GREMEDY_frame_terminator +#define glFrameTerminatorGREMEDY _al_glFrameTerminatorGREMEDY +#endif + +#if defined _ALLEGRO_GL_NV_conditional_render +#define glBeginConditionalRenderNV _al_glBeginConditionalRenderNV +#define glEndConditionalRenderNV _al_glEndConditionalRenderNV +#endif + +#if defined _ALLEGRO_GL_EXT_transform_feedback +#define glBeginTransformFeedbackEXT _al_glBeginTransformFeedbackEXT +#define glEndTransformFeedbackEXT _al_glEndTransformFeedbackEXT +#define glBindBufferRangeEXT _al_glBindBufferRangeEXT +#define glBindBufferOffsetEXT _al_glBindBufferOffsetEXT +#define glBindBufferBaseEXT _al_glBindBufferBaseEXT +#define glTransformFeedbackVaryingsEXT _al_glTransformFeedbackVaryingsEXT +#define glGetTransformFeedbackVaryingEXT _al_glGetTransformFeedbackVaryingEXT +#endif + +#if defined _ALLEGRO_GL_EXT_direct_state_access +#define glClientAttribDefaultEXT _al_glClientAttribDefaultEXT +#define glPushClientAttribDefaultEXT _al_glPushClientAttribDefaultEXT +#define glMatrixLoadfEXT _al_glMatrixLoadfEXT +#define glMatrixLoaddEXT _al_glMatrixLoaddEXT +#define glMatrixMultfEXT _al_glMatrixMultfEXT +#define glMatrixMultdEXT _al_glMatrixMultdEXT +#define glMatrixLoadIdentityEXT _al_glMatrixLoadIdentityEXT +#define glMatrixRotatefEXT _al_glMatrixRotatefEXT +#define glMatrixRotatedEXT _al_glMatrixRotatedEXT +#define glMatrixScalefEXT _al_glMatrixScalefEXT +#define glMatrixScaledEXT _al_glMatrixScaledEXT +#define glMatrixTranslatefEXT _al_glMatrixTranslatefEXT +#define glMatrixTranslatedEXT _al_glMatrixTranslatedEXT +#define glMatrixFrustumEXT _al_glMatrixFrustumEXT +#define glMatrixOrthoEXT _al_glMatrixOrthoEXT +#define glMatrixPopEXT _al_glMatrixPopEXT +#define glMatrixPushEXT _al_glMatrixPushEXT +#define glMatrixLoadTransposefEXT _al_glMatrixLoadTransposefEXT +#define glMatrixLoadTransposedEXT _al_glMatrixLoadTransposedEXT +#define glMatrixMultTransposefEXT _al_glMatrixMultTransposefEXT +#define glMatrixMultTransposedEXT _al_glMatrixMultTransposedEXT +#define glTextureParameterfEXT _al_glTextureParameterfEXT +#define glTextureParameterfvEXT _al_glTextureParameterfvEXT +#define glTextureParameteriEXT _al_glTextureParameteriEXT +#define glTextureParameterivEXT _al_glTextureParameterivEXT +#define glTextureImage1DEXT _al_glTextureImage1DEXT +#define glTextureImage2DEXT _al_glTextureImage2DEXT +#define glTextureSubImage1DEXT _al_glTextureSubImage1DEXT +#define glTextureSubImage2DEXT _al_glTextureSubImage2DEXT +#define glCopyTextureImage1DEXT _al_glCopyTextureImage1DEXT +#define glCopyTextureImage2DEXT _al_glCopyTextureImage2DEXT +#define glCopyTextureSubImage1DEXT _al_glCopyTextureSubImage1DEXT +#define glCopyTextureSubImage2DEXT _al_glCopyTextureSubImage2DEXT +#define glGetTextureImageEXT _al_glGetTextureImageEXT +#define glGetTextureParameterfvEXT _al_glGetTextureParameterfvEXT +#define glGetTextureParameterivEXT _al_glGetTextureParameterivEXT +#define glGetTextureLevelParameterfvEXT _al_glGetTextureLevelParameterfvEXT +#define glGetTextureLevelParameterivEXT _al_glGetTextureLevelParameterivEXT +#define glTextureImage3DEXT _al_glTextureImage3DEXT +#define glTextureSubImage3DEXT _al_glTextureSubImage3DEXT +#define glCopyTextureSubImage3DEXT _al_glCopyTextureSubImage3DEXT +#define glMultiTexParameterfEXT _al_glMultiTexParameterfEXT +#define glMultiTexParameterfvEXT _al_glMultiTexParameterfvEXT +#define glMultiTexParameteriEXT _al_glMultiTexParameteriEXT +#define glMultiTexParameterivEXT _al_glMultiTexParameterivEXT +#define glMultiTexImage1DEXT _al_glMultiTexImage1DEXT +#define glMultiTexImage2DEXT _al_glMultiTexImage2DEXT +#define glMultiTexSubImage1DEXT _al_glMultiTexSubImage1DEXT +#define glMultiTexSubImage2DEXT _al_glMultiTexSubImage2DEXT +#define glCopyMultiTexImage1DEXT _al_glCopyMultiTexImage1DEXT +#define glCopyMultiTexImage2DEXT _al_glCopyMultiTexImage2DEXT +#define glCopyMultiTexSubImage1DEXT _al_glCopyMultiTexSubImage1DEXT +#define glCopyMultiTexSubImage2DEXT _al_glCopyMultiTexSubImage2DEXT +#define glGetMultiTexImageEXT _al_glGetMultiTexImageEXT +#define glGetMultiTexParameterfvEXT _al_glGetMultiTexParameterfvEXT +#define glGetMultiTexParameterivEXT _al_glGetMultiTexParameterivEXT +#define glGetMultiTexLevelParameterfvEXT _al_glGetMultiTexLevelParameterfvEXT +#define glGetMultiTexLevelParameterivEXT _al_glGetMultiTexLevelParameterivEXT +#define glMultiTexImage3DEXT _al_glMultiTexImage3DEXT +#define glMultiTexSubImage3DEXT _al_glMultiTexSubImage3DEXT +#define glCopyMultiTexSubImage3DEXT _al_glCopyMultiTexSubImage3DEXT +#define glBindMultiTextureEXT _al_glBindMultiTextureEXT +#define glEnableClientStateIndexedEXT _al_glEnableClientStateIndexedEXT +#define glDisableClientStateIndexedEXT _al_glDisableClientStateIndexedEXT +#define glMultiTexCoordPointerEXT _al_glMultiTexCoordPointerEXT +#define glMultiTexEnvfEXT _al_glMultiTexEnvfEXT +#define glMultiTexEnvfvEXT _al_glMultiTexEnvfvEXT +#define glMultiTexEnviEXT _al_glMultiTexEnviEXT +#define glMultiTexEnvivEXT _al_glMultiTexEnvivEXT +#define glMultiTexGendEXT _al_glMultiTexGendEXT +#define glMultiTexGendvEXT _al_glMultiTexGendvEXT +#define glMultiTexGenfEXT _al_glMultiTexGenfEXT +#define glMultiTexGenfvEXT _al_glMultiTexGenfvEXT +#define glMultiTexGeniEXT _al_glMultiTexGeniEXT +#define glMultiTexGenivEXT _al_glMultiTexGenivEXT +#define glGetMultiTexEnvfvEXT _al_glGetMultiTexEnvfvEXT +#define glGetMultiTexEnvivEXT _al_glGetMultiTexEnvivEXT +#define glGetMultiTexGendvEXT _al_glGetMultiTexGendvEXT +#define glGetMultiTexGenfvEXT _al_glGetMultiTexGenfvEXT +#define glGetMultiTexGenivEXT _al_glGetMultiTexGenivEXT +#define glGetFloatIndexedvEXT _al_glGetFloatIndexedvEXT +#define glGetDoubleIndexedvEXT _al_glGetDoubleIndexedvEXT +#define glGetPointerIndexedvEXT _al_glGetPointerIndexedvEXT +#define glCompressedTextureImage3DEXT _al_glCompressedTextureImage3DEXT +#define glCompressedTextureImage2DEXT _al_glCompressedTextureImage2DEXT +#define glCompressedTextureImage1DEXT _al_glCompressedTextureImage1DEXT +#define glCompressedTextureSubImage3DEXT _al_glCompressedTextureSubImage3DEXT +#define glCompressedTextureSubImage2DEXT _al_glCompressedTextureSubImage2DEXT +#define glCompressedTextureSubImage1DEXT _al_glCompressedTextureSubImage1DEXT +#define glGetCompressedTextureImageEXT _al_glGetCompressedTextureImageEXT +#define glCompressedMultiTexImage3DEXT _al_glCompressedMultiTexImage3DEXT +#define glCompressedMultiTexImage2DEXT _al_glCompressedMultiTexImage2DEXT +#define glCompressedMultiTexImage1DEXT _al_glCompressedMultiTexImage1DEXT +#define glCompressedMultiTexSubImage3DEXT _al_glCompressedMultiTexSubImage3DEXT +#define glCompressedMultiTexSubImage2DEXT _al_glCompressedMultiTexSubImage2DEXT +#define glCompressedMultiTexSubImage1DEXT _al_glCompressedMultiTexSubImage1DEXT +#define glGetCompressedMultiTexImageEXT _al_glGetCompressedMultiTexImageEXT +#define glNamedProgramStringEXT _al_glNamedProgramStringEXT +#define glNamedProgramLocalParameter4dEXT _al_glNamedProgramLocalParameter4dEXT +#define glNamedProgramLocalParameter4dvEXT _al_glNamedProgramLocalParameter4dvEXT +#define glNamedProgramLocalParameter4fEXT _al_glNamedProgramLocalParameter4fEXT +#define glNamedProgramLocalParameter4fvEXT _al_glNamedProgramLocalParameter4fvEXT +#define glGetNamedProgramLocalParameterdvEXT _al_glGetNamedProgramLocalParameterdvEXT +#define glGetNamedProgramLocalParameterfvEXT _al_glGetNamedProgramLocalParameterfvEXT +#define glGetNamedProgramivEXT _al_glGetNamedProgramivEXT +#define glGetNamedProgramStringEXT _al_glGetNamedProgramStringEXT +#define glNamedProgramLocalParameters4fvEXT _al_glNamedProgramLocalParameters4fvEXT +#define glNamedProgramLocalParameterI4iEXT _al_glNamedProgramLocalParameterI4iEXT +#define glNamedProgramLocalParameterI4ivEXT _al_glNamedProgramLocalParameterI4ivEXT +#define glNamedProgramLocalParametersI4ivEXT _al_glNamedProgramLocalParametersI4ivEXT +#define glNamedProgramLocalParameterI4uiEXT _al_glNamedProgramLocalParameterI4uiEXT +#define glNamedProgramLocalParameterI4uivEXT _al_glNamedProgramLocalParameterI4uivEXT +#define glNamedProgramLocalParametersI4uivEXT _al_glNamedProgramLocalParametersI4uivEXT +#define glGetNamedProgramLocalParameterIivEXT _al_glGetNamedProgramLocalParameterIivEXT +#define glGetNamedProgramLocalParameterIuivEXT _al_glGetNamedProgramLocalParameterIuivEXT +#define glTextureParameterIivEXT _al_glTextureParameterIivEXT +#define glTextureParameterIuivEXT _al_glTextureParameterIuivEXT +#define glGetTextureParameterIivEXT _al_glGetTextureParameterIivEXT +#define glGetTextureParameterIuivEXT _al_glGetTextureParameterIuivEXT +#define glMultiTexParameterIivEXT _al_glMultiTexParameterIivEXT +#define glMultiTexParameterIuivEXT _al_glMultiTexParameterIuivEXT +#define glGetMultiTexParameterIivEXT _al_glGetMultiTexParameterIivEXT +#define glGetMultiTexParameterIuivEXT _al_glGetMultiTexParameterIuivEXT +#define glProgramUniform1fEXT _al_glProgramUniform1fEXT +#define glProgramUniform2fEXT _al_glProgramUniform2fEXT +#define glProgramUniform3fEXT _al_glProgramUniform3fEXT +#define glProgramUniform4fEXT _al_glProgramUniform4fEXT +#define glProgramUniform1iEXT _al_glProgramUniform1iEXT +#define glProgramUniform2iEXT _al_glProgramUniform2iEXT +#define glProgramUniform3iEXT _al_glProgramUniform3iEXT +#define glProgramUniform4iEXT _al_glProgramUniform4iEXT +#define glProgramUniform1fvEXT _al_glProgramUniform1fvEXT +#define glProgramUniform2fvEXT _al_glProgramUniform2fvEXT +#define glProgramUniform3fvEXT _al_glProgramUniform3fvEXT +#define glProgramUniform4fvEXT _al_glProgramUniform4fvEXT +#define glProgramUniform1ivEXT _al_glProgramUniform1ivEXT +#define glProgramUniform2ivEXT _al_glProgramUniform2ivEXT +#define glProgramUniform3ivEXT _al_glProgramUniform3ivEXT +#define glProgramUniform4ivEXT _al_glProgramUniform4ivEXT +#define glProgramUniformMatrix2fvEXT _al_glProgramUniformMatrix2fvEXT +#define glProgramUniformMatrix3fvEXT _al_glProgramUniformMatrix3fvEXT +#define glProgramUniformMatrix4fvEXT _al_glProgramUniformMatrix4fvEXT +#define glProgramUniformMatrix2x3fvEXT _al_glProgramUniformMatrix2x3fvEXT +#define glProgramUniformMatrix3x2fvEXT _al_glProgramUniformMatrix3x2fvEXT +#define glProgramUniformMatrix2x4fvEXT _al_glProgramUniformMatrix2x4fvEXT +#define glProgramUniformMatrix4x2fvEXT _al_glProgramUniformMatrix4x2fvEXT +#define glProgramUniformMatrix3x4fvEXT _al_glProgramUniformMatrix3x4fvEXT +#define glProgramUniformMatrix4x3fvEXT _al_glProgramUniformMatrix4x3fvEXT +#define glProgramUniform1uiEXT _al_glProgramUniform1uiEXT +#define glProgramUniform2uiEXT _al_glProgramUniform2uiEXT +#define glProgramUniform3uiEXT _al_glProgramUniform3uiEXT +#define glProgramUniform4uiEXT _al_glProgramUniform4uiEXT +#define glProgramUniform1uivEXT _al_glProgramUniform1uivEXT +#define glProgramUniform2uivEXT _al_glProgramUniform2uivEXT +#define glProgramUniform3uivEXT _al_glProgramUniform3uivEXT +#define glProgramUniform4uivEXT _al_glProgramUniform4uivEXT +#define glNamedBufferDataEXT _al_glNamedBufferDataEXT +#define glNamedBufferSubDataEXT _al_glNamedBufferSubDataEXT +#define glMapNamedBufferEXT _al_glMapNamedBufferEXT +#define glUnmapNamedBufferEXT _al_glUnmapNamedBufferEXT +#define glGetNamedBufferParameterivEXT _al_glGetNamedBufferParameterivEXT +#define glGetNamedBufferPointervEXT _al_glGetNamedBufferPointervEXT +#define glGetNamedBufferSubDataEXT _al_glGetNamedBufferSubDataEXT +#define glTextureBufferEXT _al_glTextureBufferEXT +#define glMultiTexBufferEXT _al_glMultiTexBufferEXT +#define glNamedRenderbufferStorageEXT _al_glNamedRenderbufferStorageEXT +#define glGetNamedRenderbufferParameterivEXT _al_glGetNamedRenderbufferParameterivEXT +#define glCheckNamedFramebufferStatusEXT _al_glCheckNamedFramebufferStatusEXT +#define glNamedFramebufferTexture1DEXT _al_glNamedFramebufferTexture1DEXT +#define glNamedFramebufferTexture2DEXT _al_glNamedFramebufferTexture2DEXT +#define glNamedFramebufferTexture3DEXT _al_glNamedFramebufferTexture3DEXT +#define glNamedFramebufferRenderbufferEXT _al_glNamedFramebufferRenderbufferEXT +#define glGetNamedFramebufferAttachmentParameterivEXT _al_glGetNamedFramebufferAttachmentParameterivEXT +#define glGenerateTextureMipmapEXT _al_glGenerateTextureMipmapEXT +#define glGenerateMultiTexMipmapEXT _al_glGenerateMultiTexMipmapEXT +#define glFramebufferDrawBufferEXT _al_glFramebufferDrawBufferEXT +#define glFramebufferDrawBuffersEXT _al_glFramebufferDrawBuffersEXT +#define glFramebufferReadBufferEXT _al_glFramebufferReadBufferEXT +#define glGetFramebufferParameterivEXT _al_glGetFramebufferParameterivEXT +#define glNamedRenderbufferStorageMultisampleEXT _al_glNamedRenderbufferStorageMultisampleEXT +#define glNamedRenderbufferStorageMultisampleCoverageEXT _al_glNamedRenderbufferStorageMultisampleCoverageEXT +#define glNamedFramebufferTextureEXT _al_glNamedFramebufferTextureEXT +#define glNamedFramebufferTextureLayerEXT _al_glNamedFramebufferTextureLayerEXT +#define glNamedFramebufferTextureFaceEXT _al_glNamedFramebufferTextureFaceEXT +#define glTextureRenderbufferEXT _al_glTextureRenderbufferEXT +#define glMultiTexRenderbufferEXT _al_glMultiTexRenderbufferEXT +#endif + +#if defined _ALLEGRO_GL_NV_explicit_multisample +#define glGetMultisamplefvNV _al_glGetMultisamplefvNV +#define glSampleMaskIndexedNV _al_glSampleMaskIndexedNV +#define glTexRenderbufferNV _al_glTexRenderbufferNV +#endif + +#if defined _ALLEGRO_GL_NV_transform_feedback2 +#define glBindTransformFeedbackNV _al_glBindTransformFeedbackNV +#define glDeleteTransformFeedbacksNV _al_glDeleteTransformFeedbacksNV +#define glGenTransformFeedbacksNV _al_glGenTransformFeedbacksNV +#define glIsTransformFeedbackNV _al_glIsTransformFeedbackNV +#define glPauseTransformFeedbackNV _al_glPauseTransformFeedbackNV +#define glResumeTransformFeedbackNV _al_glResumeTransformFeedbackNV +#define glDrawTransformFeedbackNV _al_glDrawTransformFeedbackNV +#endif + +#if defined _ALLEGRO_GL_AMD_performance_monitor +#define glGetPerfMonitorGroupsAMD _al_glGetPerfMonitorGroupsAMD +#define glGetPerfMonitorCountersAMD _al_glGetPerfMonitorCountersAMD +#define glGetPerfMonitorGroupStringAMD _al_glGetPerfMonitorGroupStringAMD +#define glGetPerfMonitorCounterStringAMD _al_glGetPerfMonitorCounterStringAMD +#define glGetPerfMonitorCounterInfoAMD _al_glGetPerfMonitorCounterInfoAMD +#define glGenPerfMonitorsAMD _al_glGenPerfMonitorsAMD +#define glDeletePerfMonitorsAMD _al_glDeletePerfMonitorsAMD +#define glSelectPerfMonitorCountersAMD _al_glSelectPerfMonitorCountersAMD +#define glBeginPerfMonitorAMD _al_glBeginPerfMonitorAMD +#define glEndPerfMonitorAMD _al_glEndPerfMonitorAMD +#define glGetPerfMonitorCounterDataAMD _al_glGetPerfMonitorCounterDataAMD +#endif + +#if defined _ALLEGRO_GL_AMD_vertex_shader_tesselator +#define glTessellationFactorAMD _al_glTessellationFactorAMD +#define glTessellationModeAMD _al_glTessellationModeAMD +#endif + +#if defined _ALLEGRO_GL_EXT_provoking_vertex +#define glProvokingVertexEXT _al_glProvokingVertexEXT +#endif + +#if defined _ALLEGRO_GL_AMD_draw_buffers_blend +#define glBlendFuncIndexedAMD _al_glBlendFuncIndexedAMD +#define glBlendFuncSeparateIndexedAMD _al_glBlendFuncSeparateIndexedAMD +#define glBlendEquationIndexedAMD _al_glBlendEquationIndexedAMD +#define glBlendEquationSeparateIndexedAMD _al_glBlendEquationSeparateIndexedAMD +#endif + +#if defined _ALLEGRO_GL_APPLE_texture_range +#define glTextureRangeAPPLE _al_glTextureRangeAPPLE +#define glGetTexParameterPointervAPPLE _al_glGetTexParameterPointervAPPLE +#endif + +#if defined _ALLEGRO_GL_APPLE_vertex_program_evaluators +#define glEnableVertexAttribAPPLE _al_glEnableVertexAttribAPPLE +#define glDisableVertexAttribAPPLE _al_glDisableVertexAttribAPPLE +#define glIsVertexAttribEnabledAPPLE _al_glIsVertexAttribEnabledAPPLE +#define glMapVertexAttrib1dAPPLE _al_glMapVertexAttrib1dAPPLE +#define glMapVertexAttrib1fAPPLE _al_glMapVertexAttrib1fAPPLE +#define glMapVertexAttrib2dAPPLE _al_glMapVertexAttrib2dAPPLE +#define glMapVertexAttrib2fAPPLE _al_glMapVertexAttrib2fAPPLE +#endif + +#if defined _ALLEGRO_GL_APPLE_object_purgeable +#define glObjectPurgeableAPPLE _al_glObjectPurgeableAPPLE +#define glObjectUnpurgeableAPPLE _al_glObjectUnpurgeableAPPLE +#define glGetObjectParameterivAPPLE _al_glGetObjectParameterivAPPLE +#endif + +#if defined _ALLEGRO_GL_NV_video_capture +#define glBeginVideoCaptureNV _al_glBeginVideoCaptureNV +#define glBindVideoCaptureStreamBufferNV _al_glBindVideoCaptureStreamBufferNV +#define glBindVideoCaptureStreamTextureNV _al_glBindVideoCaptureStreamTextureNV +#define glEndVideoCaptureNV _al_glEndVideoCaptureNV +#define glGetVideoCaptureivNV _al_glGetVideoCaptureivNV +#define glGetVideoCaptureStreamivNV _al_glGetVideoCaptureStreamivNV +#define glGetVideoCaptureStreamfvNV _al_glGetVideoCaptureStreamfvNV +#define glGetVideoCaptureStreamdvNV _al_glGetVideoCaptureStreamdvNV +#define glVideoCaptureNV _al_glVideoCaptureNV +#define glVideoCaptureStreamParameterivNV _al_glVideoCaptureStreamParameterivNV +#define glVideoCaptureStreamParameterfvNV _al_glVideoCaptureStreamParameterfvNV +#define glVideoCaptureStreamParameterdvNV _al_glVideoCaptureStreamParameterdvNV +#endif + +#if defined _ALLEGRO_GL_EXT_separate_shader_objects +#define glUseShaderProgramEXT _al_glUseShaderProgramEXT +#define glActiveProgramEXT _al_glActiveProgramEXT +#define glCreateShaderProgramEXT _al_glCreateShaderProgramEXT +#endif + +#if defined _ALLEGRO_GL_NV_shader_buffer_load +#define glMakeBufferResidentNV _al_glMakeBufferResidentNV +#define glMakeBufferNonResidentNV _al_glMakeBufferNonResidentNV +#define glIsBufferResidentNV _al_glIsBufferResidentNV +#define glMakeNamedBufferResidentNV _al_glMakeNamedBufferResidentNV +#define glMakeNamedBufferNonResidentNV _al_glMakeNamedBufferNonResidentNV +#define glIsNamedBufferResidentNV _al_glIsNamedBufferResidentNV +#define glGetBufferParameterui64vNV _al_glGetBufferParameterui64vNV +#define glGetNamedBufferParameterui64vNV _al_glGetNamedBufferParameterui64vNV +#define glGetIntegerui64vNV _al_glGetIntegerui64vNV +#define glUniformui64NV _al_glUniformui64NV +#define glUniformui64vNV _al_glUniformui64vNV +#define glGetUniformui64vNV _al_glGetUniformui64vNV +#define glProgramUniformui64NV _al_glProgramUniformui64NV +#define glProgramUniformui64vNV _al_glProgramUniformui64vNV +#endif + +#if defined _ALLEGRO_GL_NV_vertex_buffer_unified_memory +#define glBufferAddressRangeNV _al_glBufferAddressRangeNV +#define glVertexFormatNV _al_glVertexFormatNV +#define glNormalFormatNV _al_glNormalFormatNV +#define glColorFormatNV _al_glColorFormatNV +#define glIndexFormatNV _al_glIndexFormatNV +#define glTexCoordFormatNV _al_glTexCoordFormatNV +#define glEdgeFlagFormatNV _al_glEdgeFlagFormatNV +#define glSecondaryColorFormatNV _al_glSecondaryColorFormatNV +#define glFogCoordFormatNV _al_glFogCoordFormatNV +#define glVertexAttribFormatNV _al_glVertexAttribFormatNV +#define glVertexAttribIFormatNV _al_glVertexAttribIFormatNV +#define glGetIntegerui64i_vNV _al_glGetIntegerui64i_vNV +#endif + +#if defined _ALLEGRO_GL_NV_texture_barrier +#define glTextureBarrierNV _al_glTextureBarrierNV +#endif diff --git a/common/allegro/include/allegro5/opengl/GLext/gl_ext_api.h b/common/allegro/include/allegro5/opengl/GLext/gl_ext_api.h new file mode 100644 index 00000000..eb7171c2 --- /dev/null +++ b/common/allegro/include/allegro5/opengl/GLext/gl_ext_api.h @@ -0,0 +1,2564 @@ +/* */ + +#ifdef _ALLEGRO_GL_VERSION_1_2 +AGL_API(void, BlendColor, (GLclampf, GLclampf, GLclampf, GLclampf)) +AGL_API(void, BlendEquation, (GLenum)) +AGL_API(void, DrawRangeElements, (GLenum, GLuint, GLuint, GLsizei, GLenum, const GLvoid *)) +AGL_API(void, ColorTable, (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, ColorTableParameterfv, (GLenum, GLenum, const GLfloat *)) +AGL_API(void, ColorTableParameteriv, (GLenum, GLenum, const GLint *)) +AGL_API(void, CopyColorTable, (GLenum, GLenum, GLint, GLint, GLsizei)) +AGL_API(void, GetColorTable, (GLenum, GLenum, GLenum, GLvoid *)) +AGL_API(void, GetColorTableParameterfv, (GLenum, GLenum, GLfloat *)) +AGL_API(void, GetColorTableParameteriv, (GLenum, GLenum, GLint *)) +AGL_API(void, ColorSubTable, (GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, CopyColorSubTable, (GLenum, GLsizei, GLint, GLint, GLsizei)) +AGL_API(void, TexImage3D, (GLenum, GLint, GLint, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *)) +AGL_API(void, TexSubImage3D, (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, CopyTexSubImage3D, (GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei)) +#endif + +#if defined _ALLEGRO_GL_ARB_imaging +AGL_API(void, ConvolutionFilter1D, (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, ConvolutionFilter2D, (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, ConvolutionParameterf, (GLenum, GLenum, GLfloat)) +AGL_API(void, ConvolutionParameterfv, (GLenum, GLenum, const GLfloat *)) +AGL_API(void, ConvolutionParameteri, (GLenum, GLenum, GLint)) +AGL_API(void, ConvolutionParameteriv, (GLenum, GLenum, const GLint *)) +AGL_API(void, CopyConvolutionFilter1D, (GLenum, GLenum, GLint, GLint, GLsizei)) +AGL_API(void, CopyConvolutionFilter2D, (GLenum, GLenum, GLint, GLint, GLsizei, GLsizei)) +AGL_API(void, GetConvolutionFilter, (GLenum, GLenum, GLenum, GLvoid *)) +AGL_API(void, GetConvolutionParameterfv, (GLenum, GLenum, GLfloat *)) +AGL_API(void, GetConvolutionParameteriv, (GLenum, GLenum, GLint *)) +AGL_API(void, GetSeparableFilter, (GLenum, GLenum, GLenum, GLvoid *, GLvoid *, GLvoid *)) +AGL_API(void, SeparableFilter2D, (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *, const GLvoid *)) +AGL_API(void, GetHistogram, (GLenum, GLboolean, GLenum, GLenum, GLvoid *)) +AGL_API(void, GetHistogramParameterfv, (GLenum, GLenum, GLfloat *)) +AGL_API(void, GetHistogramParameteriv, (GLenum, GLenum, GLint *)) +AGL_API(void, GetMinmax, (GLenum, GLboolean, GLenum, GLenum, GLvoid *)) +AGL_API(void, GetMinmaxParameterfv, (GLenum, GLenum, GLfloat *)) +AGL_API(void, GetMinmaxParameteriv, (GLenum, GLenum, GLint *)) +AGL_API(void, Histogram, (GLenum, GLsizei, GLenum, GLboolean)) +AGL_API(void, Minmax, (GLenum, GLenum, GLboolean)) +AGL_API(void, ResetHistogram, (GLenum)) +AGL_API(void, ResetMinmax, (GLenum)) +#endif + +#if defined _ALLEGRO_GL_VERSION_1_3 +AGL_API(void, ActiveTexture, (GLenum)) +AGL_API(void, ClientActiveTexture, (GLenum)) +AGL_API(void, MultiTexCoord1d, (GLenum, GLdouble)) +AGL_API(void, MultiTexCoord1dv, (GLenum, const GLdouble *)) +AGL_API(void, MultiTexCoord1f, (GLenum, GLfloat)) +AGL_API(void, MultiTexCoord1fv, (GLenum, const GLfloat *)) +AGL_API(void, MultiTexCoord1i, (GLenum, GLint)) +AGL_API(void, MultiTexCoord1iv, (GLenum, const GLint *)) +AGL_API(void, MultiTexCoord1s, (GLenum, GLshort)) +AGL_API(void, MultiTexCoord1sv, (GLenum, const GLshort *)) +AGL_API(void, MultiTexCoord2d, (GLenum, GLdouble, GLdouble)) +AGL_API(void, MultiTexCoord2dv, (GLenum, const GLdouble *)) +AGL_API(void, MultiTexCoord2f, (GLenum, GLfloat, GLfloat)) +AGL_API(void, MultiTexCoord2fv, (GLenum, const GLfloat *)) +AGL_API(void, MultiTexCoord2i, (GLenum, GLint, GLint)) +AGL_API(void, MultiTexCoord2iv, (GLenum, const GLint *)) +AGL_API(void, MultiTexCoord2s, (GLenum, GLshort, GLshort)) +AGL_API(void, MultiTexCoord2sv, (GLenum, const GLshort *)) +AGL_API(void, MultiTexCoord3d, (GLenum, GLdouble, GLdouble, GLdouble)) +AGL_API(void, MultiTexCoord3dv, (GLenum, const GLdouble *)) +AGL_API(void, MultiTexCoord3f, (GLenum, GLfloat, GLfloat, GLfloat)) +AGL_API(void, MultiTexCoord3fv, (GLenum, const GLfloat *)) +AGL_API(void, MultiTexCoord3i, (GLenum, GLint, GLint, GLint)) +AGL_API(void, MultiTexCoord3iv, (GLenum, const GLint *)) +AGL_API(void, MultiTexCoord3s, (GLenum, GLshort, GLshort, GLshort)) +AGL_API(void, MultiTexCoord3sv, (GLenum, const GLshort *)) +AGL_API(void, MultiTexCoord4d, (GLenum, GLdouble, GLdouble, GLdouble, GLdouble)) +AGL_API(void, MultiTexCoord4dv, (GLenum, const GLdouble *)) +AGL_API(void, MultiTexCoord4f, (GLenum, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, MultiTexCoord4fv, (GLenum, const GLfloat *)) +AGL_API(void, MultiTexCoord4i, (GLenum, GLint, GLint, GLint, GLint)) +AGL_API(void, MultiTexCoord4iv, (GLenum, const GLint *)) +AGL_API(void, MultiTexCoord4s, (GLenum, GLshort, GLshort, GLshort, GLshort)) +AGL_API(void, MultiTexCoord4sv, (GLenum, const GLshort *)) +AGL_API(void, LoadTransposeMatrixf, (const GLfloat *)) +AGL_API(void, LoadTransposeMatrixd, (const GLdouble *)) +AGL_API(void, MultTransposeMatrixf, (const GLfloat *)) +AGL_API(void, MultTransposeMatrixd, (const GLdouble *)) +AGL_API(void, SampleCoverage, (GLclampf, GLboolean)) +AGL_API(void, CompressedTexImage3D, (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *)) +AGL_API(void, CompressedTexImage2D, (GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *)) +AGL_API(void, CompressedTexImage1D, (GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *)) +AGL_API(void, CompressedTexSubImage3D, (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, CompressedTexSubImage2D, (GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, CompressedTexSubImage1D, (GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, GetCompressedTexImage, (GLenum, GLint, GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_VERSION_1_4 +AGL_API(void, BlendFuncSeparate, (GLenum, GLenum, GLenum, GLenum)) +AGL_API(void, FogCoordf, (GLfloat)) +AGL_API(void, FogCoordfv, (const GLfloat *)) +AGL_API(void, FogCoordd, (GLdouble)) +AGL_API(void, FogCoorddv, (const GLdouble *)) +AGL_API(void, FogCoordPointer, (GLenum, GLsizei, const GLvoid *)) +AGL_API(void, MultiDrawArrays, (GLenum, GLint *, GLsizei *, GLsizei)) +AGL_API(void, MultiDrawElements, (GLenum, const GLsizei *, GLenum, const GLvoid* *, GLsizei)) +AGL_API(void, PointParameterf, (GLenum, GLfloat)) +AGL_API(void, PointParameterfv, (GLenum, const GLfloat *)) +AGL_API(void, PointParameteri, (GLenum, GLint)) +AGL_API(void, PointParameteriv, (GLenum, const GLint *)) +AGL_API(void, SecondaryColor3b, (GLbyte, GLbyte, GLbyte)) +AGL_API(void, SecondaryColor3bv, (const GLbyte *)) +AGL_API(void, SecondaryColor3d, (GLdouble, GLdouble, GLdouble)) +AGL_API(void, SecondaryColor3dv, (const GLdouble *)) +AGL_API(void, SecondaryColor3f, (GLfloat, GLfloat, GLfloat)) +AGL_API(void, SecondaryColor3fv, (const GLfloat *)) +AGL_API(void, SecondaryColor3i, (GLint, GLint, GLint)) +AGL_API(void, SecondaryColor3iv, (const GLint *)) +AGL_API(void, SecondaryColor3s, (GLshort, GLshort, GLshort)) +AGL_API(void, SecondaryColor3sv, (const GLshort *)) +AGL_API(void, SecondaryColor3ub, (GLubyte, GLubyte, GLubyte)) +AGL_API(void, SecondaryColor3ubv, (const GLubyte *)) +AGL_API(void, SecondaryColor3ui, (GLuint, GLuint, GLuint)) +AGL_API(void, SecondaryColor3uiv, (const GLuint *)) +AGL_API(void, SecondaryColor3us, (GLushort, GLushort, GLushort)) +AGL_API(void, SecondaryColor3usv, (const GLushort *)) +AGL_API(void, SecondaryColorPointer, (GLint, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, WindowPos2d, (GLdouble, GLdouble)) +AGL_API(void, WindowPos2dv, (const GLdouble *)) +AGL_API(void, WindowPos2f, (GLfloat, GLfloat)) +AGL_API(void, WindowPos2fv, (const GLfloat *)) +AGL_API(void, WindowPos2i, (GLint, GLint)) +AGL_API(void, WindowPos2iv, (const GLint *)) +AGL_API(void, WindowPos2s, (GLshort, GLshort)) +AGL_API(void, WindowPos2sv, (const GLshort *)) +AGL_API(void, WindowPos3d, (GLdouble, GLdouble, GLdouble)) +AGL_API(void, WindowPos3dv, (const GLdouble *)) +AGL_API(void, WindowPos3f, (GLfloat, GLfloat, GLfloat)) +AGL_API(void, WindowPos3fv, (const GLfloat *)) +AGL_API(void, WindowPos3i, (GLint, GLint, GLint)) +AGL_API(void, WindowPos3iv, (const GLint *)) +AGL_API(void, WindowPos3s, (GLshort, GLshort, GLshort)) +AGL_API(void, WindowPos3sv, (const GLshort *)) +#endif + + +#if defined _ALLEGRO_GL_VERSION_1_5 +AGL_API(void, BindBuffer, (GLenum, GLuint)) +AGL_API(void, DeleteBuffers, (GLsizei, const GLuint *)) +AGL_API(void, GenBuffers, (GLsizei, GLuint *)) +AGL_API(GLboolean, IsBuffer, (GLuint)) +AGL_API(void, BufferData, (GLenum, GLsizeiptr, const GLvoid *, GLenum)) +AGL_API(void, BufferSubData, (GLenum, GLintptr, GLsizeiptr, const GLvoid *)) +AGL_API(void, GetBufferSubData, (GLenum, GLintptr, GLsizeiptr, GLvoid *)) +AGL_API(GLvoid*, MapBuffer, (GLenum, GLenum)) +AGL_API(GLboolean, UnmapBuffer, (GLenum)) +AGL_API(void, GetBufferParameteriv, (GLenum, GLenum, GLint *)) +AGL_API(void, GetBufferPointerv, (GLenum, GLenum, GLvoid* *)) +AGL_API(void, GenQueries, (GLsizei, GLuint *)) +AGL_API(void, DeleteQueries, (GLsizei, const GLuint *)) +AGL_API(GLboolean, IsQuery, (GLuint)) +AGL_API(void, BeginQuery, (GLenum, GLuint)) +AGL_API(void, EndQuery, (GLenum)) +AGL_API(void, GetQueryiv, (GLenum, GLenum, GLint *)) +AGL_API(void, GetQueryObjectiv, (GLuint, GLenum, GLint *)) +AGL_API(void, GetQueryObjectuiv, (GLuint, GLenum, GLuint *)) +#endif + + +#if defined _ALLEGRO_GL_VERSION_2_0 +AGL_API(void, BlendEquationSeparate, (GLenum, GLenum)) +AGL_API(GLuint, CreateProgram, (void)) +AGL_API(GLuint, CreateShader, (GLenum)) +AGL_API(void, DeleteProgram, (GLuint)) +AGL_API(void, DeleteShader, (GLuint)) +AGL_API(void, AttachShader, (GLuint, GLuint)) +AGL_API(void, DetachShader, (GLuint, GLuint)) +AGL_API(void, ShaderSource, (GLuint, GLsizei, const GLchar **, const GLint *)) +AGL_API(void, CompileShader, (GLuint)) +AGL_API(GLboolean, IsProgram, (GLuint)) +AGL_API(GLboolean, IsShader, (GLuint)) +AGL_API(void, LinkProgram, (GLuint)) +AGL_API(void, UseProgram, (GLuint)) +AGL_API(void, ValidateProgram, (GLuint)) +AGL_API(void, Uniform1f, (GLint, GLfloat)) +AGL_API(void, Uniform2f, (GLint, GLfloat, GLfloat)) +AGL_API(void, Uniform3f, (GLint, GLfloat, GLfloat, GLfloat)) +AGL_API(void, Uniform4f, (GLint, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, Uniform1i, (GLint, GLint)) +AGL_API(void, Uniform2i, (GLint, GLint, GLint)) +AGL_API(void, Uniform3i, (GLint, GLint, GLint, GLint)) +AGL_API(void, Uniform4i, (GLint, GLint, GLint, GLint, GLint)) +AGL_API(void, Uniform1fv, (GLint, GLsizei, const GLfloat *)) +AGL_API(void, Uniform2fv, (GLint, GLsizei, const GLfloat *)) +AGL_API(void, Uniform3fv, (GLint, GLsizei, const GLfloat *)) +AGL_API(void, Uniform4fv, (GLint, GLsizei, const GLfloat *)) +AGL_API(void, Uniform1iv, (GLint, GLsizei, const GLint *)) +AGL_API(void, Uniform2iv, (GLint, GLsizei, const GLint *)) +AGL_API(void, Uniform3iv, (GLint, GLsizei, const GLint *)) +AGL_API(void, Uniform4iv, (GLint, GLsizei, const GLint *)) +AGL_API(void, UniformMatrix2fv, (GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, UniformMatrix3fv, (GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, UniformMatrix4fv, (GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, GetShaderfv, (GLuint, GLenum, GLfloat *)) +AGL_API(void, GetShaderiv, (GLuint, GLenum, GLint *)) +AGL_API(void, GetProgramfv, (GLuint, GLenum, GLfloat *)) +AGL_API(void, GetProgramiv, (GLuint, GLenum, GLint *)) +AGL_API(void, GetShaderInfoLog, (GLuint, GLsizei, GLsizei *, GLchar *)) +AGL_API(void, GetProgramInfoLog, (GLuint, GLsizei, GLsizei *, GLchar *)) +AGL_API(void, GetAttachedShaders, (GLuint, GLsizei, GLsizei *, GLuint *)) +AGL_API(GLint, GetUniformLocation, (GLuint, const GLchar *)) +AGL_API(void, GetActiveUniform, (GLuint, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLchar *)) +AGL_API(void, GetUniformfv, (GLuint, GLint, GLfloat *)) +AGL_API(void, GetUniformiv, (GLuint, GLint, GLint *)) +AGL_API(void, GetShaderSource, (GLuint, GLsizei, GLsizei *, GLchar *)) +AGL_API(void, VertexAttrib1f, (GLuint, GLfloat)) +AGL_API(void, VertexAttrib1s, (GLuint, GLshort)) +AGL_API(void, VertexAttrib1d, (GLuint, GLdouble)) +AGL_API(void, VertexAttrib2f, (GLuint, GLfloat, GLfloat)) +AGL_API(void, VertexAttrib2s, (GLuint, GLshort, GLshort)) +AGL_API(void, VertexAttrib2d, (GLuint, GLdouble, GLdouble)) +AGL_API(void, VertexAttrib3f, (GLuint, GLfloat, GLfloat, GLfloat)) +AGL_API(void, VertexAttrib3s, (GLuint, GLshort, GLshort, GLshort)) +AGL_API(void, VertexAttrib3d, (GLuint, GLdouble, GLdouble, GLdouble)) +AGL_API(void, VertexAttrib4f, (GLuint, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, VertexAttrib4s, (GLuint, GLshort, GLshort, GLshort, GLshort)) +AGL_API(void, VertexAttrib4d, (GLuint, GLdouble,GLdouble,GLdouble,GLdouble)) +AGL_API(void, VertexAttrib4Nub, (GLuint, GLubyte, GLubyte, GLubyte, GLubyte)) +AGL_API(void, VertexAttrib1fv, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib1sv, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib1dv, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib2fv, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib2sv, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib2dv, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib3fv, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib3sv, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib3dv, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib4fv, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib4sv, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib4dv, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib4iv, (GLuint, const GLint *)) +AGL_API(void, VertexAttrib4bv, (GLuint, const GLbyte *)) +AGL_API(void, VertexAttrib4ubv, (GLuint, const GLubyte *)) +AGL_API(void, VertexAttrib4usv, (GLuint, const GLushort *)) +AGL_API(void, VertexAttrib4uiv, (GLuint, const GLuint *)) +AGL_API(void, VertexAttrib4Nbv, (GLuint, const GLbyte *)) +AGL_API(void, VertexAttrib4Nsv, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib4Niv, (GLuint, const GLint *)) +AGL_API(void, VertexAttrib4Nubv, (GLuint, const GLubyte *)) +AGL_API(void, VertexAttrib4Nusv, (GLuint, const GLushort *)) +AGL_API(void, VertexAttrib4Nuiv, (GLuint, const GLuint *)) +AGL_API(void, VertexAttribPointer,(GLuint, GLint, GLenum, GLboolean, GLsizei, const GLvoid *)) +AGL_API(void, EnableVertexAttribArray, (GLuint)) +AGL_API(void, DisableVertexAttribArray, (GLuint)) + +AGL_API(void, BindAttribLocation, (GLuint, GLuint, const GLchar *)) +AGL_API(void, GetActiveAttrib, (GLuint, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLchar *)) +AGL_API(GLint, GetAttribLocation, (GLuint, const GLchar *)) +AGL_API(void, GetVertexAttribdv, (GLuint, GLenum, GLdouble *)) +AGL_API(void, GetVertexAttribfv, (GLuint, GLenum, GLfloat *)) +AGL_API(void, GetVertexAttribiv, (GLuint, GLenum, GLint *)) +AGL_API(void, GetVertexAttribPointerv, (GLuint, GLenum, GLvoid **)) + +AGL_API(void, DrawBuffers, (GLsizei n, const GLenum *)) + +AGL_API(void, StencilOpSeparate, (GLenum, GLenum, GLenum, GLenum)) +AGL_API(void, StencilFuncSeparate, (GLenum, GLenum, GLint, GLuint)) +AGL_API(void, StencilMaskSeparate, (GLenum, GLuint)) + +#endif + + +#if defined _ALLEGRO_GL_VERSION_2_1 +AGL_API(void, UniformMatrix2x3fv, (GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, UniformMatrix3x2fv, (GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, UniformMatrix2x4fv, (GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, UniformMatrix4x2fv, (GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, UniformMatrix3x4fv, (GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, UniformMatrix4x3fv, (GLint, GLsizei, GLboolean, const GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_VERSION_3_0 +/* OpenGL 3.0 also reuses entry points from these extensions: */ +/* ARB_framebuffer_object */ +/* ARB_map_buffer_range */ +/* ARB_vertex_array_object */ +AGL_API(void, ColorMaski, (GLuint, GLboolean, GLboolean, GLboolean, GLboolean)) +AGL_API(void, GetBooleani_v, (GLenum, GLuint, GLboolean *)) +AGL_API(void, GetIntegeri_v, (GLenum, GLuint, GLint *)) +AGL_API(void, Enablei, (GLenum, GLuint)) +AGL_API(void, Disablei, (GLenum, GLuint)) +AGL_API(GLboolean, IsEnabledi, (GLenum, GLuint)) +AGL_API(void, BeginTransformFeedback, (GLenum)) +AGL_API(void, EndTransformFeedback, (void)) +AGL_API(void, BindBufferRange, (GLenum, GLuint, GLuint, GLintptr, GLsizeiptr)) +AGL_API(void, BindBufferBase, (GLenum, GLuint, GLuint)) +AGL_API(void, TransformFeedbackVaryings, (GLuint, GLsizei, const GLint *, GLenum)) +AGL_API(void, GetTransformFeedbackVarying, (GLuint, GLuint, GLint *)) +AGL_API(void, ClampColor, (GLenum, GLenum)) +AGL_API(void, BeginConditionalRender, (GLuint, GLenum)) +AGL_API(void, EndConditionalRender, (void)) +AGL_API(void, VertexAttribI1i, (GLuint, GLint)) +AGL_API(void, VertexAttribI2i, (GLuint, GLint, GLint)) +AGL_API(void, VertexAttribI3i, (GLuint, GLint, GLint, GLint)) +AGL_API(void, VertexAttribI4i, (GLuint, GLint, GLint, GLint, GLint)) +AGL_API(void, VertexAttribI1ui, (GLuint, GLuint)) +AGL_API(void, VertexAttribI2ui, (GLuint, GLuint, GLuint)) +AGL_API(void, VertexAttribI3ui, (GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, VertexAttribI4ui, (GLuint, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, VertexAttribI1iv, (GLuint, const GLint *)) +AGL_API(void, VertexAttribI2iv, (GLuint, const GLint *)) +AGL_API(void, VertexAttribI3iv, (GLuint, const GLint *)) +AGL_API(void, VertexAttribI4iv, (GLuint, const GLint *)) +AGL_API(void, VertexAttribI1uiv, (GLuint, const GLuint *)) +AGL_API(void, VertexAttribI2uiv, (GLuint, const GLuint *)) +AGL_API(void, VertexAttribI3uiv, (GLuint, const GLuint *)) +AGL_API(void, VertexAttribI4uiv, (GLuint, const GLuint *)) +AGL_API(void, VertexAttribI4bv, (GLuint, const GLbyte *)) +AGL_API(void, VertexAttribI4sv, (GLuint, const GLshort *)) +AGL_API(void, VertexAttribI4ubv, (GLuint, const GLubyte *)) +AGL_API(void, VertexAttribI4usv, (GLuint, const GLushort *)) +AGL_API(void, VertexAttribIPointer, (GLuint, GLint, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, GetVertexAttribIiv, (GLuint, GLenum, GLint *)) +AGL_API(void, GetVertexAttribIuiv, (GLuint, GLenum, GLuint *)) +AGL_API(void, GetUniformuiv, (GLuint, GLint, GLuint *)) +AGL_API(void, BindFragDataLocation, (GLuint, GLuint, const GLchar *)) +AGL_API(GLint, GetFragDataLocation, (GLuint, const GLchar *)) +AGL_API(void, Uniform1ui, (GLint, GLuint)) +AGL_API(void, Uniform2ui, (GLint, GLuint, GLuint)) +AGL_API(void, Uniform3ui, (GLint, GLuint, GLuint, GLuint)) +AGL_API(void, Uniform4ui, (GLint, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, Uniform1uiv, (GLint, GLsizei, const GLuint *)) +AGL_API(void, Uniform2uiv, (GLint, GLsizei, const GLuint *)) +AGL_API(void, Uniform3uiv, (GLint, GLsizei, const GLuint *)) +AGL_API(void, Uniform4uiv, (GLint, GLsizei, const GLuint *)) +AGL_API(void, TexParameterIiv, (GLenum, GLenum, const GLint *)) +AGL_API(void, TexParameterIuiv, (GLenum, GLenum, const GLuint *)) +AGL_API(void, GetTexParameterIiv, (GLenum, GLenum, GLint *)) +AGL_API(void, GetTexParameterIuiv, (GLenum, GLenum, GLuint *)) +AGL_API(void, ClearBufferiv, (GLenum, GLint, const GLint *)) +AGL_API(void, ClearBufferuiv, (GLenum, GLint, const GLuint *)) +AGL_API(void, ClearBufferfv, (GLenum, GLint, const GLfloat *)) +AGL_API(void, ClearBufferfi, (GLenum, GLint, GLfloat, GLint)) +AGL_API(const GLubyte *, GetStringi, (GLenum, GLuint)) +#endif + + +#if defined _ALLEGRO_GL_VERSION_3_1 +/* OpenGL 3.1 also reuses entry points from these extensions: */ +/* ARB_copy_buffer */ +/* ARB_uniform_buffer_object */ +AGL_API(void, DrawArraysInstanced, (GLenum, GLint, GLsizei, GLsizei)) +AGL_API(void, DrawElementsInstanced, (GLenum, GLsizei, GLenum, const GLvoid *, GLsizei)) +AGL_API(void, TexBuffer, (GLenum, GLenum, GLuint)) +AGL_API(void, PrimitiveRestartIndex, (GLuint)) +#endif + +#if defined _ALLEGRO_GL_VERSION_3_2 +/* OpenGL 3.2 also reuses entry points from these extensions: */ +/* ARB_draw_elements_base_vertex */ +/* ARB_provoking_vertex */ +/* ARB_sync */ +/* ARB_texture_multisample */ +AGL_API(void, GetInteger64i_v, (GLenum target, GLuint index, GLint64 *data)) +AGL_API(void, GetBufferParameteri64v, (GLenum target, GLenum pname, GLint64 *params)) +AGL_API(void, ProgramParameteri, (GLuint program, GLenum pname, GLint value)) +AGL_API(void, FramebufferTexture, (GLenum target, GLenum attachment, GLuint texture, GLint level)) +#endif + +#if defined _ALLEGRO_GL_VERSION_3_3 +/* OpenGL 3.3 also reuses entry points from these extensions: */ +/* ARB_blend_func_extended */ +/* ARB_sampler_objects */ +/* ARB_explicit_attrib_location, but it has none */ +/* ARB_occlusion_query2 (no entry points) */ +/* ARB_shader_bit_encoding (no entry points) */ +/* ARB_texture_rgb10_a2ui (no entry points) */ +/* ARB_texture_swizzle (no entry points) */ +/* ARB_timer_query */ +/* ARB_vertex_type_2_10_10_10_rev */ +#endif + + +/* */ +/* */ + +#ifdef _ALLEGRO_GL_ARB_multitexture +AGL_API(void, ActiveTextureARB, (GLenum)) +AGL_API(void, ClientActiveTextureARB, (GLenum)) +AGL_API(void, MultiTexCoord1dARB, (GLenum, GLdouble)) +AGL_API(void, MultiTexCoord1dvARB, (GLenum, const GLdouble *)) +AGL_API(void, MultiTexCoord1fARB, (GLenum, GLfloat)) +AGL_API(void, MultiTexCoord1fvARB, (GLenum, const GLfloat *)) +AGL_API(void, MultiTexCoord1iARB, (GLenum, GLint)) +AGL_API(void, MultiTexCoord1ivARB, (GLenum, const GLint *)) +AGL_API(void, MultiTexCoord1sARB, (GLenum, GLshort)) +AGL_API(void, MultiTexCoord1svARB, (GLenum, const GLshort *)) +AGL_API(void, MultiTexCoord2dARB, (GLenum, GLdouble, GLdouble)) +AGL_API(void, MultiTexCoord2dvARB, (GLenum, const GLdouble *)) +AGL_API(void, MultiTexCoord2fARB, (GLenum, GLfloat, GLfloat)) +AGL_API(void, MultiTexCoord2fvARB, (GLenum, const GLfloat *)) +AGL_API(void, MultiTexCoord2iARB, (GLenum, GLint, GLint)) +AGL_API(void, MultiTexCoord2ivARB, (GLenum, const GLint *)) +AGL_API(void, MultiTexCoord2sARB, (GLenum, GLshort, GLshort)) +AGL_API(void, MultiTexCoord2svARB, (GLenum, const GLshort *)) +AGL_API(void, MultiTexCoord3dARB, (GLenum, GLdouble, GLdouble, GLdouble)) +AGL_API(void, MultiTexCoord3dvARB, (GLenum, const GLdouble *)) +AGL_API(void, MultiTexCoord3fARB, (GLenum, GLfloat, GLfloat, GLfloat)) +AGL_API(void, MultiTexCoord3fvARB, (GLenum, const GLfloat *)) +AGL_API(void, MultiTexCoord3iARB, (GLenum, GLint, GLint, GLint)) +AGL_API(void, MultiTexCoord3ivARB, (GLenum, const GLint *)) +AGL_API(void, MultiTexCoord3sARB, (GLenum, GLshort, GLshort, GLshort)) +AGL_API(void, MultiTexCoord3svARB, (GLenum, const GLshort *)) +AGL_API(void, MultiTexCoord4dARB, (GLenum, GLdouble, GLdouble, GLdouble, GLdouble)) +AGL_API(void, MultiTexCoord4dvARB, (GLenum, const GLdouble *)) +AGL_API(void, MultiTexCoord4fARB, (GLenum, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, MultiTexCoord4fvARB, (GLenum, const GLfloat *)) +AGL_API(void, MultiTexCoord4iARB, (GLenum, GLint, GLint, GLint, GLint)) +AGL_API(void, MultiTexCoord4ivARB, (GLenum, const GLint *)) +AGL_API(void, MultiTexCoord4sARB, (GLenum, GLshort, GLshort, GLshort, GLshort)) +AGL_API(void, MultiTexCoord4svARB, (GLenum, const GLshort *)) +#endif + +#if defined _ALLEGRO_GL_ARB_transpose_matrix +AGL_API(void, LoadTransposeMatrixfARB, (const GLfloat *)) +AGL_API(void, LoadTransposeMatrixdARB, (const GLdouble *)) +AGL_API(void, MultTransposeMatrixfARB, (const GLfloat *)) +AGL_API(void, MultTransposeMatrixdARB, (const GLdouble *)) +#endif + +#if defined _ALLEGRO_GL_ARB_multisample +AGL_API(void, SampleCoverageARB, (GLclampf, GLboolean)) +#endif + +#if defined _ALLEGRO_GL_ARB_texture_compression +AGL_API(void, CompressedTexImage3DARB, (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *)) +AGL_API(void, CompressedTexImage2DARB, (GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *)) +AGL_API(void, CompressedTexImage1DARB, (GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *)) +AGL_API(void, CompressedTexSubImage3DARB, (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, CompressedTexSubImage2DARB, (GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, CompressedTexSubImage1DARB, (GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, GetCompressedTexImageARB, (GLenum, GLint, GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_ARB_point_parameters +AGL_API(void, PointParameterfARB, (GLenum, GLfloat)) +AGL_API(void, PointParameterfvARB, (GLenum, const GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_ARB_vertex_blend +AGL_API(void, WeightbvARB, (GLint, const GLbyte *)) +AGL_API(void, WeightsvARB, (GLint, const GLshort *)) +AGL_API(void, WeightivARB, (GLint, const GLint *)) +AGL_API(void, WeightfvARB, (GLint, const GLfloat *)) +AGL_API(void, WeightdvARB, (GLint, const GLdouble *)) +AGL_API(void, WeightubvARB, (GLint, const GLubyte *)) +AGL_API(void, WeightusvARB, (GLint, const GLushort *)) +AGL_API(void, WeightuivARB, (GLint, const GLuint *)) +AGL_API(void, WeightPointerARB, (GLint, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, VertexBlendARB, (GLint)) +#endif + +#if defined _ALLEGRO_GL_ARB_matrix_palette +AGL_API(void, CurrentPaletteMatrixARB, (GLint)) +AGL_API(void, MatrixIndexubvARB, (GLint, const GLubyte *)) +AGL_API(void, MatrixIndexusvARB, (GLint, const GLushort *)) +AGL_API(void, MatrixIndexuivARB, (GLint, const GLuint *)) +AGL_API(void, MatrixIndexPointerARB, (GLint, GLenum, GLsizei, const GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_ARB_window_pos +AGL_API(void, WindowPos2dARB, (GLdouble, GLdouble)) +AGL_API(void, WindowPos2dvARB, (const GLdouble *)) +AGL_API(void, WindowPos2fARB, (GLfloat, GLfloat)) +AGL_API(void, WindowPos2fvARB, (const GLfloat *)) +AGL_API(void, WindowPos2iARB, (GLint, GLint)) +AGL_API(void, WindowPos2ivARB, (const GLint *)) +AGL_API(void, WindowPos2sARB, (GLshort, GLshort)) +AGL_API(void, WindowPos2svARB, (const GLshort *)) +AGL_API(void, WindowPos3dARB, (GLdouble, GLdouble, GLdouble)) +AGL_API(void, WindowPos3dvARB, (const GLdouble *)) +AGL_API(void, WindowPos3fARB, (GLfloat, GLfloat, GLfloat)) +AGL_API(void, WindowPos3fvARB, (const GLfloat *)) +AGL_API(void, WindowPos3iARB, (GLint, GLint, GLint)) +AGL_API(void, WindowPos3ivARB, (const GLint *)) +AGL_API(void, WindowPos3sARB, (GLshort, GLshort, GLshort)) +AGL_API(void, WindowPos3svARB, (const GLshort *)) +#endif + +#if defined _ALLEGRO_GL_ARB_vertex_program +AGL_API(void, VertexAttrib1dARB, (GLuint, GLdouble)) +AGL_API(void, VertexAttrib1dvARB, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib1fARB, (GLuint, GLfloat)) +AGL_API(void, VertexAttrib1fvARB, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib1sARB, (GLuint, GLshort)) +AGL_API(void, VertexAttrib1svARB, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib2dARB, (GLuint, GLdouble, GLdouble)) +AGL_API(void, VertexAttrib2dvARB, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib2fARB, (GLuint, GLfloat, GLfloat)) +AGL_API(void, VertexAttrib2fvARB, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib2sARB, (GLuint, GLshort, GLshort)) +AGL_API(void, VertexAttrib2svARB, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib3dARB, (GLuint, GLdouble, GLdouble, GLdouble)) +AGL_API(void, VertexAttrib3dvARB, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib3fARB, (GLuint, GLfloat, GLfloat, GLfloat)) +AGL_API(void, VertexAttrib3fvARB, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib3sARB, (GLuint, GLshort, GLshort, GLshort)) +AGL_API(void, VertexAttrib3svARB, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib4NbvARB, (GLuint, const GLbyte *)) +AGL_API(void, VertexAttrib4NivARB, (GLuint, const GLint *)) +AGL_API(void, VertexAttrib4NsvARB, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib4NubARB, (GLuint, GLubyte, GLubyte, GLubyte, GLubyte)) +AGL_API(void, VertexAttrib4NubvARB, (GLuint, const GLubyte *)) +AGL_API(void, VertexAttrib4NuivARB, (GLuint, const GLuint *)) +AGL_API(void, VertexAttrib4NusvARB, (GLuint, const GLushort *)) +AGL_API(void, VertexAttrib4bvARB, (GLuint, const GLbyte *)) +AGL_API(void, VertexAttrib4dARB, (GLuint, GLdouble, GLdouble, GLdouble, GLdouble)) +AGL_API(void, VertexAttrib4dvARB, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib4fARB, (GLuint, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, VertexAttrib4fvARB, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib4ivARB, (GLuint, const GLint *)) +AGL_API(void, VertexAttrib4sARB, (GLuint, GLshort, GLshort, GLshort, GLshort)) +AGL_API(void, VertexAttrib4svARB, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib4ubvARB, (GLuint, const GLubyte *)) +AGL_API(void, VertexAttrib4uivARB, (GLuint, const GLuint *)) +AGL_API(void, VertexAttrib4usvARB, (GLuint, const GLushort *)) +AGL_API(void, VertexAttribPointerARB, (GLuint, GLint, GLenum, GLboolean, GLsizei, const GLvoid *)) +AGL_API(void, EnableVertexAttribArrayARB, (GLuint)) +AGL_API(void, DisableVertexAttribArrayARB, (GLuint)) +AGL_API(void, ProgramStringARB, (GLenum, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, BindProgramARB, (GLenum, GLuint)) +AGL_API(void, DeleteProgramsARB, (GLsizei, const GLuint *)) +AGL_API(void, GenProgramsARB, (GLsizei, GLuint *)) +AGL_API(void, ProgramEnvParameter4dARB, (GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble)) +AGL_API(void, ProgramEnvParameter4dvARB, (GLenum, GLuint, const GLdouble *)) +AGL_API(void, ProgramEnvParameter4fARB, (GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, ProgramEnvParameter4fvARB, (GLenum, GLuint, const GLfloat *)) +AGL_API(void, ProgramLocalParameter4dARB, (GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble)) +AGL_API(void, ProgramLocalParameter4dvARB, (GLenum, GLuint, const GLdouble *)) +AGL_API(void, ProgramLocalParameter4fARB, (GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, ProgramLocalParameter4fvARB, (GLenum, GLuint, const GLfloat *)) +AGL_API(void, GetProgramEnvParameterdvARB, (GLenum, GLuint, GLdouble *)) +AGL_API(void, GetProgramEnvParameterfvARB, (GLenum, GLuint, GLfloat *)) +AGL_API(void, GetProgramLocalParameterdvARB, (GLenum, GLuint, GLdouble *)) +AGL_API(void, GetProgramLocalParameterfvARB, (GLenum, GLuint, GLfloat *)) +AGL_API(void, GetProgramivARB, (GLenum, GLenum, GLint *)) +AGL_API(void, GetProgramStringARB, (GLenum, GLenum, GLvoid *)) +AGL_API(void, GetVertexAttribdvARB, (GLuint, GLenum, GLdouble *)) +AGL_API(void, GetVertexAttribfvARB, (GLuint, GLenum, GLfloat *)) +AGL_API(void, GetVertexAttribivARB, (GLuint, GLenum, GLint *)) +AGL_API(void, GetVertexAttribPointervARB, (GLuint, GLenum, GLvoid* *)) +AGL_API(GLboolean, IsProgramARB, (GLuint)) +#endif + +#if defined _ALLEGRO_GL_ARB_vertex_buffer_object +AGL_API(void, BindBufferARB, (GLenum, GLuint)) +AGL_API(void, DeleteBuffersARB, (GLsizei, const GLuint *)) +AGL_API(void, GenBuffersARB, (GLsizei, GLuint *)) +AGL_API(GLboolean, IsBufferARB, (GLuint)) +AGL_API(void, BufferDataARB, (GLenum, GLsizeiptrARB, const GLvoid *, GLenum)) +AGL_API(void, BufferSubDataARB, (GLenum, GLintptrARB, GLsizeiptrARB, const GLvoid *)) +AGL_API(void, GetBufferSubDataARB, (GLenum, GLintptrARB, GLsizeiptrARB, GLvoid *)) +AGL_API(GLvoid*, MapBufferARB, (GLenum, GLenum)) +AGL_API(GLboolean, UnmapBufferARB, (GLenum)) +AGL_API(void, GetBufferParameterivARB, (GLenum, GLenum, GLint *)) +AGL_API(void, GetBufferPointervARB, (GLenum, GLenum, GLvoid* *)) +#endif + +#if defined _ALLEGRO_GL_ARB_occlusion_query +AGL_API(void, GenQueriesARB, (GLsizei, GLuint *)) +AGL_API(void, DeleteQueriesARB, (GLsizei, const GLuint *)) +AGL_API(GLboolean, IsQueryARB, (GLuint)) +AGL_API(void, BeginQueryARB, (GLenum, GLuint)) +AGL_API(void, EndQueryARB, (GLenum)) +AGL_API(void, GetQueryivARB, (GLenum, GLenum, GLint *)) +AGL_API(void, GetQueryObjectivARB, (GLuint, GLenum, GLint *)) +AGL_API(void, GetQueryObjectuivARB, (GLuint, GLenum, GLuint *)) +#endif + +#if defined _ALLEGRO_GL_ARB_shader_objects +AGL_API(void, DeleteObjectARB, (GLhandleARB)) +AGL_API(GLhandleARB, GetHandleARB, (GLenum)) +AGL_API(void, DetachObjectARB, (GLhandleARB, GLhandleARB)) +AGL_API(GLhandleARB, CreateShaderObjectARB, (GLenum)) +AGL_API(void, ShaderSourceARB, (GLhandleARB, GLsizei, const GLcharARB **, const GLint *)) +AGL_API(void, CompileShaderARB, (GLhandleARB)) +AGL_API(GLhandleARB, CreateProgramObjectARB, (void)) +AGL_API(void, AttachObjectARB, (GLhandleARB, GLhandleARB)) +AGL_API(void, LinkProgramARB, (GLhandleARB)) +AGL_API(void, UseProgramObjectARB, (GLhandleARB)) +AGL_API(void, ValidateProgramARB, (GLhandleARB)) +AGL_API(void, Uniform1fARB, (GLint, GLfloat)) +AGL_API(void, Uniform2fARB, (GLint, GLfloat, GLfloat)) +AGL_API(void, Uniform3fARB, (GLint, GLfloat, GLfloat, GLfloat)) +AGL_API(void, Uniform4fARB, (GLint, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, Uniform1iARB, (GLint, GLint)) +AGL_API(void, Uniform2iARB, (GLint, GLint, GLint)) +AGL_API(void, Uniform3iARB, (GLint, GLint, GLint, GLint)) +AGL_API(void, Uniform4iARB, (GLint, GLint, GLint, GLint, GLint)) +AGL_API(void, Uniform1fvARB, (GLint, GLsizei, GLfloat *)) +AGL_API(void, Uniform2fvARB, (GLint, GLsizei, GLfloat *)) +AGL_API(void, Uniform3fvARB, (GLint, GLsizei, GLfloat *)) +AGL_API(void, Uniform4fvARB, (GLint, GLsizei, GLfloat *)) +AGL_API(void, Uniform1ivARB, (GLint, GLsizei, GLint *)) +AGL_API(void, Uniform2ivARB, (GLint, GLsizei, GLint *)) +AGL_API(void, Uniform3ivARB, (GLint, GLsizei, GLint *)) +AGL_API(void, Uniform4ivARB, (GLint, GLsizei, GLint *)) +AGL_API(void, UniformMatrix2fvARB, (GLint, GLsizei, GLboolean, GLfloat *)) +AGL_API(void, UniformMatrix3fvARB, (GLint, GLsizei, GLboolean, GLfloat *)) +AGL_API(void, UniformMatrix4fvARB, (GLint, GLsizei, GLboolean, GLfloat *)) +AGL_API(void, GetObjectParameterfvARB, (GLhandleARB, GLenum, GLfloat *)) +AGL_API(void, GetObjectParameterivARB, (GLhandleARB, GLenum, GLint *)) +AGL_API(void, GetInfoLogARB, (GLhandleARB, GLsizei, GLsizei *, GLcharARB *)) +AGL_API(void, GetAttachedObjectsARB, (GLhandleARB, GLsizei, GLsizei *, GLhandleARB *)) +AGL_API(GLint, GetUniformLocationARB, (GLhandleARB, const GLcharARB *)) +AGL_API(void, GetActiveUniformARB, (GLhandleARB, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLcharARB *)) +AGL_API(void, GetUniformfvARB, (GLhandleARB, GLint, GLfloat *)) +AGL_API(void, GetUniformivARB, (GLhandleARB, GLint, GLint *)) +AGL_API(void, GetShaderSourceARB, (GLhandleARB, GLsizei, GLsizei *, GLcharARB *)) +#endif + +#ifdef _ALLEGRO_GL_ARB_vertex_shader +#ifndef GL_ARB_vertex_program +AGL_API(void, VertexAttrib1fARB, (GLuint, GLfloat)) +AGL_API(void, VertexAttrib1sARB, (GLuint, GLshort)) +AGL_API(void, VertexAttrib1dARB, (GLuint, GLdouble)) +AGL_API(void, VertexAttrib2fARB, (GLuint, GLfloat, GLfloat)) +AGL_API(void, VertexAttrib2sARB, (GLuint, GLshort, GLshort)) +AGL_API(void, VertexAttrib2dARB, (GLuint, GLdouble, GLdouble)) +AGL_API(void, VertexAttrib3fARB, (GLuint, GLfloat, GLfloat, GLfloat)) +AGL_API(void, VertexAttrib3sARB, (GLuint, GLshort, GLshort, GLshort)) +AGL_API(void, VertexAttrib3dARB, (GLuint, GLdouble, GLdouble, GLdouble)) +AGL_API(void, VertexAttrib4fARB, (GLuint, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, VertexAttrib4sARB, (GLuint, GLshort, GLshort, GLshort, GLshort)) +AGL_API(void, VertexAttrib4dARB, (GLuint, GLdouble, GLdouble, GLdouble, GLdouble)) +AGL_API(void, VertexAttrib4NubARB, (GLuint, GLubyte, GLubyte, GLubyte, GLubyte)) +AGL_API(void, VertexAttrib1fvARB, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib1svARB, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib1dvARB, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib2fvARB, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib2svARB, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib2dvARB, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib3fvARB, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib3svARB, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib3dvARB, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib4fvARB, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib4svARB, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib4dvARB, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib4ivARB, (GLuint, const GLint *)) +AGL_API(void, VertexAttrib4bvARB, (GLuint, const GLbyte *)) +AGL_API(void, VertexAttrib4ubvARB, (GLuint, const GLubyte *)) +AGL_API(void, VertexAttrib4usvARB, (GLuint, const GLushort *)) +AGL_API(void, VertexAttrib4uivARB, (GLuint, const GLuint *)) +AGL_API(void, VertexAttrib4NbvARB, (GLuint, const GLbyte *)) +AGL_API(void, VertexAttrib4NsvARB, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib4NivARB, (GLuint, const GLint *)) +AGL_API(void, VertexAttrib4NubvARB, (GLuint, const GLubyte *)) +AGL_API(void, VertexAttrib4NusvARB, (GLuint, const GLushort *)) +AGL_API(void, VertexAttrib4NuivARB, (GLuint, const GLuint *)) +AGL_API(void, VertexAttribPointerARB, (GLuint, GLint, GLenum, GLboolean, GLsizei, const GLvoid *)) +AGL_API(void, EnableVertexAttribArrayARB, (GLuint)) +AGL_API(void, DisableVertexAttribArrayARB, (GLuint)) +#endif +AGL_API(void, BindAttribLocationARB, (GLhandleARB, GLuint, const GLcharARB *)) +AGL_API(void, GetActiveAttribARB, (GLhandleARB, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLcharARB *)) +AGL_API(GLint, GetAttribLocationARB, (GLhandleARB, const GLcharARB *)) +#ifndef GL_ARB_vertex_program +AGL_API(void, GetVertexAttribdvARB, (GLuint, GLenum, GLdouble *)) +AGL_API(void, GetVertexAttribfvARB, (GLuint, GLenum, GLfloat *)) +AGL_API(void, GetVertexAttribivARB, (GLuint, GLenum, GLint *)) +AGL_API(void, GetVertexAttribPointervARB, (GLuint, GLenum, GLvoid **)) +#endif +#endif + +#if defined _ALLEGRO_GL_ARB_draw_buffers +AGL_API(void, DrawBuffersARB, (GLsizei n, const GLenum *bufs)) +#endif + +#if defined _ALLEGRO_GL_ARB_color_buffer_float +AGL_API(void, ClampColorARB, (GLenum, GLenum clamp)) +#endif + +#if defined _ALLEGRO_GL_ARB_draw_instanced +AGL_API(void, DrawArraysInstancedARB, (GLenum, GLint, GLsizei, GLsizei)) +AGL_API(void, DrawElementsInstancedARB, (GLenum, GLsizei, GLenum, const GLvoid *, GLsizei)) +#endif + +#if defined _ALLEGRO_GL_ARB_framebuffer_object +AGL_API(GLboolean, IsRenderbuffer, (GLuint)) +AGL_API(void, BindRenderbuffer, (GLenum, GLuint)) +AGL_API(void, DeleteRenderbuffers, (GLsizei, const GLuint *)) +AGL_API(void, GenRenderbuffers, (GLsizei, GLuint *)) +AGL_API(void, RenderbufferStorage, (GLenum, GLenum, GLsizei, GLsizei)) +AGL_API(void, GetRenderbufferParameteriv, (GLenum, GLenum, GLint *)) +AGL_API(GLboolean, IsFramebuffer, (GLuint)) +AGL_API(void, BindFramebuffer, (GLenum, GLuint)) +AGL_API(void, DeleteFramebuffers, (GLsizei, const GLuint *)) +AGL_API(void, GenFramebuffers, (GLsizei, GLuint *)) +AGL_API(GLenum, CheckFramebufferStatus, (GLenum)) +AGL_API(void, FramebufferTexture1D, (GLenum, GLenum, GLenum, GLuint, GLint)) +AGL_API(void, FramebufferTexture2D, (GLenum, GLenum, GLenum, GLuint, GLint)) +AGL_API(void, FramebufferTexture3D, (GLenum, GLenum, GLenum, GLuint, GLint, GLint)) +AGL_API(void, FramebufferRenderbuffer, (GLenum, GLenum, GLenum, GLuint)) +AGL_API(void, GetFramebufferAttachmentParameteriv, (GLenum, GLenum, GLenum, GLint *)) +AGL_API(void, GenerateMipmap, (GLenum)) +AGL_API(void, BlitFramebuffer, (GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLbitfield, GLenum)) +AGL_API(void, RenderbufferStorageMultisample, (GLenum, GLsizei, GLenum, GLsizei, GLsizei)) +AGL_API(void, FramebufferTextureLayer, (GLenum, GLenum, GLuint, GLint, GLint)) +#endif + +#if defined _ALLEGRO_GL_ARB_geometry_shader4 +AGL_API(void, ProgramParameteriARB, (GLuint, GLenum, GLint)) +AGL_API(void, FramebufferTextureARB, (GLenum, GLenum, GLuint, GLint)) +AGL_API(void, FramebufferTextureLayerARB, (GLenum, GLenum, GLuint, GLint, GLint)) +AGL_API(void, FramebufferTextureFaceARB, (GLenum, GLenum, GLuint, GLint, GLenum)) +#endif + +#if defined _ALLEGRO_GL_ARB_instanced_arrays +AGL_API(void, VertexAttribDivisor, (GLuint, GLuint)) +#endif + +#if defined _ALLEGRO_GL_ARB_map_buffer_range +AGL_API(void, MapBufferRange, (GLenum, GLintptr, GLsizeiptr, GLbitfield)) +AGL_API(void, FlushMappedBufferRange, (GLenum, GLintptr, GLsizeiptr)) +#endif + +#if defined _ALLEGRO_GL_ARB_texture_buffer_object +AGL_API(void, TexBufferARB, (GLenum, GLenum, GLuint)) +#endif + +#if defined _ALLEGRO_GL_ARB_vertex_array_object +AGL_API(void, BindVertexArray, (GLuint)) +AGL_API(void, DeleteVertexArrays, (GLsizei, const GLuint *)) +AGL_API(void, GenVertexArrays, (GLsizei, GLuint *)) +AGL_API(GLboolean, IsVertexArray, (GLuint)) +#endif + +#if defined _ALLEGRO_GL_ARB_uniform_buffer_object +AGL_API(void, GetUniformIndices, (GLuint, GLsizei, const GLchar* *, GLuint *)) +AGL_API(void, GetActiveUniformsiv, (GLuint, GLsizei, const GLuint *, GLenum, GLint *)) +AGL_API(void, GetActiveUniformName, (GLuint, GLuint, GLsizei, GLsizei *, GLchar *)) +AGL_API(GLuint, GetUniformBlockIndex, (GLuint, const GLchar *)) +AGL_API(void, GetActiveUniformBlockiv, (GLuint, GLuint, GLenum, GLint *)) +AGL_API(void, GetActiveUniformBlockName, (GLuint, GLuint, GLsizei, GLsizei *, GLchar *)) +AGL_API(void, UniformBlockBinding, (GLuint, GLuint, GLuint)) +#endif + +#if defined _ALLEGRO_GL_ARB_copy_buffer +AGL_API(void, CopyBufferSubData, (GLenum, GLenum, GLintptr, GLintptr, GLsizeiptr)) +#endif + + +#if defined _ALLEGRO_GL_ARB_draw_elements_base_vertex +AGL_API(void, DrawElementsBaseVertex, (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)) +AGL_API(void, DrawRangeElementsBaseVertex, (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)) +AGL_API(void, DrawElementsInstancedBaseVertex, (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount, GLint basevertex)) +AGL_API(void, MultiDrawElementsBaseVertex, (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount, const GLint *basevertex)) +#endif + +#if defined _ALLEGRO_GL_ARB_provoking_vertex +AGL_API(void, ProvokingVertex, (GLenum mode)) +#endif + +#if defined _ALLEGRO_GL_ARB_sync +AGL_API(GLsync, FenceSync, (GLenum condition, GLbitfield flags)) +AGL_API(GLboolean, IsSync, (GLsync sync)) +AGL_API(void, DeleteSync, (GLsync sync)) +AGL_API(GLenum, ClientWaitSync, (GLsync sync, GLbitfield flags, GLuint64 timeout)) +AGL_API(void, WaitSync, (GLsync sync, GLbitfield flags, GLuint64 timeout)) +AGL_API(void, GetInteger64v, (GLenum pname, GLint64 *params)) +AGL_API(void, GetSynciv, (GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values)) +#endif + +#if defined _ALLEGRO_GL_ARB_texture_multisample +AGL_API(void, TexImage2DMultisample, (GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)) +AGL_API(void, TexImage3DMultisample, (GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)) +AGL_API(void, GetMultisamplefv, (GLenum pname, GLuint index, GLfloat *val)) +AGL_API(void, SampleMaski, (GLuint index, GLbitfield mask)) +#endif + +#if defined _ALLEGRO_GL_ARB_draw_buffers_blend +AGL_API(void, BlendEquationi, (GLuint buf, GLenum mode)) +AGL_API(void, BlendEquationSeparatei, (GLuint buf, GLenum modeRGB, GLenum modeAlpha)) +AGL_API(void, BlendFunci, (GLuint buf, GLenum src, GLenum dst)) +AGL_API(void, BlendFuncSeparatei, (GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)) +#endif + +#if defined _ALLEGRO_GL_ARB_sample_shading +AGL_API(void, MinSampleShading, (GLclampf value)) +#endif + +#if defined _ALLEGRO_GL_ARB_shading_language_include +AGL_API(void, NamedStringARB, (GLenum type, GLint namelen, const GLchar *name, GLint stringlen, const GLchar *string)) +AGL_API(void, DeleteNamedStringARB, (GLint namelen, const GLchar *name)) +AGL_API(void, CompileShaderIncludeARB, (GLuint shader, GLsizei count, const GLchar* *path, const GLint *length)) +AGL_API(GLboolean, IsNamedStringARB, (GLint namelen, const GLchar *name)) +AGL_API(void, GetNamedStringARB, (GLint namelen, const GLchar *name, GLsizei bufSize, GLint *stringlen, GLchar *string)) +AGL_API(void, GetNamedStringivARB, (GLint namelen, const GLchar *name, GLenum pname, GLint *params)) +#endif + +#if defined _ALLEGRO_GL_ARB_blend_func_extended +AGL_API(void, BindFragDataLocationIndexed, (GLuint program, GLuint colorNumber, GLuint index, const GLchar *name)) +AGL_API(GLint, GetFragDataIndex, (GLuint program, const GLchar *name)) +#endif + +#if defined _ALLEGRO_GL_ARB_sampler_objects +AGL_API(void, GenSamplers, (GLsizei count, GLuint *samplers)) +AGL_API(void, DeleteSamplers, (GLsizei count, const GLuint *samplers)) +AGL_API(GLboolean, IsSampler, (GLuint sampler)) +AGL_API(void, BindSampler, (GLenum unit, GLuint sampler)) +AGL_API(void, SamplerParameteri, (GLuint sampler, GLenum pname, GLint param)) +AGL_API(void, SamplerParameteriv, (GLuint sampler, GLenum pname, const GLint *param)) +AGL_API(void, SamplerParameterf, (GLuint sampler, GLenum pname, GLfloat param)) +AGL_API(void, SamplerParameterfv, (GLuint sampler, GLenum pname, const GLfloat *param)) +AGL_API(void, SamplerParameterIiv, (GLuint sampler, GLenum pname, const GLint *param)) +AGL_API(void, SamplerParameterIuiv, (GLuint sampler, GLenum pname, const GLuint *param)) +AGL_API(void, GetSamplerParameteriv, (GLuint sampler, GLenum pname, GLint *params)) +AGL_API(void, GetSamplerParameterIiv, (GLuint sampler, GLenum pname, GLint *params)) +AGL_API(void, GetSamplerParameterfv, (GLuint sampler, GLenum pname, GLfloat *params)) +AGL_API(void, GetSamplerParameterIfv, (GLuint sampler, GLenum pname, GLfloat *params)) +#endif + +#if defined _ALLEGRO_GL_ARB_timer_query +AGL_API(void, QueryCounter, (GLuint id, GLenum target)) +AGL_API(void, GetQueryObjecti64v, (GLuint id, GLenum pname, GLint64 *params)) +AGL_API(void, GetQueryObjectui64v, (GLuint id, GLenum pname, GLuint64 *params)) +#endif + +#if defined _ALLEGRO_GL_ARB_vertex_type_2_10_10_10_rev +AGL_API(void, VertexP2ui, (GLenum type, GLuint value)) +AGL_API(void, VertexP2uiv, (GLenum type, const GLuint *value)) +AGL_API(void, VertexP3ui, (GLenum type, GLuint value)) +AGL_API(void, VertexP3uiv, (GLenum type, const GLuint *value)) +AGL_API(void, VertexP4ui, (GLenum type, GLuint value)) +AGL_API(void, VertexP4uiv, (GLenum type, const GLuint *value)) +AGL_API(void, TexCoordP1ui, (GLenum type, GLuint coords)) +AGL_API(void, TexCoordP1uiv, (GLenum type, const GLuint *coords)) +AGL_API(void, TexCoordP2ui, (GLenum type, GLuint coords)) +AGL_API(void, TexCoordP2uiv, (GLenum type, const GLuint *coords)) +AGL_API(void, TexCoordP3ui, (GLenum type, GLuint coords)) +AGL_API(void, TexCoordP3uiv, (GLenum type, const GLuint *coords)) +AGL_API(void, TexCoordP4ui, (GLenum type, GLuint coords)) +AGL_API(void, TexCoordP4uiv, (GLenum type, const GLuint *coords)) +AGL_API(void, MultiTexCoordP1ui, (GLenum texture, GLenum type, GLuint coords)) +AGL_API(void, MultiTexCoordP1uiv, (GLenum texture, GLenum type, const GLuint *coords)) +AGL_API(void, MultiTexCoordP2ui, (GLenum texture, GLenum type, GLuint coords)) +AGL_API(void, MultiTexCoordP2uiv, (GLenum texture, GLenum type, const GLuint *coords)) +AGL_API(void, MultiTexCoordP3ui, (GLenum texture, GLenum type, GLuint coords)) +AGL_API(void, MultiTexCoordP3uiv, (GLenum texture, GLenum type, const GLuint *coords)) +AGL_API(void, MultiTexCoordP4ui, (GLenum texture, GLenum type, GLuint coords)) +AGL_API(void, MultiTexCoordP4uiv, (GLenum texture, GLenum type, const GLuint *coords)) +AGL_API(void, NormalP3ui, (GLenum type, GLuint coords)) +AGL_API(void, NormalP3uiv, (GLenum type, const GLuint *coords)) +AGL_API(void, ColorP3ui, (GLenum type, GLuint color)) +AGL_API(void, ColorP3uiv, (GLenum type, const GLuint *color)) +AGL_API(void, ColorP4ui, (GLenum type, GLuint color)) +AGL_API(void, ColorP4uiv, (GLenum type, const GLuint *color)) +AGL_API(void, SecondaryColorP3ui, (GLenum type, GLuint color)) +AGL_API(void, SecondaryColorP3uiv, (GLenum type, const GLuint *color)) +AGL_API(void, VertexAttribP1ui, (GLuint index, GLenum type, GLboolean normalized, GLuint value)) +AGL_API(void, VertexAttribP1uiv, (GLuint index, GLenum type, GLboolean normalized, const GLuint *value)) +AGL_API(void, VertexAttribP2ui, (GLuint index, GLenum type, GLboolean normalized, GLuint value)) +AGL_API(void, VertexAttribP2uiv, (GLuint index, GLenum type, GLboolean normalized, const GLuint *value)) +AGL_API(void, VertexAttribP3ui, (GLuint index, GLenum type, GLboolean normalized, GLuint value)) +AGL_API(void, VertexAttribP3uiv, (GLuint index, GLenum type, GLboolean normalized, const GLuint *value)) +AGL_API(void, VertexAttribP4ui, (GLuint index, GLenum type, GLboolean normalized, GLuint value)) +AGL_API(void, VertexAttribP4uiv, (GLuint index, GLenum type, GLboolean normalized, const GLuint *value)) +#endif + +#if defined _ALLEGRO_GL_ARB_draw_indirect +AGL_API(void, DrawArraysIndirect, (GLenum mode, const GLvoid *indirect)) +AGL_API(void, DrawElementsIndirect, (GLenum mode, GLenum type, const GLvoid *indirect)) +#endif + +#if defined _ALLEGRO_GL_ARB_gpu_shader_fp64 +AGL_API(void, Uniform1d, (GLint location, GLdouble x)) +AGL_API(void, Uniform2d, (GLint location, GLdouble x, GLdouble y)) +AGL_API(void, Uniform3d, (GLint location, GLdouble x, GLdouble y, GLdouble z)) +AGL_API(void, Uniform4d, (GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w)) +AGL_API(void, Uniform1dv, (GLint location, GLsizei count, const GLdouble *value)) +AGL_API(void, Uniform2dv, (GLint location, GLsizei count, const GLdouble *value)) +AGL_API(void, Uniform3dv, (GLint location, GLsizei count, const GLdouble *value)) +AGL_API(void, Uniform4dv, (GLint location, GLsizei count, const GLdouble *value)) +AGL_API(void, UniformMatrix2dv, (GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, UniformMatrix3dv, (GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, UniformMatrix4dv, (GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, UniformMatrix2x3dv, (GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, UniformMatrix2x4dv, (GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, UniformMatrix3x2dv, (GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, UniformMatrix3x4dv, (GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, UniformMatrix4x2dv, (GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, UniformMatrix4x3dv, (GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, GetUniformdv, (GLuint program, GLint location, GLdouble *params)) +AGL_API(void, ProgramUniform1dEXT, (GLuint program, GLint location, GLdouble x)) +AGL_API(void, ProgramUniform2dEXT, (GLuint program, GLint location, GLdouble x, GLdouble y)) +AGL_API(void, ProgramUniform3dEXT, (GLuint program, GLint location, GLdouble x, GLdouble y, GLdouble z)) +AGL_API(void, ProgramUniform4dEXT, (GLuint program, GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w)) +AGL_API(void, ProgramUniform1dvEXT, (GLuint program, GLint location, GLsizei count, const GLdouble *value)) +AGL_API(void, ProgramUniform2dvEXT, (GLuint program, GLint location, GLsizei count, const GLdouble *value)) +AGL_API(void, ProgramUniform3dvEXT, (GLuint program, GLint location, GLsizei count, const GLdouble *value)) +AGL_API(void, ProgramUniform4dvEXT, (GLuint program, GLint location, GLsizei count, const GLdouble *value)) +AGL_API(void, ProgramUniformMatrix2dvEXT, (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, ProgramUniformMatrix3dvEXT, (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, ProgramUniformMatrix4dvEXT, (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, ProgramUniformMatrix2x3dvEXT, (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, ProgramUniformMatrix2x4dvEXT, (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, ProgramUniformMatrix3x2dvEXT, (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, ProgramUniformMatrix3x4dvEXT, (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, ProgramUniformMatrix4x2dvEXT, (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +AGL_API(void, ProgramUniformMatrix4x3dvEXT, (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)) +#endif + +#if defined _ALLEGRO_GL_ARB_shader_subroutine +AGL_API(GLint, GetSubroutineUniformLocation, (GLuint program, GLenum shadertype, const GLchar *name)) +AGL_API(GLuint, GetSubroutineIndex, (GLuint program, GLenum shadertype, const GLchar *name)) +AGL_API(void, GetActiveSubroutineUniformiv, (GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values)) +AGL_API(void, GetActiveSubroutineUniformName, (GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)) +AGL_API(void, GetActiveSubroutineName, (GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)) +AGL_API(void, UniformSubroutinesuiv, (GLenum shadertype, GLsizei count, const GLuint *indices)) +AGL_API(void, GetUniformSubroutineuiv, (GLenum shadertype, GLint location, GLuint *params)) +AGL_API(void, GetProgramStageiv, (GLuint program, GLenum shadertype, GLenum pname, GLint *values)) +#endif + +#if defined _ALLEGRO_GL_ARB_tessellation_shader +AGL_API(void, PatchParameteri, (GLenum pname, GLint value)) +AGL_API(void, PatchParameterfv, (GLenum pname, const GLfloat *values)) +#endif + +#if defined _ALLEGRO_GL_ARB_transform_feedback2 +AGL_API(void, BindTransformFeedback, (GLenum target, GLuint id)) +AGL_API(void, DeleteTransformFeedbacks, (GLsizei n, const GLuint *ids)) +AGL_API(void, GenTransformFeedbacks, (GLsizei n, GLuint *ids)) +AGL_API(GLboolean, IsTransformFeedback, (GLuint id)) +AGL_API(void, PauseTransformFeedback, (void)) +AGL_API(void, ResumeTransformFeedback, (void)) +AGL_API(void, DrawTransformFeedback, (GLenum mode, GLuint id)) +#endif + +#if defined _ALLEGRO_GL_ARB_transform_feedback3 +AGL_API(void, DrawTransformFeedbackStream, (GLenum mode, GLuint id, GLuint stream)) +AGL_API(void, BeginQueryIndexed, (GLenum target, GLuint index, GLuint id)) +AGL_API(void, EndQueryIndexed, (GLenum target, GLuint index)) +AGL_API(void, GetQueryIndexediv, (GLenum target, GLuint index, GLenum pname, GLint *params)) +#endif + + +/* */ + + +#if defined _ALLEGRO_GL_EXT_blend_color +AGL_API(void, BlendColorEXT, (GLclampf, GLclampf, GLclampf, GLclampf)) +#endif + +#if defined _ALLEGRO_GL_EXT_polygon_offset +AGL_API(void, PolygonOffsetEXT, (GLfloat, GLfloat)) +#endif + +#if defined _ALLEGRO_GL_EXT_texture3D +AGL_API(void, TexImage3DEXT, (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *)) +AGL_API(void, TexSubImage3DEXT, (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_SGIS_texture_filter4 +AGL_API(void, GetTexFilterFuncSGIS, (GLenum, GLenum, GLfloat *)) +AGL_API(void, TexFilterFuncSGIS, (GLenum, GLenum, GLsizei, const GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_EXT_subtexture +AGL_API(void, TexSubImage1DEXT, (GLenum, GLint, GLint, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, TexSubImage2DEXT, (GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_EXT_copy_texture +AGL_API(void, CopyTexImage1DEXT, (GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLint)) +AGL_API(void, CopyTexImage2DEXT, (GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLsizei, GLint)) +AGL_API(void, CopyTexSubImage1DEXT, (GLenum, GLint, GLint, GLint, GLint, GLsizei)) +AGL_API(void, CopyTexSubImage2DEXT, (GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei)) +AGL_API(void, CopyTexSubImage3DEXT, (GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei)) +#endif + +#if defined _ALLEGRO_GL_EXT_histogram +AGL_API(void, GetHistogramEXT, (GLenum, GLboolean, GLenum, GLenum, GLvoid *)) +AGL_API(void, GetHistogramParameterfvEXT, (GLenum, GLenum, GLfloat *)) +AGL_API(void, GetHistogramParameterivEXT, (GLenum, GLenum, GLint *)) +AGL_API(void, GetMinmaxEXT, (GLenum, GLboolean, GLenum, GLenum, GLvoid *)) +AGL_API(void, GetMinmaxParameterfvEXT, (GLenum, GLenum, GLfloat *)) +AGL_API(void, GetMinmaxParameterivEXT, (GLenum, GLenum, GLint *)) +AGL_API(void, HistogramEXT, (GLenum, GLsizei, GLenum, GLboolean)) +AGL_API(void, MinmaxEXT, (GLenum, GLenum, GLboolean)) +AGL_API(void, ResetHistogramEXT, (GLenum)) +AGL_API(void, ResetMinmaxEXT, (GLenum)) +#endif + +#if defined _ALLEGRO_GL_EXT_convolution +AGL_API(void, ConvolutionFilter1DEXT, (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, ConvolutionFilter2DEXT, (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, ConvolutionParameterfEXT, (GLenum, GLenum, GLfloat)) +AGL_API(void, ConvolutionParameterfvEXT, (GLenum, GLenum, const GLfloat *)) +AGL_API(void, ConvolutionParameteriEXT, (GLenum, GLenum, GLint)) +AGL_API(void, ConvolutionParameterivEXT, (GLenum, GLenum, const GLint *)) +AGL_API(void, CopyConvolutionFilter1DEXT, (GLenum, GLenum, GLint, GLint, GLsizei)) +AGL_API(void, CopyConvolutionFilter2DEXT, (GLenum, GLenum, GLint, GLint, GLsizei, GLsizei)) +AGL_API(void, GetConvolutionFilterEXT, (GLenum, GLenum, GLenum, GLvoid *)) +AGL_API(void, GetConvolutionParameterfvEXT, (GLenum, GLenum, GLfloat *)) +AGL_API(void, GetConvolutionParameterivEXT, (GLenum, GLenum, GLint *)) +AGL_API(void, GetSeparableFilterEXT, (GLenum, GLenum, GLenum, GLvoid *, GLvoid *, GLvoid *)) +AGL_API(void, SeparableFilter2DEXT, (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *, const GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_SGI_color_table +AGL_API(void, ColorTableSGI, (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, ColorTableParameterfvSGI, (GLenum, GLenum, const GLfloat *)) +AGL_API(void, ColorTableParameterivSGI, (GLenum, GLenum, const GLint *)) +AGL_API(void, CopyColorTableSGI, (GLenum, GLenum, GLint, GLint, GLsizei)) +AGL_API(void, GetColorTableSGI, (GLenum, GLenum, GLenum, GLvoid *)) +AGL_API(void, GetColorTableParameterfvSGI, (GLenum, GLenum, GLfloat *)) +AGL_API(void, GetColorTableParameterivSGI, (GLenum, GLenum, GLint *)) +#endif + +#if defined _ALLEGRO_GL_SGIX_pixel_texture +AGL_API(void, PixelTexGenSGIX, (GLenum)) +#endif + +#if defined _ALLEGRO_GL_SGIS_pixel_texture +AGL_API(void, PixelTexGenParameteriSGIS, (GLenum, GLint)) +AGL_API(void, PixelTexGenParameterivSGIS, (GLenum, const GLint *)) +AGL_API(void, PixelTexGenParameterfSGIS, (GLenum, GLfloat)) +AGL_API(void, PixelTexGenParameterfvSGIS, (GLenum, const GLfloat *)) +AGL_API(void, GetPixelTexGenParameterivSGIS, (GLenum, GLint *)) +AGL_API(void, GetPixelTexGenParameterfvSGIS, (GLenum, GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_SGIS_texture4D +AGL_API(void, TexImage4DSGIS, (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *)) +AGL_API(void, TexSubImage4DSGIS, (GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_EXT_texture_object +AGL_API(GLboolean, AreTexturesResidentEXT, (GLsizei, const GLuint *, GLboolean *)) +AGL_API(void, BindTextureEXT, (GLenum, GLuint)) +AGL_API(void, DeleteTexturesEXT, (GLsizei, const GLuint *)) +AGL_API(void, GenTexturesEXT, (GLsizei, GLuint *)) +AGL_API(GLboolean, IsTextureEXT, (GLuint)) +AGL_API(void, PrioritizeTexturesEXT, (GLsizei, const GLuint *, const GLclampf *)) +#endif + +#if defined _ALLEGRO_GL_SGIS_detail_texture +AGL_API(void, DetailTexFuncSGIS, (GLenum, GLsizei, const GLfloat *)) +AGL_API(void, GetDetailTexFuncSGIS, (GLenum, GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_SGIS_sharpen_texture +AGL_API(void, SharpenTexFuncSGIS, (GLenum, GLsizei, const GLfloat *)) +AGL_API(void, GetSharpenTexFuncSGIS, (GLenum, GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_SGIS_multisample +AGL_API(void, SampleMaskSGIS, (GLclampf, GLboolean)) +AGL_API(void, SamplePatternSGIS, (GLenum)) +#endif + +#if defined _ALLEGRO_GL_EXT_vertex_array +AGL_API(void, ArrayElementEXT, (GLint)) +AGL_API(void, ColorPointerEXT, (GLint, GLenum, GLsizei, GLsizei, const GLvoid *)) +AGL_API(void, DrawArraysEXT, (GLenum, GLint, GLsizei)) +AGL_API(void, EdgeFlagPointerEXT, (GLsizei, GLsizei, const GLboolean *)) +AGL_API(void, GetPointervEXT, (GLenum, GLvoid* *)) +AGL_API(void, IndexPointerEXT, (GLenum, GLsizei, GLsizei, const GLvoid *)) +AGL_API(void, NormalPointerEXT, (GLenum, GLsizei, GLsizei, const GLvoid *)) +AGL_API(void, TexCoordPointerEXT, (GLint, GLenum, GLsizei, GLsizei, const GLvoid *)) +AGL_API(void, VertexPointerEXT, (GLint, GLenum, GLsizei, GLsizei, const GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_EXT_blend_minmax +AGL_API(void, BlendEquationEXT, (GLenum)) +#endif + +#if defined _ALLEGRO_GL_SGIX_sprite +AGL_API(void, SpriteParameterfSGIX, (GLenum, GLfloat)) +AGL_API(void, SpriteParameterfvSGIX, (GLenum, const GLfloat *)) +AGL_API(void, SpriteParameteriSGIX, (GLenum, GLint)) +AGL_API(void, SpriteParameterivSGIX, (GLenum, const GLint *)) +#endif + +#if defined _ALLEGRO_GL_EXT_point_parameters +AGL_API(void, PointParameterfEXT, (GLenum, GLfloat)) +AGL_API(void, PointParameterfvEXT, (GLenum, const GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_SGIS_point_parameters +AGL_API(void, PointParameterfSGIS, (GLenum, GLfloat)) +AGL_API(void, PointParameterfvSGIS, (GLenum, const GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_SGIX_instruments +AGL_API(GLint, GetInstrumentsSGIX, (void)) +AGL_API(void, InstrumentsBufferSGIX, (GLsizei, GLint *)) +AGL_API(GLint, PollInstrumentsSGIX, (GLint *)) +AGL_API(void, ReadInstrumentsSGIX, (GLint)) +AGL_API(void, StartInstrumentsSGIX, (void)) +AGL_API(void, StopInstrumentsSGIX, (GLint)) +#endif + +#if defined _ALLEGRO_GL_SGIX_framezoom +AGL_API(void, FrameZoomSGIX, (GLint)) +#endif + +#if defined _ALLEGRO_GL_SGIX_tag_sample_buffer +AGL_API(void, TagSampleBufferSGIX, (void)) +#endif + +#if defined _ALLEGRO_GL_SGIX_polynomial_ffd +AGL_API(void, DeformationMap3dSGIX, (GLenum, GLdouble, GLdouble, GLint, GLint, GLdouble, GLdouble, GLint, GLint, GLdouble, GLdouble, GLint, GLint, const GLdouble *)) +AGL_API(void, DeformationMap3fSGIX, (GLenum, GLfloat, GLfloat, GLint, GLint, GLfloat, GLfloat, GLint, GLint, GLfloat, GLfloat, GLint, GLint, const GLfloat *)) +AGL_API(void, DeformSGIX, (GLbitfield)) +AGL_API(void, LoadIdentityDeformationMapSGIX, (GLbitfield)) +#endif + +#if defined _ALLEGRO_GL_SGIX_reference_plane +AGL_API(void, ReferencePlaneSGIX, (const GLdouble *)) +#endif + +#if defined _ALLEGRO_GL_SGIX_flush_raster +AGL_API(void, FlushRasterSGIX, (void)) +#endif + +#if defined _ALLEGRO_GL_SGIS_fog_function +AGL_API(void, FogFuncSGIS, (GLsizei, const GLfloat *)) +AGL_API(void, GetFogFuncSGIS, (GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_HP_image_transform +AGL_API(void, ImageTransformParameteriHP, (GLenum, GLenum, GLint)) +AGL_API(void, ImageTransformParameterfHP, (GLenum, GLenum, GLfloat)) +AGL_API(void, ImageTransformParameterivHP, (GLenum, GLenum, const GLint *)) +AGL_API(void, ImageTransformParameterfvHP, (GLenum, GLenum, const GLfloat *)) +AGL_API(void, GetImageTransformParameterivHP, (GLenum, GLenum, GLint *)) +AGL_API(void, GetImageTransformParameterfvHP, (GLenum, GLenum, GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_EXT_color_subtable +#ifndef GL_EXT_paletted_texture +AGL_API(void, ColorSubTableEXT, (GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *)) +#endif +AGL_API(void, CopyColorSubTableEXT, (GLenum, GLsizei, GLint, GLint, GLsizei)) +#endif + +#if defined _ALLEGRO_GL_PGI_misc_hints +AGL_API(void, HintPGI, (GLenum, GLint)) +#endif + +#if defined _ALLEGRO_GL_EXT_paletted_texture +AGL_API(void, ColorTableEXT, (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, GetColorTableEXT, (GLenum, GLenum, GLenum, GLvoid *)) +AGL_API(void, GetColorTableParameterivEXT, (GLenum, GLenum, GLint *)) +AGL_API(void, GetColorTableParameterfvEXT, (GLenum, GLenum, GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_SGIX_list_priority +AGL_API(void, GetListParameterfvSGIX, (GLuint, GLenum, GLfloat *)) +AGL_API(void, GetListParameterivSGIX, (GLuint, GLenum, GLint *)) +AGL_API(void, ListParameterfSGIX, (GLuint, GLenum, GLfloat)) +AGL_API(void, ListParameterfvSGIX, (GLuint, GLenum, const GLfloat *)) +AGL_API(void, ListParameteriSGIX, (GLuint, GLenum, GLint)) +AGL_API(void, ListParameterivSGIX, (GLuint, GLenum, const GLint *)) +#endif + +#if defined _ALLEGRO_GL_EXT_index_material +AGL_API(void, IndexMaterialEXT, (GLenum, GLenum)) +#endif + +#if defined _ALLEGRO_GL_EXT_index_func +AGL_API(void, IndexFuncEXT, (GLenum, GLclampf)) +#endif + +#if defined _ALLEGRO_GL_EXT_compiled_vertex_array +AGL_API(void, LockArraysEXT, (GLint, GLsizei)) +AGL_API(void, UnlockArraysEXT, (void)) +#endif + +#if defined _ALLEGRO_GL_EXT_cull_vertex +AGL_API(void, CullParameterdvEXT, (GLenum, GLdouble *)) +AGL_API(void, CullParameterfvEXT, (GLenum, GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_SGIX_fragment_lighting +AGL_API(void, FragmentColorMaterialSGIX, (GLenum, GLenum)) +AGL_API(void, FragmentLightfSGIX, (GLenum, GLenum, GLfloat)) +AGL_API(void, FragmentLightfvSGIX, (GLenum, GLenum, const GLfloat *)) +AGL_API(void, FragmentLightiSGIX, (GLenum, GLenum, GLint)) +AGL_API(void, FragmentLightivSGIX, (GLenum, GLenum, const GLint *)) +AGL_API(void, FragmentLightModelfSGIX, (GLenum, GLfloat)) +AGL_API(void, FragmentLightModelfvSGIX, (GLenum, const GLfloat *)) +AGL_API(void, FragmentLightModeliSGIX, (GLenum, GLint)) +AGL_API(void, FragmentLightModelivSGIX, (GLenum, const GLint *)) +AGL_API(void, FragmentMaterialfSGIX, (GLenum, GLenum, GLfloat)) +AGL_API(void, FragmentMaterialfvSGIX, (GLenum, GLenum, const GLfloat *)) +AGL_API(void, FragmentMaterialiSGIX, (GLenum, GLenum, GLint)) +AGL_API(void, FragmentMaterialivSGIX, (GLenum, GLenum, const GLint *)) +AGL_API(void, GetFragmentLightfvSGIX, (GLenum, GLenum, GLfloat *)) +AGL_API(void, GetFragmentLightivSGIX, (GLenum, GLenum, GLint *)) +AGL_API(void, GetFragmentMaterialfvSGIX, (GLenum, GLenum, GLfloat *)) +AGL_API(void, GetFragmentMaterialivSGIX, (GLenum, GLenum, GLint *)) +AGL_API(void, LightEnviSGIX, (GLenum, GLint)) +#endif + +#if defined _ALLEGRO_GL_EXT_draw_range_elements +AGL_API(void, DrawRangeElementsEXT, (GLenum, GLuint, GLuint, GLsizei, GLenum, const GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_EXT_light_texture +AGL_API(void, ApplyTextureEXT, (GLenum)) +AGL_API(void, TextureLightEXT, (GLenum)) +AGL_API(void, TextureMaterialEXT, (GLenum, GLenum)) +#endif + +#if defined _ALLEGRO_GL_SGIX_async +AGL_API(void, AsyncMarkerSGIX, (GLuint)) +AGL_API(GLint, FinishAsyncSGIX, (GLuint *)) +AGL_API(GLint, PollAsyncSGIX, (GLuint *)) +AGL_API(GLuint, GenAsyncMarkersSGIX, (GLsizei)) +AGL_API(void, DeleteAsyncMarkersSGIX, (GLuint, GLsizei)) +AGL_API(GLboolean, IsAsyncMarkerSGIX, (GLuint)) +#endif + +#if defined _ALLEGRO_GL_INTEL_parallel_arrays +AGL_API(void, VertexPointervINTEL, (GLint, GLenum, const GLvoid* *)) +AGL_API(void, NormalPointervINTEL, (GLenum, const GLvoid* *)) +AGL_API(void, ColorPointervINTEL, (GLint, GLenum, const GLvoid* *)) +AGL_API(void, TexCoordPointervINTEL, (GLint, GLenum, const GLvoid* *)) +#endif + +#if defined _ALLEGRO_GL_EXT_pixel_transform +AGL_API(void, PixelTransformParameteriEXT, (GLenum, GLenum, GLint)) +AGL_API(void, PixelTransformParameterfEXT, (GLenum, GLenum, GLfloat)) +AGL_API(void, PixelTransformParameterivEXT, (GLenum, GLenum, const GLint *)) +AGL_API(void, PixelTransformParameterfvEXT, (GLenum, GLenum, const GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_EXT_secondary_color +AGL_API(void, SecondaryColor3bEXT, (GLbyte, GLbyte, GLbyte)) +AGL_API(void, SecondaryColor3bvEXT, (const GLbyte *)) +AGL_API(void, SecondaryColor3dEXT, (GLdouble, GLdouble, GLdouble)) +AGL_API(void, SecondaryColor3dvEXT, (const GLdouble *)) +AGL_API(void, SecondaryColor3fEXT, (GLfloat, GLfloat, GLfloat)) +AGL_API(void, SecondaryColor3fvEXT, (const GLfloat *)) +AGL_API(void, SecondaryColor3iEXT, (GLint, GLint, GLint)) +AGL_API(void, SecondaryColor3ivEXT, (const GLint *)) +AGL_API(void, SecondaryColor3sEXT, (GLshort, GLshort, GLshort)) +AGL_API(void, SecondaryColor3svEXT, (const GLshort *)) +AGL_API(void, SecondaryColor3ubEXT, (GLubyte, GLubyte, GLubyte)) +AGL_API(void, SecondaryColor3ubvEXT, (const GLubyte *)) +AGL_API(void, SecondaryColor3uiEXT, (GLuint, GLuint, GLuint)) +AGL_API(void, SecondaryColor3uivEXT, (const GLuint *)) +AGL_API(void, SecondaryColor3usEXT, (GLushort, GLushort, GLushort)) +AGL_API(void, SecondaryColor3usvEXT, (const GLushort *)) +AGL_API(void, SecondaryColorPointerEXT, (GLint, GLenum, GLsizei, const GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_EXT_texture_perturb_normal +AGL_API(void, TextureNormalEXT, (GLenum)) +#endif + +#if defined _ALLEGRO_GL_EXT_multi_draw_arrays +AGL_API(void, MultiDrawArraysEXT, (GLenum, GLint *, GLsizei *, GLsizei)) +AGL_API(void, MultiDrawElementsEXT, (GLenum, const GLsizei *, GLenum, const GLvoid* *, GLsizei)) +#endif + +#if defined _ALLEGRO_GL_EXT_fog_coord +AGL_API(void, FogCoordfEXT, (GLfloat)) +AGL_API(void, FogCoordfvEXT, (const GLfloat *)) +AGL_API(void, FogCoorddEXT, (GLdouble)) +AGL_API(void, FogCoorddvEXT, (const GLdouble *)) +AGL_API(void, FogCoordPointerEXT, (GLenum, GLsizei, const GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_EXT_coordinate_frame +AGL_API(void, Tangent3bEXT, (GLbyte, GLbyte, GLbyte)) +AGL_API(void, Tangent3bvEXT, (const GLbyte *)) +AGL_API(void, Tangent3dEXT, (GLdouble, GLdouble, GLdouble)) +AGL_API(void, Tangent3dvEXT, (const GLdouble *)) +AGL_API(void, Tangent3fEXT, (GLfloat, GLfloat, GLfloat)) +AGL_API(void, Tangent3fvEXT, (const GLfloat *)) +AGL_API(void, Tangent3iEXT, (GLint, GLint, GLint)) +AGL_API(void, Tangent3ivEXT, (const GLint *)) +AGL_API(void, Tangent3sEXT, (GLshort, GLshort, GLshort)) +AGL_API(void, Tangent3svEXT, (const GLshort *)) +AGL_API(void, Binormal3bEXT, (GLbyte, GLbyte, GLbyte)) +AGL_API(void, Binormal3bvEXT, (const GLbyte *)) +AGL_API(void, Binormal3dEXT, (GLdouble, GLdouble, GLdouble)) +AGL_API(void, Binormal3dvEXT, (const GLdouble *)) +AGL_API(void, Binormal3fEXT, (GLfloat, GLfloat, GLfloat)) +AGL_API(void, Binormal3fvEXT, (const GLfloat *)) +AGL_API(void, Binormal3iEXT, (GLint, GLint, GLint)) +AGL_API(void, Binormal3ivEXT, (const GLint *)) +AGL_API(void, Binormal3sEXT, (GLshort, GLshort, GLshort)) +AGL_API(void, Binormal3svEXT, (const GLshort *)) +AGL_API(void, TangentPointerEXT, (GLenum, GLsizei, const GLvoid *)) +AGL_API(void, BinormalPointerEXT, (GLenum, GLsizei, const GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_SUNX_constant_data +AGL_API(void, FinishTextureSUNX, (void)) +#endif + +#if defined _ALLEGRO_GL_SUN_global_alpha +AGL_API(void, GlobalAlphaFactorbSUN, (GLbyte)) +AGL_API(void, GlobalAlphaFactorsSUN, (GLshort)) +AGL_API(void, GlobalAlphaFactoriSUN, (GLint)) +AGL_API(void, GlobalAlphaFactorfSUN, (GLfloat)) +AGL_API(void, GlobalAlphaFactordSUN, (GLdouble)) +AGL_API(void, GlobalAlphaFactorubSUN, (GLubyte)) +AGL_API(void, GlobalAlphaFactorusSUN, (GLushort)) +AGL_API(void, GlobalAlphaFactoruiSUN, (GLuint)) +#endif + +#if defined _ALLEGRO_GL_SUN_triangle_list +AGL_API(void, ReplacementCodeuiSUN, (GLuint)) +AGL_API(void, ReplacementCodeusSUN, (GLushort)) +AGL_API(void, ReplacementCodeubSUN, (GLubyte)) +AGL_API(void, ReplacementCodeuivSUN, (const GLuint *)) +AGL_API(void, ReplacementCodeusvSUN, (const GLushort *)) +AGL_API(void, ReplacementCodeubvSUN, (const GLubyte *)) +AGL_API(void, ReplacementCodePointerSUN, (GLenum, GLsizei, const GLvoid* *)) +#endif + +#if defined _ALLEGRO_GL_SUN_vertex +AGL_API(void, Color4ubVertex2fSUN, (GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat)) +AGL_API(void, Color4ubVertex2fvSUN, (const GLubyte *, const GLfloat *)) +AGL_API(void, Color4ubVertex3fSUN, (GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat, GLfloat)) +AGL_API(void, Color4ubVertex3fvSUN, (const GLubyte *, const GLfloat *)) +AGL_API(void, Color3fVertex3fSUN, (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, Color3fVertex3fvSUN, (const GLfloat *, const GLfloat *)) +AGL_API(void, Normal3fVertex3fSUN, (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, Normal3fVertex3fvSUN, (const GLfloat *, const GLfloat *)) +AGL_API(void, Color4fNormal3fVertex3fSUN, (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, Color4fNormal3fVertex3fvSUN, (const GLfloat *, const GLfloat *, const GLfloat *)) +AGL_API(void, TexCoord2fVertex3fSUN, (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, TexCoord2fVertex3fvSUN, (const GLfloat *, const GLfloat *)) +AGL_API(void, TexCoord4fVertex4fSUN, (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, TexCoord4fVertex4fvSUN, (const GLfloat *, const GLfloat *)) +AGL_API(void, TexCoord2fColor4ubVertex3fSUN, (GLfloat, GLfloat, GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat, GLfloat)) +AGL_API(void, TexCoord2fColor4ubVertex3fvSUN, (const GLfloat *, const GLubyte *, const GLfloat *)) +AGL_API(void, TexCoord2fColor3fVertex3fSUN, (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, TexCoord2fColor3fVertex3fvSUN, (const GLfloat *, const GLfloat *, const GLfloat *)) +AGL_API(void, TexCoord2fNormal3fVertex3fSUN, (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, TexCoord2fNormal3fVertex3fvSUN, (const GLfloat *, const GLfloat *, const GLfloat *)) +AGL_API(void, TexCoord2fColor4fNormal3fVertex3fSUN, (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, TexCoord2fColor4fNormal3fVertex3fvSUN, (const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *)) +AGL_API(void, TexCoord4fColor4fNormal3fVertex4fSUN, (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, TexCoord4fColor4fNormal3fVertex4fvSUN, (const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *)) +AGL_API(void, ReplacementCodeuiVertex3fSUN, (GLuint, GLfloat, GLfloat, GLfloat)) +AGL_API(void, ReplacementCodeuiVertex3fvSUN, (const GLuint *, const GLfloat *)) +AGL_API(void, ReplacementCodeuiColor4ubVertex3fSUN, (GLuint, GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat, GLfloat)) +AGL_API(void, ReplacementCodeuiColor4ubVertex3fvSUN, (const GLuint *, const GLubyte *, const GLfloat *)) +AGL_API(void, ReplacementCodeuiColor3fVertex3fSUN, (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, ReplacementCodeuiColor3fVertex3fvSUN, (const GLuint *, const GLfloat *, const GLfloat *)) +AGL_API(void, ReplacementCodeuiNormal3fVertex3fSUN, (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, ReplacementCodeuiNormal3fVertex3fvSUN, (const GLuint *, const GLfloat *, const GLfloat *)) +AGL_API(void, ReplacementCodeuiColor4fNormal3fVertex3fSUN, (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, ReplacementCodeuiColor4fNormal3fVertex3fvSUN, (const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *)) +AGL_API(void, ReplacementCodeuiTexCoord2fVertex3fSUN, (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, ReplacementCodeuiTexCoord2fVertex3fvSUN, (const GLuint *, const GLfloat *, const GLfloat *)) +AGL_API(void, ReplacementCodeuiTexCoord2fNormal3fVertex3fSUN, (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, ReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN, (const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *)) +AGL_API(void, ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN, (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN, (const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_EXT_blend_func_separate +AGL_API(void, BlendFuncSeparateEXT, (GLenum, GLenum, GLenum, GLenum)) +#endif + +#if defined _ALLEGRO_GL_INGR_blend_func_separate +AGL_API(void, BlendFuncSeparateINGR, (GLenum, GLenum, GLenum, GLenum)) +#endif + +#if defined _ALLEGRO_GL_EXT_vertex_weighting +AGL_API(void, VertexWeightfEXT, (GLfloat)) +AGL_API(void, VertexWeightfvEXT, (const GLfloat *)) +AGL_API(void, VertexWeightPointerEXT, (GLsizei, GLenum, GLsizei, const GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_NV_vertex_array_range +AGL_API(void, FlushVertexArrayRangeNV, (void)) +AGL_API(void, VertexArrayRangeNV, (GLsizei, const GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_NV_register_combiners +AGL_API(void, CombinerParameterfvNV, (GLenum, const GLfloat *)) +AGL_API(void, CombinerParameterfNV, (GLenum, GLfloat)) +AGL_API(void, CombinerParameterivNV, (GLenum, const GLint *)) +AGL_API(void, CombinerParameteriNV, (GLenum, GLint)) +AGL_API(void, CombinerInputNV, (GLenum, GLenum, GLenum, GLenum, GLenum, GLenum)) +AGL_API(void, CombinerOutputNV, (GLenum, GLenum, GLenum, GLenum, GLenum, GLenum, GLenum, GLboolean, GLboolean, GLboolean)) +AGL_API(void, FinalCombinerInputNV, (GLenum, GLenum, GLenum, GLenum)) +AGL_API(void, GetCombinerInputParameterfvNV, (GLenum, GLenum, GLenum, GLenum, GLfloat *)) +AGL_API(void, GetCombinerInputParameterivNV, (GLenum, GLenum, GLenum, GLenum, GLint *)) +AGL_API(void, GetCombinerOutputParameterfvNV, (GLenum, GLenum, GLenum, GLfloat *)) +AGL_API(void, GetCombinerOutputParameterivNV, (GLenum, GLenum, GLenum, GLint *)) +AGL_API(void, GetFinalCombinerInputParameterfvNV, (GLenum, GLenum, GLfloat *)) +AGL_API(void, GetFinalCombinerInputParameterivNV, (GLenum, GLenum, GLint *)) +#endif + +#if defined _ALLEGRO_GL_MESA_resize_buffers +AGL_API(void, ResizeBuffersMESA, (void)) +#endif + +#if defined _ALLEGRO_GL_MESA_window_pos +AGL_API(void, WindowPos2dMESA, (GLdouble, GLdouble)) +AGL_API(void, WindowPos2dvMESA, (const GLdouble *)) +AGL_API(void, WindowPos2fMESA, (GLfloat, GLfloat)) +AGL_API(void, WindowPos2fvMESA, (const GLfloat *)) +AGL_API(void, WindowPos2iMESA, (GLint, GLint)) +AGL_API(void, WindowPos2ivMESA, (const GLint *)) +AGL_API(void, WindowPos2sMESA, (GLshort, GLshort)) +AGL_API(void, WindowPos2svMESA, (const GLshort *)) +AGL_API(void, WindowPos3dMESA, (GLdouble, GLdouble, GLdouble)) +AGL_API(void, WindowPos3dvMESA, (const GLdouble *)) +AGL_API(void, WindowPos3fMESA, (GLfloat, GLfloat, GLfloat)) +AGL_API(void, WindowPos3fvMESA, (const GLfloat *)) +AGL_API(void, WindowPos3iMESA, (GLint, GLint, GLint)) +AGL_API(void, WindowPos3ivMESA, (const GLint *)) +AGL_API(void, WindowPos3sMESA, (GLshort, GLshort, GLshort)) +AGL_API(void, WindowPos3svMESA, (const GLshort *)) +AGL_API(void, WindowPos4dMESA, (GLdouble, GLdouble, GLdouble, GLdouble)) +AGL_API(void, WindowPos4dvMESA, (const GLdouble *)) +AGL_API(void, WindowPos4fMESA, (GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, WindowPos4fvMESA, (const GLfloat *)) +AGL_API(void, WindowPos4iMESA, (GLint, GLint, GLint, GLint)) +AGL_API(void, WindowPos4ivMESA, (const GLint *)) +AGL_API(void, WindowPos4sMESA, (GLshort, GLshort, GLshort, GLshort)) +AGL_API(void, WindowPos4svMESA, (const GLshort *)) +#endif + +#if defined _ALLEGRO_GL_IBM_multimode_draw_arrays +AGL_API(void, MultiModeDrawArraysIBM, (GLenum, const GLint *, const GLsizei *, GLsizei, GLint)) +AGL_API(void, MultiModeDrawElementsIBM, (const GLenum *, const GLsizei *, GLenum, const GLvoid* *, GLsizei, GLint)) +#endif + +#ifdef AGK_IBM_vertex_array_lists +AGL_API(void, ColorPointerListIBM, (GLint, GLenum, GLint, const GLvoid* *, GLint)) +AGL_API(void, SecondaryColorPointerListIBM, (GLint, GLenum, GLint, const GLvoid* *, GLint)) +AGL_API(void, EdgeFlagPointerListIBM, (GLint, const GLboolean* *, GLint)) +AGL_API(void, FogCoordPointerListIBM, (GLenum, GLint, const GLvoid* *, GLint)) +AGL_API(void, IndexPointerListIBM, (GLenum, GLint, const GLvoid* *, GLint)) +AGL_API(void, NormalPointerListIBM, (GLenum, GLint, const GLvoid* *, GLint)) +AGL_API(void, TexCoordPointerListIBM, (GLint, GLenum, GLint, const GLvoid* *, GLint)) +AGL_API(void, VertexPointerListIBM, (GLint, GLenum, GLint, const GLvoid* *, GLint)) +#endif + +#if defined _ALLEGRO_GL_3DFX_tbuffer +AGL_API(void, TbufferMask3DFX, (GLuint)) +#endif + +#if defined _ALLEGRO_GL_EXT_multisample +AGL_API(void, SampleMaskEXT, (GLclampf, GLboolean)) +AGL_API(void, SamplePatternEXT, (GLenum)) +#endif + +#if defined _ALLEGRO_GL_SGIS_texture_color_mask +AGL_API(void, TextureColorMaskSGIS, (GLboolean, GLboolean, GLboolean, GLboolean)) +#endif + +#if defined _ALLEGRO_GL_SGIX_igloo_interface +AGL_API(void, IglooInterfaceSGIX, (GLenum, const GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_NV_fence +AGL_API(void, DeleteFencesNV, (GLsizei, const GLuint *)) +AGL_API(void, GenFencesNV, (GLsizei, GLuint *)) +AGL_API(GLboolean, IsFenceNV, (GLuint)) +AGL_API(GLboolean, TestFenceNV, (GLuint)) +AGL_API(void, GetFenceivNV, (GLuint, GLenum, GLint *)) +AGL_API(void, FinishFenceNV, (GLuint)) +AGL_API(void, SetFenceNV, (GLuint, GLenum)) +#endif + +#if defined _ALLEGRO_GL_NV_evaluators +AGL_API(void, MapControlPointsNV, (GLenum, GLuint, GLenum, GLsizei, GLsizei, GLint, GLint, GLboolean, const GLvoid *)) +AGL_API(void, MapParameterivNV, (GLenum, GLenum, const GLint *)) +AGL_API(void, MapParameterfvNV, (GLenum, GLenum, const GLfloat *)) +AGL_API(void, GetMapControlPointsNV, (GLenum, GLuint, GLenum, GLsizei, GLsizei, GLboolean, GLvoid *)) +AGL_API(void, GetMapParameterivNV, (GLenum, GLenum, GLint *)) +AGL_API(void, GetMapParameterfvNV, (GLenum, GLenum, GLfloat *)) +AGL_API(void, GetMapAttribParameterivNV, (GLenum, GLuint, GLenum, GLint *)) +AGL_API(void, GetMapAttribParameterfvNV, (GLenum, GLuint, GLenum, GLfloat *)) +AGL_API(void, EvalMapsNV, (GLenum, GLenum)) +#endif + +#if defined _ALLEGRO_GL_NV_register_combiners2 +AGL_API(void, CombinerStageParameterfvNV, (GLenum, GLenum, const GLfloat *)) +AGL_API(void, GetCombinerStageParameterfvNV, (GLenum, GLenum, GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_NV_vertex_program +AGL_API(GLboolean, AreProgramsResidentNV, (GLsizei, const GLuint *, GLboolean *)) +AGL_API(void, BindProgramNV, (GLenum, GLuint)) +AGL_API(void, DeleteProgramsNV, (GLsizei, const GLuint *)) +AGL_API(void, ExecuteProgramNV, (GLenum, GLuint, const GLfloat *)) +AGL_API(void, GenProgramsNV, (GLsizei, GLuint *)) +AGL_API(void, GetProgramParameterdvNV, (GLenum, GLuint, GLenum, GLdouble *)) +AGL_API(void, GetProgramParameterfvNV, (GLenum, GLuint, GLenum, GLfloat *)) +AGL_API(void, GetProgramivNV, (GLuint, GLenum, GLint *)) +AGL_API(void, GetProgramStringNV, (GLuint, GLenum, GLubyte *)) +AGL_API(void, GetTrackMatrixivNV, (GLenum, GLuint, GLenum, GLint *)) +AGL_API(void, GetVertexAttribdvNV, (GLuint, GLenum, GLdouble *)) +AGL_API(void, GetVertexAttribfvNV, (GLuint, GLenum, GLfloat *)) +AGL_API(void, GetVertexAttribivNV, (GLuint, GLenum, GLint *)) +AGL_API(void, GetVertexAttribPointervNV, (GLuint, GLenum, GLvoid* *)) +AGL_API(GLboolean, IsProgramNV, (GLuint)) +AGL_API(void, LoadProgramNV, (GLenum, GLuint, GLsizei, const GLubyte *)) +AGL_API(void, ProgramParameter4dNV, (GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble)) +AGL_API(void, ProgramParameter4dvNV, (GLenum, GLuint, const GLdouble *)) +AGL_API(void, ProgramParameter4fNV, (GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, ProgramParameter4fvNV, (GLenum, GLuint, const GLfloat *)) +AGL_API(void, ProgramParameters4dvNV, (GLenum, GLuint, GLuint, const GLdouble *)) +AGL_API(void, ProgramParameters4fvNV, (GLenum, GLuint, GLuint, const GLfloat *)) +AGL_API(void, RequestResidentProgramsNV, (GLsizei, const GLuint *)) +AGL_API(void, TrackMatrixNV, (GLenum, GLuint, GLenum, GLenum)) +AGL_API(void, VertexAttribPointerNV, (GLuint, GLint, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, VertexAttrib1dNV, (GLuint, GLdouble)) +AGL_API(void, VertexAttrib1dvNV, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib1fNV, (GLuint, GLfloat)) +AGL_API(void, VertexAttrib1fvNV, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib1sNV, (GLuint, GLshort)) +AGL_API(void, VertexAttrib1svNV, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib2dNV, (GLuint, GLdouble, GLdouble)) +AGL_API(void, VertexAttrib2dvNV, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib2fNV, (GLuint, GLfloat, GLfloat)) +AGL_API(void, VertexAttrib2fvNV, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib2sNV, (GLuint, GLshort, GLshort)) +AGL_API(void, VertexAttrib2svNV, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib3dNV, (GLuint, GLdouble, GLdouble, GLdouble)) +AGL_API(void, VertexAttrib3dvNV, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib3fNV, (GLuint, GLfloat, GLfloat, GLfloat)) +AGL_API(void, VertexAttrib3fvNV, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib3sNV, (GLuint, GLshort, GLshort, GLshort)) +AGL_API(void, VertexAttrib3svNV, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib4dNV, (GLuint, GLdouble, GLdouble, GLdouble, GLdouble)) +AGL_API(void, VertexAttrib4dvNV, (GLuint, const GLdouble *)) +AGL_API(void, VertexAttrib4fNV, (GLuint, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, VertexAttrib4fvNV, (GLuint, const GLfloat *)) +AGL_API(void, VertexAttrib4sNV, (GLuint, GLshort, GLshort, GLshort, GLshort)) +AGL_API(void, VertexAttrib4svNV, (GLuint, const GLshort *)) +AGL_API(void, VertexAttrib4ubNV, (GLuint, GLubyte, GLubyte, GLubyte, GLubyte)) +AGL_API(void, VertexAttrib4ubvNV, (GLuint, const GLubyte *)) +AGL_API(void, VertexAttribs1dvNV, (GLuint, GLsizei, const GLdouble *)) +AGL_API(void, VertexAttribs1fvNV, (GLuint, GLsizei, const GLfloat *)) +AGL_API(void, VertexAttribs1svNV, (GLuint, GLsizei, const GLshort *)) +AGL_API(void, VertexAttribs2dvNV, (GLuint, GLsizei, const GLdouble *)) +AGL_API(void, VertexAttribs2fvNV, (GLuint, GLsizei, const GLfloat *)) +AGL_API(void, VertexAttribs2svNV, (GLuint, GLsizei, const GLshort *)) +AGL_API(void, VertexAttribs3dvNV, (GLuint, GLsizei, const GLdouble *)) +AGL_API(void, VertexAttribs3fvNV, (GLuint, GLsizei, const GLfloat *)) +AGL_API(void, VertexAttribs3svNV, (GLuint, GLsizei, const GLshort *)) +AGL_API(void, VertexAttribs4dvNV, (GLuint, GLsizei, const GLdouble *)) +AGL_API(void, VertexAttribs4fvNV, (GLuint, GLsizei, const GLfloat *)) +AGL_API(void, VertexAttribs4svNV, (GLuint, GLsizei, const GLshort *)) +AGL_API(void, VertexAttribs4ubvNV, (GLuint, GLsizei, const GLubyte *)) +#endif + +#if defined _ALLEGRO_GL_ATI_envmap_bumpmap +AGL_API(void, TexBumpParameterivATI, (GLenum, const GLint *)) +AGL_API(void, TexBumpParameterfvATI, (GLenum, const GLfloat *)) +AGL_API(void, GetTexBumpParameterivATI, (GLenum, GLint *)) +AGL_API(void, GetTexBumpParameterfvATI, (GLenum, GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_ATI_fragment_shader +AGL_API(GLuint, GenFragmentShadersATI, (GLuint)) +AGL_API(void, BindFragmentShaderATI, (GLuint)) +AGL_API(void, DeleteFragmentShaderATI, (GLuint)) +AGL_API(void, BeginFragmentShaderATI, (void)) +AGL_API(void, EndFragmentShaderATI, (void)) +AGL_API(void, PassTexCoordATI, (GLuint, GLuint, GLenum)) +AGL_API(void, SampleMapATI, (GLuint, GLuint, GLenum)) +AGL_API(void, ColorFragmentOp1ATI, (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, ColorFragmentOp2ATI, (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, ColorFragmentOp3ATI, (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, AlphaFragmentOp1ATI, (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, AlphaFragmentOp2ATI, (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, AlphaFragmentOp3ATI, (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, SetFragmentShaderConstantATI, (GLuint, const GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_ATI_pn_triangles +AGL_API(void, PNTrianglesiATI, (GLenum, GLint)) +AGL_API(void, PNTrianglesfATI, (GLenum, GLfloat)) +#endif + +#if defined _ALLEGRO_GL_ATI_vertex_array_object +AGL_API(GLuint, NewObjectBufferATI, (GLsizei, const GLvoid *, GLenum)) +AGL_API(GLboolean, IsObjectBufferATI, (GLuint)) +AGL_API(void, UpdateObjectBufferATI, (GLuint, GLuint, GLsizei, const GLvoid *, GLenum)) +AGL_API(void, GetObjectBufferfvATI, (GLuint, GLenum, GLfloat *)) +AGL_API(void, GetObjectBufferivATI, (GLuint, GLenum, GLint *)) +AGL_API(void, FreeObjectBufferATI, (GLuint)) +AGL_API(void, ArrayObjectATI, (GLenum, GLint, GLenum, GLsizei, GLuint, GLuint)) +AGL_API(void, GetArrayObjectfvATI, (GLenum, GLenum, GLfloat *)) +AGL_API(void, GetArrayObjectivATI, (GLenum, GLenum, GLint *)) +AGL_API(void, VariantArrayObjectATI, (GLuint, GLenum, GLsizei, GLuint, GLuint)) +AGL_API(void, GetVariantArrayObjectfvATI, (GLuint, GLenum, GLfloat *)) +AGL_API(void, GetVariantArrayObjectivATI, (GLuint, GLenum, GLint *)) +#endif + +#if defined _ALLEGRO_GL_EXT_vertex_shader +AGL_API(void, BeginVertexShaderEXT, (void)) +AGL_API(void, EndVertexShaderEXT, (void)) +AGL_API(void, BindVertexShaderEXT, (GLuint)) +AGL_API(GLuint, GenVertexShadersEXT, (GLuint)) +AGL_API(void, DeleteVertexShaderEXT, (GLuint)) +AGL_API(void, ShaderOp1EXT, (GLenum, GLuint, GLuint)) +AGL_API(void, ShaderOp2EXT, (GLenum, GLuint, GLuint, GLuint)) +AGL_API(void, ShaderOp3EXT, (GLenum, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, SwizzleEXT, (GLuint, GLuint, GLenum, GLenum, GLenum, GLenum)) +AGL_API(void, WriteMaskEXT, (GLuint, GLuint, GLenum, GLenum, GLenum, GLenum)) +AGL_API(void, InsertComponentEXT, (GLuint, GLuint, GLuint)) +AGL_API(void, ExtractComponentEXT, (GLuint, GLuint, GLuint)) +AGL_API(GLuint, GenSymbolsEXT, (GLenum, GLenum, GLenum, GLuint)) +AGL_API(void, SetInvariantEXT, (GLuint, GLenum, const GLvoid *)) +AGL_API(void, SetLocalConstantEXT, (GLuint, GLenum, const GLvoid *)) +AGL_API(void, VariantbvEXT, (GLuint, const GLbyte *)) +AGL_API(void, VariantsvEXT, (GLuint, const GLshort *)) +AGL_API(void, VariantivEXT, (GLuint, const GLint *)) +AGL_API(void, VariantfvEXT, (GLuint, const GLfloat *)) +AGL_API(void, VariantdvEXT, (GLuint, const GLdouble *)) +AGL_API(void, VariantubvEXT, (GLuint, const GLubyte *)) +AGL_API(void, VariantusvEXT, (GLuint, const GLushort *)) +AGL_API(void, VariantuivEXT, (GLuint, const GLuint *)) +AGL_API(void, VariantPointerEXT, (GLuint, GLenum, GLuint, const GLvoid *)) +AGL_API(void, EnableVariantClientStateEXT, (GLuint)) +AGL_API(void, DisableVariantClientStateEXT, (GLuint)) +AGL_API(GLuint, BindLightParameterEXT, (GLenum, GLenum)) +AGL_API(GLuint, BindMaterialParameterEXT, (GLenum, GLenum)) +AGL_API(GLuint, BindTexGenParameterEXT, (GLenum, GLenum, GLenum)) +AGL_API(GLuint, BindTextureUnitParameterEXT, (GLenum, GLenum)) +AGL_API(GLuint, BindParameterEXT, (GLenum)) +AGL_API(GLboolean, IsVariantEnabledEXT, (GLuint, GLenum)) +AGL_API(void, GetVariantBooleanvEXT, (GLuint, GLenum, GLboolean *)) +AGL_API(void, GetVariantIntegervEXT, (GLuint, GLenum, GLint *)) +AGL_API(void, GetVariantFloatvEXT, (GLuint, GLenum, GLfloat *)) +AGL_API(void, GetVariantPointervEXT, (GLuint, GLenum, GLvoid* *)) +AGL_API(void, GetInvariantBooleanvEXT, (GLuint, GLenum, GLboolean *)) +AGL_API(void, GetInvariantIntegervEXT, (GLuint, GLenum, GLint *)) +AGL_API(void, GetInvariantFloatvEXT, (GLuint, GLenum, GLfloat *)) +AGL_API(void, GetLocalConstantBooleanvEXT, (GLuint, GLenum, GLboolean *)) +AGL_API(void, GetLocalConstantIntegervEXT, (GLuint, GLenum, GLint *)) +AGL_API(void, GetLocalConstantFloatvEXT, (GLuint, GLenum, GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_ATI_vertex_streams +AGL_API(void, VertexStream1sATI, (GLenum, GLshort)) +AGL_API(void, VertexStream1svATI, (GLenum, const GLshort *)) +AGL_API(void, VertexStream1iATI, (GLenum, GLint)) +AGL_API(void, VertexStream1ivATI, (GLenum, const GLint *)) +AGL_API(void, VertexStream1fATI, (GLenum, GLfloat)) +AGL_API(void, VertexStream1fvATI, (GLenum, const GLfloat *)) +AGL_API(void, VertexStream1dATI, (GLenum, GLdouble)) +AGL_API(void, VertexStream1dvATI, (GLenum, const GLdouble *)) +AGL_API(void, VertexStream2sATI, (GLenum, GLshort, GLshort)) +AGL_API(void, VertexStream2svATI, (GLenum, const GLshort *)) +AGL_API(void, VertexStream2iATI, (GLenum, GLint, GLint)) +AGL_API(void, VertexStream2ivATI, (GLenum, const GLint *)) +AGL_API(void, VertexStream2fATI, (GLenum, GLfloat, GLfloat)) +AGL_API(void, VertexStream2fvATI, (GLenum, const GLfloat *)) +AGL_API(void, VertexStream2dATI, (GLenum, GLdouble, GLdouble)) +AGL_API(void, VertexStream2dvATI, (GLenum, const GLdouble *)) +AGL_API(void, VertexStream3sATI, (GLenum, GLshort, GLshort, GLshort)) +AGL_API(void, VertexStream3svATI, (GLenum, const GLshort *)) +AGL_API(void, VertexStream3iATI, (GLenum, GLint, GLint, GLint)) +AGL_API(void, VertexStream3ivATI, (GLenum, const GLint *)) +AGL_API(void, VertexStream3fATI, (GLenum, GLfloat, GLfloat, GLfloat)) +AGL_API(void, VertexStream3fvATI, (GLenum, const GLfloat *)) +AGL_API(void, VertexStream3dATI, (GLenum, GLdouble, GLdouble, GLdouble)) +AGL_API(void, VertexStream3dvATI, (GLenum, const GLdouble *)) +AGL_API(void, VertexStream4sATI, (GLenum, GLshort, GLshort, GLshort, GLshort)) +AGL_API(void, VertexStream4svATI, (GLenum, const GLshort *)) +AGL_API(void, VertexStream4iATI, (GLenum, GLint, GLint, GLint, GLint)) +AGL_API(void, VertexStream4ivATI, (GLenum, const GLint *)) +AGL_API(void, VertexStream4fATI, (GLenum, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, VertexStream4fvATI, (GLenum, const GLfloat *)) +AGL_API(void, VertexStream4dATI, (GLenum, GLdouble, GLdouble, GLdouble, GLdouble)) +AGL_API(void, VertexStream4dvATI, (GLenum, const GLdouble *)) +AGL_API(void, NormalStream3bATI, (GLenum, GLbyte, GLbyte, GLbyte)) +AGL_API(void, NormalStream3bvATI, (GLenum, const GLbyte *)) +AGL_API(void, NormalStream3sATI, (GLenum, GLshort, GLshort, GLshort)) +AGL_API(void, NormalStream3svATI, (GLenum, const GLshort *)) +AGL_API(void, NormalStream3iATI, (GLenum, GLint, GLint, GLint)) +AGL_API(void, NormalStream3ivATI, (GLenum, const GLint *)) +AGL_API(void, NormalStream3fATI, (GLenum, GLfloat, GLfloat, GLfloat)) +AGL_API(void, NormalStream3fvATI, (GLenum, const GLfloat *)) +AGL_API(void, NormalStream3dATI, (GLenum, GLdouble, GLdouble, GLdouble)) +AGL_API(void, NormalStream3dvATI, (GLenum, const GLdouble *)) +AGL_API(void, ClientActiveVertexStreamATI, (GLenum)) +AGL_API(void, VertexBlendEnviATI, (GLenum, GLint)) +AGL_API(void, VertexBlendEnvfATI, (GLenum, GLfloat)) +#endif + +#if defined _ALLEGRO_GL_ATI_element_array +AGL_API(void, ElementPointerATI, (GLenum, const GLvoid *)) +AGL_API(void, DrawElementArrayATI, (GLenum, GLsizei)) +AGL_API(void, DrawRangeElementArrayATI, (GLenum, GLuint, GLuint, GLsizei)) +#endif + +#if defined _ALLEGRO_GL_SUN_mesh_array +AGL_API(void, DrawMeshArraysSUN, (GLenum, GLint, GLsizei, GLsizei)) +#endif + +#if defined _ALLEGRO_GL_NV_occlusion_query +AGL_API(void, GenOcclusionQueriesNV, (GLsizei, GLuint *)) +AGL_API(void, DeleteOcclusionQueriesNV, (GLsizei, const GLuint *)) +AGL_API(GLboolean, IsOcclusionQueryNV, (GLuint)) +AGL_API(void, BeginOcclusionQueryNV, (GLuint)) +AGL_API(void, EndOcclusionQueryNV, (void)) +AGL_API(void, GetOcclusionQueryivNV, (GLuint, GLenum, GLint *)) +AGL_API(void, GetOcclusionQueryuivNV, (GLuint, GLenum, GLuint *)) +#endif + +#if defined _ALLEGRO_GL_NV_point_sprite +AGL_API(void, PointParameteriNV, (GLenum, GLint)) +AGL_API(void, PointParameterivNV, (GLenum, const GLint *)) +#endif + +#if defined _ALLEGRO_GL_EXT_stencil_two_side +AGL_API(void, ActiveStencilFaceEXT, (GLenum)) +#endif + +#if defined _ALLEGRO_GL_APPLE_element_array +AGL_API(void, ElementPointerAPPLE, (GLenum, const GLvoid *)) +AGL_API(void, DrawElementArrayAPPLE, (GLenum, GLint, GLsizei)) +AGL_API(void, DrawRangeElementArrayAPPLE, (GLenum, GLuint, GLuint, GLint, GLsizei)) +AGL_API(void, MultiDrawElementArrayAPPLE, (GLenum, const GLint *, const GLsizei *, GLsizei)) +AGL_API(void, MultiDrawRangeElementArrayAPPLE, (GLenum, GLuint, GLuint, const GLint *, const GLsizei *, GLsizei)) +#endif + +#if defined _ALLEGRO_GL_APPLE_fence +AGL_API(void, GenFencesAPPLE, (GLsizei, GLuint *)) +AGL_API(void, DeleteFencesAPPLE, (GLsizei, const GLuint *)) +AGL_API(void, SetFenceAPPLE, (GLuint)) +AGL_API(GLboolean, IsFenceAPPLE, (GLuint)) +AGL_API(GLboolean, TestFenceAPPLE, (GLuint)) +AGL_API(void, FinishFenceAPPLE, (GLuint)) +AGL_API(GLboolean, TestObjectAPPLE, (GLenum, GLuint)) +AGL_API(void, FinishObjectAPPLE, (GLenum, GLint)) +#endif + +#if defined _ALLEGRO_GL_APPLE_vertex_array_object +AGL_API(void, BindVertexArrayAPPLE, (GLuint)) +AGL_API(void, DeleteVertexArraysAPPLE, (GLsizei, const GLuint *)) +AGL_API(void, GenVertexArraysAPPLE, (GLsizei, const GLuint *)) +AGL_API(GLboolean, IsVertexArrayAPPLE, (GLuint)) +#endif + +#if defined _ALLEGRO_GL_APPLE_vertex_array_range +AGL_API(void, VertexArrayRangeAPPLE, (GLsizei, GLvoid *)) +AGL_API(void, FlushVertexArrayRangeAPPLE, (GLsizei, GLvoid *)) +AGL_API(void, VertexArrayParameteriAPPLE, (GLenum, GLint)) +#endif + +#if defined _ALLEGRO_GL_ATI_draw_buffers +AGL_API(void, DrawBuffersATI, (GLsizei, const GLenum *)) +#endif + +#if defined _ALLEGRO_GL_NV_fragment_program +AGL_API(void, ProgramNamedParameter4fNV, (GLuint, GLsizei, const GLubyte *, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, ProgramNamedParameter4dNV, (GLuint, GLsizei, const GLubyte *, GLdouble, GLdouble, GLdouble, GLdouble)) +AGL_API(void, ProgramNamedParameter4fvNV, (GLuint, GLsizei, const GLubyte *, const GLfloat *)) +AGL_API(void, ProgramNamedParameter4dvNV, (GLuint, GLsizei, const GLubyte *, const GLdouble *)) +AGL_API(void, GetProgramNamedParameterfvNV, (GLuint, GLsizei, const GLubyte *, GLfloat *)) +AGL_API(void, GetProgramNamedParameterdvNV, (GLuint, GLsizei, const GLubyte *, GLdouble *)) +#endif + +#if defined _ALLEGRO_GL_NV_half_float +AGL_API(void, Vertex2hNV, (GLhalfNV, GLhalfNV)) +AGL_API(void, Vertex2hvNV, (const GLhalfNV *)) +AGL_API(void, Vertex3hNV, (GLhalfNV, GLhalfNV, GLhalfNV)) +AGL_API(void, Vertex3hvNV, (const GLhalfNV *)) +AGL_API(void, Vertex4hNV, (GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV)) +AGL_API(void, Vertex4hvNV, (const GLhalfNV *)) +AGL_API(void, Normal3hNV, (GLhalfNV, GLhalfNV, GLhalfNV)) +AGL_API(void, Normal3hvNV, (const GLhalfNV *)) +AGL_API(void, Color3hNV, (GLhalfNV, GLhalfNV, GLhalfNV)) +AGL_API(void, Color3hvNV, (const GLhalfNV *)) +AGL_API(void, Color4hNV, (GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV)) +AGL_API(void, Color4hvNV, (const GLhalfNV *)) +AGL_API(void, TexCoord1hNV, (GLhalfNV)) +AGL_API(void, TexCoord1hvNV, (const GLhalfNV *)) +AGL_API(void, TexCoord2hNV, (GLhalfNV, GLhalfNV)) +AGL_API(void, TexCoord2hvNV, (const GLhalfNV *)) +AGL_API(void, TexCoord3hNV, (GLhalfNV, GLhalfNV, GLhalfNV)) +AGL_API(void, TexCoord3hvNV, (const GLhalfNV *)) +AGL_API(void, TexCoord4hNV, (GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV)) +AGL_API(void, TexCoord4hvNV, (const GLhalfNV *)) +AGL_API(void, MultiTexCoord1hNV, (GLenum, GLhalfNV)) +AGL_API(void, MultiTexCoord1hvNV, (GLenum, const GLhalfNV *)) +AGL_API(void, MultiTexCoord2hNV, (GLenum, GLhalfNV, GLhalfNV)) +AGL_API(void, MultiTexCoord2hvNV, (GLenum, const GLhalfNV *)) +AGL_API(void, MultiTexCoord3hNV, (GLenum, GLhalfNV, GLhalfNV, GLhalfNV)) +AGL_API(void, MultiTexCoord3hvNV, (GLenum, const GLhalfNV *)) +AGL_API(void, MultiTexCoord4hNV, (GLenum, GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV)) +AGL_API(void, MultiTexCoord4hvNV, (GLenum, const GLhalfNV *)) +AGL_API(void, FogCoordhNV, (GLhalfNV)) +AGL_API(void, FogCoordhvNV, (const GLhalfNV *)) +AGL_API(void, SecondaryColor3hNV, (GLhalfNV, GLhalfNV, GLhalfNV)) +AGL_API(void, SecondaryColor3hvNV, (const GLhalfNV *)) +AGL_API(void, VertexWeighthNV, (GLhalfNV)) +AGL_API(void, VertexWeighthvNV, (const GLhalfNV *)) +AGL_API(void, VertexAttrib1hNV, (GLuint, GLhalfNV)) +AGL_API(void, VertexAttrib1hvNV, (GLuint, const GLhalfNV *)) +AGL_API(void, VertexAttrib2hNV, (GLuint, GLhalfNV, GLhalfNV)) +AGL_API(void, VertexAttrib2hvNV, (GLuint, const GLhalfNV *)) +AGL_API(void, VertexAttrib3hNV, (GLuint, GLhalfNV, GLhalfNV, GLhalfNV)) +AGL_API(void, VertexAttrib3hvNV, (GLuint, const GLhalfNV *)) +AGL_API(void, VertexAttrib4hNV, (GLuint, GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV)) +AGL_API(void, VertexAttrib4hvNV, (GLuint, const GLhalfNV *)) +AGL_API(void, VertexAttribs1hvNV, (GLuint, GLsizei, const GLhalfNV *)) +AGL_API(void, VertexAttribs2hvNV, (GLuint, GLsizei, const GLhalfNV *)) +AGL_API(void, VertexAttribs3hvNV, (GLuint, GLsizei, const GLhalfNV *)) +AGL_API(void, VertexAttribs4hvNV, (GLuint, GLsizei, const GLhalfNV *)) +#endif + +#if defined _ALLEGRO_GL_NV_pixel_data_range +AGL_API(void, PixelDataRangeNV, (GLenum, GLsizei, GLvoid *)) +AGL_API(void, FlushPixelDataRangeNV, (GLenum)) +#endif + +#if defined _ALLEGRO_GL_NV_primitive_restart +AGL_API(void, PrimitiveRestartNV, (void)) +AGL_API(void, PrimitiveRestartIndexNV, (GLuint)) +#endif + +#if defined _ALLEGRO_GL_ATI_map_object_buffer +AGL_API(GLvoid*, MapObjectBufferATI, (GLuint)) +AGL_API(void, UnmapObjectBufferATI, (GLuint)) +#endif + +#if defined _ALLEGRO_GL_ATI_separate_stencil +AGL_API(void, StencilOpSeparateATI, (GLenum, GLenum, GLenum, GLenum)) +AGL_API(void, StencilFuncSeparateATI, (GLenum, GLenum, GLint, GLuint)) +#endif + +#if defined _ALLEGRO_GL_ATI_vertex_attrib_array_object +AGL_API(void, VertexAttribArrayObjectATI, (GLuint, GLint, GLenum, GLboolean, GLsizei, GLuint, GLuint)) +AGL_API(void, GetVertexAttribArrayObjectfvATI, (GLuint, GLenum, GLfloat *)) +AGL_API(void, GetVertexAttribArrayObjectivATI, (GLuint, GLenum, GLint *)) +#endif + +#if defined _ALLEGRO_GL_OES_byte_coordinates +AGL_API(void, Vertex2bOES, ( GLbyte, GLbyte )) +AGL_API(void, Vertex3bOES, ( GLbyte, GLbyte, GLbyte )) +AGL_API(void, Vertex4bOES, ( GLbyte, GLbyte, GLbyte, GLbyte )) +AGL_API(void, Vertex2bvOES, ( const GLbyte * )) +AGL_API(void, Vertex3bvOES, ( const GLbyte * )) +AGL_API(void, Vertex4bvOES, ( const GLbyte * )) +AGL_API(void, TexCoord1bOES, ( GLbyte )) +AGL_API(void, TexCoord2bOES, ( GLbyte, GLbyte )) +AGL_API(void, TexCoord3bOES, ( GLbyte, GLbyte, GLbyte )) +AGL_API(void, TexCoord4bOES, ( GLbyte, GLbyte, GLbyte, GLbyte )) +AGL_API(void, TexCoord1bvOES, ( const GLbyte * )) +AGL_API(void, TexCoord2bvOES, ( const GLbyte * )) +AGL_API(void, TexCoord3bvOES, ( const GLbyte * )) +AGL_API(void, TexCoord4bvOES, ( const GLbyte * )) +AGL_API(void, MultiTexCoord1bOES, ( GLenum, GLbyte )) +AGL_API(void, MultiTexCoord2bOES, ( GLenum, GLbyte, GLbyte )) +AGL_API(void, MultiTexCoord3bOES, ( GLenum, GLbyte, GLbyte, GLbyte )) +AGL_API(void, MultiTexCoord4bOES, ( GLenum, GLbyte, GLbyte, GLbyte, GLbyte )) +AGL_API(void, MultiTexCoord1bvOES, ( GLenum texture, const GLbyte * )) +AGL_API(void, MultiTexCoord2bvOES, ( GLenum texture, const GLbyte * )) +AGL_API(void, MultiTexCoord3bvOES, ( GLenum texture, const GLbyte * )) +AGL_API(void, MultiTexCoord4bvOES, ( GLenum texture, const GLbyte * )) +#endif + +#if defined _ALLEGRO_GL_OES_fixed_point +AGL_API(void, Vertex2xOES, (GLfixed, GLfixed)) +AGL_API(void, Vertex3xOES, (GLfixed, GLfixed, GLfixed)) +AGL_API(void, Vertex4xOES, (GLfixed, GLfixed, GLfixed, GLfixed)) +AGL_API(void, Vertex2xvOES, (const GLfixed *)) +AGL_API(void, Vertex3xvOES, (const GLfixed *)) +AGL_API(void, Vertex4xvOES, (const GLfixed *)) +AGL_API(void, Normal3xOES, (GLfixed, GLfixed, GLfixed)) +AGL_API(void, Normal3xvOES, (const GLfixed *)) +AGL_API(void, TexCoord1xOES, (GLfixed)) +AGL_API(void, TexCoord2xOES, (GLfixed, GLfixed)) +AGL_API(void, TexCoord3xOES, (GLfixed, GLfixed, GLfixed)) +AGL_API(void, TexCoord4xOES, (GLfixed, GLfixed, GLfixed, GLfixed)) +AGL_API(void, TexCoord1xvOES, (const GLfixed *)) +AGL_API(void, TexCoord2xvOES, (const GLfixed *)) +AGL_API(void, TexCoord3xvOES, (const GLfixed *)) +AGL_API(void, TexCoord4xvOES, (const GLfixed *)) +AGL_API(void, MultiTexCoord1xOES, (GLenum, GLfixed)) +AGL_API(void, MultiTexCoord2xOES, (GLenum, GLfixed, GLfixed)) +AGL_API(void, MultiTexCoord3xOES, (GLenum, GLfixed, GLfixed, GLfixed)) +AGL_API(void, MultiTexCoord4xOES, (GLenum, GLfixed, GLfixed, GLfixed, GLfixed)) +AGL_API(void, MultiTexCoord1xvOES, (GLenum, const GLfixed *)) +AGL_API(void, MultiTexCoord2xvOES, (GLenum, const GLfixed *)) +AGL_API(void, MultiTexCoord3xvOES, (GLenum, const GLfixed *)) +AGL_API(void, MultiTexCoord4xvOES, (GLenum, const GLfixed *)) +AGL_API(void, Color3xOES, (GLfixed, GLfixed, GLfixed)) +AGL_API(void, Color4xOES, (GLfixed, GLfixed, GLfixed, GLfixed)) +AGL_API(void, Color3xvOES, (const GLfixed *)) +AGL_API(void, Color4xvOES, (const GLfixed *)) +AGL_API(void, IndexxOES, (GLfixed)) +AGL_API(void, IndexxvOES, (const GLfixed *)) +AGL_API(void, RectxOES, (GLfixed, GLfixed, GLfixed, GLfixed)) +AGL_API(void, RectxvOES, (const GLfixed [2], const GLfixed [2])) +AGL_API(void, DepthRangexOES, (GLclampx, GLclampx)) +AGL_API(void, LoadMatrixxOES, (const GLfixed [16])) +AGL_API(void, MultMatrixxOES, (const GLfixed [16])) +AGL_API(void, LoadTransposeMatrixxOES, (const GLfixed [16])) +AGL_API(void, MultTransposeMatrixxOES, (const GLfixed [16])) +AGL_API(void, RotatexOES, (GLfixed, GLfixed, GLfixed, GLfixed)) +AGL_API(void, ScalexOES, (GLfixed, GLfixed, GLfixed)) +AGL_API(void, TranslatexOES, (GLfixed, GLfixed, GLfixed)) +AGL_API(void, FrustumxOES, (GLfixed, GLfixed, GLfixed, GLfixed, GLfixed, GLfixed)) +AGL_API(void, OrthoxOES, (GLfixed, GLfixed, GLfixed, GLfixed, GLfixed, GLfixed)) +AGL_API(void, TexGenxOES, (GLenum, GLenum, GLfixed)) +AGL_API(void, TexGenxvOES, (GLenum, GLenum, const GLfixed *)) +AGL_API(void, GetTexGenxvOES, (GLenum, GLenum, GLfixed *)) +AGL_API(void, ClipPlanexOES, (GLenum, const GLfixed *)) +AGL_API(void, GetClipPlanexOES, (GLenum, GLfixed *)) +AGL_API(void, RasterPos2xOES, (GLfixed, GLfixed)) +AGL_API(void, RasterPos3xOES, (GLfixed, GLfixed, GLfixed)) +AGL_API(void, RasterPos4xOES, (GLfixed, GLfixed, GLfixed, GLfixed)) +AGL_API(void, RasterPos2xvOES, (const GLfixed *)) +AGL_API(void, RasterPos3xvOES, (const GLfixed *)) +AGL_API(void, RasterPos4xvOES, (const GLfixed *)) +AGL_API(void, MaterialxOES, (GLenum, GLenum, GLfixed)) +AGL_API(void, MaterialxvOES, (GLenum, GLenum, const GLfixed *)) +AGL_API(void, GetMaterialxOES, (GLenum, GLenum, GLfixed *)) +AGL_API(void, LightxOES, (GLenum, GLenum, GLfixed)) +AGL_API(void, LightxvOES, (GLenum, GLenum, const GLfixed *)) +AGL_API(void, GetLightxOES, (GLenum, GLenum, const GLfixed *)) +AGL_API(void, LightModelxOES, (GLenum, GLfixed)) +AGL_API(void, LightModelxvOES, (GLenum, const GLfixed *)) +AGL_API(void, PointSizexOES, (GLfixed size)) +AGL_API(void, LineWidthxOES, (GLfixed width)) +AGL_API(void, PolygonOffsetxOES, (GLfixed factor, GLfixed units)) +AGL_API(void, PixelStorex, (GLenum pname, GLfixed param)) +AGL_API(void, PixelTransferxOES, (GLenum pname, GLfixed param)) +AGL_API(void, PixelMapx, (GLenum, GLint, const GLfixed *)) +AGL_API(void, GetPixelMapxv, (GLenum, GLint, GLfixed *)) +AGL_API(void, ConvolutionParameterxOES, (GLenum, GLenum, GLfixed)) +AGL_API(void, ConvolutionParameterxvOES, (GLenum, GLenum, const GLfixed *)) +AGL_API(void, GetConvolutionParameterxvOES, (GLenum, GLenum, GLfixed *)) +AGL_API(void, GetHistogramParameterxvOES, (GLenum, GLenum, GLfixed *)) +AGL_API(void, PixelZoomxOES, (GLfixed, GLfixed)) +AGL_API(void, BitmapxOES, (GLsizei, GLsizei, GLfixed, GLfixed, GLfixed, GLfixed, const GLubyte *)) +AGL_API(void, TexParameterxOES, (GLenum, GLenum, GLfixed)) +AGL_API(void, TexParameterxvOES, (GLenum, GLenum, const GLfixed *)) +AGL_API(void, GetTexParameterxvOES, (GLenum, GLenum, GLfixed *)) +AGL_API(void, GetTexLevelParameterxvOES, (GLenum, GLint, GLenum, GLfixed *)) +AGL_API(void, PrioritizeTexturesxOES, (GLsizei, GLuint *, GLclampx *)) +AGL_API(void, TexEnvxOES, (GLenum, GLenum, GLfixed)) +AGL_API(void, TexEnvxvOES, (GLenum, GLenum, const GLfixed *)) +AGL_API(void, GetTexEnvxvOES, (GLenum, GLenum, GLfixed *)) +AGL_API(void, FogxOES, (GLenum, GLfixed)) +AGL_API(void, FogxvOES, (GLenum, const GLfixed *)) +AGL_API(void, SampleCoverageOES, (GLclampx, GLboolean)) +AGL_API(void, AlphaFuncxOES, (GLenum, GLclampx)) +AGL_API(void, BlendColorxOES, (GLclampx, GLclampx, GLclampx, GLclampx)) +AGL_API(void, ClearColorxOES, (GLclampx, GLclampx, GLclampx, GLclampx)) +AGL_API(void, ClearDepthxOES, (GLclampx)) +AGL_API(void, ClearAccumxOES, (GLclampx, GLclampx, GLclampx, GLclampx)) +AGL_API(void, AccumxOES, (GLenum, GLfixed)) +AGL_API(void, Map1xOES, (GLenum, GLfixed, GLfixed, GLint, GLint, const GLfixed *)) +AGL_API(void, Map2xOES, (GLenum, GLfixed, GLfixed, GLint, GLint, GLfixed, GLfixed, GLint, GLint, const GLfixed *)) +AGL_API(void, MapGrid1xOES, (GLint, GLfixed, GLfixed)) +AGL_API(void, MapGrid2xOES, (GLint, GLfixed, GLfixed, GLfixed, GLfixed)) +AGL_API(void, GetMapxvOES, (GLenum, GLenum, GLfixed *)) +AGL_API(void, EvalCoord1xOES, (GLfixed)) +AGL_API(void, EvalCoord2xOES, (GLfixed, GLfixed)) +AGL_API(void, EvalCoord1xvOES, (const GLfixed *)) +AGL_API(void, EvalCoord2xvOES, (const GLfixed *)) +AGL_API(void, FeedbackBufferxOES, (GLsizei, GLenum, GLfixed *)) +AGL_API(void, PassThroughxOES, (GLfixed)) +AGL_API(void, GetFixedvOES, (GLenum, GLfixed *)) +#endif + +#if defined _ALLEGRO_GL_OES_single_precision +AGL_API(void, DepthRangefOES, (GLclampf, GLclampf)) +AGL_API(void, FrustumfOES, (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, OrthofOES, (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, ClipPlanefOES, (GLenum, const GLfloat*)) +AGL_API(void, GetClipPlanefOES, (GLenum, GLfloat*)) +AGL_API(void, ClearDepthfOES, (GLclampd)) +#endif + +#if defined _ALLEGRO_GL_OES_query_matrix +AGL_API(GLbitfield, QueryMatrixxOES, (GLfixed [16], GLint [16] )) +#endif + +#if defined _ALLEGRO_GL_EXT_depth_bounds_test +AGL_API(void, DepthBoundsEXT, (GLclampd, GLclampd)) +#endif + + +#if defined _ALLEGRO_GL_EXT_blend_equation_separate +AGL_API(void, BlendEquationSeparateEXT, (GLenum, GLenum)) +#endif + + +#if defined _ALLEGRO_GL_EXT_framebuffer_object +AGL_API(GLboolean, IsRenderbufferEXT, (GLuint)) +AGL_API(void, BindRenderbufferEXT, (GLenum, GLuint)) +AGL_API(void, DeleteRenderbuffersEXT, (GLsizei, const GLuint *)) +AGL_API(void, GenRenderbuffersEXT, (GLsizei, GLuint *)) +AGL_API(void, RenderbufferStorageEXT, (GLenum, GLenum, GLsizei, GLsizei)) +AGL_API(void, GetRenderbufferParameterivEXT, (GLenum, GLenum, GLint*)) +AGL_API(GLboolean, IsFramebufferEXT, (GLuint)) +AGL_API(void, BindFramebufferEXT, (GLenum, GLuint)) +AGL_API(void, DeleteFramebuffersEXT, (GLsizei, const GLuint *)) +AGL_API(void, GenFramebuffersEXT, (GLsizei, GLuint *)) +AGL_API(GLenum, CheckFramebufferStatusEXT, (GLenum)) +AGL_API(void, FramebufferTexture1DEXT, (GLenum, GLenum, GLenum, GLuint, GLint)) +AGL_API(void, FramebufferTexture2DEXT, (GLenum, GLenum, GLenum, GLuint, GLint)) +AGL_API(void, FramebufferTexture3DEXT, (GLenum, GLenum, GLenum, GLuint, GLint, GLint)) +AGL_API(void, FramebufferRenderbufferEXT, (GLenum, GLenum, GLenum, GLuint)) +AGL_API(void, GetFramebufferAttachmentParameterivEXT, (GLenum, GLenum, GLenum, GLint *)) +AGL_API(void, GenerateMipmapEXT, (GLenum)) +#endif + +#if defined _ALLEGRO_GL_GREMEDY_string_marker +AGL_API(void, StringMarkerGREMEDY, (GLsizei, const GLvoid *)) +#endif + +#if defined _ALLEGRO_GL_EXT_stencil_clear_tag +AGL_API(void, StencilClearTagEXT, (GLsizei, GLuint)) +#endif + +#if defined _ALLEGRO_GL_EXT_framebuffer_blit +AGL_API(void, BlitFramebufferEXT, (GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLbitfield, GLenum)) +#endif + +#if defined _ALLEGRO_GL_EXT_framebuffer_multisample +AGL_API(void, RenderbufferStorageMultisampleEXT, (GLenum, GLsizei, GLenum, GLsizei, GLsizei)) +#endif + +#if defined _ALLEGRO_GL_EXT_timer_query +AGL_API(void, GetQueryObjecti64vEXT, (GLuint, GLenum, GLint64EXT *)) +AGL_API(void, GetQueryObjectui64vEXT, (GLuint, GLenum, GLuint64EXT *)) +#endif + +#if defined _ALLEGRO_GL_EXT_gpu_program_parameters +AGL_API(void, ProgramEnvParameters4fvEXT, (GLenum, GLuint, GLsizei, const GLfloat *)) +AGL_API(void, ProgramLocalParameters4fvEXT, (GLenum, GLuint, GLsizei, const GLfloat *)) +#endif + +#if defined _ALLEGRO_GL_APPLE_flush_buffer_range +AGL_API(void, BufferParameteriAPPLE, (GLenum, GLenum, GLint)) +AGL_API(void, FlushMappedBufferRangeAPPLE, (GLenum, GLintptr, GLsizeiptr)) +#endif + +#if defined _ALLEGRO_GL_EXT_bindable_uniform +AGL_API(void, UniformBufferEXT, (GLuint, GLint, GLuint)) +AGL_API(GLint, GetUniformBufferSizeEXT, (GLuint, GLint)) +AGL_API(GLintptr, GetUniformOffsetEXT, (GLuint program, GLint)) +#endif + +#if defined _ALLEGRO_GL_EXT_draw_buffers2 +AGL_API(void, ColorMaskIndexedEXT, (GLuint, GLboolean, GLboolean, GLboolean, GLboolean)) +AGL_API(void, GetBooleanIndexedvEXT, (GLenum, GLuint, GLboolean *)) +AGL_API(void, GetIntegerIndexedvEXT, (GLenum, GLuint, GLint *)) +AGL_API(void, EnableIndexedEXT, (GLenum, GLuint)) +AGL_API(void, DisableIndexedEXT, (GLenum, GLuint)) +AGL_API(GLboolean, IsEnabledIndexedEXT, (GLenum, GLuint)) +#endif + +#if defined _ALLEGRO_GL_EXT_draw_instanced +AGL_API(void, DrawArraysInstancedEXT, (GLenum, GLint, GLsizei, GLsizei)) +AGL_API(void, DrawElementsInstancedEXT, (GLenum, GLsizei, GLenum, const GLvoid *, GLsizei)) +#endif + +#if defined _ALLEGRO_GL_EXT_geometry_shader4 +AGL_API(void, ProgramParameteriEXT, (GLuint, GLenum, GLint)) +AGL_API(void, FramebufferTextureEXT, (GLenum, GLenum, GLuint, GLint)) +#if !defined _ALLEGRO_GL_EXT_texture_array +AGL_API(void, FramebufferTextureLayerEXT, (GLenum, GLenum, GLuint, GLint, GLint)) +#endif +AGL_API(void, FramebufferTextureFaceEXT, (GLenum, GLenum, GLuint, GLint, GLenum)) +#endif + +#if defined _ALLEGRO_GL_EXT_gpu_shader4 +AGL_API(void, VertexAttribI1iEXT, (GLuint, GLint)) +AGL_API(void, VertexAttribI2iEXT, (GLuint, GLint, GLint)) +AGL_API(void, VertexAttribI3iEXT, (GLuint, GLint, GLint, GLint)) +AGL_API(void, VertexAttribI4iEXT, (GLuint, GLint, GLint, GLint, GLint)) +AGL_API(void, VertexAttribI1uiEXT, (GLuint, GLuint)) +AGL_API(void, VertexAttribI2uiEXT, (GLuint, GLuint, GLuint)) +AGL_API(void, VertexAttribI3uiEXT, (GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, VertexAttribI4uiEXT, (GLuint, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, VertexAttribI1ivEXT, (GLuint, const GLint *)) +AGL_API(void, VertexAttribI2ivEXT, (GLuint, const GLint *)) +AGL_API(void, VertexAttribI3ivEXT, (GLuint, const GLint *)) +AGL_API(void, VertexAttribI4ivEXT, (GLuint, const GLint *)) +AGL_API(void, VertexAttribI1uivEXT, (GLuint, const GLuint *)) +AGL_API(void, VertexAttribI2uivEXT, (GLuint, const GLuint *)) +AGL_API(void, VertexAttribI3uivEXT, (GLuint, const GLuint *)) +AGL_API(void, VertexAttribI4uivEXT, (GLuint, const GLuint *)) +AGL_API(void, VertexAttribI4bvEXT, (GLuint, const GLbyte *)) +AGL_API(void, VertexAttribI4svEXT, (GLuint, const GLshort *)) +AGL_API(void, VertexAttribI4ubvEXT, (GLuint, const GLubyte *)) +AGL_API(void, VertexAttribI4usvEXT, (GLuint, const GLushort *)) +AGL_API(void, VertexAttribIPointerEXT, (GLuint, GLint, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, GetVertexAttribIivEXT, (GLuint, GLenum, GLint *)) +AGL_API(void, GetVertexAttribIuivEXT, (GLuint, GLenum, GLint *)) +AGL_API(void, Uniform1uiEXT, (GLint, GLuint)) +AGL_API(void, Uniform2uiEXT, (GLint, GLuint, GLuint)) +AGL_API(void, Uniform3uiEXT, (GLint, GLuint, GLuint, GLuint)) +AGL_API(void, Uniform4uiEXT, (GLint, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, Uniform1uivEXT, (GLint, GLsizei, const GLuint *)) +AGL_API(void, Uniform2uivEXT, (GLint, GLsizei, const GLuint *)) +AGL_API(void, Uniform3uivEXT, (GLint, GLsizei, const GLuint *)) +AGL_API(void, Uniform4uivEXT, (GLint, GLsizei, const GLuint *)) +AGL_API(void, GetUniformuivEXT, (GLuint, GLint location, GLint *)) +AGL_API(void, BindFragDataLocationEXT, (GLuint, GLuint, const GLchar *)) +AGL_API(GLint, GetFragDataLocationEXT, (GLuint, const GLchar *)) +#endif + +#if defined _ALLEGRO_GL_EXT_texture_array +AGL_API(void, FramebufferTextureLayerEXT, (GLenum, GLenum, GLuint, GLint, GLint)) +#endif + +#if defined _ALLEGRO_GL_EXT_texture_buffer_object +AGL_API(void, TexBufferEXT, (GLenum, GLenum, GLuint)) +#endif + +#if defined _ALLEGRO_GL_texture_integer +AGL_API(void, ClearColorIiEXT, (GLint, GLint, GLint, GLint)) +AGL_API(void, ClearColorIuiEXT, (GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, TexParameterIivEXT, (GLenum, GLenum, GLint *)) +AGL_API(void, TexParameterIuivEXT, (GLenum, GLenum, GLuint *)) +AGL_API(void, GetTexParameterIivEXT, (GLenum, GLenum, GLint *)) +AGL_API(void, GetTexParameterIiuvEXT, (GLenum, GLenum, GLuint *)) +#endif + +#if defined _ALLEGRO_GL_NV_depth_buffer_float +AGL_API(void, DepthRangedNV, (GLdouble, GLdouble)) +AGL_API(void, ClearDepthdNV, (GLdouble)) +AGL_API(void, DepthBoundsdNV, (GLdouble, GLdouble)) +#endif + +#if defined _ALLEGRO_GL_NV_framebuffer_multisample_coverage +AGL_API(void, RenderbufferStorageMultsampleCoverageNV, (GLenum, GLsizei, GLsizei, GLenum, GLsizei, GLsizei)) +#endif + +#if defined _ALLEGRO_GL_NV_geometry_program4 +AGL_API(void, ProgramVertexLimitNV, (GLenum, GLint)) +#if !defined _ALLEGRO_GL_EXT_geometry_shader4 +AGL_API(void, FramebufferTextureEXT, (GLenum, GLenum, GLuint, GLint)) +#if !defined _ALLEGRO_GL_EXT_texture_array +AGL_API(void, FramebufferTextureLayerEXT, (GLenum, GLenum, GLuint, GLint, GLint)) +#endif +#endif +#endif + +#if defined _ALLEGRO_GL_NV_gpu_program4 +AGL_API(void, ProgramLocalParameterI4iNV, (GLenum, GLuint, GLint, GLint, GLint, GLint)) +AGL_API(void, ProgramLocalParameterI4ivNV, (GLenum, GLuint, const GLint *)) +AGL_API(void, ProgramLocalParametersI4ivNV, (GLenum, GLuint, GLsizei, const GLint *)) +AGL_API(void, ProgramLocalParameterI4uiNV, (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, ProgramLocalParameterI4uivNV, (GLenum, GLuint, const GLuint *)) +AGL_API(void, ProgramLocalParametersI4uivNV, (GLenum, GLuint, GLsizei, const GLuint *)) +AGL_API(void, ProgramEnvParameterI4iNV, (GLenum, GLuint, GLint, GLint, GLint, GLint)) +AGL_API(void, ProgramEnvParameterI4ivNV, (GLenum, GLuint, const GLint *)) +AGL_API(void, ProgramEnvParametersI4ivNV, (GLenum, GLuint, GLsizei, const GLint *)) +AGL_API(void, ProgramEnvParameterI4uiNV, (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, ProgramEnvParameterI4uivNV, (GLenum, GLuint, const GLuint *)) +AGL_API(void, ProgramEnvParametersI4uivNV, (GLenum, GLuint, GLsizei, const GLuint *)) +AGL_API(void, GetProgramLocalParameterIivNV, (GLenum, GLuint, GLint *)) +AGL_API(void, GetProgramLocalParameterIuivNV,(GLenum, GLuint, GLuint *)) +AGL_API(void, GetProgramEnvParameterIivNV, (GLenum, GLuint, GLint *)) +AGL_API(void, GetProgramEnvParameterIuivNV, (GLenum, GLuint, GLuint *)) +#endif + +#if defined _ALLEGRO_GL_NV_parameter_buffer_object +#if !defined _ALLEGRO_GL_NV_transform_feedback +AGL_API(void, BindBufferRangeNV, (GLenum, GLuint, GLuint, GLintptr, GLsizeiptr)) +AGL_API(void, BindBufferOffsetNV,(GLenum, GLuint, GLuint, GLintptr)) +AGL_API(void, BindBufferBaseNV, (GLenum, GLuint, GLuint)) +#endif +AGL_API(void, ProgramBufferParametersfvNV, (GLenum, GLuint, GLuint, GLsizei, const GLfloat *)) +AGL_API(void, ProgramBufferParametersIivNV, (GLenum, GLuint, GLuint, GLsizei, const GLint *)) +AGL_API(void, ProgramBufferParametersIuivNV,(GLenum, GLuint, GLuint, GLuint, const GLuint *)) +#if !defined _ALLEGRO_GL_EXT_draw_buffers2 +AGL_API(void, GetIntegerIndexedvEXT, (GLenum, GLuint, GLboolean *)) +#endif +#endif + +#if defined _ALLEGRO_GL_NV_transform_feedback +AGL_API(void, BindBufferRangeNV, (GLenum, GLuint, GLuint, GLintptr, GLsizeiptr)) +AGL_API(void, BindBufferOffsetNV,(GLenum, GLuint, GLuint, GLintptr)) +AGL_API(void, BindBufferBaseNV, (GLenum, GLuint, GLuint)) +AGL_API(void, TransformFeedbackAttribsNV, (GLsizei, const GLint *, GLenum)) +AGL_API(void, TransformFeedbackVaryingsNV,(GLuint, GLsizei, const GLint *, GLenum)) +AGL_API(void, BeginTransformFeedbackNV, (GLenum)) +AGL_API(void, EndTransformFeedbackNV, (void)) +AGL_API(GLint, GetVaryingLocationNV, (GLuint, const GLchar *)) +AGL_API(void, GetActiveVaryingNV, (GLuint, GLuint, GLsizei, GLsizei *, GLsizei *, GLenum *, GLchar *)) +AGL_API(void, ActiveVaryingNV, (GLuint, const GLchar *)) +AGL_API(void, GetTransformFeedbackVaryingNV, (GLuint, GLuint, GLint *)) +#if !defined _ALLEGRO_GL_EXT_draw_buffers2 +AGL_API(void, GetBooleanIndexedvEXT, (GLenum, GLuint, GLboolean *)) +/*AGL_API(void, GetIntegerIndexedvEXT, (GLenum, GLuint, GLint *))*/ +#endif +#endif + +#if defined _ALLEGRO_GL_NV_vertex_program4 +#ifndef _ALLEGRO_GL_EXT_gpu_shader4 +AGL_API(void, VertexAttribI1iEXT, (GLuint, GLint)) +AGL_API(void, VertexAttribI2iEXT, (GLuint, GLint, GLint)) +AGL_API(void, VertexAttribI3iEXT, (GLuint, GLint, GLint, GLint)) +AGL_API(void, VertexAttribI4iEXT, (GLuint, GLint, GLint, GLint, GLint)) +AGL_API(void, VertexAttribI1uiEXT, (GLuint, GLuint)) +AGL_API(void, VertexAttribI2uiEXT, (GLuint, GLuint, GLuint)) +AGL_API(void, VertexAttribI3uiEXT, (GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, VertexAttribI4uiEXT, (GLuint, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, VertexAttribI1ivEXT, (GLuint, const GLint *)) +AGL_API(void, VertexAttribI2ivEXT, (GLuint, const GLint *)) +AGL_API(void, VertexAttribI3ivEXT, (GLuint, const GLint *)) +AGL_API(void, VertexAttribI4ivEXT, (GLuint, const GLint *)) +AGL_API(void, VertexAttribI1uivEXT, (GLuint, const GLuint *)) +AGL_API(void, VertexAttribI2uivEXT, (GLuint, const GLuint *)) +AGL_API(void, VertexAttribI3uivEXT, (GLuint, const GLuint *)) +AGL_API(void, VertexAttribI4uivEXT, (GLuint, const GLuint *)) +AGL_API(void, VertexAttribI4bvEXT, (GLuint, const GLbyte *)) +AGL_API(void, VertexAttribI4svEXT, (GLuint, const GLshort *)) +AGL_API(void, VertexAttribI4ubvEXT, (GLuint, const GLubyte *)) +AGL_API(void, VertexAttribI4usvEXT, (GLuint, const GLushort *)) +AGL_API(void, VertexAttribIPointerEXT, (GLuint, GLint, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, GetVertexAttribIivEXT, (GLuint, GLenum, GLint *)) +AGL_API(void, GetVertexAttribIuivEXT, (GLuint, GLenum, GLint *)) +#endif +#endif + +#if defined _ALLEGRO_GL_GREMEDY_frame_terminator +AGL_API(void, FrameTerminatorGREMEDY, (void)) +#endif + +#if defined _ALLEGRO_GL_NV_conditional_render +AGL_API(void, BeginConditionalRenderNV, (GLuint, GLenum)) +AGL_API(void, EndConditionalRenderNV, (void)) +#endif + +#if defined _ALLEGRO_GL_EXT_transform_feedback +AGL_API(void, BeginTransformFeedbackEXT, (GLenum)) +AGL_API(void, EndTransformFeedbackEXT, (void)) +AGL_API(void, BindBufferRangeEXT, (GLenum, GLuint, GLuint, GLintptr, GLsizeiptr)) +AGL_API(void, BindBufferOffsetEXT, (GLenum, GLuint, GLuint, GLintptr)) +AGL_API(void, BindBufferBaseEXT, (GLenum, GLuint, GLuint)) +AGL_API(void, TransformFeedbackVaryingsEXT, (GLuint, GLsizei, const GLint *, GLenum)) +AGL_API(void, GetTransformFeedbackVaryingEXT, (GLuint, GLuint, GLint *)) +#endif + +#if defined _ALLEGRO_GL_EXT_direct_state_access +AGL_API(void, ClientAttribDefaultEXT, (GLbitfield)) +AGL_API(void, PushClientAttribDefaultEXT, (GLbitfield)) +AGL_API(void, MatrixLoadfEXT, (GLenum, const GLfloat *)) +AGL_API(void, MatrixLoaddEXT, (GLenum, const GLdouble *)) +AGL_API(void, MatrixMultfEXT, (GLenum, const GLfloat *)) +AGL_API(void, MatrixMultdEXT, (GLenum, const GLdouble *)) +AGL_API(void, MatrixLoadIdentityEXT, (GLenum)) +AGL_API(void, MatrixRotatefEXT, (GLenum, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, MatrixRotatedEXT, (GLenum, GLdouble, GLdouble, GLdouble, GLdouble)) +AGL_API(void, MatrixScalefEXT, (GLenum, GLfloat, GLfloat, GLfloat)) +AGL_API(void, MatrixScaledEXT, (GLenum, GLdouble, GLdouble, GLdouble)) +AGL_API(void, MatrixTranslatefEXT, (GLenum, GLfloat, GLfloat, GLfloat)) +AGL_API(void, MatrixTranslatedEXT, (GLenum, GLdouble, GLdouble, GLdouble)) +AGL_API(void, MatrixFrustumEXT, (GLenum, GLdouble, GLdouble, GLdouble, GLdouble, GLdouble, GLdouble)) +AGL_API(void, MatrixOrthoEXT, (GLenum, GLdouble, GLdouble, GLdouble, GLdouble, GLdouble, GLdouble)) +AGL_API(void, MatrixPopEXT, (GLenum)) +AGL_API(void, MatrixPushEXT, (GLenum)) +AGL_API(void, MatrixLoadTransposefEXT, (GLenum, const GLfloat *)) +AGL_API(void, MatrixLoadTransposedEXT, (GLenum, const GLdouble *)) +AGL_API(void, MatrixMultTransposefEXT, (GLenum, const GLfloat *)) +AGL_API(void, MatrixMultTransposedEXT, (GLenum, const GLdouble *)) +AGL_API(void, TextureParameterfEXT, (GLuint, GLenum, GLenum, GLfloat)) +AGL_API(void, TextureParameterfvEXT, (GLuint, GLenum, GLenum, const GLfloat *)) +AGL_API(void, TextureParameteriEXT, (GLuint, GLenum, GLenum, GLint)) +AGL_API(void, TextureParameterivEXT, (GLuint, GLenum, GLenum, const GLint *)) +AGL_API(void, TextureImage1DEXT, (GLuint, GLenum, GLint, GLenum, GLsizei, GLint, GLenum, GLenum, const GLvoid *)) +AGL_API(void, TextureImage2DEXT, (GLuint, GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *)) +AGL_API(void, TextureSubImage1DEXT, (GLuint, GLenum, GLint, GLint, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, TextureSubImage2DEXT, (GLuint, GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, CopyTextureImage1DEXT, (GLuint, GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLint)) +AGL_API(void, CopyTextureImage2DEXT, (GLuint, GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLsizei, GLint)) +AGL_API(void, CopyTextureSubImage1DEXT, (GLuint, GLenum, GLint, GLint, GLint, GLint, GLsizei)) +AGL_API(void, CopyTextureSubImage2DEXT, (GLuint, GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei)) +AGL_API(void, GetTextureImageEXT, (GLuint, GLenum, GLint, GLenum, GLenum, GLvoid *)) +AGL_API(void, GetTextureParameterfvEXT, (GLuint, GLenum, GLenum, GLfloat *)) +AGL_API(void, GetTextureParameterivEXT, (GLuint, GLenum, GLenum, GLint *)) +AGL_API(void, GetTextureLevelParameterfvEXT, (GLuint, GLenum, GLint, GLenum, GLfloat *)) +AGL_API(void, GetTextureLevelParameterivEXT, (GLuint, GLenum, GLint, GLenum, GLint *)) +AGL_API(void, TextureImage3DEXT, (GLuint, GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *)) +AGL_API(void, TextureSubImage3DEXT, (GLuint, GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, CopyTextureSubImage3DEXT, (GLuint, GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei)) +AGL_API(void, MultiTexParameterfEXT, (GLenum, GLenum, GLenum, GLfloat)) +AGL_API(void, MultiTexParameterfvEXT, (GLenum, GLenum, GLenum, const GLfloat *)) +AGL_API(void, MultiTexParameteriEXT, (GLenum, GLenum, GLenum, GLint)) +AGL_API(void, MultiTexParameterivEXT, (GLenum, GLenum, GLenum, const GLint *)) +AGL_API(void, MultiTexImage1DEXT, (GLenum, GLenum, GLint, GLenum, GLsizei, GLint, GLenum, GLenum, const GLvoid *)) +AGL_API(void, MultiTexImage2DEXT, (GLenum, GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *)) +AGL_API(void, MultiTexSubImage1DEXT, (GLenum, GLenum, GLint, GLint, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, MultiTexSubImage2DEXT, (GLenum, GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, CopyMultiTexImage1DEXT, (GLenum, GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLint)) +AGL_API(void, CopyMultiTexImage2DEXT, (GLenum, GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLsizei, GLint)) +AGL_API(void, CopyMultiTexSubImage1DEXT, (GLenum, GLenum, GLint, GLint, GLint, GLint, GLsizei)) +AGL_API(void, CopyMultiTexSubImage2DEXT, (GLenum, GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei)) +AGL_API(void, GetMultiTexImageEXT, (GLenum, GLenum, GLint, GLenum, GLenum, GLvoid *)) +AGL_API(void, GetMultiTexParameterfvEXT, (GLenum, GLenum, GLenum, GLfloat *)) +AGL_API(void, GetMultiTexParameterivEXT, (GLenum, GLenum, GLenum, GLint *)) +AGL_API(void, GetMultiTexLevelParameterfvEXT, (GLenum, GLenum, GLint, GLenum, GLfloat *)) +AGL_API(void, GetMultiTexLevelParameterivEXT, (GLenum, GLenum, GLint, GLenum, GLint *)) +AGL_API(void, MultiTexImage3DEXT, (GLenum, GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *)) +AGL_API(void, MultiTexSubImage3DEXT, (GLenum, GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *)) +AGL_API(void, CopyMultiTexSubImage3DEXT, (GLenum, GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei)) +AGL_API(void, BindMultiTextureEXT, (GLenum, GLenum, GLuint)) +AGL_API(void, EnableClientStateIndexedEXT, (GLenum, GLuint)) +AGL_API(void, DisableClientStateIndexedEXT, (GLenum, GLuint)) +AGL_API(void, MultiTexCoordPointerEXT, (GLenum, GLint, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, MultiTexEnvfEXT, (GLenum, GLenum, GLenum, GLfloat)) +AGL_API(void, MultiTexEnvfvEXT, (GLenum, GLenum, GLenum, const GLfloat *)) +AGL_API(void, MultiTexEnviEXT, (GLenum, GLenum, GLenum, GLint)) +AGL_API(void, MultiTexEnvivEXT, (GLenum, GLenum, GLenum, const GLint *)) +AGL_API(void, MultiTexGendEXT, (GLenum, GLenum, GLenum, GLdouble)) +AGL_API(void, MultiTexGendvEXT, (GLenum, GLenum, GLenum, const GLdouble *)) +AGL_API(void, MultiTexGenfEXT, (GLenum, GLenum, GLenum, GLfloat)) +AGL_API(void, MultiTexGenfvEXT, (GLenum, GLenum, GLenum, const GLfloat *)) +AGL_API(void, MultiTexGeniEXT, (GLenum, GLenum, GLenum, GLint)) +AGL_API(void, MultiTexGenivEXT, (GLenum, GLenum, GLenum, const GLint *)) +AGL_API(void, GetMultiTexEnvfvEXT, (GLenum, GLenum, GLenum, GLfloat *)) +AGL_API(void, GetMultiTexEnvivEXT, (GLenum, GLenum, GLenum, GLint *)) +AGL_API(void, GetMultiTexGendvEXT, (GLenum, GLenum, GLenum, GLdouble *)) +AGL_API(void, GetMultiTexGenfvEXT, (GLenum, GLenum, GLenum, GLfloat *)) +AGL_API(void, GetMultiTexGenivEXT, (GLenum, GLenum, GLenum, GLint *)) +AGL_API(void, GetFloatIndexedvEXT, (GLenum, GLuint, GLfloat *)) +AGL_API(void, GetDoubleIndexedvEXT, (GLenum, GLuint, GLdouble *)) +AGL_API(void, GetPointerIndexedvEXT, (GLenum, GLuint, GLvoid* *)) +AGL_API(void, CompressedTextureImage3DEXT, (GLuint, GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *)) +AGL_API(void, CompressedTextureImage2DEXT, (GLuint, GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *)) +AGL_API(void, CompressedTextureImage1DEXT, (GLuint, GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *)) +AGL_API(void, CompressedTextureSubImage3DEXT, (GLuint, GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, CompressedTextureSubImage2DEXT, (GLuint, GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, CompressedTextureSubImage1DEXT, (GLuint, GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, GetCompressedTextureImageEXT, (GLuint, GLenum, GLint, GLvoid *)) +AGL_API(void, CompressedMultiTexImage3DEXT, (GLenum, GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *)) +AGL_API(void, CompressedMultiTexImage2DEXT, (GLenum, GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *)) +AGL_API(void, CompressedMultiTexImage1DEXT, (GLenum, GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *)) +AGL_API(void, CompressedMultiTexSubImage3DEXT, (GLenum, GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, CompressedMultiTexSubImage2DEXT, (GLenum, GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, CompressedMultiTexSubImage1DEXT, (GLenum, GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, GetCompressedMultiTexImageEXT, (GLenum, GLenum, GLint, GLvoid *)) +AGL_API(void, NamedProgramStringEXT, (GLuint, GLenum, GLenum, GLsizei, const GLvoid *)) +AGL_API(void, NamedProgramLocalParameter4dEXT, (GLuint, GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble)) +AGL_API(void, NamedProgramLocalParameter4dvEXT, (GLuint, GLenum, GLuint, const GLdouble *)) +AGL_API(void, NamedProgramLocalParameter4fEXT, (GLuint, GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, NamedProgramLocalParameter4fvEXT, (GLuint, GLenum, GLuint, const GLfloat *)) +AGL_API(void, GetNamedProgramLocalParameterdvEXT, (GLuint, GLenum, GLuint, GLdouble *)) +AGL_API(void, GetNamedProgramLocalParameterfvEXT, (GLuint, GLenum, GLuint, GLfloat *)) +AGL_API(void, GetNamedProgramivEXT, (GLuint, GLenum, GLenum, GLint *)) +AGL_API(void, GetNamedProgramStringEXT, (GLuint, GLenum, GLenum, GLvoid *)) +AGL_API(void, NamedProgramLocalParameters4fvEXT, (GLuint, GLenum, GLuint, GLsizei, const GLfloat *)) +AGL_API(void, NamedProgramLocalParameterI4iEXT, (GLuint, GLenum, GLuint, GLint, GLint, GLint, GLint)) +AGL_API(void, NamedProgramLocalParameterI4ivEXT, (GLuint, GLenum, GLuint, const GLint *)) +AGL_API(void, NamedProgramLocalParametersI4ivEXT, (GLuint, GLenum, GLuint, GLsizei, const GLint *)) +AGL_API(void, NamedProgramLocalParameterI4uiEXT, (GLuint, GLenum, GLuint, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, NamedProgramLocalParameterI4uivEXT, (GLuint, GLenum, GLuint, const GLuint *)) +AGL_API(void, NamedProgramLocalParametersI4uivEXT, (GLuint, GLenum, GLuint, GLsizei, const GLuint *)) +AGL_API(void, GetNamedProgramLocalParameterIivEXT, (GLuint, GLenum, GLuint, GLint *)) +AGL_API(void, GetNamedProgramLocalParameterIuivEXT, (GLuint, GLenum, GLuint, GLuint *)) +AGL_API(void, TextureParameterIivEXT, (GLuint, GLenum, GLenum, const GLint *)) +AGL_API(void, TextureParameterIuivEXT, (GLuint, GLenum, GLenum, const GLuint *)) +AGL_API(void, GetTextureParameterIivEXT, (GLuint, GLenum, GLenum, GLint *)) +AGL_API(void, GetTextureParameterIuivEXT, (GLuint, GLenum, GLenum, GLuint *)) +AGL_API(void, MultiTexParameterIivEXT, (GLenum, GLenum, GLenum, const GLint *)) +AGL_API(void, MultiTexParameterIuivEXT, (GLenum, GLenum, GLenum, const GLuint *)) +AGL_API(void, GetMultiTexParameterIivEXT, (GLenum, GLenum, GLenum, GLint *)) +AGL_API(void, GetMultiTexParameterIuivEXT, (GLenum, GLenum, GLenum, GLuint *)) +AGL_API(void, ProgramUniform1fEXT, (GLuint, GLint, GLfloat)) +AGL_API(void, ProgramUniform2fEXT, (GLuint, GLint, GLfloat, GLfloat)) +AGL_API(void, ProgramUniform3fEXT, (GLuint, GLint, GLfloat, GLfloat, GLfloat)) +AGL_API(void, ProgramUniform4fEXT, (GLuint, GLint, GLfloat, GLfloat, GLfloat, GLfloat)) +AGL_API(void, ProgramUniform1iEXT, (GLuint, GLint, GLint)) +AGL_API(void, ProgramUniform2iEXT, (GLuint, GLint, GLint, GLint)) +AGL_API(void, ProgramUniform3iEXT, (GLuint, GLint, GLint, GLint, GLint)) +AGL_API(void, ProgramUniform4iEXT, (GLuint, GLint, GLint, GLint, GLint, GLint)) +AGL_API(void, ProgramUniform1fvEXT, (GLuint, GLint, GLsizei, const GLfloat *)) +AGL_API(void, ProgramUniform2fvEXT, (GLuint, GLint, GLsizei, const GLfloat *)) +AGL_API(void, ProgramUniform3fvEXT, (GLuint, GLint, GLsizei, const GLfloat *)) +AGL_API(void, ProgramUniform4fvEXT, (GLuint, GLint, GLsizei, const GLfloat *)) +AGL_API(void, ProgramUniform1ivEXT, (GLuint, GLint, GLsizei, const GLint *)) +AGL_API(void, ProgramUniform2ivEXT, (GLuint, GLint, GLsizei, const GLint *)) +AGL_API(void, ProgramUniform3ivEXT, (GLuint, GLint, GLsizei, const GLint *)) +AGL_API(void, ProgramUniform4ivEXT, (GLuint, GLint, GLsizei, const GLint *)) +AGL_API(void, ProgramUniformMatrix2fvEXT, (GLuint, GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, ProgramUniformMatrix3fvEXT, (GLuint, GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, ProgramUniformMatrix4fvEXT, (GLuint, GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, ProgramUniformMatrix2x3fvEXT, (GLuint, GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, ProgramUniformMatrix3x2fvEXT, (GLuint, GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, ProgramUniformMatrix2x4fvEXT, (GLuint, GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, ProgramUniformMatrix4x2fvEXT, (GLuint, GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, ProgramUniformMatrix3x4fvEXT, (GLuint, GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, ProgramUniformMatrix4x3fvEXT, (GLuint, GLint, GLsizei, GLboolean, const GLfloat *)) +AGL_API(void, ProgramUniform1uiEXT, (GLuint, GLint, GLuint)) +AGL_API(void, ProgramUniform2uiEXT, (GLuint, GLint, GLuint, GLuint)) +AGL_API(void, ProgramUniform3uiEXT, (GLuint, GLint, GLuint, GLuint, GLuint)) +AGL_API(void, ProgramUniform4uiEXT, (GLuint, GLint, GLuint, GLuint, GLuint, GLuint)) +AGL_API(void, ProgramUniform1uivEXT, (GLuint, GLint, GLsizei, const GLuint *)) +AGL_API(void, ProgramUniform2uivEXT, (GLuint, GLint, GLsizei, const GLuint *)) +AGL_API(void, ProgramUniform3uivEXT, (GLuint, GLint, GLsizei, const GLuint *)) +AGL_API(void, ProgramUniform4uivEXT, (GLuint, GLint, GLsizei, const GLuint *)) +AGL_API(void, NamedBufferDataEXT, (GLuint, GLsizeiptr, const GLvoid *, GLenum)) +AGL_API(void, NamedBufferSubDataEXT, (GLuint, GLintptr, GLsizeiptr, const GLvoid *)) +AGL_API(GLvoid*, MapNamedBufferEXT, (GLuint, GLenum)) +AGL_API(GLboolean, UnmapNamedBufferEXT, (GLuint)) +AGL_API(void, GetNamedBufferParameterivEXT, (GLuint, GLenum, GLint *)) +AGL_API(void, GetNamedBufferPointervEXT, (GLuint, GLenum, GLvoid* *)) +AGL_API(void, GetNamedBufferSubDataEXT, (GLuint, GLintptr, GLsizeiptr, GLvoid *)) +AGL_API(void, TextureBufferEXT, (GLuint, GLenum, GLenum, GLuint)) +AGL_API(void, MultiTexBufferEXT, (GLenum, GLenum, GLenum, GLuint)) +AGL_API(void, NamedRenderbufferStorageEXT, (GLuint, GLenum, GLsizei, GLsizei)) +AGL_API(void, GetNamedRenderbufferParameterivEXT, (GLuint, GLenum, GLint *)) +AGL_API(GLenum, CheckNamedFramebufferStatusEXT, (GLuint, GLenum)) +AGL_API(void, NamedFramebufferTexture1DEXT, (GLuint, GLenum, GLenum, GLuint, GLint)) +AGL_API(void, NamedFramebufferTexture2DEXT, (GLuint, GLenum, GLenum, GLuint, GLint)) +AGL_API(void, NamedFramebufferTexture3DEXT, (GLuint, GLenum, GLenum, GLuint, GLint, GLint)) +AGL_API(void, NamedFramebufferRenderbufferEXT, (GLuint, GLenum, GLenum, GLuint)) +AGL_API(void, GetNamedFramebufferAttachmentParameterivEXT, (GLuint, GLenum, GLenum, GLint *)) +AGL_API(void, GenerateTextureMipmapEXT, (GLuint, GLenum)) +AGL_API(void, GenerateMultiTexMipmapEXT, (GLenum, GLenum)) +AGL_API(void, FramebufferDrawBufferEXT, (GLuint, GLenum)) +AGL_API(void, FramebufferDrawBuffersEXT, (GLuint, GLsizei, const GLenum *)) +AGL_API(void, FramebufferReadBufferEXT, (GLuint, GLenum)) +AGL_API(void, GetFramebufferParameterivEXT, (GLuint, GLenum, GLint *)) +AGL_API(void, NamedRenderbufferStorageMultisampleEXT, (GLuint, GLsizei, GLenum, GLsizei, GLsizei)) +AGL_API(void, NamedRenderbufferStorageMultisampleCoverageEXT, (GLuint, GLsizei, GLsizei, GLenum, GLsizei, GLsizei)) +AGL_API(void, NamedFramebufferTextureEXT, (GLuint, GLenum, GLuint, GLint)) +AGL_API(void, NamedFramebufferTextureLayerEXT, (GLuint, GLenum, GLuint, GLint, GLint)) +AGL_API(void, NamedFramebufferTextureFaceEXT, (GLuint, GLenum, GLuint, GLint, GLenum)) +AGL_API(void, TextureRenderbufferEXT, (GLuint, GLenum, GLuint)) +AGL_API(void, MultiTexRenderbufferEXT, (GLenum, GLenum, GLuint)) +#endif + +#if defined _ALLEGRO_GL_NV_explicit_multisample +AGL_API(void, GetMultisamplefvNV, (GLenum, GLuint, GLfloat *)) +AGL_API(void, SampleMaskIndexedNV, (GLuint, GLbitfield)) +AGL_API(void, TexRenderbufferNV, (GLenum, GLuint)) +#endif + +#if defined _ALLEGRO_GL_NV_transform_feedback2 +AGL_API(void, BindTransformFeedbackNV, (GLenum, GLuint)) +AGL_API(void, DeleteTransformFeedbacksNV, (GLsizei, const GLuint *)) +AGL_API(void, GenTransformFeedbacksNV, (GLsizei, GLuint *)) +AGL_API(GLboolean, IsTransformFeedbackNV, (GLuint)) +AGL_API(void, PauseTransformFeedbackNV, (void)) +AGL_API(void, ResumeTransformFeedbackNV, (void)) +AGL_API(void, DrawTransformFeedbackNV, (GLenum, GLuint)) +#endif + +#if defined _ALLEGRO_GL_AMD_performance_monitor +AGL_API(void, GetPerfMonitorGroupsAMD, (GLint *, GLsizei, GLuint *)) +AGL_API(void, GetPerfMonitorCountersAMD, (GLuint, GLint *, GLint *, GLsizei, GLuint *)) +AGL_API(void, GetPerfMonitorGroupStringAMD, (GLuint, GLsizei, GLsizei *, GLchar *)) +AGL_API(void, GetPerfMonitorCounterStringAMD, (GLuint, GLuint, GLsizei, GLsizei *, GLchar *)) +AGL_API(void, GetPerfMonitorCounterInfoAMD, (GLuint, GLuint, GLenum, void *)) +AGL_API(void, GenPerfMonitorsAMD, (GLsizei, GLuint *)) +AGL_API(void, DeletePerfMonitorsAMD, (GLsizei, GLuint *)) +AGL_API(void, SelectPerfMonitorCountersAMD, (GLuint, GLboolean, GLuint, GLint, GLuint *)) +AGL_API(void, BeginPerfMonitorAMD, (GLuint)) +AGL_API(void, EndPerfMonitorAMD, (GLuint)) +AGL_API(void, GetPerfMonitorCounterDataAMD, (GLuint, GLenum, GLsizei, GLuint *, GLint *)) +#endif + +#if defined _ALLEGRO_GL_AMD_vertex_shader_tesselator +AGL_API(void, TessellationFactorAMD, (GLfloat)) +AGL_API(void, TessellationModeAMD, (GLenum)) +#endif + +#if defined _ALLEGRO_GL_EXT_provoking_vertex +AGL_API(void, ProvokingVertexEXT, (GLenum)) +#endif + +#if defined _ALLEGRO_GL_AMD_draw_buffers_blend +AGL_API(void, BlendFuncIndexedAMD, (GLuint buf, GLenum src, GLenum dst)) +AGL_API(void, BlendFuncSeparateIndexedAMD, (GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)) +AGL_API(void, BlendEquationIndexedAMD, (GLuint buf, GLenum mode)) +AGL_API(void, BlendEquationSeparateIndexedAMD, (GLuint buf, GLenum modeRGB, GLenum modeAlpha)) +#endif + +#if defined _ALLEGRO_GL_APPLE_texture_range +AGL_API(void, TextureRangeAPPLE, (GLenum target, GLsizei length, const GLvoid *pointer)) +AGL_API(void, GetTexParameterPointervAPPLE, (GLenum target, GLenum pname, GLvoid* *params)) +#endif + +#if defined _ALLEGRO_GL_APPLE_vertex_program_evaluators +AGL_API(void, EnableVertexAttribAPPLE, (GLuint index, GLenum pname)) +AGL_API(void, DisableVertexAttribAPPLE, (GLuint index, GLenum pname)) +AGL_API(GLboolean, IsVertexAttribEnabledAPPLE, (GLuint index, GLenum pname)) +AGL_API(void, MapVertexAttrib1dAPPLE, (GLuint index, GLuint size, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)) +AGL_API(void, MapVertexAttrib1fAPPLE, (GLuint index, GLuint size, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)) +AGL_API(void, MapVertexAttrib2dAPPLE, (GLuint index, GLuint size, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)) +AGL_API(void, MapVertexAttrib2fAPPLE, (GLuint index, GLuint size, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)) +#endif + +#if defined _ALLEGRO_GL_APPLE_object_purgeable +AGL_API(GLenum, ObjectPurgeableAPPLE, (GLenum objectType, GLuint name, GLenum option)) +AGL_API(GLenum, ObjectUnpurgeableAPPLE, (GLenum objectType, GLuint name, GLenum option)) +AGL_API(void, GetObjectParameterivAPPLE, (GLenum objectType, GLuint name, GLenum pname, GLint *params)) +#endif + +#if defined _ALLEGRO_GL_NV_video_capture +AGL_API(void, BeginVideoCaptureNV, (GLuint video_capture_slot)) +AGL_API(void, BindVideoCaptureStreamBufferNV, (GLuint video_capture_slot, GLuint stream, GLenum frame_region, GLintptrARB offset)) +AGL_API(void, BindVideoCaptureStreamTextureNV, (GLuint video_capture_slot, GLuint stream, GLenum frame_region, GLenum target, GLuint texture)) +AGL_API(void, EndVideoCaptureNV, (GLuint video_capture_slot)) +AGL_API(void, GetVideoCaptureivNV, (GLuint video_capture_slot, GLenum pname, GLint *params)) +AGL_API(void, GetVideoCaptureStreamivNV, (GLuint video_capture_slot, GLuint stream, GLenum pname, GLint *params)) +AGL_API(void, GetVideoCaptureStreamfvNV, (GLuint video_capture_slot, GLuint stream, GLenum pname, GLfloat *params)) +AGL_API(void, GetVideoCaptureStreamdvNV, (GLuint video_capture_slot, GLuint stream, GLenum pname, GLdouble *params)) +AGL_API(GLenum, VideoCaptureNV, (GLuint video_capture_slot, GLuint *sequence_num, GLuint64EXT *capture_time)) +AGL_API(void, VideoCaptureStreamParameterivNV, (GLuint video_capture_slot, GLuint stream, GLenum pname, const GLint *params)) +AGL_API(void, VideoCaptureStreamParameterfvNV, (GLuint video_capture_slot, GLuint stream, GLenum pname, const GLfloat *params)) +AGL_API(void, VideoCaptureStreamParameterdvNV, (GLuint video_capture_slot, GLuint stream, GLenum pname, const GLdouble *params)) +#endif + +#if defined _ALLEGRO_GL_EXT_separate_shader_objects +AGL_API(void, UseShaderProgramEXT, (GLenum type, GLuint program)) +AGL_API(void, ActiveProgramEXT, (GLuint program)) +AGL_API(GLuint, CreateShaderProgramEXT, (GLenum type, const GLchar *string)) +#endif + +#if defined _ALLEGRO_GL_NV_shader_buffer_load +AGL_API(void, MakeBufferResidentNV, (GLenum target, GLenum access)) +AGL_API(void, MakeBufferNonResidentNV, (GLenum target)) +AGL_API(GLboolean, IsBufferResidentNV, (GLenum target)) +AGL_API(void, MakeNamedBufferResidentNV, (GLuint buffer, GLenum access)) +AGL_API(void, MakeNamedBufferNonResidentNV, (GLuint buffer)) +AGL_API(GLboolean, IsNamedBufferResidentNV, (GLuint buffer)) +AGL_API(void, GetBufferParameterui64vNV, (GLenum target, GLenum pname, GLuint64EXT *params)) +AGL_API(void, GetNamedBufferParameterui64vNV, (GLuint buffer, GLenum pname, GLuint64EXT *params)) +AGL_API(void, GetIntegerui64vNV, (GLenum value, GLuint64EXT *result)) +AGL_API(void, Uniformui64NV, (GLint location, GLuint64EXT value)) +AGL_API(void, Uniformui64vNV, (GLint location, GLsizei count, const GLuint64EXT *value)) +AGL_API(void, GetUniformui64vNV, (GLuint program, GLint location, GLuint64EXT *params)) +AGL_API(void, ProgramUniformui64NV, (GLuint program, GLint location, GLuint64EXT value)) +AGL_API(void, ProgramUniformui64vNV, (GLuint program, GLint location, GLsizei count, const GLuint64EXT *value)) +#endif + +#if defined _ALLEGRO_GL_NV_vertex_buffer_unified_memory +AGL_API(void, BufferAddressRangeNV, (GLenum pname, GLuint index, GLuint64EXT address, GLsizeiptr length)) +AGL_API(void, VertexFormatNV, (GLint size, GLenum type, GLsizei stride)) +AGL_API(void, NormalFormatNV, (GLenum type, GLsizei stride)) +AGL_API(void, ColorFormatNV, (GLint size, GLenum type, GLsizei stride)) +AGL_API(void, IndexFormatNV, (GLenum type, GLsizei stride)) +AGL_API(void, TexCoordFormatNV, (GLint size, GLenum type, GLsizei stride)) +AGL_API(void, EdgeFlagFormatNV, (GLsizei stride)) +AGL_API(void, SecondaryColorFormatNV, (GLint size, GLenum type, GLsizei stride)) +AGL_API(void, FogCoordFormatNV, (GLenum type, GLsizei stride)) +AGL_API(void, VertexAttribFormatNV, (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride)) +AGL_API(void, VertexAttribIFormatNV, (GLuint index, GLint size, GLenum type, GLsizei stride)) +AGL_API(void, GetIntegerui64i_vNV, (GLenum value, GLuint index, GLuint64EXT *result)) +#endif + +#if defined _ALLEGRO_GL_NV_texture_barrier +AGL_API(void, TextureBarrierNV, (void)) +#endif diff --git a/common/allegro/include/allegro5/opengl/GLext/gl_ext_defs.h b/common/allegro/include/allegro5/opengl/GLext/gl_ext_defs.h new file mode 100644 index 00000000..4443b94a --- /dev/null +++ b/common/allegro/include/allegro5/opengl/GLext/gl_ext_defs.h @@ -0,0 +1,5156 @@ +/* */ + +#ifndef GL_VERSION_1_2 +#define GL_VERSION_1_2 1 +#define _ALLEGRO_GL_VERSION_1_2 +#define GL_UNSIGNED_BYTE_3_3_2 0x8032 +#define GL_UNSIGNED_SHORT_4_4_4_4 0x8033 +#define GL_UNSIGNED_SHORT_5_5_5_1 0x8034 +#define GL_UNSIGNED_INT_8_8_8_8 0x8035 +#define GL_UNSIGNED_INT_10_10_10_2 0x8036 +#define GL_RESCALE_NORMAL 0x803A +#define GL_TEXTURE_BINDING_3D 0x806A +#define GL_PACK_SKIP_IMAGES 0x806B +#define GL_PACK_IMAGE_HEIGHT 0x806C +#define GL_UNPACK_SKIP_IMAGES 0x806D +#define GL_UNPACK_IMAGE_HEIGHT 0x806E +#define GL_TEXTURE_3D 0x806F +#define GL_PROXY_TEXTURE_3D 0x8070 +#define GL_TEXTURE_DEPTH 0x8071 +#define GL_TEXTURE_WRAP_R 0x8072 +#define GL_MAX_3D_TEXTURE_SIZE 0x8073 +#define GL_UNSIGNED_BYTE_2_3_3_REV 0x8362 +#define GL_UNSIGNED_SHORT_5_6_5 0x8363 +#define GL_UNSIGNED_SHORT_5_6_5_REV 0x8364 +#define GL_UNSIGNED_SHORT_4_4_4_4_REV 0x8365 +#define GL_UNSIGNED_SHORT_1_5_5_5_REV 0x8366 +#define GL_UNSIGNED_INT_8_8_8_8_REV 0x8367 +#define GL_UNSIGNED_INT_2_10_10_10_REV 0x8368 +#define GL_BGR 0x80E0 +#define GL_BGRA 0x80E1 +#define GL_MAX_ELEMENTS_VERTICES 0x80E8 +#define GL_MAX_ELEMENTS_INDICES 0x80E9 +#define GL_CLAMP_TO_EDGE 0x812F +#define GL_TEXTURE_MIN_LOD 0x813A +#define GL_TEXTURE_MAX_LOD 0x813B +#define GL_TEXTURE_BASE_LEVEL 0x813C +#define GL_TEXTURE_MAX_LEVEL 0x813D +#define GL_LIGHT_MODEL_COLOR_CONTROL 0x81F8 +#define GL_SINGLE_COLOR 0x81F9 +#define GL_SEPARATE_SPECULAR_COLOR 0x81FA +#define GL_SMOOTH_POINT_SIZE_RANGE 0x0B12 +#define GL_SMOOTH_POINT_SIZE_GRANULARITY 0x0B13 +#define GL_SMOOTH_LINE_WIDTH_RANGE 0x0B22 +#define GL_SMOOTH_LINE_WIDTH_GRANULARITY 0x0B23 +#define GL_ALIASED_POINT_SIZE_RANGE 0x846D +#define GL_ALIASED_LINE_WIDTH_RANGE 0x846E +#endif + +#ifndef GL_ARB_imaging +#define GL_ARB_imaging +#define _ALLEGRO_GL_ARB_imaging +#define GL_CONSTANT_COLOR 0x8001 +#define GL_ONE_MINUS_CONSTANT_COLOR 0x8002 +#define GL_CONSTANT_ALPHA 0x8003 +#define GL_ONE_MINUS_CONSTANT_ALPHA 0x8004 +#define GL_BLEND_COLOR 0x8005 +#define GL_FUNC_ADD 0x8006 +#define GL_MIN 0x8007 +#define GL_MAX 0x8008 +#define GL_BLEND_EQUATION 0x8009 +#define GL_FUNC_SUBTRACT 0x800A +#define GL_FUNC_REVERSE_SUBTRACT 0x800B +#define GL_CONVOLUTION_1D 0x8010 +#define GL_CONVOLUTION_2D 0x8011 +#define GL_SEPARABLE_2D 0x8012 +#define GL_CONVOLUTION_BORDER_MODE 0x8013 +#define GL_CONVOLUTION_FILTER_SCALE 0x8014 +#define GL_CONVOLUTION_FILTER_BIAS 0x8015 +#define GL_REDUCE 0x8016 +#define GL_CONVOLUTION_FORMAT 0x8017 +#define GL_CONVOLUTION_WIDTH 0x8018 +#define GL_CONVOLUTION_HEIGHT 0x8019 +#define GL_MAX_CONVOLUTION_WIDTH 0x801A +#define GL_MAX_CONVOLUTION_HEIGHT 0x801B +#define GL_POST_CONVOLUTION_RED_SCALE 0x801C +#define GL_POST_CONVOLUTION_GREEN_SCALE 0x801D +#define GL_POST_CONVOLUTION_BLUE_SCALE 0x801E +#define GL_POST_CONVOLUTION_ALPHA_SCALE 0x801F +#define GL_POST_CONVOLUTION_RED_BIAS 0x8020 +#define GL_POST_CONVOLUTION_GREEN_BIAS 0x8021 +#define GL_POST_CONVOLUTION_BLUE_BIAS 0x8022 +#define GL_POST_CONVOLUTION_ALPHA_BIAS 0x8023 +#define GL_HISTOGRAM 0x8024 +#define GL_PROXY_HISTOGRAM 0x8025 +#define GL_HISTOGRAM_WIDTH 0x8026 +#define GL_HISTOGRAM_FORMAT 0x8027 +#define GL_HISTOGRAM_RED_SIZE 0x8028 +#define GL_HISTOGRAM_GREEN_SIZE 0x8029 +#define GL_HISTOGRAM_BLUE_SIZE 0x802A +#define GL_HISTOGRAM_ALPHA_SIZE 0x802B +#define GL_HISTOGRAM_LUMINANCE_SIZE 0x802C +#define GL_HISTOGRAM_SINK 0x802D +#define GL_MINMAX 0x802E +#define GL_MINMAX_FORMAT 0x802F +#define GL_MINMAX_SINK 0x8030 +#define GL_TABLE_TOO_LARGE 0x8031 +#define GL_COLOR_MATRIX 0x80B1 +#define GL_COLOR_MATRIX_STACK_DEPTH 0x80B2 +#define GL_MAX_COLOR_MATRIX_STACK_DEPTH 0x80B3 +#define GL_POST_COLOR_MATRIX_RED_SCALE 0x80B4 +#define GL_POST_COLOR_MATRIX_GREEN_SCALE 0x80B5 +#define GL_POST_COLOR_MATRIX_BLUE_SCALE 0x80B6 +#define GL_POST_COLOR_MATRIX_ALPHA_SCALE 0x80B7 +#define GL_POST_COLOR_MATRIX_RED_BIAS 0x80B8 +#define GL_POST_COLOR_MATRIX_GREEN_BIAS 0x80B9 +#define GL_POST_COLOR_MATRIX_BLUE_BIAS 0x80BA +#define GL_POST_COLOR_MATRIX_ALPHA_BIAS 0x80BB +#define GL_COLOR_TABLE 0x80D0 +#define GL_POST_CONVOLUTION_COLOR_TABLE 0x80D1 +#define GL_POST_COLOR_MATRIX_COLOR_TABLE 0x80D2 +#define GL_PROXY_COLOR_TABLE 0x80D3 +#define GL_PROXY_POST_CONVOLUTION_COLOR_TABLE 0x80D4 +#define GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE 0x80D5 +#define GL_COLOR_TABLE_SCALE 0x80D6 +#define GL_COLOR_TABLE_BIAS 0x80D7 +#define GL_COLOR_TABLE_FORMAT 0x80D8 +#define GL_COLOR_TABLE_WIDTH 0x80D9 +#define GL_COLOR_TABLE_RED_SIZE 0x80DA +#define GL_COLOR_TABLE_GREEN_SIZE 0x80DB +#define GL_COLOR_TABLE_BLUE_SIZE 0x80DC +#define GL_COLOR_TABLE_ALPHA_SIZE 0x80DD +#define GL_COLOR_TABLE_LUMINANCE_SIZE 0x80DE +#define GL_COLOR_TABLE_INTENSITY_SIZE 0x80DF +#define GL_CONSTANT_BORDER 0x8151 +#define GL_REPLICATE_BORDER 0x8153 +#define GL_CONVOLUTION_BORDER_COLOR 0x8154 +#endif + +#ifndef GL_VERSION_1_3 +#define GL_VERSION_1_3 1 +#define _ALLEGRO_GL_VERSION_1_3 +#define GL_TEXTURE0 0x84C0 +#define GL_TEXTURE1 0x84C1 +#define GL_TEXTURE2 0x84C2 +#define GL_TEXTURE3 0x84C3 +#define GL_TEXTURE4 0x84C4 +#define GL_TEXTURE5 0x84C5 +#define GL_TEXTURE6 0x84C6 +#define GL_TEXTURE7 0x84C7 +#define GL_TEXTURE8 0x84C8 +#define GL_TEXTURE9 0x84C9 +#define GL_TEXTURE10 0x84CA +#define GL_TEXTURE11 0x84CB +#define GL_TEXTURE12 0x84CC +#define GL_TEXTURE13 0x84CD +#define GL_TEXTURE14 0x84CE +#define GL_TEXTURE15 0x84CF +#define GL_TEXTURE16 0x84D0 +#define GL_TEXTURE17 0x84D1 +#define GL_TEXTURE18 0x84D2 +#define GL_TEXTURE19 0x84D3 +#define GL_TEXTURE20 0x84D4 +#define GL_TEXTURE21 0x84D5 +#define GL_TEXTURE22 0x84D6 +#define GL_TEXTURE23 0x84D7 +#define GL_TEXTURE24 0x84D8 +#define GL_TEXTURE25 0x84D9 +#define GL_TEXTURE26 0x84DA +#define GL_TEXTURE27 0x84DB +#define GL_TEXTURE28 0x84DC +#define GL_TEXTURE29 0x84DD +#define GL_TEXTURE30 0x84DE +#define GL_TEXTURE31 0x84DF +#define GL_ACTIVE_TEXTURE 0x84E0 +#define GL_CLIENT_ACTIVE_TEXTURE 0x84E1 +#define GL_MAX_TEXTURE_UNITS 0x84E2 +#define GL_TRANSPOSE_MODELVIEW_MATRIX 0x84E3 +#define GL_TRANSPOSE_PROJECTION_MATRIX 0x84E4 +#define GL_TRANSPOSE_TEXTURE_MATRIX 0x84E5 +#define GL_TRANSPOSE_COLOR_MATRIX 0x84E6 +#define GL_MULTISAMPLE 0x809D +#define GL_SAMPLE_ALPHA_TO_COVERAGE 0x809E +#define GL_SAMPLE_ALPHA_TO_ONE 0x809F +#define GL_SAMPLE_COVERAGE 0x80A0 +#define GL_SAMPLE_BUFFERS 0x80A8 +#define GL_SAMPLES 0x80A9 +#define GL_SAMPLE_COVERAGE_VALUE 0x80AA +#define GL_SAMPLE_COVERAGE_INVERT 0x80AB +#define GL_MULTISAMPLE_BIT 0x20000000 +#define GL_NORMAL_MAP 0x8511 +#define GL_REFLECTION_MAP 0x8512 +#define GL_TEXTURE_CUBE_MAP 0x8513 +#define GL_TEXTURE_BINDING_CUBE_MAP 0x8514 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_X 0x8515 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X 0x8516 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y 0x8517 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y 0x8518 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z 0x8519 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z 0x851A +#define GL_PROXY_TEXTURE_CUBE_MAP 0x851B +#define GL_MAX_CUBE_MAP_TEXTURE_SIZE 0x851C +#define GL_COMPRESSED_ALPHA 0x84E9 +#define GL_COMPRESSED_LUMINANCE 0x84EA +#define GL_COMPRESSED_LUMINANCE_ALPHA 0x84EB +#define GL_COMPRESSED_INTENSITY 0x84EC +#define GL_COMPRESSED_RGB 0x84ED +#define GL_COMPRESSED_RGBA 0x84EE +#define GL_TEXTURE_COMPRESSION_HINT 0x84EF +#define GL_TEXTURE_COMPRESSED_IMAGE_SIZE 0x86A0 +#define GL_TEXTURE_COMPRESSED 0x86A1 +#define GL_NUM_COMPRESSED_TEXTURE_FORMATS 0x86A2 +#define GL_COMPRESSED_TEXTURE_FORMATS 0x86A3 +#define GL_CLAMP_TO_BORDER 0x812D +#define GL_CLAMP_TO_BORDER_SGIS 0x812D +#define GL_COMBINE 0x8570 +#define GL_COMBINE_RGB 0x8571 +#define GL_COMBINE_ALPHA 0x8572 +#define GL_SOURCE0_RGB 0x8580 +#define GL_SOURCE1_RGB 0x8581 +#define GL_SOURCE2_RGB 0x8582 +#define GL_SOURCE0_ALPHA 0x8588 +#define GL_SOURCE1_ALPHA 0x8589 +#define GL_SOURCE2_ALPHA 0x858A +#define GL_OPERAND0_RGB 0x8590 +#define GL_OPERAND1_RGB 0x8591 +#define GL_OPERAND2_RGB 0x8592 +#define GL_OPERAND0_ALPHA 0x8598 +#define GL_OPERAND1_ALPHA 0x8599 +#define GL_OPERAND2_ALPHA 0x859A +#define GL_RGB_SCALE 0x8573 +#define GL_ADD_SIGNED 0x8574 +#define GL_INTERPOLATE 0x8575 +#define GL_SUBTRACT 0x84E7 +#define GL_CONSTANT 0x8576 +#define GL_PRIMARY_COLOR 0x8577 +#define GL_PREVIOUS 0x8578 +#define GL_DOT3_RGB 0x86AE +#define GL_DOT3_RGBA 0x86AF +#endif + +#ifndef GL_VERSION_1_4 +#define GL_VERSION_1_4 1 +#define _ALLEGRO_GL_VERSION_1_4 +#define GL_BLEND_DST_RGB 0x80C8 +#define GL_BLEND_SRC_RGB 0x80C9 +#define GL_BLEND_DST_ALPHA 0x80CA +#define GL_BLEND_SRC_ALPHA 0x80CB +#define GL_POINT_SIZE_MIN 0x8126 +#define GL_POINT_SIZE_MAX 0x8127 +#define GL_POINT_FADE_THRESHOLD_SIZE 0x8128 +#define GL_POINT_DISTANCE_ATTENUATION 0x8129 +#define GL_GENERATE_MIPMAP 0x8191 +#define GL_GENERATE_MIPMAP_HINT 0x8192 +#define GL_DEPTH_COMPONENT16 0x81A5 +#define GL_DEPTH_COMPONENT24 0x81A6 +#define GL_DEPTH_COMPONENT32 0x81A7 +#define GL_MIRRORED_REPEAT 0x8370 +#define GL_FOG_COORDINATE_SOURCE 0x8450 +#define GL_FOG_COORDINATE 0x8451 +#define GL_FRAGMENT_DEPTH 0x8452 +#define GL_CURRENT_FOG_COORDINATE 0x8453 +#define GL_FOG_COORDINATE_ARRAY_TYPE 0x8454 +#define GL_FOG_COORDINATE_ARRAY_STRIDE 0x8455 +#define GL_FOG_COORDINATE_ARRAY_POINTER 0x8456 +#define GL_FOG_COORDINATE_ARRAY 0x8457 +#define GL_COLOR_SUM 0x8458 +#define GL_CURRENT_SECONDARY_COLOR 0x8459 +#define GL_SECONDARY_COLOR_ARRAY_SIZE 0x845A +#define GL_SECONDARY_COLOR_ARRAY_TYPE 0x845B +#define GL_SECONDARY_COLOR_ARRAY_STRIDE 0x845C +#define GL_SECONDARY_COLOR_ARRAY_POINTER 0x845D +#define GL_SECONDARY_COLOR_ARRAY 0x845E +#define GL_MAX_TEXTURE_LOD_BIAS 0x84FD +#define GL_TEXTURE_FILTER_CONTROL 0x8500 +#define GL_TEXTURE_LOD_BIAS 0x8501 +#define GL_INCR_WRAP 0x8507 +#define GL_DECR_WRAP 0x8508 +#define GL_TEXTURE_DEPTH_SIZE 0x884A +#define GL_DEPTH_TEXTURE_MODE 0x884B +#define GL_TEXTURE_COMPARE_MODE 0x884C +#define GL_TEXTURE_COMPARE_FUNC 0x884D +#define GL_COMPARE_R_TO_TEXTURE 0x884E +#endif + +#ifndef GL_VERSION_1_5 +#define GL_VERSION_1_5 1 +#define _ALLEGRO_GL_VERSION_1_5 +/* New types */ +#include +typedef ptrdiff_t GLintptr; +typedef ptrdiff_t GLsizeiptr; +/* Renamed enumerants */ +#define GL_FOG_COORD_SRC GL_FOG_COORDINATE_SOURCE +#define GL_FOG_COORD GL_FOG_COORDINATE +#define GL_CURRENT_FOG_COORD GL_CURRENT_FOG_COORDINATE +#define GL_FOG_COORD_ARRAY_TYPE GL_FOG_COORDINATE_ARRAY_TYPE +#define GL_FOG_COORD_ARRAY_STRIDE GL_FOG_COORDINATE_ARRAY_STRIDE +#define GL_FOG_COORD_ARRAY_POINTER GL_FOG_COORDINATE_ARRAY_POINTER +#define GL_FOG_COORD_ARRAY GL_FOG_COORDINATE_ARRAY +#define GL_SRC0_RGB GL_SOURCE0_RGB +#define GL_SRC1_RGB GL_SOURCE1_RGB +#define GL_SRC2_RGB GL_SOURCE2_RGB +#define GL_SRC0_ALPHA GL_SOURCE0_ALPHA +#define GL_SRC1_ALPHA GL_SOURCE1_ALPHA +#define GL_SRC2_ALPHA GL_SOURCE2_ALPHA +/* Promoted exts */ +#define GL_BUFFER_SIZE 0x8764 +#define GL_BUFFER_USAGE 0x8765 +#define GL_ARRAY_BUFFER 0x8892 +#define GL_ELEMENT_ARRAY_BUFFER 0x8893 +#define GL_ARRAY_BUFFER_BINDING 0x8894 +#define GL_ELEMENT_ARRAY_BUFFER_BINDING 0x8895 +#define GL_VERTEX_ARRAY_BUFFER_BINDING 0x8896 +#define GL_NORMAL_ARRAY_BUFFER_BINDING 0x8897 +#define GL_COLOR_ARRAY_BUFFER_BINDING 0x8898 +#define GL_INDEX_ARRAY_BUFFER_BINDING 0x8899 +#define GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING 0x889A +#define GL_EDGE_FLAG_ARRAY_BUFFER_BINDING 0x889B +#define GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING 0x889C +#define GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING 0x889D +#define GL_WEIGHT_ARRAY_BUFFER_BINDING 0x889E +#define GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING 0x889F +#define GL_READ_ONLY 0x88B8 +#define GL_WRITE_ONLY 0x88B9 +#define GL_READ_WRITE 0x88BA +#define GL_BUFFER_ACCESS 0x88BB +#define GL_BUFFER_MAPPED 0x88BC +#define GL_BUFFER_MAP_POINTER 0x88BD +#define GL_STREAM_DRAW 0x88E0 +#define GL_STREAM_READ 0x88E1 +#define GL_STREAM_COPY 0x88E2 +#define GL_STATIC_DRAW 0x88E4 +#define GL_STATIC_READ 0x88E5 +#define GL_STATIC_COPY 0x88E6 +#define GL_DYNAMIC_DRAW 0x88E8 +#define GL_DYNAMIC_READ 0x88E9 +#define GL_DYNAMIC_COPY 0x88EA +#define GL_SAMPLES_PASSED 0x8914 +#define GL_QUERY_COUNTER_BITS 0x8864 +#define GL_CURRENT_QUERY 0x8865 +#define GL_QUERY_RESULT 0x8866 +#define GL_QUERY_RESULT_AVAILABLE 0x8867 +#endif + + +#ifndef GL_VERSION_2_0 +#define GL_VERSION_2_0 1 +#define _ALLEGRO_GL_VERSION_2_0 +/* New types */ +typedef char GLchar; + +#define GL_BLEND_EQUATION_RGB GL_BLEND_EQUATION +#define GL_VERTEX_ATTRIB_ARRAY_ENABLED 0x8622 +#define GL_VERTEX_ATTRIB_ARRAY_SIZE 0x8623 +#define GL_VERTEX_ATTRIB_ARRAY_STRIDE 0x8624 +#define GL_VERTEX_ATTRIB_ARRAY_TYPE 0x8625 +#define GL_CURRENT_VERTEX_ATTRIB 0x8626 +#define GL_VERTEX_PROGRAM_POINT_SIZE 0x8642 +#define GL_VERTEX_PROGRAM_TWO_SIDE 0x8643 +#define GL_VERTEX_ATTRIB_ARRAY_POINTER 0x8645 +#define GL_STENCIL_BACK_FUNC 0x8800 +#define GL_STENCIL_BACK_FAIL 0x8801 +#define GL_STENCIL_BACK_PASS_DEPTH_FAIL 0x8802 +#define GL_STENCIL_BACK_PASS_DEPTH_PASS 0x8803 +#define GL_MAX_DRAW_BUFFERS 0x8824 +#define GL_DRAW_BUFFER0 0x8825 +#define GL_DRAW_BUFFER1 0x8826 +#define GL_DRAW_BUFFER2 0x8827 +#define GL_DRAW_BUFFER3 0x8828 +#define GL_DRAW_BUFFER4 0x8829 +#define GL_DRAW_BUFFER5 0x882A +#define GL_DRAW_BUFFER6 0x882B +#define GL_DRAW_BUFFER7 0x882C +#define GL_DRAW_BUFFER8 0x882D +#define GL_DRAW_BUFFER9 0x882E +#define GL_DRAW_BUFFER10 0x882F +#define GL_DRAW_BUFFER11 0x8830 +#define GL_DRAW_BUFFER12 0x8831 +#define GL_DRAW_BUFFER13 0x8832 +#define GL_DRAW_BUFFER14 0x8833 +#define GL_DRAW_BUFFER15 0x8834 +#define GL_BLEND_EQUATION_ALPHA 0x883D +#define GL_POINT_SPRITE 0x8861 +#define GL_COORD_REPLACE 0x8862 +#define GL_MAX_VERTEX_ATTRIBS 0x8869 +#define GL_VERTEX_ATTRIB_ARRAY_NORMALIZED 0x886A +#define GL_MAX_TEXTURE_COORDS 0x8871 +#define GL_MAX_TEXTURE_IMAGE_UNITS 0x8872 +#define GL_FRAGMENT_SHADER 0x8B30 +#define GL_VERTEX_SHADER 0x8B31 +#define GL_MAX_FRAGMENT_UNIFORM_COMPONENTS 0x8B49 +#define GL_MAX_VERTEX_UNIFORM_COMPONENTS 0x8B4A +#define GL_MAX_VARYING_FLOATS 0x8B4B +#define GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS 0x8B4C +#define GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS 0x8B4D +#define GL_SHADER_TYPE 0x8B4F +#define GL_FLOAT_VEC2 0x8B50 +#define GL_FLOAT_VEC3 0x8B51 +#define GL_FLOAT_VEC4 0x8B52 +#define GL_INT_VEC2 0x8B53 +#define GL_INT_VEC3 0x8B54 +#define GL_INT_VEC4 0x8B55 +#define GL_BOOL 0x8B56 +#define GL_BOOL_VEC2 0x8B57 +#define GL_BOOL_VEC3 0x8B58 +#define GL_BOOL_VEC4 0x8B59 +#define GL_FLOAT_MAT2 0x8B5A +#define GL_FLOAT_MAT3 0x8B5B +#define GL_FLOAT_MAT4 0x8B5C +#define GL_SAMPLER_1D 0x8B5D +#define GL_SAMPLER_2D 0x8B5E +#define GL_SAMPLER_3D 0x8B5F +#define GL_SAMPLER_CUBE 0x8B60 +#define GL_SAMPLER_1D_SHADOW 0x8B61 +#define GL_SAMPLER_2D_SHADOW 0x8B62 +#define GL_DELETE_STATUS 0x8B80 +#define GL_COMPILE_STATUS 0x8B81 +#define GL_LINK_STATUS 0x8B82 +#define GL_VALIDATE_STATUS 0x8B83 +#define GL_INFO_LOG_LENGTH 0x8B84 +#define GL_ATTACHED_SHADERS 0x8B85 +#define GL_ACTIVE_UNIFORMS 0x8B86 +#define GL_ACTIVE_UNIFORM_MAX_LENGTH 0x8B87 +#define GL_SHADER_SOURCE_LENGTH 0x8B88 +#define GL_ACTIVE_ATTRIBUTES 0x8B89 +#define GL_ACTIVE_ATTRIBUTE_MAX_LENGTH 0x8B8A +#define GL_FRAGMENT_SHADER_DERIVATIVE_HINT 0x8B8B +#define GL_SHADING_LANGUAGE_VERSION 0x8B8C +#define GL_CURRENT_PROGRAM 0x8B8D +#define GL_POINT_SPRITE_COORD_ORIGIN 0x8CA0 +#define GL_LOWER_LEFT 0x8CA1 +#define GL_UPPER_LEFT 0x8CA2 +#define GL_STENCIL_BACK_REF 0x8CA3 +#define GL_STENCIL_BACK_VALUE_MASK 0x8CA4 +#define GL_STENCIL_BACK_WRITEMASK 0x8CA5 +#endif + + +#ifndef GL_VERSION_2_1 +#define GL_VERSION_2_1 1 +#define _ALLEGRO_GL_VERSION_2_1 +#define GL_CURRENT_RASTER_SECONDARY_COLOR 0x845F +#define GL_PIXEL_PACK_BUFFER 0x88EB +#define GL_PIXEL_UNPACK_BUFFER 0x88EC +#define GL_PIXEL_PACK_BUFFER_BINDING 0x88ED +#define GL_PIXEL_UNPACK_BUFFER_BINDING 0x88EF +#define GL_FLOAT_MAT2x3 0x8B65 +#define GL_FLOAT_MAT2x4 0x8B66 +#define GL_FLOAT_MAT3x2 0x8B67 +#define GL_FLOAT_MAT3x4 0x8B68 +#define GL_FLOAT_MAT4x2 0x8B69 +#define GL_FLOAT_MAT4x3 0x8B6A +#define GL_SRGB 0x8C40 +#define GL_SRGB8 0x8C41 +#define GL_SRGB_ALPHA 0x8C42 +#define GL_SRGB8_ALPHA8 0x8C43 +#define GL_SLUMINANCE_ALPHA 0x8C44 +#define GL_SLUMINANCE8_ALPHA8 0x8C45 +#define GL_SLUMINANCE 0x8C46 +#define GL_SLUMINANCE8 0x8C47 +#define GL_COMPRESSED_SRGB 0x8C48 +#define GL_COMPRESSED_SRGB_ALPHA 0x8C49 +#define GL_COMPRESSED_SLUMINANCE 0x8C4A +#define GL_COMPRESSED_SLUMINANCE_ALPHA 0x8C4B +#endif + +#ifndef GL_VERSION_3_0 +#define GL_VERSION_3_0 +#define _ALLEGRO_GL_VERSION_3_0 +#define GL_COMPARE_REF_TO_TEXTURE GL_COMPARE_R_TO_TEXTURE_ARB +#define GL_CLIP_DISTANCE0 GL_CLIP_PLANE0 +#define GL_CLIP_DISTANCE1 GL_CLIP_PLANE1 +#define GL_CLIP_DISTANCE2 GL_CLIP_PLANE2 +#define GL_CLIP_DISTANCE3 GL_CLIP_PLANE3 +#define GL_CLIP_DISTANCE4 GL_CLIP_PLANE4 +#define GL_CLIP_DISTANCE5 GL_CLIP_PLANE5 +#define GL_MAX_CLIP_DISTANCES GL_MAX_CLIP_PLANES +#define GL_MAJOR_VERSION 0x821B +#define GL_MINOR_VERSION 0x821C +#define GL_NUM_EXTENSIONS 0x821D +#define GL_CONTEXT_FLAGS 0x821E +#define GL_DEPTH_BUFFER 0x8223 +#define GL_STENCIL_BUFFER 0x8224 +#define GL_COMPRESSED_RED 0x8225 +#define GL_COMPRESSED_RG 0x8226 +#define GL_CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT 0x0001 +#define GL_RGBA32F 0x8814 +#define GL_RGB32F 0x8815 +#define GL_RGBA16F 0x881A +#define GL_RGB16F 0x881B +#define GL_VERTEX_ATTRIB_ARRAY_INTEGER 0x88FD +#define GL_MAX_ARRAY_TEXTURE_LAYERS 0x88FF +#define GL_MIN_PROGRAM_TEXEL_OFFSET 0x8904 +#define GL_MAX_PROGRAM_TEXEL_OFFSET 0x8905 +#define GL_CLAMP_VERTEX_COLOR 0x891A +#define GL_CLAMP_FRAGMENT_COLOR 0x891B +#define GL_CLAMP_READ_COLOR 0x891C +#define GL_FIXED_ONLY 0x891D +#define GL_MAX_VARYING_COMPONENTS GL_MAX_VARYING_FLOATS +#define GL_TEXTURE_RED_TYPE 0x8C10 +#define GL_TEXTURE_GREEN_TYPE 0x8C11 +#define GL_TEXTURE_BLUE_TYPE 0x8C12 +#define GL_TEXTURE_ALPHA_TYPE 0x8C13 +#define GL_TEXTURE_LUMINANCE_TYPE 0x8C14 +#define GL_TEXTURE_INTENSITY_TYPE 0x8C15 +#define GL_TEXTURE_DEPTH_TYPE 0x8C16 +#define GL_UNSIGNED_NORMALIZED 0x8C17 +#define GL_TEXTURE_1D_ARRAY 0x8C18 +#define GL_PROXY_TEXTURE_1D_ARRAY 0x8C19 +#define GL_TEXTURE_2D_ARRAY 0x8C1A +#define GL_PROXY_TEXTURE_2D_ARRAY 0x8C1B +#define GL_TEXTURE_BINDING_1D_ARRAY 0x8C1C +#define GL_TEXTURE_BINDING_2D_ARRAY 0x8C1D +#define GL_R11F_G11F_B10F 0x8C3A +#define GL_UNSIGNED_INT_10F_11F_11F_REV 0x8C3B +#define GL_RGB9_E5 0x8C3D +#define GL_UNSIGNED_INT_5_9_9_9_REV 0x8C3E +#define GL_TEXTURE_SHARED_SIZE 0x8C3F +#define GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH 0x8C76 +#define GL_TRANSFORM_FEEDBACK_BUFFER_MODE 0x8C7F +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS 0x8C80 +#define GL_TRANSFORM_FEEDBACK_VARYINGS 0x8C83 +#define GL_TRANSFORM_FEEDBACK_BUFFER_START 0x8C84 +#define GL_TRANSFORM_FEEDBACK_BUFFER_SIZE 0x8C85 +#define GL_PRIMITIVES_GENERATED 0x8C87 +#define GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN 0x8C88 +#define GL_RASTERIZER_DISCARD 0x8C89 +#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS 0x8C8A +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS 0x8C8B +#define GL_INTERLEAVED_ATTRIBS 0x8C8C +#define GL_SEPARATE_ATTRIBS 0x8C8D +#define GL_TRANSFORM_FEEDBACK_BUFFER 0x8C8E +#define GL_TRANSFORM_FEEDBACK_BUFFER_BINDING 0x8C8F +#define GL_RGBA32UI 0x8D70 +#define GL_RGB32UI 0x8D71 +#define GL_RGBA16UI 0x8D76 +#define GL_RGB16UI 0x8D77 +#define GL_RGBA8UI 0x8D7C +#define GL_RGB8UI 0x8D7D +#define GL_RGBA32I 0x8D82 +#define GL_RGB32I 0x8D83 +#define GL_RGBA16I 0x8D88 +#define GL_RGB16I 0x8D89 +#define GL_RGBA8I 0x8D8E +#define GL_RGB8I 0x8D8F +#define GL_RED_INTEGER 0x8D94 +#define GL_GREEN_INTEGER 0x8D95 +#define GL_BLUE_INTEGER 0x8D96 +#define GL_ALPHA_INTEGER 0x8D97 +#define GL_RGB_INTEGER 0x8D98 +#define GL_RGBA_INTEGER 0x8D99 +#define GL_BGR_INTEGER 0x8D9A +#define GL_BGRA_INTEGER 0x8D9B +#define GL_SAMPLER_1D_ARRAY 0x8DC0 +#define GL_SAMPLER_2D_ARRAY 0x8DC1 +#define GL_SAMPLER_1D_ARRAY_SHADOW 0x8DC3 +#define GL_SAMPLER_2D_ARRAY_SHADOW 0x8DC4 +#define GL_SAMPLER_CUBE_SHADOW 0x8DC5 +#define GL_UNSIGNED_INT_VEC2 0x8DC6 +#define GL_UNSIGNED_INT_VEC3 0x8DC7 +#define GL_UNSIGNED_INT_VEC4 0x8DC8 +#define GL_INT_SAMPLER_1D 0x8DC9 +#define GL_INT_SAMPLER_2D 0x8DCA +#define GL_INT_SAMPLER_3D 0x8DCB +#define GL_INT_SAMPLER_CUBE 0x8DCC +#define GL_INT_SAMPLER_1D_ARRAY 0x8DCE +#define GL_INT_SAMPLER_2D_ARRAY 0x8DCF +#define GL_UNSIGNED_INT_SAMPLER_1D 0x8DD1 +#define GL_UNSIGNED_INT_SAMPLER_2D 0x8DD2 +#define GL_UNSIGNED_INT_SAMPLER_3D 0x8DD3 +#define GL_UNSIGNED_INT_SAMPLER_CUBE 0x8DD4 +#define GL_UNSIGNED_INT_SAMPLER_1D_ARRAY 0x8DD6 +#define GL_UNSIGNED_INT_SAMPLER_2D_ARRAY 0x8DD7 +#define GL_QUERY_WAIT 0x8E13 +#define GL_QUERY_NO_WAIT 0x8E14 +#define GL_QUERY_BY_REGION_WAIT 0x8E15 +#define GL_QUERY_BY_REGION_NO_WAIT 0x8E16 +#endif + +#ifndef GL_VERSION_3_0_DEPRECATED +#define GL_VERSION_3_0_DEPRECATED +#define _ALLEGRO_GL_VERSION_3_0_DEPRECATED +#define GL_CLAMP_VERTEX_COLOR 0x891A +#define GL_CLAMP_FRAGMENT_COLOR 0x891B +#define GL_ALPHA_INTEGER 0x8D97 +/* Reuse tokens from ARB_framebuffer_object */ +/* reuse GL_TEXTURE_LUMINANCE_TYPE */ +/* reuse GL_TEXTURE_INTENSITY_TYPE */ +#endif + + +#ifndef GL_VERSION_3_1 +#define GL_VERSION_3_1 +#define _ALLEGRO_GL_VERSION_3_1 +#define GL_SAMPLER_2D_RECT 0x8B63 +#define GL_SAMPLER_2D_RECT_SHADOW 0x8B64 +#define GL_SAMPLER_BUFFER 0x8DC2 +#define GL_INT_SAMPLER_2D_RECT 0x8DCD +#define GL_INT_SAMPLER_BUFFER 0x8DD0 +#define GL_UNSIGNED_INT_SAMPLER_2D_RECT 0x8DD5 +#define GL_UNSIGNED_INT_SAMPLER_BUFFER 0x8DD8 +#define GL_TEXTURE_BUFFER 0x8C2A +#define GL_MAX_TEXTURE_BUFFER_SIZE 0x8C2B +#define GL_TEXTURE_BINDING_BUFFER 0x8C2C +#define GL_TEXTURE_BUFFER_DATA_STORE_BINDING 0x8C2D +#define GL_TEXTURE_BUFFER_FORMAT 0x8C2E +#define GL_TEXTURE_RECTANGLE 0x84F5 +#define GL_TEXTURE_BINDING_RECTANGLE 0x84F6 +#define GL_PROXY_TEXTURE_RECTANGLE 0x84F7 +#define GL_MAX_RECTANGLE_TEXTURE_SIZE 0x84F8 +#define GL_RED_SNORM 0x8F90 +#define GL_RG_SNORM 0x8F91 +#define GL_RGB_SNORM 0x8F92 +#define GL_RGBA_SNORM 0x8F93 +#define GL_R8_SNORM 0x8F94 +#define GL_RG8_SNORM 0x8F95 +#define GL_RGB8_SNORM 0x8F96 +#define GL_RGBA8_SNORM 0x8F97 +#define GL_R16_SNORM 0x8F98 +#define GL_RG16_SNORM 0x8F99 +#define GL_RGB16_SNORM 0x8F9A +#define GL_RGBA16_SNORM 0x8F9B +#define GL_SIGNED_NORMALIZED 0x8F9C +#define GL_PRIMITIVE_RESTART 0x8F9D +#define GL_PRIMITIVE_RESTART_INDEX 0x8F9E +#endif + +#ifndef GL_VERSION_3_2 +#define GL_VERSION_3_2 +#define _ALLEGRO_GL_VERSION_3_2 +#define GL_CONTEXT_CORE_PROFILE_BIT 0x00000001 +#define GL_CONTEXT_COMPATIBILITY_PROFILE_BIT 0x00000002 +#define GL_LINES_ADJACENCY 0x000A +#define GL_LINE_STRIP_ADJACENCY 0x000B +#define GL_TRIANGLES_ADJACENCY 0x000C +#define GL_TRIANGLE_STRIP_ADJACENCY 0x000D +#define GL_PROGRAM_POINT_SIZE 0x8642 +#define GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS 0x8C29 +#define GL_FRAMEBUFFER_ATTACHMENT_LAYERED 0x8DA7 +#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS 0x8DA8 +#define GL_GEOMETRY_SHADER 0x8DD9 +#define GL_GEOMETRY_VERTICES_OUT 0x8916 +#define GL_GEOMETRY_INPUT_TYPE 0x8917 +#define GL_GEOMETRY_OUTPUT_TYPE 0x8918 +#define GL_MAX_GEOMETRY_UNIFORM_COMPONENTS 0x8DDF +#define GL_MAX_GEOMETRY_OUTPUT_VERTICES 0x8DE0 +#define GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS 0x8DE1 +#define GL_MAX_VERTEX_OUTPUT_COMPONENTS 0x9122 +#define GL_MAX_GEOMETRY_INPUT_COMPONENTS 0x9123 +#define GL_MAX_GEOMETRY_OUTPUT_COMPONENTS 0x9124 +#define GL_MAX_FRAGMENT_INPUT_COMPONENTS 0x9125 +#define GL_CONTEXT_PROFILE_MASK 0x9126 +#endif + +#ifndef GL_VERSION_3_3 +#define GL_VERSION_3_3 +#define _ALLEGRO_GL_VERSION_3_3 +#endif + + + +/* */ +/* */ + +#ifndef GL_ARB_multitexture +#define GL_ARB_multitexture +#define _ALLEGRO_GL_ARB_multitexture +#define GL_TEXTURE0_ARB 0x84C0 +#define GL_TEXTURE1_ARB 0x84C1 +#define GL_TEXTURE2_ARB 0x84C2 +#define GL_TEXTURE3_ARB 0x84C3 +#define GL_TEXTURE4_ARB 0x84C4 +#define GL_TEXTURE5_ARB 0x84C5 +#define GL_TEXTURE6_ARB 0x84C6 +#define GL_TEXTURE7_ARB 0x84C7 +#define GL_TEXTURE8_ARB 0x84C8 +#define GL_TEXTURE9_ARB 0x84C9 +#define GL_TEXTURE10_ARB 0x84CA +#define GL_TEXTURE11_ARB 0x84CB +#define GL_TEXTURE12_ARB 0x84CC +#define GL_TEXTURE13_ARB 0x84CD +#define GL_TEXTURE14_ARB 0x84CE +#define GL_TEXTURE15_ARB 0x84CF +#define GL_TEXTURE16_ARB 0x84D0 +#define GL_TEXTURE17_ARB 0x84D1 +#define GL_TEXTURE18_ARB 0x84D2 +#define GL_TEXTURE19_ARB 0x84D3 +#define GL_TEXTURE20_ARB 0x84D4 +#define GL_TEXTURE21_ARB 0x84D5 +#define GL_TEXTURE22_ARB 0x84D6 +#define GL_TEXTURE23_ARB 0x84D7 +#define GL_TEXTURE24_ARB 0x84D8 +#define GL_TEXTURE25_ARB 0x84D9 +#define GL_TEXTURE26_ARB 0x84DA +#define GL_TEXTURE27_ARB 0x84DB +#define GL_TEXTURE28_ARB 0x84DC +#define GL_TEXTURE29_ARB 0x84DD +#define GL_TEXTURE30_ARB 0x84DE +#define GL_TEXTURE31_ARB 0x84DF +#define GL_ACTIVE_TEXTURE_ARB 0x84E0 +#define GL_CLIENT_ACTIVE_TEXTURE_ARB 0x84E1 +#define GL_MAX_TEXTURE_UNITS_ARB 0x84E2 +#endif + +#ifndef GL_ARB_transpose_matrix +#define GL_ARB_transpose_matrix +#define _ALLEGRO_GL_ARB_transpose_matrix +#define GL_TRANSPOSE_MODELVIEW_MATRIX_ARB 0x84E3 +#define GL_TRANSPOSE_PROJECTION_MATRIX_ARB 0x84E4 +#define GL_TRANSPOSE_TEXTURE_MATRIX_ARB 0x84E5 +#define GL_TRANSPOSE_COLOR_MATRIX_ARB 0x84E6 +#endif + +#ifndef GL_ARB_multisample +#define GL_ARB_multisample +#define _ALLEGRO_GL_ARB_multisample +#define GL_MULTISAMPLE_ARB 0x809D +#define GL_SAMPLE_ALPHA_TO_COVERAGE_ARB 0x809E +#define GL_SAMPLE_ALPHA_TO_ONE_ARB 0x809F +#define GL_SAMPLE_COVERAGE_ARB 0x80A0 +#define GL_SAMPLE_BUFFERS_ARB 0x80A8 +#define GL_SAMPLES_ARB 0x80A9 +#define GL_SAMPLE_COVERAGE_VALUE_ARB 0x80AA +#define GL_SAMPLE_COVERAGE_INVERT_ARB 0x80AB +#define GL_MULTISAMPLE_BIT_ARB 0x20000000 +#endif + +#ifndef GL_ARB_texture_cube_map +#define GL_ARB_texture_cube_map +#define _ALLEGRO_GL_ARB_texture_cube_map +#define GL_NORMAL_MAP_ARB 0x8511 +#define GL_REFLECTION_MAP_ARB 0x8512 +#define GL_TEXTURE_CUBE_MAP_ARB 0x8513 +#define GL_TEXTURE_BINDING_CUBE_MAP_ARB 0x8514 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB 0x8515 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB 0x8516 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB 0x8517 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB 0x8518 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB 0x8519 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB 0x851A +#define GL_PROXY_TEXTURE_CUBE_MAP_ARB 0x851B +#define GL_MAX_CUBE_MAP_TEXTURE_SIZE_ARB 0x851C +#endif + +#ifndef GL_ARB_texture_compression +#define GL_ARB_texture_compression +#define _ALLEGRO_GL_ARB_texture_compression +#define GL_COMPRESSED_ALPHA_ARB 0x84E9 +#define GL_COMPRESSED_LUMINANCE_ARB 0x84EA +#define GL_COMPRESSED_LUMINANCE_ALPHA_ARB 0x84EB +#define GL_COMPRESSED_INTENSITY_ARB 0x84EC +#define GL_COMPRESSED_RGB_ARB 0x84ED +#define GL_COMPRESSED_RGBA_ARB 0x84EE +#define GL_TEXTURE_COMPRESSION_HINT_ARB 0x84EF +#define GL_TEXTURE_COMPRESSED_IMAGE_SIZE_ARB 0x86A0 +#define GL_TEXTURE_COMPRESSED_ARB 0x86A1 +#define GL_NUM_COMPRESSED_TEXTURE_FORMATS_ARB 0x86A2 +#define GL_COMPRESSED_TEXTURE_FORMATS_ARB 0x86A3 +#endif + +#ifndef GL_ARB_texture_border_clamp +#define GL_ARB_texture_border_clamp +#define _ALLEGRO_GL_ARB_texture_border_clamp +#define GL_CLAMP_TO_BORDER_ARB 0x812D +#endif + +#ifndef GL_ARB_point_parameters +#define GL_ARB_point_parameters +#define _ALLEGRO_GL_ARB_point_parameters +#define GL_POINT_SIZE_MIN_ARB 0x8126 +#define GL_POINT_SIZE_MAX_ARB 0x8127 +#define GL_POINT_FADE_THRESHOLD_SIZE_ARB 0x8128 +#define GL_POINT_DISTANCE_ATTENUATION_ARB 0x8129 +#endif + +#ifndef GL_ARB_vertex_blend +#define GL_ARB_vertex_blend +#define _ALLEGRO_GL_ARB_vertex_blend +#define GL_MAX_VERTEX_UNITS_ARB 0x86A4 +#define GL_ACTIVE_VERTEX_UNITS_ARB 0x86A5 +#define GL_WEIGHT_SUM_UNITY_ARB 0x86A6 +#define GL_VERTEX_BLEND_ARB 0x86A7 +#define GL_CURRENT_WEIGHT_ARB 0x86A8 +#define GL_WEIGHT_ARRAY_TYPE_ARB 0x86A9 +#define GL_WEIGHT_ARRAY_STRIDE_ARB 0x86AA +#define GL_WEIGHT_ARRAY_SIZE_ARB 0x86AB +#define GL_WEIGHT_ARRAY_POINTER_ARB 0x86AC +#define GL_WEIGHT_ARRAY_ARB 0x86AD +#define GL_MODELVIEW0_ARB 0x1700 +#define GL_MODELVIEW1_ARB 0x850A +#define GL_MODELVIEW2_ARB 0x8722 +#define GL_MODELVIEW3_ARB 0x8723 +#define GL_MODELVIEW4_ARB 0x8724 +#define GL_MODELVIEW5_ARB 0x8725 +#define GL_MODELVIEW6_ARB 0x8726 +#define GL_MODELVIEW7_ARB 0x8727 +#define GL_MODELVIEW8_ARB 0x8728 +#define GL_MODELVIEW9_ARB 0x8729 +#define GL_MODELVIEW10_ARB 0x872A +#define GL_MODELVIEW11_ARB 0x872B +#define GL_MODELVIEW12_ARB 0x872C +#define GL_MODELVIEW13_ARB 0x872D +#define GL_MODELVIEW14_ARB 0x872E +#define GL_MODELVIEW15_ARB 0x872F +#define GL_MODELVIEW16_ARB 0x8730 +#define GL_MODELVIEW17_ARB 0x8731 +#define GL_MODELVIEW18_ARB 0x8732 +#define GL_MODELVIEW19_ARB 0x8733 +#define GL_MODELVIEW20_ARB 0x8734 +#define GL_MODELVIEW21_ARB 0x8735 +#define GL_MODELVIEW22_ARB 0x8736 +#define GL_MODELVIEW23_ARB 0x8737 +#define GL_MODELVIEW24_ARB 0x8738 +#define GL_MODELVIEW25_ARB 0x8739 +#define GL_MODELVIEW26_ARB 0x873A +#define GL_MODELVIEW27_ARB 0x873B +#define GL_MODELVIEW28_ARB 0x873C +#define GL_MODELVIEW29_ARB 0x873D +#define GL_MODELVIEW30_ARB 0x873E +#define GL_MODELVIEW31_ARB 0x873F +#endif + +#ifndef GL_ARB_matrix_palette +#define GL_ARB_matrix_palette +#define _ALLEGRO_GL_ARB_matrix_palette +#define GL_MATRIX_PALETTE_ARB 0x8840 +#define GL_MAX_MATRIX_PALETTE_STACK_DEPTH_ARB 0x8841 +#define GL_MAX_PALETTE_MATRICES_ARB 0x8842 +#define GL_CURRENT_PALETTE_MATRIX_ARB 0x8843 +#define GL_MATRIX_INDEX_ARRAY_ARB 0x8844 +#define GL_CURRENT_MATRIX_INDEX_ARB 0x8845 +#define GL_MATRIX_INDEX_ARRAY_SIZE_ARB 0x8846 +#define GL_MATRIX_INDEX_ARRAY_TYPE_ARB 0x8847 +#define GL_MATRIX_INDEX_ARRAY_STRIDE_ARB 0x8848 +#define GL_MATRIX_INDEX_ARRAY_POINTER_ARB 0x8849 +#endif + +#ifndef GL_ARB_texture_env_combine +#define GL_ARB_texture_env_combine +#define _ALLEGRO_GL_ARB_texture_env_combine +#define GL_COMBINE_ARB 0x8570 +#define GL_COMBINE_RGB_ARB 0x8571 +#define GL_COMBINE_ALPHA_ARB 0x8572 +#define GL_SOURCE0_RGB_ARB 0x8580 +#define GL_SOURCE1_RGB_ARB 0x8581 +#define GL_SOURCE2_RGB_ARB 0x8582 +#define GL_SOURCE0_ALPHA_ARB 0x8588 +#define GL_SOURCE1_ALPHA_ARB 0x8589 +#define GL_SOURCE2_ALPHA_ARB 0x858A +#define GL_OPERAND0_RGB_ARB 0x8590 +#define GL_OPERAND1_RGB_ARB 0x8591 +#define GL_OPERAND2_RGB_ARB 0x8592 +#define GL_OPERAND0_ALPHA_ARB 0x8598 +#define GL_OPERAND1_ALPHA_ARB 0x8599 +#define GL_OPERAND2_ALPHA_ARB 0x859A +#define GL_RGB_SCALE_ARB 0x8573 +#define GL_ADD_SIGNED_ARB 0x8574 +#define GL_INTERPOLATE_ARB 0x8575 +#define GL_SUBTRACT_ARB 0x84E7 +#define GL_CONSTANT_ARB 0x8576 +#define GL_PRIMARY_COLOR_ARB 0x8577 +#define GL_PREVIOUS_ARB 0x8578 +#endif + +#ifndef GL_ARB_texture_env_dot3 +#define GL_ARB_texture_env_dot3 +#define _ALLEGRO_GL_ARB_texture_env_dot3 +#define GL_DOT3_RGB_ARB 0x86AE +#define GL_DOT3_RGBA_ARB 0x86AF +#endif + +#ifndef GL_ARB_texture_mirrored_repeat +#define GL_ARB_texture_mirrored_repeat +#define _ALLEGRO_GL_ARB_texture_mirrored_repeat +#define GL_MIRRORED_REPEAT_ARB 0x8370 +#endif + +#ifndef GL_ARB_depth_texture +#define GL_ARB_depth_texture +#define _ALLEGRO_GL_ARB_depth_texture +#define GL_DEPTH_COMPONENT16_ARB 0x81A5 +#define GL_DEPTH_COMPONENT24_ARB 0x81A6 +#define GL_DEPTH_COMPONENT32_ARB 0x81A7 +#define GL_TEXTURE_DEPTH_SIZE_ARB 0x884A +#define GL_DEPTH_TEXTURE_MODE_ARB 0x884B +#endif + +#ifndef GL_ARB_window_pos +#define GL_ARB_window_pos +#define _ALLEGRO_GL_ARB_window_pos +#endif + +#ifndef GL_ARB_shadow +#define GL_ARB_shadow +#define _ALLEGRO_GL_ARB_shadow +#define GL_TEXTURE_COMPARE_MODE_ARB 0x884C +#define GL_TEXTURE_COMPARE_FUNC_ARB 0x884D +#define GL_COMPARE_R_TO_TEXTURE_ARB 0x884E +#endif + +#ifndef GL_ARB_shadow_ambient +#define GL_ARB_shadow_ambient +#define _ALLEGRO_GL_ARB_shadow_ambient +#define GL_TEXTURE_COMPARE_FAIL_VALUE_ARB 0x80BF +#endif + +#ifndef GL_ARB_vertex_program +#define GL_ARB_vertex_program +#define _ALLEGRO_GL_ARB_vertex_program +#define GL_COLOR_SUM_ARB 0x8458 +#define GL_VERTEX_PROGRAM_ARB 0x8620 +#define GL_VERTEX_ATTRIB_ARRAY_ENABLED_ARB 0x8622 +#define GL_VERTEX_ATTRIB_ARRAY_SIZE_ARB 0x8623 +#define GL_VERTEX_ATTRIB_ARRAY_STRIDE_ARB 0x8624 +#define GL_VERTEX_ATTRIB_ARRAY_TYPE_ARB 0x8625 +#define GL_CURRENT_VERTEX_ATTRIB_ARB 0x8626 +#define GL_PROGRAM_LENGTH_ARB 0x8627 +#define GL_PROGRAM_STRING_ARB 0x8628 +#define GL_MAX_PROGRAM_MATRIX_STACK_DEPTH_ARB 0x862E +#define GL_MAX_PROGRAM_MATRICES_ARB 0x862F +#define GL_CURRENT_MATRIX_STACK_DEPTH_ARB 0x8640 +#define GL_CURRENT_MATRIX_ARB 0x8641 +#define GL_VERTEX_PROGRAM_POINT_SIZE_ARB 0x8642 +#define GL_VERTEX_PROGRAM_TWO_SIDE_ARB 0x8643 +#define GL_VERTEX_ATTRIB_ARRAY_POINTER_ARB 0x8645 +#define GL_PROGRAM_ERROR_POSITION_ARB 0x864B +#define GL_PROGRAM_BINDING_ARB 0x8677 +#define GL_MAX_VERTEX_ATTRIBS_ARB 0x8869 +#define GL_VERTEX_ATTRIB_ARRAY_NORMALIZED_ARB 0x886A +#define GL_PROGRAM_ERROR_STRING_ARB 0x8874 +#define GL_PROGRAM_FORMAT_ASCII_ARB 0x8875 +#define GL_PROGRAM_FORMAT_ARB 0x8876 +#define GL_PROGRAM_INSTRUCTIONS_ARB 0x88A0 +#define GL_MAX_PROGRAM_INSTRUCTIONS_ARB 0x88A1 +#define GL_PROGRAM_NATIVE_INSTRUCTIONS_ARB 0x88A2 +#define GL_MAX_PROGRAM_NATIVE_INSTRUCTIONS_ARB 0x88A3 +#define GL_PROGRAM_TEMPORARIES_ARB 0x88A4 +#define GL_MAX_PROGRAM_TEMPORARIES_ARB 0x88A5 +#define GL_PROGRAM_NATIVE_TEMPORARIES_ARB 0x88A6 +#define GL_MAX_PROGRAM_NATIVE_TEMPORARIES_ARB 0x88A7 +#define GL_PROGRAM_PARAMETERS_ARB 0x88A8 +#define GL_MAX_PROGRAM_PARAMETERS_ARB 0x88A9 +#define GL_PROGRAM_NATIVE_PARAMETERS_ARB 0x88AA +#define GL_MAX_PROGRAM_NATIVE_PARAMETERS_ARB 0x88AB +#define GL_PROGRAM_ATTRIBS_ARB 0x88AC +#define GL_MAX_PROGRAM_ATTRIBS_ARB 0x88AD +#define GL_PROGRAM_NATIVE_ATTRIBS_ARB 0x88AE +#define GL_MAX_PROGRAM_NATIVE_ATTRIBS_ARB 0x88AF +#define GL_PROGRAM_ADDRESS_REGISTERS_ARB 0x88B0 +#define GL_MAX_PROGRAM_ADDRESS_REGISTERS_ARB 0x88B1 +#define GL_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB 0x88B2 +#define GL_MAX_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB 0x88B3 +#define GL_MAX_PROGRAM_LOCAL_PARAMETERS_ARB 0x88B4 +#define GL_MAX_PROGRAM_ENV_PARAMETERS_ARB 0x88B5 +#define GL_PROGRAM_UNDER_NATIVE_LIMITS_ARB 0x88B6 +#define GL_TRANSPOSE_CURRENT_MATRIX_ARB 0x88B7 +#define GL_MATRIX0_ARB 0x88C0 +#define GL_MATRIX1_ARB 0x88C1 +#define GL_MATRIX2_ARB 0x88C2 +#define GL_MATRIX3_ARB 0x88C3 +#define GL_MATRIX4_ARB 0x88C4 +#define GL_MATRIX5_ARB 0x88C5 +#define GL_MATRIX6_ARB 0x88C6 +#define GL_MATRIX7_ARB 0x88C7 +#define GL_MATRIX8_ARB 0x88C8 +#define GL_MATRIX9_ARB 0x88C9 +#define GL_MATRIX10_ARB 0x88CA +#define GL_MATRIX11_ARB 0x88CB +#define GL_MATRIX12_ARB 0x88CC +#define GL_MATRIX13_ARB 0x88CD +#define GL_MATRIX14_ARB 0x88CE +#define GL_MATRIX15_ARB 0x88CF +#define GL_MATRIX16_ARB 0x88D0 +#define GL_MATRIX17_ARB 0x88D1 +#define GL_MATRIX18_ARB 0x88D2 +#define GL_MATRIX19_ARB 0x88D3 +#define GL_MATRIX20_ARB 0x88D4 +#define GL_MATRIX21_ARB 0x88D5 +#define GL_MATRIX22_ARB 0x88D6 +#define GL_MATRIX23_ARB 0x88D7 +#define GL_MATRIX24_ARB 0x88D8 +#define GL_MATRIX25_ARB 0x88D9 +#define GL_MATRIX26_ARB 0x88DA +#define GL_MATRIX27_ARB 0x88DB +#define GL_MATRIX28_ARB 0x88DC +#define GL_MATRIX29_ARB 0x88DD +#define GL_MATRIX30_ARB 0x88DE +#define GL_MATRIX31_ARB 0x88DF +#endif + +#ifndef GL_ARB_fragment_program +#define GL_ARB_fragment_program +#define _ALLEGRO_GL_ARB_fragment_program +#define GL_FRAGMENT_PROGRAM_ARB 0x8804 +#define GL_PROGRAM_ALU_INSTRUCTIONS_ARB 0x8805 +#define GL_PROGRAM_TEX_INSTRUCTIONS_ARB 0x8806 +#define GL_PROGRAM_TEX_INDIRECTIONS_ARB 0x8807 +#define GL_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB 0x8808 +#define GL_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB 0x8809 +#define GL_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB 0x880A +#define GL_MAX_PROGRAM_ALU_INSTRUCTIONS_ARB 0x880B +#define GL_MAX_PROGRAM_TEX_INSTRUCTIONS_ARB 0x880C +#define GL_MAX_PROGRAM_TEX_INDIRECTIONS_ARB 0x880D +#define GL_MAX_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB 0x880E +#define GL_MAX_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB 0x880F +#define GL_MAX_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB 0x8810 +#define GL_MAX_TEXTURE_COORDS_ARB 0x8871 +#define GL_MAX_TEXTURE_IMAGE_UNITS_ARB 0x8872 +#endif + +#ifndef GL_ARB_vertex_buffer_object +#define GL_ARB_vertex_buffer_object +#define _ALLEGRO_GL_ARB_vertex_buffer_object +#include +typedef ptrdiff_t GLintptrARB; +typedef ptrdiff_t GLsizeiptrARB; +#define GL_BUFFER_SIZE_ARB 0x8764 +#define GL_BUFFER_USAGE_ARB 0x8765 +#define GL_ARRAY_BUFFER_ARB 0x8892 +#define GL_ELEMENT_ARRAY_BUFFER_ARB 0x8893 +#define GL_ARRAY_BUFFER_BINDING_ARB 0x8894 +#define GL_ELEMENT_ARRAY_BUFFER_BINDING_ARB 0x8895 +#define GL_VERTEX_ARRAY_BUFFER_BINDING_ARB 0x8896 +#define GL_NORMAL_ARRAY_BUFFER_BINDING_ARB 0x8897 +#define GL_COLOR_ARRAY_BUFFER_BINDING_ARB 0x8898 +#define GL_INDEX_ARRAY_BUFFER_BINDING_ARB 0x8899 +#define GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING_ARB 0x889A +#define GL_EDGE_FLAG_ARRAY_BUFFER_BINDING_ARB 0x889B +#define GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING_ARB 0x889C +#define GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING_ARB 0x889D +#define GL_WEIGHT_ARRAY_BUFFER_BINDING_ARB 0x889E +#define GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING_ARB 0x889F +#define GL_READ_ONLY_ARB 0x88B8 +#define GL_WRITE_ONLY_ARB 0x88B9 +#define GL_READ_WRITE_ARB 0x88BA +#define GL_BUFFER_ACCESS_ARB 0x88BB +#define GL_BUFFER_MAPPED_ARB 0x88BC +#define GL_BUFFER_MAP_POINTER_ARB 0x88BD +#define GL_STREAM_DRAW_ARB 0x88E0 +#define GL_STREAM_READ_ARB 0x88E1 +#define GL_STREAM_COPY_ARB 0x88E2 +#define GL_STATIC_DRAW_ARB 0x88E4 +#define GL_STATIC_READ_ARB 0x88E5 +#define GL_STATIC_COPY_ARB 0x88E6 +#define GL_DYNAMIC_DRAW_ARB 0x88E8 +#define GL_DYNAMIC_READ_ARB 0x88E9 +#define GL_DYNAMIC_COPY_ARB 0x88EA +#endif + +#ifndef GL_ARB_occlusion_query +#define GL_ARB_occlusion_query +#define _ALLEGRO_GL_ARB_occlusion_query +#define GL_SAMPLES_PASSED_ARB 0x8914 +#define GL_QUERY_COUNTER_BITS_ARB 0x8864 +#define GL_CURRENT_QUERY_ARB 0x8865 +#define GL_QUERY_RESULT_ARB 0x8866 +#define GL_QUERY_RESULT_AVAILABLE_ARB 0x8867 +#endif + +#ifndef GL_ARB_shader_objects +#define GL_ARB_shader_objects +#define _ALLEGRO_GL_ARB_shader_objects +typedef char GLcharARB; +typedef unsigned long GLhandleARB; +#define GL_PROGRAM_OBJECT_ARB 0x8B40 +#define GL_OBJECT_TYPE_ARB 0x8B4E +#define GL_OBJECT_SUBTYPE_ARB 0x8B4F +#define GL_OBJECT_DELETE_STATUS_ARB 0x8B80 +#define GL_OBJECT_COMPILE_STATUS_ARB 0x8B81 +#define GL_OBJECT_LINK_STATUS_ARB 0x8B82 +#define GL_OBJECT_VALIDATE_STATUS_ARB 0x8B83 +#define GL_OBJECT_INFO_LOG_LENGTH_ARB 0x8B84 +#define GL_OBJECT_ATTACHED_OBJECTS_ARB 0x8B85 +#define GL_OBJECT_ACTIVE_UNIFORMS_ARB 0x8B86 +#define GL_OBJECT_ACTIVE_UNIFORM_MAX_LENGTH_ARB 0x8B87 +#define GL_OBJECT_SHADER_SOURCE_LENGTH_ARB 0x8B88 +#define GL_SHADER_OBJECT_ARB 0x8B48 +/* GL_FLOAT */ +#define GL_FLOAT_VEC2_ARB 0x8B50 +#define GL_FLOAT_VEC3_ARB 0x8B51 +#define GL_FLOAT_VEC4_ARB 0x8B52 +/* GL_INT */ +#define GL_INT_VEC2_ARB 0x8B53 +#define GL_INT_VEC3_ARB 0x8B54 +#define GL_INT_VEC4_ARB 0x8B55 +#define GL_BOOL_ARB 0x8B56 +#define GL_BOOL_VEC2_ARB 0x8B57 +#define GL_BOOL_VEC3_ARB 0x8B58 +#define GL_BOOL_VEC4_ARB 0x8B59 +#define GL_FLOAT_MAT2_ARB 0x8B5A +#define GL_FLOAT_MAT3_ARB 0x8B5B +#define GL_FLOAT_MAT4_ARB 0x8B5C +#define GL_SAMPLER_1D_ARB 0x8B5D +#define GL_SAMPLER_2D_ARB 0x8B5E +#define GL_SAMPLER_3D_ARB 0x8B5F +#define GL_SAMPLER_CUBE_ARB 0x8B60 +#define GL_SAMPLER_1D_SHADOW_ARB 0x8B61 +#define GL_SAMPLER_2D_SHADOW_ARB 0x8B62 +#define GL_SAMPLER_2D_RECT_ARB 0x8B63 +#define GL_SAMPLER_2D_RECT_SHADOW_ARB 0x8B64 +#endif + + +#ifndef GL_ARB_vertex_shader +#define GL_ARB_vertex_shader +#define _ALLEGRO_GL_ARB_vertex_shader +#define GL_VERTEX_SHADER_ARB 0x8B31 +#define GL_MAX_VERTEX_UNIFORM_COMPONENTS_ARB 0x8B4A +#define GL_MAX_VARYING_FLOATS_ARB 0x8B4B +#define GL_MAX_VERTEX_ATTRIBS_ARB 0x8869 +#define GL_MAX_TEXTURE_IMAGE_UNITS_ARB 0x8872 +#define GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB 0x8B4C +#define GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS_ARB 0x8B4D +#define GL_MAX_TEXTURE_COORDS_ARB 0x8871 +#define GL_VERTEX_PROGRAM_POINT_SIZE_ARB 0x8642 +#define GL_VERTEX_PROGRAM_TWO_SIDE_ARB 0x8643 +#if !defined GL_ARB_shader_objects +#define GL_OBJECT_TYPE_ARB 0x8B4E +#define GL_OBJECT_SUBTYPE_ARB 0x8B4F +#endif +#define GL_OBJECT_ACTIVE_ATTRIBUTES_ARB 0x8B89 +#define GL_OBJECT_ACTIVE_ATTRIBUTE_MAX_LENGTH_ARB 0x8B8A +#if !defined GL_ARB_shader_objects +#define GL_SHADER_OBJECT_ARB 0x8B48 +#endif +#define GL_VERTEX_ATTRIB_ARRAY_ENABLED_ARB 0x8622 +#define GL_VERTEX_ATTRIB_ARRAY_SIZE_ARB 0x8623 +#define GL_VERTEX_ATTRIB_ARRAY_STRIDE_ARB 0x8624 +#define GL_VERTEX_ATTRIB_ARRAY_TYPE_ARB 0x8625 +#define GL_VERTEX_ATTRIB_ARRAY_NORMALIZED_ARB 0x886A +#define GL_CURRENT_VERTEX_ATTRIB_ARB 0x8626 +#define GL_VERTEX_ATTRIB_ARRAY_POINTER_ARB 0x8645 +#if !defined GL_ARB_shader_objects +/* GL_FLOAT */ +#define GL_FLOAT_VEC2_ARB 0x8B50 +#define GL_FLOAT_VEC3_ARB 0x8B51 +#define GL_FLOAT_VEC4_ARB 0x8B52 +#define GL_FLOAT_MAT2_ARB 0x8B5A +#define GL_FLOAT_MAT3_ARB 0x8B5B +#define GL_FLOAT_MAT4_ARB 0x8B5C +#endif +#endif + +#ifndef GL_ARB_fragment_shader +#define GL_ARB_fragment_shader +#define _ALLEGRO_GL_ARB_fragment_shader +#define GL_FRAGMENT_SHADER_ARB 0x8B30 +#define GL_MAX_FRAGMENT_UNIFORM_COMPONENTS_ARB 0x8B49 +#define GL_MAX_TEXTURE_COORDS_ARB 0x8871 +#define GL_MAX_TEXTURE_IMAGE_UNITS_ARB 0x8872 +#if !defined GL_ARB_shader_objects && !defined GL_ARB_vertex_shader +#define GL_OBJECT_TYPE_ARB 0x8B4E +#define GL_OBJECT_SUBTYPE_ARB 0x8B4F +#define GL_SHADER_OBJECT_ARB 0x8B48 +#endif +#endif + +#ifndef GL_ARB_shading_language_100 +#define GL_ARB_shading_language_100 +#define _ALLEGRO_GL_ARB_shading_language_100 +#endif + +#ifndef GL_ARB_texture_non_power_of_two +#define GL_ARB_texture_non_power_of_two +#define _ALLEGRO_GL_ARB_texture_non_power_of_two +#endif + +#ifndef GL_ARB_point_sprite +#define GL_ARB_point_sprite +#define _ALLEGRO_GL_ARB_point_sprite +#define GL_POINT_SPRITE_ARB 0x8861 +#define GL_COORD_REPLACE_ARB 0x8862 +/* GL_FALSE */ +/* GL_TRUE */ +#endif + + +#ifndef GL_ARB_draw_buffers +#define GL_ARB_draw_buffers +#define _ALLEGRO_GL_ARB_draw_buffers +#define GL_MAX_DRAW_BUFFERS_ARB 0x8824 +#define GL_DRAW_BUFFER0_ARB 0x8825 +#define GL_DRAW_BUFFER1_ARB 0x8826 +#define GL_DRAW_BUFFER2_ARB 0x8827 +#define GL_DRAW_BUFFER3_ARB 0x8828 +#define GL_DRAW_BUFFER4_ARB 0x8829 +#define GL_DRAW_BUFFER5_ARB 0x882A +#define GL_DRAW_BUFFER6_ARB 0x882B +#define GL_DRAW_BUFFER7_ARB 0x882C +#define GL_DRAW_BUFFER8_ARB 0x882D +#define GL_DRAW_BUFFER9_ARB 0x882E +#define GL_DRAW_BUFFER10_ARB 0x882F +#define GL_DRAW_BUFFER11_ARB 0x8830 +#define GL_DRAW_BUFFER12_ARB 0x8831 +#define GL_DRAW_BUFFER13_ARB 0x8832 +#define GL_DRAW_BUFFER14_ARB 0x8833 +#define GL_DRAW_BUFFER15_ARB 0x8834 +#endif + + +#ifndef GL_ARB_texture_rectangle +#define GL_ARB_texture_rectangle +#define _ALLEGRO_GL_ARB_texture_rectangle +#define GL_TEXTURE_RECTANGLE_ARB 0x84F5 +#define GL_TEXTURE_BINDING_RECTANGLE_ARB 0x84F6 +#define GL_PROXY_TEXTURE_RECTANGLE_ARB 0x84F7 +#define GL_MAX_RECTANGLE_TEXTURE_SIZE_ARB 0x84F8 +#endif +#ifdef ALLEGRO_MACOSX +#ifndef GL_EXT_texture_rectangle +#define GL_EXT_texture_rectangle +#define _ALLEGRO_GL_EXT_texture_rectangle +#define GL_TEXTURE_RECTANGLE_EXT 0x84F5 +#define GL_TEXTURE_BINDING_RECTANGLE_EXT 0x84F6 +#define GL_PROXY_TEXTURE_RECTANGLE_EXT 0x84F7 +#define GL_MAX_RECTANGLE_TEXTURE_SIZE_EXT 0x84F8 +#endif +#endif + +#ifndef GL_ARB_color_buffer_float +#define GL_ARB_color_buffer_float +#define _ALLEGRO_GL_ARB_color_buffer_float +#define GL_RGBA_FLOAT_MODE_ARB 0x8820 +#define GL_CLAMP_VERTEX_COLOR_ARB 0x891A +#define GL_CLAMP_FRAGMENT_COLOR_ARB 0x891B +#define GL_CLAMP_READ_COLOR_ARB 0x891C +#define GL_FIXED_ONLY_ARB 0x891D +#endif + + +#ifndef GL_ARB_half_float_pixel +#define GL_ARB_half_float_pixel +#define _ALLEGRO_GL_ARB_half_float_pixel +#define GL_HALF_FLOAT_ARB 0x140B +#endif + + +#ifndef GL_ARB_texture_float +#define GL_ARB_texture_float +#define _ALLEGRO_GL_ARB_texture_float +#define GL_TEXTURE_RED_TYPE_ARB 0x8C10 +#define GL_TEXTURE_GREEN_TYPE_ARB 0x8C11 +#define GL_TEXTURE_BLUE_TYPE_ARB 0x8C12 +#define GL_TEXTURE_ALPHA_TYPE_ARB 0x8C13 +#define GL_TEXTURE_LUMINANCE_TYPE_ARB 0x8C14 +#define GL_TEXTURE_INTENSITY_TYPE_ARB 0x8C15 +#define GL_TEXTURE_DEPTH_TYPE_ARB 0x8C16 +#define GL_UNSIGNED_NORMALIZED_ARB 0x8C17 +#define GL_RGBA32F_ARB 0x8814 +#define GL_RGB32F_ARB 0x8815 +#define GL_ALPHA32F_ARB 0x8816 +#define GL_INTENSITY32F_ARB 0x8817 +#define GL_LUMINANCE32F_ARB 0x8818 +#define GL_LUMINANCE_ALPHA32F_ARB 0x8819 +#define GL_RGBA16F_ARB 0x881A +#define GL_RGB16F_ARB 0x881B +#define GL_ALPHA16F_ARB 0x881C +#define GL_INTENSITY16F_ARB 0x881D +#define GL_LUMINANCE16F_ARB 0x881E +#define GL_LUMINANCE_ALPHA16F_ARB 0x881F +#endif + +#ifndef GL_ARB_pixel_buffer_object +#define GL_ARB_pixel_buffer_object +#define _ALLEGRO_GL_ARB_pixel_buffer_object +#define GL_PIXEL_PACK_BUFFER_ARB 0x88EB +#define GL_PIXEL_UNPACK_BUFFER_ARB 0x88EC +#define GL_PIXEL_PACK_BUFFER_BINDING_ARB 0x88ED +#define GL_PIXEL_UNPACK_BUFFER_BINDING_ARB 0x88EF +#endif + +#ifndef GL_ARB_depth_buffer_float +#define GL_ARB_depth_buffer_float +#define _ALLEGRO_GL_ARB_depth_buffer_float +#define GL_DEPTH_COMPONENT32F 0x8CAC +#define GL_DEPTH32F_STENCIL8 0x8CAD +#define GL_FLOAT_32_UNSIGNED_INT_24_8_REV 0x8DAD +#endif + +#ifndef GL_ARB_draw_instanced +#define GL_ARB_draw_instanced +#define _ALLEGRO_GL_ARB_draw_instanced +#endif + +#ifndef GL_ARB_framebuffer_object +#define GL_ARB_framebuffer_object +#define _ALLEGRO_GL_ARB_framebuffer_object +#define GL_INVALID_FRAMEBUFFER_OPERATION 0x0506 +#define GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING 0x8210 +#define GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE 0x8211 +#define GL_FRAMEBUFFER_ATTACHMENT_RED_SIZE 0x8212 +#define GL_FRAMEBUFFER_ATTACHMENT_GREEN_SIZE 0x8213 +#define GL_FRAMEBUFFER_ATTACHMENT_BLUE_SIZE 0x8214 +#define GL_FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE 0x8215 +#define GL_FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE 0x8216 +#define GL_FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE 0x8217 +#define GL_FRAMEBUFFER_DEFAULT 0x8218 +#define GL_FRAMEBUFFER_UNDEFINED 0x8219 +#define GL_DEPTH_STENCIL_ATTACHMENT 0x821A +#define GL_INDEX 0x8222 +#define GL_MAX_RENDERBUFFER_SIZE 0x84E8 +#define GL_DEPTH_STENCIL 0x84F9 +#define GL_UNSIGNED_INT_24_8 0x84FA +#define GL_DEPTH24_STENCIL8 0x88F0 +#define GL_TEXTURE_STENCIL_SIZE 0x88F1 +#define GL_FRAMEBUFFER_BINDING 0x8CA6 +#define GL_DRAW_FRAMEBUFFER_BINDING GL_FRAMEBUFFER_BINDING +#define GL_RENDERBUFFER_BINDING 0x8CA7 +#define GL_READ_FRAMEBUFFER 0x8CA8 +#define GL_DRAW_FRAMEBUFFER 0x8CA9 +#define GL_READ_FRAMEBUFFER_BINDING 0x8CAA +#define GL_RENDERBUFFER_SAMPLES 0x8CAB +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE 0x8CD0 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME 0x8CD1 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL 0x8CD2 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE 0x8CD3 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER 0x8CD4 +#define GL_FRAMEBUFFER_COMPLETE 0x8CD5 +#define GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT 0x8CD6 +#define GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT 0x8CD7 +#define GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER 0x8CDB +#define GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER 0x8CDC +#define GL_FRAMEBUFFER_UNSUPPORTED 0x8CDD +#define GL_MAX_COLOR_ATTACHMENTS 0x8CDF +#define GL_COLOR_ATTACHMENT0 0x8CE0 +#define GL_COLOR_ATTACHMENT1 0x8CE1 +#define GL_COLOR_ATTACHMENT2 0x8CE2 +#define GL_COLOR_ATTACHMENT3 0x8CE3 +#define GL_COLOR_ATTACHMENT4 0x8CE4 +#define GL_COLOR_ATTACHMENT5 0x8CE5 +#define GL_COLOR_ATTACHMENT6 0x8CE6 +#define GL_COLOR_ATTACHMENT7 0x8CE7 +#define GL_COLOR_ATTACHMENT8 0x8CE8 +#define GL_COLOR_ATTACHMENT9 0x8CE9 +#define GL_COLOR_ATTACHMENT10 0x8CEA +#define GL_COLOR_ATTACHMENT11 0x8CEB +#define GL_COLOR_ATTACHMENT12 0x8CEC +#define GL_COLOR_ATTACHMENT13 0x8CED +#define GL_COLOR_ATTACHMENT14 0x8CEE +#define GL_COLOR_ATTACHMENT15 0x8CEF +#define GL_DEPTH_ATTACHMENT 0x8D00 +#define GL_STENCIL_ATTACHMENT 0x8D20 +#define GL_FRAMEBUFFER 0x8D40 +#define GL_RENDERBUFFER 0x8D41 +#define GL_RENDERBUFFER_WIDTH 0x8D42 +#define GL_RENDERBUFFER_HEIGHT 0x8D43 +#define GL_RENDERBUFFER_INTERNAL_FORMAT 0x8D44 +#define GL_STENCIL_INDEX1 0x8D46 +#define GL_STENCIL_INDEX4 0x8D47 +#define GL_STENCIL_INDEX8 0x8D48 +#define GL_STENCIL_INDEX16 0x8D49 +#define GL_RENDERBUFFER_RED_SIZE 0x8D50 +#define GL_RENDERBUFFER_GREEN_SIZE 0x8D51 +#define GL_RENDERBUFFER_BLUE_SIZE 0x8D52 +#define GL_RENDERBUFFER_ALPHA_SIZE 0x8D53 +#define GL_RENDERBUFFER_DEPTH_SIZE 0x8D54 +#define GL_RENDERBUFFER_STENCIL_SIZE 0x8D55 +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE 0x8D56 +#define GL_MAX_SAMPLES 0x8D57 +#endif + +#ifndef GL_ARB_framebuffer_sRGB +#define GL_ARB_framebuffer_sRGB +#define _ALLEGRO_GL_ARB_framebuffer_sRGB +#define GL_FRAMEBUFFER_SRGB 0x8DB9 +#endif + +#ifndef GL_ARB_geometry_shader4 +#define GL_ARB_geometry_shader4 +#define _ALLEGRO_GL_ARB_geometry_shader4 +#define GL_LINES_ADJACENCY_ARB 0x000A +#define GL_LINE_STRIP_ADJACENCY_ARB 0x000B +#define GL_TRIANGLES_ADJACENCY_ARB 0x000C +#define GL_TRIANGLE_STRIP_ADJACENCY_ARB 0x000D +#define GL_PROGRAM_POINT_SIZE_ARB 0x8642 +#define GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_ARB 0x8C29 +#define GL_FRAMEBUFFER_ATTACHMENT_LAYERED_ARB 0x8DA7 +#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_ARB 0x8DA8 +#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_ARB 0x8DA9 +#define GL_GEOMETRY_SHADER_ARB 0x8DD9 +#define GL_GEOMETRY_VERTICES_OUT_ARB 0x8DDA +#define GL_GEOMETRY_INPUT_TYPE_ARB 0x8DDB +#define GL_GEOMETRY_OUTPUT_TYPE_ARB 0x8DDC +#define GL_MAX_GEOMETRY_VARYING_COMPONENTS_ARB 0x8DDD +#define GL_MAX_VERTEX_VARYING_COMPONENTS_ARB 0x8DDE +#define GL_MAX_GEOMETRY_UNIFORM_COMPONENTS_ARB 0x8DDF +#define GL_MAX_GEOMETRY_OUTPUT_VERTICES_ARB 0x8DE0 +#define GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_ARB 0x8DE1 +/* reuse GL_MAX_VARYING_COMPONENTS */ +/* reuse GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER */ +#endif + +#ifndef GL_ARB_half_float_vertex +#define GL_ARB_half_float_vertex +#define _ALLEGRO_GL_ARB_half_float_vertex +#define GL_HALF_FLOAT 0x140B +#endif + +#ifndef GL_ARB_instanced_arrays +#define GL_ARB_instanced_arrays +#define _ALLEGRO_GL_ARB_instanced_arrays +#endif + +#ifndef GL_ARB_map_buffer_range +#define GL_ARB_map_buffer_range +#define _ALLEGRO_GL_ARB_map_buffer_range +#define GL_MAP_READ_BIT 0x0001 +#define GL_MAP_WRITE_BIT 0x0002 +#define GL_MAP_INVALIDATE_RANGE_BIT 0x0004 +#define GL_MAP_INVALIDATE_BUFFER_BIT 0x0008 +#define GL_MAP_FLUSH_EXPLICIT_BIT 0x0010 +#define GL_MAP_UNSYNCHRONIZED_BIT 0x0020 +#endif + +#ifndef GL_ARB_texture_buffer_object +#define GL_ARB_texture_buffer_object +#define _ALLEGRO_GL_ARB_texture_buffer_object +#define GL_TEXTURE_BUFFER_ARB 0x8C2A +#define GL_MAX_TEXTURE_BUFFER_SIZE_ARB 0x8C2B +#define GL_TEXTURE_BINDING_BUFFER_ARB 0x8C2C +#define GL_TEXTURE_BUFFER_DATA_STORE_BINDING_ARB 0x8C2D +#define GL_TEXTURE_BUFFER_FORMAT_ARB 0x8C2E +#endif + +#ifndef GL_ARB_texture_compression_rgtc +#define GL_ARB_texture_compression_rgtc +#define _ALLEGRO_GL_ARB_texture_compression_rgtc +#define GL_COMPRESSED_RED_RGTC1 0x8DBB +#define GL_COMPRESSED_SIGNED_RED_RGTC1 0x8DBC +#define GL_COMPRESSED_RG_RGTC2 0x8DBD +#define GL_COMPRESSED_SIGNED_RG_RGTC2 0x8DBE +#endif + +#ifndef GL_ARB_texture_rg +#define GL_ARB_texture_rg +#define _ALLEGRO_GL_ARB_texture_rg +#define GL_RG 0x8227 +#define GL_RG_INTEGER 0x8228 +#define GL_R8 0x8229 +#define GL_R16 0x822A +#define GL_RG8 0x822B +#define GL_RG16 0x822C +#define GL_R16F 0x822D +#define GL_R32F 0x822E +#define GL_RG16F 0x822F +#define GL_RG32F 0x8230 +#define GL_R8I 0x8231 +#define GL_R8UI 0x8232 +#define GL_R16I 0x8233 +#define GL_R16UI 0x8234 +#define GL_R32I 0x8235 +#define GL_R32UI 0x8236 +#define GL_RG8I 0x8237 +#define GL_RG8UI 0x8238 +#define GL_RG16I 0x8239 +#define GL_RG16UI 0x823A +#define GL_RG32I 0x823B +#define GL_RG32UI 0x823C +#endif + +#ifndef GL_ARB_vertex_array_object +#define GL_ARB_vertex_array_object +#define _ALLEGRO_GL_ARB_vertex_array_object +#define GL_VERTEX_ARRAY_BINDING 0x85B5 +#endif + +#ifndef GL_ARB_uniform_buffer_object +#define GL_ARB_uniform_buffer_object +#define _ALLEGRO_GL_ARB_uniform_buffer_object +#define GL_UNIFORM_BUFFER 0x8A11 +#define GL_UNIFORM_BUFFER_BINDING 0x8A28 +#define GL_UNIFORM_BUFFER_START 0x8A29 +#define GL_UNIFORM_BUFFER_SIZE 0x8A2A +#define GL_MAX_VERTEX_UNIFORM_BLOCKS 0x8A2B +#define GL_MAX_GEOMETRY_UNIFORM_BLOCKS 0x8A2C +#define GL_MAX_FRAGMENT_UNIFORM_BLOCKS 0x8A2D +#define GL_MAX_COMBINED_UNIFORM_BLOCKS 0x8A2E +#define GL_MAX_UNIFORM_BUFFER_BINDINGS 0x8A2F +#define GL_MAX_UNIFORM_BLOCK_SIZE 0x8A30 +#define GL_MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS 0x8A31 +#define GL_MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS 0x8A32 +#define GL_MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS 0x8A33 +#define GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT 0x8A34 +#define GL_ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH 0x8A35 +#define GL_ACTIVE_UNIFORM_BLOCKS 0x8A36 +#define GL_UNIFORM_TYPE 0x8A37 +#define GL_UNIFORM_SIZE 0x8A38 +#define GL_UNIFORM_NAME_LENGTH 0x8A39 +#define GL_UNIFORM_BLOCK_INDEX 0x8A3A +#define GL_UNIFORM_OFFSET 0x8A3B +#define GL_UNIFORM_ARRAY_STRIDE 0x8A3C +#define GL_UNIFORM_MATRIX_STRIDE 0x8A3D +#define GL_UNIFORM_IS_ROW_MAJOR 0x8A3E +#define GL_UNIFORM_BLOCK_BINDING 0x8A3F +#define GL_UNIFORM_BLOCK_DATA_SIZE 0x8A40 +#define GL_UNIFORM_BLOCK_NAME_LENGTH 0x8A41 +#define GL_UNIFORM_BLOCK_ACTIVE_UNIFORMS 0x8A42 +#define GL_UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES 0x8A43 +#define GL_UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER 0x8A44 +#define GL_UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER 0x8A45 +#define GL_UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER 0x8A46 +#define GL_INVALID_INDEX 0xFFFFFFFFu +#endif + +#ifndef GL_ARB_compatibility +#define GL_ARB_compatibility +#define _ALLEGRO_GL_ARB_compatibility +/* ARB_compatibility just defines tokens from core 3.0 */ +#endif + +#ifndef GL_ARB_copy_buffer +#define GL_ARB_copy_buffer +#define _ALLEGRO_GL_ARB_copy_buffer +#define GL_COPY_READ_BUFFER 0x8F36 +#define GL_COPY_WRITE_BUFFER 0x8F37 +#endif + +#ifndef GL_ARB_shader_texture_lod +#define GL_ARB_shader_texture_lod +#define _ALLEGRO_GL_ARB_shader_texture_lod +#endif + +#ifndef GL_ARB_depth_clamp +#define GL_ARB_depth_clamp +#define _ALLEGRO_GL_ARB_depth_clamp +#define GL_DEPTH_CLAMP 0x864F +#endif + +#ifndef GL_ARB_draw_elements_base_vertex +#define GL_ARB_draw_elements_base_vertex +#define _ALLEGRO_GL_ARB_draw_elements_base_vertex +#endif + +#ifndef GL_ARB_fragment_coord_conventions +#define GL_ARB_fragment_coord_conventions +#define _ALLEGRO_GL_ARB_fragment_coord_conventions +#endif + +#ifndef GL_ARB_provoking_vertex +#define GL_ARB_provoking_vertex +#define _ALLEGRO_GL_ARB_provoking_vertex +#define GL_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION 0x8E4C +#define GL_FIRST_VERTEX_CONVENTION 0x8E4D +#define GL_LAST_VERTEX_CONVENTION 0x8E4E +#define GL_PROVOKING_VERTEX 0x8E4F +#endif + +#ifndef GL_ARB_seamless_cube_map +#define GL_ARB_seamless_cube_map +#define _ALLEGRO_GL_ARB_seamless_cube_map +#define GL_TEXTURE_CUBE_MAP_SEAMLESS 0x884F +#endif + +#ifndef GL_ARB_sync +#define GL_ARB_sync +#define _ALLEGRO_GL_ARB_sync +#if (defined _MSC_VER) && (_MSC_VER < 1400) +typedef __int64 GLint64; +typedef unsigned __int64 GLuint64; +#else +typedef int64_t GLint64; +typedef uint64_t GLuint64; +#endif +typedef struct __GLsync *GLsync; +#define GL_MAX_SERVER_WAIT_TIMEOUT 0x9111 +#define GL_OBJECT_TYPE 0x9112 +#define GL_SYNC_CONDITION 0x9113 +#define GL_SYNC_STATUS 0x9114 +#define GL_SYNC_FLAGS 0x9115 +#define GL_SYNC_FENCE 0x9116 +#define GL_SYNC_GPU_COMMANDS_COMPLETE 0x9117 +#define GL_UNSIGNALED 0x9118 +#define GL_SIGNALED 0x9119 +#define GL_ALREADY_SIGNALED 0x911A +#define GL_TIMEOUT_EXPIRED 0x911B +#define GL_CONDITION_SATISFIED 0x911C +#define GL_WAIT_FAILED 0x911D +#define GL_SYNC_FLUSH_COMMANDS_BIT 0x00000001 +#define GL_TIMEOUT_IGNORED 0xFFFFFFFFFFFFFFFFull +#endif + +#ifndef GL_ARB_texture_multisample +#define GL_ARB_texture_multisample +#define _ALLEGRO_GL_ARB_texture_multisample +#define GL_SAMPLE_POSITION 0x8E50 +#define GL_SAMPLE_MASK 0x8E51 +#define GL_SAMPLE_MASK_VALUE 0x8E52 +#define GL_MAX_SAMPLE_MASK_WORDS 0x8E59 +#define GL_TEXTURE_2D_MULTISAMPLE 0x9100 +#define GL_PROXY_TEXTURE_2D_MULTISAMPLE 0x9101 +#define GL_TEXTURE_2D_MULTISAMPLE_ARRAY 0x9102 +#define GL_PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY 0x9103 +#define GL_TEXTURE_BINDING_2D_MULTISAMPLE 0x9104 +#define GL_TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY 0x9105 +#define GL_TEXTURE_SAMPLES 0x9106 +#define GL_TEXTURE_FIXED_SAMPLE_LOCATIONS 0x9107 +#define GL_SAMPLER_2D_MULTISAMPLE 0x9108 +#define GL_INT_SAMPLER_2D_MULTISAMPLE 0x9109 +#define GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE 0x910A +#define GL_SAMPLER_2D_MULTISAMPLE_ARRAY 0x910B +#define GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY 0x910C +#define GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY 0x910D +#define GL_MAX_COLOR_TEXTURE_SAMPLES 0x910E +#define GL_MAX_DEPTH_TEXTURE_SAMPLES 0x910F +#define GL_MAX_INTEGER_SAMPLES 0x9110 +#endif + +#ifndef GL_ARB_vertex_array_bgra +#define GL_ARB_vertex_array_bgra +#define _ALLEGRO_GL_ARB_vertex_array_bgra +/* reuse GL_BGRA */ +#endif + +#ifndef GL_ARB_draw_buffers_blend +#define GL_ARB_draw_buffers_blend +#define _ALLEGRO_GL_ARB_draw_buffers_blend +#endif + +#ifndef GL_ARB_sample_shading +#define GL_ARB_sample_shading +#define _ALLEGRO_GL_ARB_sample_shading +#define GL_SAMPLE_SHADING 0x8C36 +#define GL_MIN_SAMPLE_SHADING_VALUE 0x8C37 +#endif + +#ifndef GL_ARB_texture_cube_map_array +#define GL_ARB_texture_cube_map_array +#define _ALLEGRO_GL_ARB_texture_cube_map_array +#define GL_TEXTURE_CUBE_MAP_ARRAY 0x9009 +#define GL_TEXTURE_BINDING_CUBE_MAP_ARRAY 0x900A +#define GL_PROXY_TEXTURE_CUBE_MAP_ARRAY 0x900B +#define GL_SAMPLER_CUBE_MAP_ARRAY 0x900C +#define GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW 0x900D +#define GL_INT_SAMPLER_CUBE_MAP_ARRAY 0x900E +#define GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY 0x900F +#endif + +#ifndef GL_ARB_texture_gather +#define GL_ARB_texture_gather +#define _ALLEGRO_GL_ARB_texture_gather +#define GL_MIN_PROGRAM_TEXTURE_GATHER_OFFSET_ARB 0x8E5E +#define GL_MAX_PROGRAM_TEXTURE_GATHER_OFFSET_ARB 0x8E5F +#endif + +#ifndef GL_ARB_texture_query_lod +#define GL_ARB_texture_query_lod +#define _ALLEGRO_GL_ARB_texture_query_lod +#endif + +#ifndef GL_ARB_shading_language_include +#define GL_ARB_shading_language_include +#define _ALLEGRO_GL_ARB_shading_language_include +#define GL_SHADER_INCLUDE_ARB 0x8DAE +#define GL_NAMED_STRING_LENGTH_ARB 0x8DE9 +#define GL_NAMED_STRING_TYPE_ARB 0x8DEA +#endif + +#ifndef GL_ARB_texture_compression_bptc +#define GL_ARB_texture_compression_bptc +#define _ALLEGRO_GL_ARB_texture_compression_bptc +#define GL_COMPRESSED_RGBA_BPTC_UNORM_ARB 0x8E8C +#define GL_COMPRESSED_SRGB_ALPHA_BPTC_UNORM_ARB 0x8E8D +#define GL_COMPRESSED_RGB_BPTC_SIGNED_FLOAT_ARB 0x8E8E +#define GL_COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT_ARB 0x8E8F +#endif + +#ifndef GL_ARB_blend_func_extended +#define GL_ARB_blend_func_extended +#define _ALLEGRO_GL_ARB_blend_func_extended +#define GL_SRC1_COLOR 0x88F9 +/* reuse GL_SRC1_ALPHA */ +#define GL_ONE_MINUS_SRC1_COLOR 0x88FA +#define GL_ONE_MINUS_SRC1_ALPHA 0x88FB +#define GL_MAX_DUAL_SOURCE_DRAW_BUFFERS 0x88FC +#endif + +#ifndef GL_ARB_explicit_attrib_location +#define GL_ARB_explicit_attrib_location +#define _ALLEGRO_GL_ARB_explicit_attrib_location +#endif + +#ifndef GL_ARB_occlusion_query2 +#define GL_ARB_occlusion_query2 +#define _ALLEGRO_GL_ARB_occlusion_query2 +#define GL_ANY_SAMPLES_PASSED 0x8C2F +#endif + +#ifndef GL_ARB_sampler_objects +#define GL_ARB_sampler_objects +#define _ALLEGRO_GL_ARB_sampler_objects +#define GL_SAMPLER_BINDING 0x8919 +#endif + +#ifndef GL_ARB_shader_bit_encoding +#define GL_ARB_shader_bit_encoding +#define _ALLEGRO_GL_ARB_shader_bit_encoding +#endif + +#ifndef GL_ARB_texture_rgb10_a2ui +#define GL_ARB_texture_rgb10_a2ui +#define _ALLEGRO_GL_ARB_texture_rgb10_a2ui +#define GL_RGB10_A2UI 0x906F +#endif + +#ifndef GL_ARB_texture_swizzle +#define GL_ARB_texture_swizzle +#define _ALLEGRO_GL_ARB_texture_swizzle +#define GL_TEXTURE_SWIZZLE_R 0x8E42 +#define GL_TEXTURE_SWIZZLE_G 0x8E43 +#define GL_TEXTURE_SWIZZLE_B 0x8E44 +#define GL_TEXTURE_SWIZZLE_A 0x8E45 +#define GL_TEXTURE_SWIZZLE_RGBA 0x8E46 +#endif + +#ifndef GL_ARB_timer_query +#define GL_ARB_timer_query +#define _ALLEGRO_GL_ARB_timer_query +#define GL_TIME_ELAPSED 0x88BF +#define GL_TIMESTAMP 0x8E28 +#endif + +#ifndef GL_ARB_vertex_type_2_10_10_10_rev +#define GL_ARB_vertex_type_2_10_10_10_rev +#define _ALLEGRO_GL_ARB_vertex_type_2_10_10_10_rev +/* reuse GL_UNSIGNED_INT_2_10_10_10_REV */ +#define GL_INT_2_10_10_10_REV 0x8D9F +#endif + +#ifndef GL_ARB_draw_indirect +#define GL_ARB_draw_indirect +#define _ALLEGRO_GL_ARB_draw_indirect +#define GL_DRAW_INDIRECT_BUFFER 0x8F3F +#define GL_DRAW_INDIRECT_BUFFER_BINDING 0x8F43 +#endif + +#ifndef GL_ARB_gpu_shader5 +#define GL_ARB_gpu_shader5 +#define _ALLEGRO_GL_ARB_gpu_shader5 +#define GL_GEOMETRY_SHADER_INVOCATIONS 0x887F +#define GL_MAX_GEOMETRY_SHADER_INVOCATIONS 0x8E5A +#define GL_MIN_FRAGMENT_INTERPOLATION_OFFSET 0x8E5B +#define GL_MAX_FRAGMENT_INTERPOLATION_OFFSET 0x8E5C +#define GL_FRAGMENT_INTERPOLATION_OFFSET_BITS 0x8E5D +#define GL_MAX_VERTEX_STREAMS 0x8E71 +#endif + +#ifndef GL_ARB_gpu_shader_fp64 +#define GL_ARB_gpu_shader_fp64 +#define _ALLEGRO_GL_ARB_gpu_shader_fp64 +/* reuse GL_DOUBLE */ +#define GL_DOUBLE_VEC2 0x8FFC +#define GL_DOUBLE_VEC3 0x8FFD +#define GL_DOUBLE_VEC4 0x8FFE +#define GL_DOUBLE_MAT2 0x8F46 +#define GL_DOUBLE_MAT3 0x8F47 +#define GL_DOUBLE_MAT4 0x8F48 +#define GL_DOUBLE_MAT2x3 0x8F49 +#define GL_DOUBLE_MAT2x4 0x8F4A +#define GL_DOUBLE_MAT3x2 0x8F4B +#define GL_DOUBLE_MAT3x4 0x8F4C +#define GL_DOUBLE_MAT4x2 0x8F4D +#define GL_DOUBLE_MAT4x3 0x8F4E +#endif + +#ifndef GL_ARB_shader_subroutine +#define GL_ARB_shader_subroutine +#define _ALLEGRO_GL_ARB_shader_subroutine +#define GL_ACTIVE_SUBROUTINES 0x8DE5 +#define GL_ACTIVE_SUBROUTINE_UNIFORMS 0x8DE6 +#define GL_ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS 0x8E47 +#define GL_ACTIVE_SUBROUTINE_MAX_LENGTH 0x8E48 +#define GL_ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH 0x8E49 +#define GL_MAX_SUBROUTINES 0x8DE7 +#define GL_MAX_SUBROUTINE_UNIFORM_LOCATIONS 0x8DE8 +#define GL_NUM_COMPATIBLE_SUBROUTINES 0x8E4A +#define GL_COMPATIBLE_SUBROUTINES 0x8E4B +/* reuse GL_UNIFORM_SIZE */ +/* reuse GL_UNIFORM_NAME_LENGTH */ +#endif + +#ifndef GL_ARB_tessellation_shader +#define GL_ARB_tessellation_shader +#define _ALLEGRO_GL_ARB_tessellation_shader +#define GL_PATCHES 0x000E +#define GL_PATCH_VERTICES 0x8E72 +#define GL_PATCH_DEFAULT_INNER_LEVEL 0x8E73 +#define GL_PATCH_DEFAULT_OUTER_LEVEL 0x8E74 +#define GL_TESS_CONTROL_OUTPUT_VERTICES 0x8E75 +#define GL_TESS_GEN_MODE 0x8E76 +#define GL_TESS_GEN_SPACING 0x8E77 +#define GL_TESS_GEN_VERTEX_ORDER 0x8E78 +#define GL_TESS_GEN_POINT_MODE 0x8E79 +/* reuse GL_TRIANGLES */ +/* reuse GL_QUADS */ +#define GL_ISOLINES 0x8E7A +/* reuse GL_EQUAL */ +#define GL_FRACTIONAL_ODD 0x8E7B +#define GL_FRACTIONAL_EVEN 0x8E7C +/* reuse GL_CCW */ +/* reuse GL_CW */ +#define GL_MAX_PATCH_VERTICES 0x8E7D +#define GL_MAX_TESS_GEN_LEVEL 0x8E7E +#define GL_MAX_TESS_CONTROL_UNIFORM_COMPONENTS 0x8E7F +#define GL_MAX_TESS_EVALUATION_UNIFORM_COMPONENTS 0x8E80 +#define GL_MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS 0x8E81 +#define GL_MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS 0x8E82 +#define GL_MAX_TESS_CONTROL_OUTPUT_COMPONENTS 0x8E83 +#define GL_MAX_TESS_PATCH_COMPONENTS 0x8E84 +#define GL_MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS 0x8E85 +#define GL_MAX_TESS_EVALUATION_OUTPUT_COMPONENTS 0x8E86 +#define GL_MAX_TESS_CONTROL_UNIFORM_BLOCKS 0x8E89 +#define GL_MAX_TESS_EVALUATION_UNIFORM_BLOCKS 0x8E8A +#define GL_MAX_TESS_CONTROL_INPUT_COMPONENTS 0x886C +#define GL_MAX_TESS_EVALUATION_INPUT_COMPONENTS 0x886D +#define GL_MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS 0x8E1E +#define GL_MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS 0x8E1F +#define GL_UNIFORM_BLOCK_REFERENCED_BY_TESS_CONTROL_SHADER 0x84F0 +#define GL_UNIFORM_BLOCK_REFERENCED_BY_TESS_EVALUATION_SHADER 0x84F1 +#define GL_TESS_EVALUATION_SHADER 0x8E87 +#define GL_TESS_CONTROL_SHADER 0x8E88 +#endif + +#ifndef GL_ARB_texture_buffer_object_rgb32 +#define GL_ARB_texture_buffer_object_rgb32 +#define _ALLEGRO_GL_ARB_texture_buffer_object_rgb32 +/* reuse GL_RGB32F */ +/* reuse GL_RGB32UI */ +/* reuse GL_RGB32I */ +#endif + +#ifndef GL_ARB_transform_feedback2 +#define GL_ARB_transform_feedback2 +#define _ALLEGRO_GL_ARB_transform_feedback2 +#define GL_TRANSFORM_FEEDBACK 0x8E22 +#define GL_TRANSFORM_FEEDBACK_BUFFER_PAUSED 0x8E23 +#define GL_TRANSFORM_FEEDBACK_BUFFER_ACTIVE 0x8E24 +#define GL_TRANSFORM_FEEDBACK_BINDING 0x8E25 +#endif + +#ifndef GL_ARB_transform_feedback3 +#define GL_ARB_transform_feedback3 +#define _ALLEGRO_GL_ARB_transform_feedback3 +#define GL_MAX_TRANSFORM_FEEDBACK_BUFFERS 0x8E70 +#endif + + +/* */ + + +#ifndef GL_EXT_abgr +#define GL_EXT_abgr +#define _ALLEGRO_GL_EXT_abgr +#define GL_ABGR_EXT 0x8000 +#endif + +#ifndef GL_EXT_blend_color +#define GL_EXT_blend_color +#define _ALLEGRO_GL_EXT_blend_color +#define GL_CONSTANT_COLOR_EXT 0x8001 +#define GL_ONE_MINUS_CONSTANT_COLOR_EXT 0x8002 +#define GL_CONSTANT_ALPHA_EXT 0x8003 +#define GL_ONE_MINUS_CONSTANT_ALPHA_EXT 0x8004 +#define GL_BLEND_COLOR_EXT 0x8005 +#endif + +#ifndef GL_EXT_polygon_offset +#define GL_EXT_polygon_offset +#define _ALLEGRO_GL_EXT_polygon_offset +#define GL_POLYGON_OFFSET_EXT 0x8037 +#define GL_POLYGON_OFFSET_FACTOR_EXT 0x8038 +#define GL_POLYGON_OFFSET_BIAS_EXT 0x8039 +#endif + +#ifndef GL_EXT_texture +#define GL_EXT_texture +#define _ALLEGRO_GL_EXT_texture +#define GL_ALPHA4_EXT 0x803B +#define GL_ALPHA8_EXT 0x803C +#define GL_ALPHA12_EXT 0x803D +#define GL_ALPHA16_EXT 0x803E +#define GL_LUMINANCE4_EXT 0x803F +#define GL_LUMINANCE8_EXT 0x8040 +#define GL_LUMINANCE12_EXT 0x8041 +#define GL_LUMINANCE16_EXT 0x8042 +#define GL_LUMINANCE4_ALPHA4_EXT 0x8043 +#define GL_LUMINANCE6_ALPHA2_EXT 0x8044 +#define GL_LUMINANCE8_ALPHA8_EXT 0x8045 +#define GL_LUMINANCE12_ALPHA4_EXT 0x8046 +#define GL_LUMINANCE12_ALPHA12_EXT 0x8047 +#define GL_LUMINANCE16_ALPHA16_EXT 0x8048 +#define GL_INTENSITY_EXT 0x8049 +#define GL_INTENSITY4_EXT 0x804A +#define GL_INTENSITY8_EXT 0x804B +#define GL_INTENSITY12_EXT 0x804C +#define GL_INTENSITY16_EXT 0x804D +#define GL_RGB2_EXT 0x804E +#define GL_RGB4_EXT 0x804F +#define GL_RGB5_EXT 0x8050 +#define GL_RGB8_EXT 0x8051 +#define GL_RGB10_EXT 0x8052 +#define GL_RGB12_EXT 0x8053 +#define GL_RGB16_EXT 0x8054 +#define GL_RGBA2_EXT 0x8055 +#define GL_RGBA4_EXT 0x8056 +#define GL_RGB5_A1_EXT 0x8057 +#define GL_RGBA8_EXT 0x8058 +#define GL_RGB10_A2_EXT 0x8059 +#define GL_RGBA12_EXT 0x805A +#define GL_RGBA16_EXT 0x805B +#define GL_TEXTURE_RED_SIZE_EXT 0x805C +#define GL_TEXTURE_GREEN_SIZE_EXT 0x805D +#define GL_TEXTURE_BLUE_SIZE_EXT 0x805E +#define GL_TEXTURE_ALPHA_SIZE_EXT 0x805F +#define GL_TEXTURE_LUMINANCE_SIZE_EXT 0x8060 +#define GL_TEXTURE_INTENSITY_SIZE_EXT 0x8061 +#define GL_REPLACE_EXT 0x8062 +#define GL_PROXY_TEXTURE_1D_EXT 0x8063 +#define GL_PROXY_TEXTURE_2D_EXT 0x8064 +#define GL_TEXTURE_TOO_LARGE_EXT 0x8065 +#endif + +#ifndef GL_EXT_texture3D +#define GL_EXT_texture3D +#define _ALLEGRO_GL_EXT_texture3D +#define GL_PACK_SKIP_IMAGES_EXT 0x806B +#define GL_PACK_IMAGE_HEIGHT_EXT 0x806C +#define GL_UNPACK_SKIP_IMAGES_EXT 0x806D +#define GL_UNPACK_IMAGE_HEIGHT_EXT 0x806E +#define GL_TEXTURE_3D_EXT 0x806F +#define GL_PROXY_TEXTURE_3D_EXT 0x8070 +#define GL_TEXTURE_DEPTH_EXT 0x8071 +#define GL_TEXTURE_WRAP_R_EXT 0x8072 +#define GL_MAX_3D_TEXTURE_SIZE_EXT 0x8073 +#endif + +#ifndef GL_SGIS_texture_filter4 +#define GL_SGIS_texture_filter4 +#define _ALLEGRO_GL_SGIS_texture_filter4 +#define GL_FILTER4_SGIS 0x8146 +#define GL_TEXTURE_FILTER4_SIZE_SGIS 0x8147 +#endif + +#ifndef GL_EXT_histogram +#define GL_EXT_histogram +#define _ALLEGRO_GL_EXT_histogram +#define GL_HISTOGRAM_EXT 0x8024 +#define GL_PROXY_HISTOGRAM_EXT 0x8025 +#define GL_HISTOGRAM_WIDTH_EXT 0x8026 +#define GL_HISTOGRAM_FORMAT_EXT 0x8027 +#define GL_HISTOGRAM_RED_SIZE_EXT 0x8028 +#define GL_HISTOGRAM_GREEN_SIZE_EXT 0x8029 +#define GL_HISTOGRAM_BLUE_SIZE_EXT 0x802A +#define GL_HISTOGRAM_ALPHA_SIZE_EXT 0x802B +#define GL_HISTOGRAM_LUMINANCE_SIZE_EXT 0x802C +#define GL_HISTOGRAM_SINK_EXT 0x802D +#define GL_MINMAX_EXT 0x802E +#define GL_MINMAX_FORMAT_EXT 0x802F +#define GL_MINMAX_SINK_EXT 0x8030 +#define GL_TABLE_TOO_LARGE_EXT 0x8031 +#endif + +#ifndef GL_EXT_subtexture +#define GL_EXT_subtexture +#define _ALLEGRO_GL_EXT_subtexture +#endif + +#ifndef GL_EXT_copy_texture +#define GL_EXT_copy_texture +/* NV's headers don't define EXT_copy_texture yet provide the API */ +#ifndef ALLEGRO_GL_HEADER_NV +#define _ALLEGRO_GL_EXT_copy_texture +#endif +#endif + +#ifndef GL_EXT_histogram +#define GL_EXT_histogram +#define _ALLEGRO_GL_EXT_histogram +#endif + +#ifndef GL_EXT_convolution +#define GL_EXT_convolution +#define _ALLEGRO_GL_EXT_convolution +#define GL_CONVOLUTION_1D_EXT 0x8010 +#define GL_CONVOLUTION_2D_EXT 0x8011 +#define GL_SEPARABLE_2D_EXT 0x8012 +#define GL_CONVOLUTION_BORDER_MODE_EXT 0x8013 +#define GL_CONVOLUTION_FILTER_SCALE_EXT 0x8014 +#define GL_CONVOLUTION_FILTER_BIAS_EXT 0x8015 +#define GL_REDUCE_EXT 0x8016 +#define GL_CONVOLUTION_FORMAT_EXT 0x8017 +#define GL_CONVOLUTION_WIDTH_EXT 0x8018 +#define GL_CONVOLUTION_HEIGHT_EXT 0x8019 +#define GL_MAX_CONVOLUTION_WIDTH_EXT 0x801A +#define GL_MAX_CONVOLUTION_HEIGHT_EXT 0x801B +#define GL_POST_CONVOLUTION_RED_SCALE_EXT 0x801C +#define GL_POST_CONVOLUTION_GREEN_SCALE_EXT 0x801D +#define GL_POST_CONVOLUTION_BLUE_SCALE_EXT 0x801E +#define GL_POST_CONVOLUTION_ALPHA_SCALE_EXT 0x801F +#define GL_POST_CONVOLUTION_RED_BIAS_EXT 0x8020 +#define GL_POST_CONVOLUTION_GREEN_BIAS_EXT 0x8021 +#define GL_POST_CONVOLUTION_BLUE_BIAS_EXT 0x8022 +#define GL_POST_CONVOLUTION_ALPHA_BIAS_EXT 0x8023 +#endif + +#ifndef GL_SGI_color_matrix +#define GL_SGI_color_matrix +#define _ALLEGRO_GL_SGI_color_matrix +#define GL_COLOR_MATRIX_SGI 0x80B1 +#define GL_COLOR_MATRIX_STACK_DEPTH_SGI 0x80B2 +#define GL_MAX_COLOR_MATRIX_STACK_DEPTH_SGI 0x80B3 +#define GL_POST_COLOR_MATRIX_RED_SCALE_SGI 0x80B4 +#define GL_POST_COLOR_MATRIX_GREEN_SCALE_SGI 0x80B5 +#define GL_POST_COLOR_MATRIX_BLUE_SCALE_SGI 0x80B6 +#define GL_POST_COLOR_MATRIX_ALPHA_SCALE_SGI 0x80B7 +#define GL_POST_COLOR_MATRIX_RED_BIAS_SGI 0x80B8 +#define GL_POST_COLOR_MATRIX_GREEN_BIAS_SGI 0x80B9 +#define GL_POST_COLOR_MATRIX_BLUE_BIAS_SGI 0x80BA +#define GL_POST_COLOR_MATRIX_ALPHA_BIAS_SGI 0x80BB +#endif + +#ifndef GL_SGI_color_table +#define GL_SGI_color_table +#define _ALLEGRO_GL_SGI_color_table +#define GL_COLOR_TABLE_SGI 0x80D0 +#define GL_POST_CONVOLUTION_COLOR_TABLE_SGI 0x80D1 +#define GL_POST_COLOR_MATRIX_COLOR_TABLE_SGI 0x80D2 +#define GL_PROXY_COLOR_TABLE_SGI 0x80D3 +#define GL_PROXY_POST_CONVOLUTION_COLOR_TABLE_SGI 0x80D4 +#define GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE_SGI 0x80D5 +#define GL_COLOR_TABLE_SCALE_SGI 0x80D6 +#define GL_COLOR_TABLE_BIAS_SGI 0x80D7 +#define GL_COLOR_TABLE_FORMAT_SGI 0x80D8 +#define GL_COLOR_TABLE_WIDTH_SGI 0x80D9 +#define GL_COLOR_TABLE_RED_SIZE_SGI 0x80DA +#define GL_COLOR_TABLE_GREEN_SIZE_SGI 0x80DB +#define GL_COLOR_TABLE_BLUE_SIZE_SGI 0x80DC +#define GL_COLOR_TABLE_ALPHA_SIZE_SGI 0x80DD +#define GL_COLOR_TABLE_LUMINANCE_SIZE_SGI 0x80DE +#define GL_COLOR_TABLE_INTENSITY_SIZE_SGI 0x80DF +#endif + +#ifndef GL_SGIS_pixel_texture +#define GL_SGIS_pixel_texture +#define _ALLEGRO_GL_SGIS_pixel_texture +#define GL_PIXEL_TEXTURE_SGIS 0x8353 +#define GL_PIXEL_FRAGMENT_RGB_SOURCE_SGIS 0x8354 +#define GL_PIXEL_FRAGMENT_ALPHA_SOURCE_SGIS 0x8355 +#define GL_PIXEL_GROUP_COLOR_SGIS 0x8356 +#endif + +#ifndef GL_SGIX_pixel_texture +#define GL_SGIX_pixel_texture +#define _ALLEGRO_GL_SGIX_pixel_texture +#define GL_PIXEL_TEX_GEN_SGIX 0x8139 +#define GL_PIXEL_TEX_GEN_MODE_SGIX 0x832B +#endif + +#ifndef GL_SGIS_texture4D +#define GL_SGIS_texture4D +#define _ALLEGRO_GL_SGIS_texture4D +#define GL_PACK_SKIP_VOLUMES_SGIS 0x8130 +#define GL_PACK_IMAGE_DEPTH_SGIS 0x8131 +#define GL_UNPACK_SKIP_VOLUMES_SGIS 0x8132 +#define GL_UNPACK_IMAGE_DEPTH_SGIS 0x8133 +#define GL_TEXTURE_4D_SGIS 0x8134 +#define GL_PROXY_TEXTURE_4D_SGIS 0x8135 +#define GL_TEXTURE_4DSIZE_SGIS 0x8136 +#define GL_TEXTURE_WRAP_Q_SGIS 0x8137 +#define GL_MAX_4D_TEXTURE_SIZE_SGIS 0x8138 +#define GL_TEXTURE_4D_BINDING_SGIS 0x814F +#endif + +#ifndef GL_SGI_texture_color_table +#define GL_SGI_texture_color_table +#define _ALLEGRO_GL_SGI_texture_color_table +#define GL_TEXTURE_COLOR_TABLE_SGI 0x80BC +#define GL_PROXY_TEXTURE_COLOR_TABLE_SGI 0x80BD +#endif + +#ifndef GL_EXT_cmyka +#define GL_EXT_cmyka +#define _ALLEGRO_GL_EXT_cmyka +#define GL_CMYK_EXT 0x800C +#define GL_CMYKA_EXT 0x800D +#define GL_PACK_CMYK_HINT_EXT 0x800E +#define GL_UNPACK_CMYK_HINT_EXT 0x800F +#endif + +#ifndef GL_EXT_texture_object +#define GL_EXT_texture_object +#define _ALLEGRO_GL_EXT_texture_object +#define GL_TEXTURE_PRIORITY_EXT 0x8066 +#define GL_TEXTURE_RESIDENT_EXT 0x8067 +#define GL_TEXTURE_1D_BINDING_EXT 0x8068 +#define GL_TEXTURE_2D_BINDING_EXT 0x8069 +#define GL_TEXTURE_3D_BINDING_EXT 0x806A +#endif + +#ifndef GL_SGIS_detail_texture +#define GL_SGIS_detail_texture +#define _ALLEGRO_GL_SGIS_detail_texture +#define GL_DETAIL_TEXTURE_2D_SGIS 0x8095 +#define GL_DETAIL_TEXTURE_2D_BINDING_SGIS 0x8096 +#define GL_LINEAR_DETAIL_SGIS 0x8097 +#define GL_LINEAR_DETAIL_ALPHA_SGIS 0x8098 +#define GL_LINEAR_DETAIL_COLOR_SGIS 0x8099 +#define GL_DETAIL_TEXTURE_LEVEL_SGIS 0x809A +#define GL_DETAIL_TEXTURE_MODE_SGIS 0x809B +#define GL_DETAIL_TEXTURE_FUNC_POINTS_SGIS 0x809C +#endif + +#ifndef GL_SGIS_sharpen_texture +#define GL_SGIS_sharpen_texture +#define _ALLEGRO_GL_SGIS_sharpen_texture +#define GL_LINEAR_SHARPEN_SGIS 0x80AD +#define GL_LINEAR_SHARPEN_ALPHA_SGIS 0x80AE +#define GL_LINEAR_SHARPEN_COLOR_SGIS 0x80AF +#define GL_SHARPEN_TEXTURE_FUNC_POINTS_SGIS 0x80B0 +#endif + +#ifndef GL_EXT_packed_pixels +#define GL_EXT_packed_pixels +#define _ALLEGRO_GL_EXT_packed_pixels +#define GL_UNSIGNED_BYTE_3_3_2_EXT 0x8032 +#define GL_UNSIGNED_SHORT_4_4_4_4_EXT 0x8033 +#define GL_UNSIGNED_SHORT_5_5_5_1_EXT 0x8034 +#define GL_UNSIGNED_INT_8_8_8_8_EXT 0x8035 +#define GL_UNSIGNED_INT_10_10_10_2_EXT 0x8036 +#endif + +#ifndef GL_SGIS_texture_lod +#define GL_SGIS_texture_lod +#define _ALLEGRO_GL_SGIS_texture_lod +#define GL_TEXTURE_MIN_LOD_SGIS 0x813A +#define GL_TEXTURE_MAX_LOD_SGIS 0x813B +#define GL_TEXTURE_BASE_LEVEL_SGIS 0x813C +#define GL_TEXTURE_MAX_LEVEL_SGIS 0x813D +#endif + +#ifndef GL_SGIS_multisample +#define GL_SGIS_multisample +#define _ALLEGRO_GL_SGIS_multisample +#define GL_MULTISAMPLE_SGIS 0x809D +#define GL_SAMPLE_ALPHA_TO_MASK_SGIS 0x809E +#define GL_SAMPLE_ALPHA_TO_ONE_SGIS 0x809F +#define GL_SAMPLE_MASK_SGIS 0x80A0 +#define GL_1PASS_SGIS 0x80A1 +#define GL_2PASS_0_SGIS 0x80A2 +#define GL_2PASS_1_SGIS 0x80A3 +#define GL_4PASS_0_SGIS 0x80A4 +#define GL_4PASS_1_SGIS 0x80A5 +#define GL_4PASS_2_SGIS 0x80A6 +#define GL_4PASS_3_SGIS 0x80A7 +#define GL_SAMPLE_BUFFERS_SGIS 0x80A8 +#define GL_SAMPLES_SGIS 0x80A9 +#define GL_SAMPLE_MASK_VALUE_SGIS 0x80AA +#define GL_SAMPLE_MASK_INVERT_SGIS 0x80AB +#define GL_SAMPLE_PATTERN_SGIS 0x80AC +#endif + +#ifndef GL_EXT_rescale_normal +#define GL_EXT_rescale_normal +#define _ALLEGRO_GL_EXT_rescale_normal +#define GL_RESCALE_NORMAL_EXT 0x803A +#endif + +#ifndef GL_EXT_vertex_array +#define GL_EXT_vertex_array +#define _ALLEGRO_GL_EXT_vertex_array +#define GL_VERTEX_ARRAY_EXT 0x8074 +#define GL_NORMAL_ARRAY_EXT 0x8075 +#define GL_COLOR_ARRAY_EXT 0x8076 +#define GL_INDEX_ARRAY_EXT 0x8077 +#define GL_TEXTURE_COORD_ARRAY_EXT 0x8078 +#define GL_EDGE_FLAG_ARRAY_EXT 0x8079 +#define GL_VERTEX_ARRAY_SIZE_EXT 0x807A +#define GL_VERTEX_ARRAY_TYPE_EXT 0x807B +#define GL_VERTEX_ARRAY_STRIDE_EXT 0x807C +#define GL_VERTEX_ARRAY_COUNT_EXT 0x807D +#define GL_NORMAL_ARRAY_TYPE_EXT 0x807E +#define GL_NORMAL_ARRAY_STRIDE_EXT 0x807F +#define GL_NORMAL_ARRAY_COUNT_EXT 0x8080 +#define GL_COLOR_ARRAY_SIZE_EXT 0x8081 +#define GL_COLOR_ARRAY_TYPE_EXT 0x8082 +#define GL_COLOR_ARRAY_STRIDE_EXT 0x8083 +#define GL_COLOR_ARRAY_COUNT_EXT 0x8084 +#define GL_INDEX_ARRAY_TYPE_EXT 0x8085 +#define GL_INDEX_ARRAY_STRIDE_EXT 0x8086 +#define GL_INDEX_ARRAY_COUNT_EXT 0x8087 +#define GL_TEXTURE_COORD_ARRAY_SIZE_EXT 0x8088 +#define GL_TEXTURE_COORD_ARRAY_TYPE_EXT 0x8089 +#define GL_TEXTURE_COORD_ARRAY_STRIDE_EXT 0x808A +#define GL_TEXTURE_COORD_ARRAY_COUNT_EXT 0x808B +#define GL_EDGE_FLAG_ARRAY_STRIDE_EXT 0x808C +#define GL_EDGE_FLAG_ARRAY_COUNT_EXT 0x808D +#define GL_VERTEX_ARRAY_POINTER_EXT 0x808E +#define GL_NORMAL_ARRAY_POINTER_EXT 0x808F +#define GL_COLOR_ARRAY_POINTER_EXT 0x8090 +#define GL_INDEX_ARRAY_POINTER_EXT 0x8091 +#define GL_TEXTURE_COORD_ARRAY_POINTER_EXT 0x8092 +#define GL_EDGE_FLAG_ARRAY_POINTER_EXT 0x8093 +#endif + +#ifndef GL_SGIS_generate_mipmap +#define GL_SGIS_generate_mipmap +#define _ALLEGRO_GL_SGIS_generate_mipmap +#define GL_GENERATE_MIPMAP_SGIS 0x8191 +#define GL_GENERATE_MIPMAP_HINT_SGIS 0x8192 +#endif + +#ifndef GL_SGIX_clipmap +#define GL_SGIX_clipmap +#define _ALLEGRO_GL_SGIX_clipmap +#define GL_LINEAR_CLIPMAP_LINEAR_SGIX 0x8170 +#define GL_TEXTURE_CLIPMAP_CENTER_SGIX 0x8171 +#define GL_TEXTURE_CLIPMAP_FRAME_SGIX 0x8172 +#define GL_TEXTURE_CLIPMAP_OFFSET_SGIX 0x8173 +#define GL_TEXTURE_CLIPMAP_VIRTUAL_DEPTH_SGIX 0x8174 +#define GL_TEXTURE_CLIPMAP_LOD_OFFSET_SGIX 0x8175 +#define GL_TEXTURE_CLIPMAP_DEPTH_SGIX 0x8176 +#define GL_MAX_CLIPMAP_DEPTH_SGIX 0x8177 +#define GL_MAX_CLIPMAP_VIRTUAL_DEPTH_SGIX 0x8178 +#define GL_NEAREST_CLIPMAP_NEAREST_SGIX 0x844D +#define GL_NEAREST_CLIPMAP_LINEAR_SGIX 0x844E +#define GL_LINEAR_CLIPMAP_NEAREST_SGIX 0x844F +#endif + +#ifndef GL_SGIX_shadow +#define GL_SGIX_shadow +#define _ALLEGRO_GL_SGIX_shadow +#define GL_TEXTURE_COMPARE_SGIX 0x819A +#define GL_TEXTURE_COMPARE_OPERATOR_SGIX 0x819B +#define GL_TEXTURE_LEQUAL_R_SGIX 0x819C +#define GL_TEXTURE_GEQUAL_R_SGIX 0x819D +#endif + +#ifndef GL_SGIS_texture_edge_clamp +#define GL_SGIS_texture_edge_clamp +#define _ALLEGRO_GL_SGIS_texture_edge_clamp +#define GL_CLAMP_TO_EDGE_SGIS 0x812F +#endif + +#ifndef GL_EXT_blend_minmax +#define GL_EXT_blend_minmax +#define _ALLEGRO_GL_EXT_blend_minmax +#define GL_FUNC_ADD_EXT 0x8006 +#define GL_MIN_EXT 0x8007 +#define GL_MAX_EXT 0x8008 +#define GL_BLEND_EQUATION_EXT 0x8009 +#endif + +#ifndef GL_EXT_blend_subtract +#define GL_EXT_blend_subtract +#define _ALLEGRO_GL_EXT_blend_subtract +#define GL_FUNC_SUBTRACT_EXT 0x800A +#define GL_FUNC_REVERSE_SUBTRACT_EXT 0x800B +#endif + +#ifndef GL_SGIX_interlace +#define GL_SGIX_interlace +#define _ALLEGRO_GL_SGIX_interlace +#define GL_INTERLACE_SGIX 0x8094 +#endif + +#ifndef GL_SGIX_pixel_tiles +#define GL_SGIX_pixel_tiles +#define _ALLEGRO_GL_SGIX_pixel_tiles +#define GL_PIXEL_TILE_BEST_ALIGNMENT_SGIX 0x813E +#define GL_PIXEL_TILE_CACHE_INCREMENT_SGIX 0x813F +#define GL_PIXEL_TILE_WIDTH_SGIX 0x8140 +#define GL_PIXEL_TILE_HEIGHT_SGIX 0x8141 +#define GL_PIXEL_TILE_GRID_WIDTH_SGIX 0x8142 +#define GL_PIXEL_TILE_GRID_HEIGHT_SGIX 0x8143 +#define GL_PIXEL_TILE_GRID_DEPTH_SGIX 0x8144 +#define GL_PIXEL_TILE_CACHE_SIZE_SGIX 0x8145 +#endif + +#ifndef GL_SGIS_texture_select +#define GL_SGIS_texture_select +#define _ALLEGRO_GL_SGIS_texture_select +#define GL_DUAL_ALPHA4_SGIS 0x8110 +#define GL_DUAL_ALPHA8_SGIS 0x8111 +#define GL_DUAL_ALPHA12_SGIS 0x8112 +#define GL_DUAL_ALPHA16_SGIS 0x8113 +#define GL_DUAL_LUMINANCE4_SGIS 0x8114 +#define GL_DUAL_LUMINANCE8_SGIS 0x8115 +#define GL_DUAL_LUMINANCE12_SGIS 0x8116 +#define GL_DUAL_LUMINANCE16_SGIS 0x8117 +#define GL_DUAL_INTENSITY4_SGIS 0x8118 +#define GL_DUAL_INTENSITY8_SGIS 0x8119 +#define GL_DUAL_INTENSITY12_SGIS 0x811A +#define GL_DUAL_INTENSITY16_SGIS 0x811B +#define GL_DUAL_LUMINANCE_ALPHA4_SGIS 0x811C +#define GL_DUAL_LUMINANCE_ALPHA8_SGIS 0x811D +#define GL_QUAD_ALPHA4_SGIS 0x811E +#define GL_QUAD_ALPHA8_SGIS 0x811F +#define GL_QUAD_LUMINANCE4_SGIS 0x8120 +#define GL_QUAD_LUMINANCE8_SGIS 0x8121 +#define GL_QUAD_INTENSITY4_SGIS 0x8122 +#define GL_QUAD_INTENSITY8_SGIS 0x8123 +#define GL_DUAL_TEXTURE_SELECT_SGIS 0x8124 +#define GL_QUAD_TEXTURE_SELECT_SGIS 0x8125 +#endif + +#ifndef GL_SGIX_sprite +#define GL_SGIX_sprite +#define _ALLEGRO_GL_SGIX_sprite +#define GL_SPRITE_SGIX 0x8148 +#define GL_SPRITE_MODE_SGIX 0x8149 +#define GL_SPRITE_AXIS_SGIX 0x814A +#define GL_SPRITE_TRANSLATION_SGIX 0x814B +#define GL_SPRITE_AXIAL_SGIX 0x814C +#define GL_SPRITE_OBJECT_ALIGNED_SGIX 0x814D +#define GL_SPRITE_EYE_ALIGNED_SGIX 0x814E +#endif + +#ifndef GL_SGIX_texture_multi_buffer +#define GL_SGIX_texture_multi_buffer +#define _ALLEGRO_GL_SGIX_texture_multi_buffer +#define GL_TEXTURE_MULTI_BUFFER_HINT_SGIX 0x812E +#endif + +#ifndef GL_EXT_point_parameters +#define GL_EXT_point_parameters +#define _ALLEGRO_GL_EXT_point_parameters +#define GL_POINT_SIZE_MIN_EXT 0x8126 +#define GL_POINT_SIZE_MAX_EXT 0x8127 +#define GL_POINT_FADE_THRESHOLD_SIZE_EXT 0x8128 +#define GL_DISTANCE_ATTENUATION_EXT 0x8129 +#endif + +#ifndef GL_SGIS_point_parameters +#define GL_SGIS_point_parameters +#define _ALLEGRO_GL_SGIS_point_parameters +#define GL_POINT_SIZE_MIN_SGIS 0x8126 +#define GL_POINT_SIZE_MAX_SGIS 0x8127 +#define GL_POINT_FADE_THRESHOLD_SIZE_SGIS 0x8128 +#define GL_DISTANCE_ATTENUATION_SGIS 0x8129 +#endif + +#ifndef GL_SGIX_instruments +#define GL_SGIX_instruments +#define _ALLEGRO_GL_SGIX_instruments +#define GL_INSTRUMENT_BUFFER_POINTER_SGIX 0x8180 +#define GL_INSTRUMENT_MEASUREMENTS_SGIX 0x8181 +#endif + +#ifndef GL_SGIX_texture_scale_bias +#define GL_SGIX_texture_scale_bias +#define _ALLEGRO_GL_SGIX_texture_scale_bias +#define GL_POST_TEXTURE_FILTER_BIAS_SGIX 0x8179 +#define GL_POST_TEXTURE_FILTER_SCALE_SGIX 0x817A +#define GL_POST_TEXTURE_FILTER_BIAS_RANGE_SGIX 0x817B +#define GL_POST_TEXTURE_FILTER_SCALE_RANGE_SGIX 0x817C +#endif + +#ifndef GL_SGIX_framezoom +#define GL_SGIX_framezoom +#define _ALLEGRO_GL_SGIX_framezoom +#define GL_FRAMEZOOM_SGIX 0x818B +#define GL_FRAMEZOOM_FACTOR_SGIX 0x818C +#define GL_MAX_FRAMEZOOM_FACTOR_SGIX 0x818D +#endif + +#ifndef GL_FfdMaskSGIX +#define GL_FfdMaskSGIX +#define _ALLEGRO_GL_FfdMaskSGIX +#define GL_TEXTURE_DEFORMATION_BIT_SGIX 0x00000001 +#define GL_GEOMETRY_DEFORMATION_BIT_SGIX 0x00000002 +#endif + +#ifndef GL_SGIX_tag_sample_buffer +#define GL_SGIX_tag_sample_buffer +#define _ALLEGRO_GL_SGIX_tag_sample_buffer +#endif + +#ifndef GL_SGIX_polynomial_ffd +#define GL_SGIX_polynomial_ffd +#define _ALLEGRO_GL_SGIX_polynomial_ffd +#define GL_GEOMETRY_DEFORMATION_SGIX 0x8194 +#define GL_TEXTURE_DEFORMATION_SGIX 0x8195 +#define GL_DEFORMATIONS_MASK_SGIX 0x8196 +#define GL_MAX_DEFORMATION_ORDER_SGIX 0x8197 +#endif + +#ifndef GL_SGIX_reference_plane +#define GL_SGIX_reference_plane +#define _ALLEGRO_GL_SGIX_reference_plane +#define GL_REFERENCE_PLANE_SGIX 0x817D +#define GL_REFERENCE_PLANE_EQUATION_SGIX 0x817E +#endif + +#ifndef GL_SGIX_depth_texture +#define GL_SGIX_depth_texture +#define _ALLEGRO_GL_SGIX_depth_texture +#define GL_DEPTH_COMPONENT16_SGIX 0x81A5 +#define GL_DEPTH_COMPONENT24_SGIX 0x81A6 +#define GL_DEPTH_COMPONENT32_SGIX 0x81A7 +#endif + +#ifndef GL_SGIX_flush_raster +#define GL_SGIX_flush_raster +#define _ALLEGRO_GL_SGIX_flush_raster +#endif + +#ifndef GL_SGIS_fog_function +#define GL_SGIS_fog_function +#define _ALLEGRO_GL_SGIS_fog_function +#define GL_FOG_FUNC_SGIS 0x812A +#define GL_FOG_FUNC_POINTS_SGIS 0x812B +#define GL_MAX_FOG_FUNC_POINTS_SGIS 0x812C +#endif + +#ifndef GL_SGIX_fog_offset +#define GL_SGIX_fog_offset +#define _ALLEGRO_GL_SGIX_fog_offset +#define GL_FOG_OFFSET_SGIX 0x8198 +#define GL_FOG_OFFSET_VALUE_SGIX 0x8199 +#endif + +#ifndef GL_HP_image_transform +#define GL_HP_image_transform +#define _ALLEGRO_GL_HP_image_transform +#define GL_IMAGE_SCALE_X_HP 0x8155 +#define GL_IMAGE_SCALE_Y_HP 0x8156 +#define GL_IMAGE_TRANSLATE_X_HP 0x8157 +#define GL_IMAGE_TRANSLATE_Y_HP 0x8158 +#define GL_IMAGE_ROTATE_ANGLE_HP 0x8159 +#define GL_IMAGE_ROTATE_ORIGIN_X_HP 0x815A +#define GL_IMAGE_ROTATE_ORIGIN_Y_HP 0x815B +#define GL_IMAGE_MAG_FILTER_HP 0x815C +#define GL_IMAGE_MIN_FILTER_HP 0x815D +#define GL_IMAGE_CUBIC_WEIGHT_HP 0x815E +#define GL_CUBIC_HP 0x815F +#define GL_AVERAGE_HP 0x8160 +#define GL_IMAGE_TRANSFORM_2D_HP 0x8161 +#define GL_POST_IMAGE_TRANSFORM_COLOR_TABLE_HP 0x8162 +#define GL_PROXY_POST_IMAGE_TRANSFORM_COLOR_TABLE_HP 0x8163 +#endif + +#ifndef GL_HP_convolution_border_modes +#define GL_HP_convolution_border_modes +#define _ALLEGRO_GL_HP_convolution_border_modes +#define GL_IGNORE_BORDER_HP 0x8150 +#define GL_CONSTANT_BORDER_HP 0x8151 +#define GL_REPLICATE_BORDER_HP 0x8153 +#define GL_CONVOLUTION_BORDER_COLOR_HP 0x8154 +#endif + +#ifndef GL_SGIX_texture_add_env +#define GL_SGIX_texture_add_env +#define _ALLEGRO_GL_SGIX_texture_add_env +#define GL_TEXTURE_ENV_BIAS_SGIX 0x80BE +#endif + +#ifndef GL_EXT_color_subtable +#define GL_EXT_color_subtable +#define _ALLEGRO_GL_EXT_color_subtable +#endif + +#ifndef GL_PGI_vertex_hints +#define GL_PGI_vertex_hints +#define _ALLEGRO_GL_PGI_vertex_hints +#define GL_VERTEX_DATA_HINT_PGI 0x1A22A +#define GL_VERTEX_CONSISTENT_HINT_PGI 0x1A22B +#define GL_MATERIAL_SIDE_HINT_PGI 0x1A22C +#define GL_MAX_VERTEX_HINT_PGI 0x1A22D +#define GL_COLOR3_BIT_PGI 0x00010000 +#define GL_COLOR4_BIT_PGI 0x00020000 +#define GL_EDGEFLAG_BIT_PGI 0x00040000 +#define GL_INDEX_BIT_PGI 0x00080000 +#define GL_MAT_AMBIENT_BIT_PGI 0x00100000 +#define GL_MAT_AMBIENT_AND_DIFFUSE_BIT_PGI 0x00200000 +#define GL_MAT_DIFFUSE_BIT_PGI 0x00400000 +#define GL_MAT_EMISSION_BIT_PGI 0x00800000 +#define GL_MAT_COLOR_INDEXES_BIT_PGI 0x01000000 +#define GL_MAT_SHININESS_BIT_PGI 0x02000000 +#define GL_MAT_SPECULAR_BIT_PGI 0x04000000 +#define GL_NORMAL_BIT_PGI 0x08000000 +#define GL_TEXCOORD1_BIT_PGI 0x10000000 +#define GL_TEXCOORD2_BIT_PGI 0x20000000 +#define GL_TEXCOORD3_BIT_PGI 0x40000000 +#define GL_TEXCOORD4_BIT_PGI 0x80000000 +#define GL_VERTEX23_BIT_PGI 0x00000004 +#define GL_VERTEX4_BIT_PGI 0x00000008 +#endif + +#ifndef GL_PGI_misc_hints +#define GL_PGI_misc_hints +#define _ALLEGRO_GL_PGI_misc_hints +#define GL_PREFER_DOUBLEBUFFER_HINT_PGI 0x1A1F8 +#define GL_CONSERVE_MEMORY_HINT_PGI 0x1A1FD +#define GL_RECLAIM_MEMORY_HINT_PGI 0x1A1FE +#define GL_NATIVE_GRAPHICS_HANDLE_PGI 0x1A202 +#define GL_NATIVE_GRAPHICS_BEGIN_HINT_PGI 0x1A203 +#define GL_NATIVE_GRAPHICS_END_HINT_PGI 0x1A204 +#define GL_ALWAYS_FAST_HINT_PGI 0x1A20C +#define GL_ALWAYS_SOFT_HINT_PGI 0x1A20D +#define GL_ALLOW_DRAW_OBJ_HINT_PGI 0x1A20E +#define GL_ALLOW_DRAW_WIN_HINT_PGI 0x1A20F +#define GL_ALLOW_DRAW_FRG_HINT_PGI 0x1A210 +#define GL_ALLOW_DRAW_MEM_HINT_PGI 0x1A211 +#define GL_STRICT_DEPTHFUNC_HINT_PGI 0x1A216 +#define GL_STRICT_LIGHTING_HINT_PGI 0x1A217 +#define GL_STRICT_SCISSOR_HINT_PGI 0x1A218 +#define GL_FULL_STIPPLE_HINT_PGI 0x1A219 +#define GL_CLIP_NEAR_HINT_PGI 0x1A220 +#define GL_CLIP_FAR_HINT_PGI 0x1A221 +#define GL_WIDE_LINE_HINT_PGI 0x1A222 +#define GL_BACK_NORMALS_HINT_PGI 0x1A223 +#endif + +#ifndef GL_EXT_paletted_texture +#define GL_EXT_paletted_texture +#define _ALLEGRO_GL_EXT_paletted_texture +#define GL_COLOR_INDEX1_EXT 0x80E2 +#define GL_COLOR_INDEX2_EXT 0x80E3 +#define GL_COLOR_INDEX4_EXT 0x80E4 +#define GL_COLOR_INDEX8_EXT 0x80E5 +#define GL_COLOR_INDEX12_EXT 0x80E6 +#define GL_COLOR_INDEX16_EXT 0x80E7 +#define GL_TEXTURE_INDEX_SIZE_EXT 0x80ED +#endif + +#ifndef GL_EXT_clip_volume_hint +#define GL_EXT_clip_volume_hint +#define _ALLEGRO_GL_EXT_clip_volume_hint +#define GL_CLIP_VOLUME_CLIPPING_HINT_EXT 0x80F0 +#endif + +#ifndef GL_SGIX_list_priority +#define GL_SGIX_list_priority +#define _ALLEGRO_GL_SGIX_list_priority +#define GL_LIST_PRIORITY_SGIX 0x8182 +#endif + +#ifndef GL_SGIX_ir_instrument1 +#define GL_SGIX_ir_instrument1 +#define _ALLEGRO_GL_SGIX_ir_instrument1 +#define GL_IR_INSTRUMENT1_SGIX 0x817F +#endif + +#ifndef GL_SGIX_calligraphic_fragment +#define GL_SGIX_calligraphic_fragment +#define _ALLEGRO_GL_SGIX_calligraphic_fragment +#define GL_CALLIGRAPHIC_FRAGMENT_SGIX 0x8183 +#endif + +#ifndef GL_SGIX_texture_lod_bias +#define GL_SGIX_texture_lod_bias +#define _ALLEGRO_GL_SGIX_texture_lod_bias +#define GL_TEXTURE_LOD_BIAS_S_SGIX 0x818E +#define GL_TEXTURE_LOD_BIAS_T_SGIX 0x818F +#define GL_TEXTURE_LOD_BIAS_R_SGIX 0x8190 +#endif + +#ifndef GL_SGIX_shadow_ambient +#define GL_SGIX_shadow_ambient +#define _ALLEGRO_GL_SGIX_shadow_ambient +#define GL_SHADOW_AMBIENT_SGIX 0x80BF +#endif + +#ifndef GL_EXT_index_material +#define GL_EXT_index_material +#define _ALLEGRO_GL_EXT_index_material +#define GL_INDEX_MATERIAL_EXT 0x81B8 +#define GL_INDEX_MATERIAL_PARAMETER_EXT 0x81B9 +#define GL_INDEX_MATERIAL_FACE_EXT 0x81BA +#endif + +#ifndef GL_EXT_index_func +#define GL_EXT_index_func +#define _ALLEGRO_GL_EXT_index_func +#define GL_INDEX_TEST_EXT 0x81B5 +#define GL_INDEX_TEST_FUNC_EXT 0x81B6 +#define GL_INDEX_TEST_REF_EXT 0x81B7 +#endif + +#ifndef GL_EXT_index_array_formats +#define GL_EXT_index_array_formats +#define _ALLEGRO_GL_EXT_index_array_formats +#define GL_IUI_V2F_EXT 0x81AD +#define GL_IUI_V3F_EXT 0x81AE +#define GL_IUI_N3F_V2F_EXT 0x81AF +#define GL_IUI_N3F_V3F_EXT 0x81B0 +#define GL_T2F_IUI_V2F_EXT 0x81B1 +#define GL_T2F_IUI_V3F_EXT 0x81B2 +#define GL_T2F_IUI_N3F_V2F_EXT 0x81B3 +#define GL_T2F_IUI_N3F_V3F_EXT 0x81B4 +#endif + +#ifndef GL_EXT_compiled_vertex_array +#define GL_EXT_compiled_vertex_array +#define _ALLEGRO_GL_EXT_compiled_vertex_array +#define GL_ARRAY_ELEMENT_LOCK_FIRST_EXT 0x81A8 +#define GL_ARRAY_ELEMENT_LOCK_COUNT_EXT 0x81A9 +#endif + +#ifndef GL_EXT_cull_vertex +#define GL_EXT_cull_vertex +#define _ALLEGRO_GL_EXT_cull_vertex +#define GL_CULL_VERTEX_EXT 0x81AA +#define GL_CULL_VERTEX_EYE_POSITION_EXT 0x81AB +#define GL_CULL_VERTEX_OBJECT_POSITION_EXT 0x81AC +#endif + +#ifndef GL_SGIX_ycrcb +#define GL_SGIX_ycrcb +#define _ALLEGRO_GL_SGIX_ycrcb +#define GL_YCRCB_422_SGIX 0x81BB +#define GL_YCRCB_444_SGIX 0x81BC +#endif + +#ifndef GL_SGIX_fragment_lighting +#define GL_SGIX_fragment_lighting +#define _ALLEGRO_GL_SGIX_fragment_lighting +#define GL_FRAGMENT_LIGHTING_SGIX 0x8400 +#define GL_FRAGMENT_COLOR_MATERIAL_SGIX 0x8401 +#define GL_FRAGMENT_COLOR_MATERIAL_FACE_SGIX 0x8402 +#define GL_FRAGMENT_COLOR_MATERIAL_PARAMETER_SGIX 0x8403 +#define GL_MAX_FRAGMENT_LIGHTS_SGIX 0x8404 +#define GL_MAX_ACTIVE_LIGHTS_SGIX 0x8405 +#define GL_CURRENT_RASTER_NORMAL_SGIX 0x8406 +#define GL_LIGHT_ENV_MODE_SGIX 0x8407 +#define GL_FRAGMENT_LIGHT_MODEL_LOCAL_VIEWER_SGIX 0x8408 +#define GL_FRAGMENT_LIGHT_MODEL_TWO_SIDE_SGIX 0x8409 +#define GL_FRAGMENT_LIGHT_MODEL_AMBIENT_SGIX 0x840A +#define GL_FRAGMENT_LIGHT_MODEL_NORMAL_INTERPOLATION_SGIX 0x840B +#define GL_FRAGMENT_LIGHT0_SGIX 0x840C +#define GL_FRAGMENT_LIGHT1_SGIX 0x840D +#define GL_FRAGMENT_LIGHT2_SGIX 0x840E +#define GL_FRAGMENT_LIGHT3_SGIX 0x840F +#define GL_FRAGMENT_LIGHT4_SGIX 0x8410 +#define GL_FRAGMENT_LIGHT5_SGIX 0x8411 +#define GL_FRAGMENT_LIGHT6_SGIX 0x8412 +#define GL_FRAGMENT_LIGHT7_SGIX 0x8413 +#endif + +#ifndef GL_IBM_rasterpos_clip +#define GL_IBM_rasterpos_clip +#define _ALLEGRO_GL_IBM_rasterpos_clip +#define GL_RASTER_POSITION_UNCLIPPED_IBM 0x19262 +#endif + +#ifndef GL_HP_texture_lighting +#define GL_HP_texture_lighting +#define _ALLEGRO_GL_HP_texture_lighting +#define GL_TEXTURE_LIGHTING_MODE_HP 0x8167 +#define GL_TEXTURE_POST_SPECULAR_HP 0x8168 +#define GL_TEXTURE_PRE_SPECULAR_HP 0x8169 +#endif + +#ifndef GL_EXT_draw_range_elements +#define GL_EXT_draw_range_elements +#define _ALLEGRO_GL_EXT_draw_range_elements +#define GL_MAX_ELEMENTS_VERTICES_EXT 0x80E8 +#define GL_MAX_ELEMENTS_INDICES_EXT 0x80E9 +#endif + +#ifndef GL_WIN_phong_shading +#define GL_WIN_phong_shading +#define _ALLEGRO_GL_WIN_phong_shading +#define GL_PHONG_WIN 0x80EA +#define GL_PHONG_HINT_WIN 0x80EB +#endif + +#ifndef GL_WIN_specular_fog +#define GL_WIN_specular_fog +#define _ALLEGRO_GL_WIN_specular_fog +#define GL_FOG_SPECULAR_TEXTURE_WIN 0x80EC +#endif + +#ifndef GL_EXT_light_texture +#define GL_EXT_light_texture +#define _ALLEGRO_GL_EXT_light_texture +#define GL_FRAGMENT_MATERIAL_EXT 0x8349 +#define GL_FRAGMENT_NORMAL_EXT 0x834A +#define GL_FRAGMENT_COLOR_EXT 0x834C +#define GL_ATTENUATION_EXT 0x834D +#define GL_SHADOW_ATTENUATION_EXT 0x834E +#define GL_TEXTURE_APPLICATION_MODE_EXT 0x834F +#define GL_TEXTURE_LIGHT_EXT 0x8350 +#define GL_TEXTURE_MATERIAL_FACE_EXT 0x8351 +#define GL_TEXTURE_MATERIAL_PARAMETER_EXT 0x8352 +#ifndef GL_FRAGMENT_DEPTH_EXT +#define GL_FRAGMENT_DEPTH_EXT 0x8452 +#endif +#endif + +#ifndef GL_SGIX_blend_alpha_minmax +#define GL_SGIX_blend_alpha_minmax +#define _ALLEGRO_GL_SGIX_blend_alpha_minmax +#define GL_ALPHA_MIN_SGIX 0x8320 +#define GL_ALPHA_MAX_SGIX 0x8321 +#endif + +#ifndef GL_SGIX_impact_pixel_texture +#define GL_SGIX_impact_pixel_texture +#define _ALLEGRO_GL_SGIX_impact_pixel_texture +#define GL_PIXEL_TEX_GEN_Q_CEILING_SGIX 0x8184 +#define GL_PIXEL_TEX_GEN_Q_ROUND_SGIX 0x8185 +#define GL_PIXEL_TEX_GEN_Q_FLOOR_SGIX 0x8186 +#define GL_PIXEL_TEX_GEN_ALPHA_REPLACE_SGIX 0x8187 +#define GL_PIXEL_TEX_GEN_ALPHA_NO_REPLACE_SGIX 0x8188 +#define GL_PIXEL_TEX_GEN_ALPHA_LS_SGIX 0x8189 +#define GL_PIXEL_TEX_GEN_ALPHA_MS_SGIX 0x818A +#endif + +#ifndef GL_EXT_bgra +#define GL_EXT_bgra +#define _ALLEGRO_GL_EXT_bgra +#define GL_BGR_EXT 0x80E0 +#define GL_BGRA_EXT 0x80E1 +#endif + +#ifndef GL_SGIX_async +#define GL_SGIX_async +#define _ALLEGRO_GL_SGIX_async +#define GL_ASYNC_MARKER_SGIX 0x8329 +#endif + +#ifndef GL_SGIX_async_pixel +#define GL_SGIX_async_pixel +#define _ALLEGRO_GL_SGIX_async_pixel +#define GL_ASYNC_TEX_IMAGE_SGIX 0x835C +#define GL_ASYNC_DRAW_PIXELS_SGIX 0x835D +#define GL_ASYNC_READ_PIXELS_SGIX 0x835E +#define GL_MAX_ASYNC_TEX_IMAGE_SGIX 0x835F +#define GL_MAX_ASYNC_DRAW_PIXELS_SGIX 0x8360 +#define GL_MAX_ASYNC_READ_PIXELS_SGIX 0x8361 +#endif + +#ifndef GL_SGIX_async_histogram +#define GL_SGIX_async_histogram +#define _ALLEGRO_GL_SGIX_async_histogram +#define GL_ASYNC_HISTOGRAM_SGIX 0x832C +#define GL_MAX_ASYNC_HISTOGRAM_SGIX 0x832D +#endif + +#ifndef GL_INTEL_parallel_arrays +#define GL_INTEL_parallel_arrays +#define _ALLEGRO_GL_INTEL_parallel_arrays +#define GL_PARALLEL_ARRAYS_INTEL 0x83F4 +#define GL_VERTEX_ARRAY_PARALLEL_POINTERS_INTEL 0x83F5 +#define GL_NORMAL_ARRAY_PARALLEL_POINTERS_INTEL 0x83F6 +#define GL_COLOR_ARRAY_PARALLEL_POINTERS_INTEL 0x83F7 +#define GL_TEXTURE_COORD_ARRAY_PARALLEL_POINTERS_INTEL 0x83F8 +#endif + +#ifndef GL_HP_occlusion_test +#define GL_HP_occlusion_test +#define _ALLEGRO_GL_HP_occlusion_test +#define GL_OCCLUSION_TEST_HP 0x8165 +#define GL_OCCLUSION_TEST_RESULT_HP 0x8166 +#endif + +#ifndef GL_EXT_pixel_transform +#define GL_EXT_pixel_transform +#define _ALLEGRO_GL_EXT_pixel_transform +#define GL_PIXEL_TRANSFORM_2D_EXT 0x8330 +#define GL_PIXEL_MAG_FILTER_EXT 0x8331 +#define GL_PIXEL_MIN_FILTER_EXT 0x8332 +#define GL_PIXEL_CUBIC_WEIGHT_EXT 0x8333 +#define GL_CUBIC_EXT 0x8334 +#define GL_AVERAGE_EXT 0x8335 +#define GL_PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT 0x8336 +#define GL_MAX_PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT 0x8337 +#define GL_PIXEL_TRANSFORM_2D_MATRIX_EXT 0x8338 +#endif + +#ifndef GL_EXT_shared_texture_palette +#define GL_EXT_shared_texture_palette +#define _ALLEGRO_GL_EXT_shared_texture_palette +#define GL_SHARED_TEXTURE_PALETTE_EXT 0x81FB +#endif + +#ifndef GL_EXT_separate_specular_color +#define GL_EXT_separate_specular_color +#define _ALLEGRO_GL_EXT_separate_specular_color +#define GL_LIGHT_MODEL_COLOR_CONTROL_EXT 0x81F8 +#define GL_SINGLE_COLOR_EXT 0x81F9 +#define GL_SEPARATE_SPECULAR_COLOR_EXT 0x81FA +#endif + +#ifndef GL_EXT_secondary_color +#define GL_EXT_secondary_color +#define _ALLEGRO_GL_EXT_secondary_color +#define GL_COLOR_SUM_EXT 0x8458 +#define GL_CURRENT_SECONDARY_COLOR_EXT 0x8459 +#define GL_SECONDARY_COLOR_ARRAY_SIZE_EXT 0x845A +#define GL_SECONDARY_COLOR_ARRAY_TYPE_EXT 0x845B +#define GL_SECONDARY_COLOR_ARRAY_STRIDE_EXT 0x845C +#define GL_SECONDARY_COLOR_ARRAY_POINTER_EXT 0x845D +#define GL_SECONDARY_COLOR_ARRAY_EXT 0x845E +#endif + +#ifndef GL_EXT_texture_perturb_normal +#define GL_EXT_texture_perturb_normal +#define _ALLEGRO_GL_EXT_texture_perturb_normal +#define GL_PERTURB_EXT 0x85AE +#define GL_TEXTURE_NORMAL_EXT 0x85AF +#endif + +#ifndef GL_EXT_multi_draw_arrays +#define GL_EXT_multi_draw_arrays +#define _ALLEGRO_GL_EXT_multi_draw_arrays +#endif + +#ifndef GL_EXT_fog_coord +#define GL_EXT_fog_coord +#define _ALLEGRO_GL_EXT_fog_coord +#define GL_FOG_COORDINATE_SOURCE_EXT 0x8450 +#define GL_FOG_COORDINATE_EXT 0x8451 +#define GL_FRAGMENT_DEPTH_EXT 0x8452 +#define GL_CURRENT_FOG_COORDINATE_EXT 0x8453 +#define GL_FOG_COORDINATE_ARRAY_TYPE_EXT 0x8454 +#define GL_FOG_COORDINATE_ARRAY_STRIDE_EXT 0x8455 +#define GL_FOG_COORDINATE_ARRAY_POINTER_EXT 0x8456 +#define GL_FOG_COORDINATE_ARRAY_EXT 0x8457 +#endif + +#ifndef GL_REND_screen_coordinates +#define GL_REND_screen_coordinates +#define _ALLEGRO_GL_REND_screen_coordinates +#define GL_SCREEN_COORDINATES_REND 0x8490 +#define GL_INVERTED_SCREEN_W_REND 0x8491 +#endif + +#ifndef GL_EXT_coordinate_frame +#define GL_EXT_coordinate_frame +#define _ALLEGRO_GL_EXT_coordinate_frame +#define GL_TANGENT_ARRAY_EXT 0x8439 +#define GL_BINORMAL_ARRAY_EXT 0x843A +#define GL_CURRENT_TANGENT_EXT 0x843B +#define GL_CURRENT_BINORMAL_EXT 0x843C +#define GL_TANGENT_ARRAY_TYPE_EXT 0x843E +#define GL_TANGENT_ARRAY_STRIDE_EXT 0x843F +#define GL_BINORMAL_ARRAY_TYPE_EXT 0x8440 +#define GL_BINORMAL_ARRAY_STRIDE_EXT 0x8441 +#define GL_TANGENT_ARRAY_POINTER_EXT 0x8442 +#define GL_BINORMAL_ARRAY_POINTER_EXT 0x8443 +#define GL_MAP1_TANGENT_EXT 0x8444 +#define GL_MAP2_TANGENT_EXT 0x8445 +#define GL_MAP1_BINORMAL_EXT 0x8446 +#define GL_MAP2_BINORMAL_EXT 0x8447 +#endif + +#ifndef GL_EXT_texture_env_combine +#define GL_EXT_texture_env_combine +#define _ALLEGRO_GL_EXT_texture_env_combine +#define GL_COMBINE_EXT 0x8570 +#define GL_COMBINE_RGB_EXT 0x8571 +#define GL_COMBINE_ALPHA_EXT 0x8572 +#define GL_RGB_SCALE_EXT 0x8573 +#define GL_ADD_SIGNED_EXT 0x8574 +#define GL_INTERPOLATE_EXT 0x8575 +#define GL_CONSTANT_EXT 0x8576 +#define GL_PRIMARY_COLOR_EXT 0x8577 +#define GL_PREVIOUS_EXT 0x8578 +#define GL_SOURCE0_RGB_EXT 0x8580 +#define GL_SOURCE1_RGB_EXT 0x8581 +#define GL_SOURCE2_RGB_EXT 0x8582 +#define GL_SOURCE0_ALPHA_EXT 0x8588 +#define GL_SOURCE1_ALPHA_EXT 0x8589 +#define GL_SOURCE2_ALPHA_EXT 0x858A +#define GL_OPERAND0_RGB_EXT 0x8590 +#define GL_OPERAND1_RGB_EXT 0x8591 +#define GL_OPERAND2_RGB_EXT 0x8592 +#define GL_OPERAND0_ALPHA_EXT 0x8598 +#define GL_OPERAND1_ALPHA_EXT 0x8599 +#define GL_OPERAND2_ALPHA_EXT 0x859A +#endif + +#ifndef GL_APPLE_specular_vector +#define GL_APPLE_specular_vector +#define _ALLEGRO_GL_APPLE_specular_vector +#define GL_LIGHT_MODEL_SPECULAR_VECTOR_APPLE 0x85B0 +#endif + +#ifndef GL_APPLE_transform_hint +#define GL_APPLE_transform_hint +#define _ALLEGRO_GL_APPLE_transform_hint +#define GL_TRANSFORM_HINT_APPLE 0x85B1 +#endif + +#ifndef GL_SGIX_fog_scale +#define GL_SGIX_fog_scale +#define _ALLEGRO_GL_SGIX_fog_scale +#define GL_FOG_SCALE_SGIX 0x81FC +#define GL_FOG_SCALE_VALUE_SGIX 0x81FD +#endif + +#ifndef GL_SUNX_constant_data +#define GL_SUNX_constant_data +#define _ALLEGRO_GL_SUNX_constant_data +#define GL_UNPACK_CONSTANT_DATA_SUNX 0x81D5 +#define GL_TEXTURE_CONSTANT_DATA_SUNX 0x81D6 +#endif + +#ifndef GL_SUN_global_alpha +#define GL_SUN_global_alpha +#define _ALLEGRO_GL_SUN_global_alpha +#define GL_GLOBAL_ALPHA_SUN 0x81D9 +#define GL_GLOBAL_ALPHA_FACTOR_SUN 0x81DA +#endif + +#ifndef GL_SUN_triangle_list +#define GL_SUN_triangle_list +#define _ALLEGRO_GL_SUN_triangle_list +#define GL_RESTART_SUN 0x0001 +#define GL_REPLACE_MIDDLE_SUN 0x0002 +#define GL_REPLACE_OLDEST_SUN 0x0003 +#define GL_TRIANGLE_LIST_SUN 0x81D7 +#define GL_REPLACEMENT_CODE_SUN 0x81D8 +#define GL_REPLACEMENT_CODE_ARRAY_SUN 0x85C0 +#define GL_REPLACEMENT_CODE_ARRAY_TYPE_SUN 0x85C1 +#define GL_REPLACEMENT_CODE_ARRAY_STRIDE_SUN 0x85C2 +#define GL_REPLACEMENT_CODE_ARRAY_POINTER_SUN 0x85C3 +#define GL_R1UI_V3F_SUN 0x85C4 +#define GL_R1UI_C4UB_V3F_SUN 0x85C5 +#define GL_R1UI_C3F_V3F_SUN 0x85C6 +#define GL_R1UI_N3F_V3F_SUN 0x85C7 +#define GL_R1UI_C4F_N3F_V3F_SUN 0x85C8 +#define GL_R1UI_T2F_V3F_SUN 0x85C9 +#define GL_R1UI_T2F_N3F_V3F_SUN 0x85CA +#define GL_R1UI_T2F_C4F_N3F_V3F_SUN 0x85CB +#endif + +#ifndef GL_SUN_vertex +#define GL_SUN_vertex +#define _ALLEGRO_GL_SUN_vertex +#endif + +#ifndef GL_EXT_blend_func_separate +#define GL_EXT_blend_func_separate +#define _ALLEGRO_GL_EXT_blend_func_separate +#define GL_BLEND_DST_RGB_EXT 0x80C8 +#define GL_BLEND_SRC_RGB_EXT 0x80C9 +#define GL_BLEND_DST_ALPHA_EXT 0x80CA +#define GL_BLEND_SRC_ALPHA_EXT 0x80CB +#endif + +#ifndef GL_INGR_color_clamp +#define GL_INGR_color_clamp +#define _ALLEGRO_GL_INGR_color_clamp +#define GL_RED_MIN_CLAMP_INGR 0x8560 +#define GL_GREEN_MIN_CLAMP_INGR 0x8561 +#define GL_BLUE_MIN_CLAMP_INGR 0x8562 +#define GL_ALPHA_MIN_CLAMP_INGR 0x8563 +#define GL_RED_MAX_CLAMP_INGR 0x8564 +#define GL_GREEN_MAX_CLAMP_INGR 0x8565 +#define GL_BLUE_MAX_CLAMP_INGR 0x8566 +#define GL_ALPHA_MAX_CLAMP_INGR 0x8567 +#endif + +#ifndef GL_INGR_blend_func_separate +#define GL_INGR_blend_func_separate +#define _ALLEGRO_GL_INGR_blend_func_separate +#endif + +#ifndef GL_INGR_interlace_read +#define GL_INGR_interlace_read +#define _ALLEGRO_GL_INGR_interlace_read +#define GL_INTERLACE_READ_INGR 0x8568 +#endif + +#ifndef GL_EXT_stencil_wrap +#define GL_EXT_stencil_wrap +#define _ALLEGRO_GL_EXT_stencil_wrap +#define GL_INCR_WRAP_EXT 0x8507 +#define GL_DECR_WRAP_EXT 0x8508 +#endif + +#ifndef GL_EXT_422_pixels +#define GL_EXT_422_pixels +#define _ALLEGRO_GL_EXT_422_pixels +#define GL_422_EXT 0x80CC +#define GL_422_REV_EXT 0x80CD +#define GL_422_AVERAGE_EXT 0x80CE +#define GL_422_REV_AVERAGE_EXT 0x80CF +#endif + +#ifndef GL_NV_texgen_reflection +#define GL_NV_texgen_reflection +#define _ALLEGRO_GL_NV_texgen_reflection +#define GL_NORMAL_MAP_NV 0x8511 +#define GL_REFLECTION_MAP_NV 0x8512 +#endif + +#ifndef GL_EXT_texture_cube_map +#define GL_EXT_texture_cube_map +#define _ALLEGRO_GL_EXT_texture_cube_map +#define GL_NORMAL_MAP_EXT 0x8511 +#define GL_REFLECTION_MAP_EXT 0x8512 +#define GL_TEXTURE_CUBE_MAP_EXT 0x8513 +#define GL_TEXTURE_BINDING_CUBE_MAP_EXT 0x8514 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_X_EXT 0x8515 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X_EXT 0x8516 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y_EXT 0x8517 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_EXT 0x8518 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z_EXT 0x8519 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_EXT 0x851A +#define GL_PROXY_TEXTURE_CUBE_MAP_EXT 0x851B +#define GL_MAX_CUBE_MAP_TEXTURE_SIZE_EXT 0x851C +#endif + +#ifndef GL_SUN_convolution_border_modes +#define GL_SUN_convolution_border_modes +#define _ALLEGRO_GL_SUN_convolution_border_modes +#define GL_WRAP_BORDER_SUN 0x81D4 +#endif + +#ifndef GL_EXT_texture_lod_bias +#define GL_EXT_texture_lod_bias +#define _ALLEGRO_GL_EXT_texture_lod_bias +#define GL_MAX_TEXTURE_LOD_BIAS_EXT 0x84FD +#define GL_TEXTURE_FILTER_CONTROL_EXT 0x8500 +#define GL_TEXTURE_LOD_BIAS_EXT 0x8501 +#endif + +#ifndef GL_EXT_texture_filter_anisotropic +#define GL_EXT_texture_filter_anisotropic +#define _ALLEGRO_GL_EXT_texture_filter_anisotropic +#define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE +#define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF +#endif + +#ifndef GL_EXT_vertex_weighting +#define GL_EXT_vertex_weighting +#define _ALLEGRO_GL_EXT_vertex_weighting +#define GL_MODELVIEW0_STACK_DEPTH_EXT GL_MODELVIEW_STACK_DEPTH +#define GL_MODELVIEW1_STACK_DEPTH_EXT 0x8502 +#define GL_MODELVIEW0_MATRIX_EXT GL_MODELVIEW_MATRIX +#define GL_MODELVIEW1_MATRIX_EXT 0x8506 +#define GL_VERTEX_WEIGHTING_EXT 0x8509 +#define GL_MODELVIEW0_EXT GL_MODELVIEW +#define GL_MODELVIEW1_EXT 0x850A +#define GL_CURRENT_VERTEX_WEIGHT_EXT 0x850B +#define GL_VERTEX_WEIGHT_ARRAY_EXT 0x850C +#define GL_VERTEX_WEIGHT_ARRAY_SIZE_EXT 0x850D +#define GL_VERTEX_WEIGHT_ARRAY_TYPE_EXT 0x850E +#define GL_VERTEX_WEIGHT_ARRAY_STRIDE_EXT 0x850F +#define GL_VERTEX_WEIGHT_ARRAY_POINTER_EXT 0x8510 +#endif + +#ifndef GL_NV_light_max_exponent +#define GL_NV_light_max_exponent +#define _ALLEGRO_GL_NV_light_max_exponent +#define GL_MAX_SHININESS_NV 0x8504 +#define GL_MAX_SPOT_EXPONENT_NV 0x8505 +#endif + +#ifndef GL_NV_vertex_array_range +#define GL_NV_vertex_array_range +#define _ALLEGRO_GL_NV_vertex_array_range +#define GL_VERTEX_ARRAY_RANGE_NV 0x851D +#define GL_VERTEX_ARRAY_RANGE_LENGTH_NV 0x851E +#define GL_VERTEX_ARRAY_RANGE_VALID_NV 0x851F +#define GL_MAX_VERTEX_ARRAY_RANGE_ELEMENT_NV 0x8520 +#define GL_VERTEX_ARRAY_RANGE_POINTER_NV 0x8521 +#endif + +#ifndef GL_NV_register_combiners +#define GL_NV_register_combiners +#define _ALLEGRO_GL_NV_register_combiners +#define GL_REGISTER_COMBINERS_NV 0x8522 +#define GL_VARIABLE_A_NV 0x8523 +#define GL_VARIABLE_B_NV 0x8524 +#define GL_VARIABLE_C_NV 0x8525 +#define GL_VARIABLE_D_NV 0x8526 +#define GL_VARIABLE_E_NV 0x8527 +#define GL_VARIABLE_F_NV 0x8528 +#define GL_VARIABLE_G_NV 0x8529 +#define GL_CONSTANT_COLOR0_NV 0x852A +#define GL_CONSTANT_COLOR1_NV 0x852B +#define GL_PRIMARY_COLOR_NV 0x852C +#define GL_SECONDARY_COLOR_NV 0x852D +#define GL_SPARE0_NV 0x852E +#define GL_SPARE1_NV 0x852F +#define GL_DISCARD_NV 0x8530 +#define GL_E_TIMES_F_NV 0x8531 +#define GL_SPARE0_PLUS_SECONDARY_COLOR_NV 0x8532 +#define GL_UNSIGNED_IDENTITY_NV 0x8536 +#define GL_UNSIGNED_INVERT_NV 0x8537 +#define GL_EXPAND_NORMAL_NV 0x8538 +#define GL_EXPAND_NEGATE_NV 0x8539 +#define GL_HALF_BIAS_NORMAL_NV 0x853A +#define GL_HALF_BIAS_NEGATE_NV 0x853B +#define GL_SIGNED_IDENTITY_NV 0x853C +#define GL_SIGNED_NEGATE_NV 0x853D +#define GL_SCALE_BY_TWO_NV 0x853E +#define GL_SCALE_BY_FOUR_NV 0x853F +#define GL_SCALE_BY_ONE_HALF_NV 0x8540 +#define GL_BIAS_BY_NEGATIVE_ONE_HALF_NV 0x8541 +#define GL_COMBINER_INPUT_NV 0x8542 +#define GL_COMBINER_MAPPING_NV 0x8543 +#define GL_COMBINER_COMPONENT_USAGE_NV 0x8544 +#define GL_COMBINER_AB_DOT_PRODUCT_NV 0x8545 +#define GL_COMBINER_CD_DOT_PRODUCT_NV 0x8546 +#define GL_COMBINER_MUX_SUM_NV 0x8547 +#define GL_COMBINER_SCALE_NV 0x8548 +#define GL_COMBINER_BIAS_NV 0x8549 +#define GL_COMBINER_AB_OUTPUT_NV 0x854A +#define GL_COMBINER_CD_OUTPUT_NV 0x854B +#define GL_COMBINER_SUM_OUTPUT_NV 0x854C +#define GL_MAX_GENERAL_COMBINERS_NV 0x854D +#define GL_NUM_GENERAL_COMBINERS_NV 0x854E +#define GL_COLOR_SUM_CLAMP_NV 0x854F +#define GL_COMBINER0_NV 0x8550 +#define GL_COMBINER1_NV 0x8551 +#define GL_COMBINER2_NV 0x8552 +#define GL_COMBINER3_NV 0x8553 +#define GL_COMBINER4_NV 0x8554 +#define GL_COMBINER5_NV 0x8555 +#define GL_COMBINER6_NV 0x8556 +#define GL_COMBINER7_NV 0x8557 +/* GL_TEXTURE0_ARB */ +/* GL_TEXTURE1_ARB */ +/* GL_ZERO */ +/* GL_NONE */ +/* GL_FOG */ +#endif + +#ifndef GL_NV_fog_distance +#define GL_NV_fog_distance +#define _ALLEGRO_GL_NV_fog_distance +#define GL_FOG_DISTANCE_MODE_NV 0x855A +#define GL_EYE_RADIAL_NV 0x855B +#define GL_EYE_PLANE_ABSOLUTE_NV 0x855C +/* GL_EYE_PLANE */ +#endif + +#ifndef GL_NV_texgen_emboss +#define GL_NV_texgen_emboss +#define _ALLEGRO_GL_NV_texgen_emboss +#define GL_EMBOSS_LIGHT_NV 0x855D +#define GL_EMBOSS_CONSTANT_NV 0x855E +#define GL_EMBOSS_MAP_NV 0x855F +#endif + +#ifndef GL_NV_texture_env_combine4 +#define GL_NV_texture_env_combine4 +#define _ALLEGRO_GL_NV_texture_env_combine4 +#define GL_COMBINE4_NV 0x8503 +#define GL_SOURCE3_RGB_NV 0x8583 +#define GL_SOURCE3_ALPHA_NV 0x858B +#define GL_OPERAND3_RGB_NV 0x8593 +#define GL_OPERAND3_ALPHA_NV 0x859B +#endif + +#ifndef GL_EXT_texture_compression_s3tc +#define GL_EXT_texture_compression_s3tc +#define _ALLEGRO_GL_EXT_texture_compression_s3tc +#define GL_COMPRESSED_RGB_S3TC_DXT1_EXT 0x83F0 +#define GL_COMPRESSED_RGBA_S3TC_DXT1_EXT 0x83F1 +#define GL_COMPRESSED_RGBA_S3TC_DXT3_EXT 0x83F2 +#define GL_COMPRESSED_RGBA_S3TC_DXT5_EXT 0x83F3 +#endif + +#ifndef GL_MESA_resize_buffers +#define GL_MESA_resize_buffers +#define _ALLEGRO_GL_MESA_resize_buffers +#endif + +#ifndef GL_MESA_window_pos +#define GL_MESA_window_pos +#define _ALLEGRO_GL_MESA_window_pos +#endif + +#ifndef GL_IBM_cull_vertex +#define GL_IBM_cull_vertex +#define _ALLEGRO_GL_IBM_cull_vertex +#define GL_CULL_VERTEX_IBM 103050 +#endif + +#ifndef GL_IBM_multimode_draw_arrays +#define GL_IBM_multimode_draw_arrays +#define _ALLEGRO_GL_IBM_multimode_draw_arrays +#endif + +#ifndef GL_IBM_vertex_array_lists +#define GL_IBM_vertex_array_lists +#define _ALLEGRO_GL_IBM_vertex_array_lists +#define GL_VERTEX_ARRAY_LIST_IBM 103070 +#define GL_NORMAL_ARRAY_LIST_IBM 103071 +#define GL_COLOR_ARRAY_LIST_IBM 103072 +#define GL_INDEX_ARRAY_LIST_IBM 103073 +#define GL_TEXTURE_COORD_ARRAY_LIST_IBM 103074 +#define GL_EDGE_FLAG_ARRAY_LIST_IBM 103075 +#define GL_FOG_COORDINATE_ARRAY_LIST_IBM 103076 +#define GL_SECONDARY_COLOR_ARRAY_LIST_IBM 103077 +#define GL_VERTEX_ARRAY_LIST_STRIDE_IBM 103080 +#define GL_NORMAL_ARRAY_LIST_STRIDE_IBM 103081 +#define GL_COLOR_ARRAY_LIST_STRIDE_IBM 103082 +#define GL_INDEX_ARRAY_LIST_STRIDE_IBM 103083 +#define GL_TEXTURE_COORD_ARRAY_LIST_STRIDE_IBM 103084 +#define GL_EDGE_FLAG_ARRAY_LIST_STRIDE_IBM 103085 +#define GL_FOG_COORDINATE_ARRAY_LIST_STRIDE_IBM 103086 +#define GL_SECONDARY_COLOR_ARRAY_LIST_STRIDE_IBM 103087 +#endif + +#ifndef GL_SGIX_subsample +#define GL_SGIX_subsample +#define _ALLEGRO_GL_SGIX_subsample +#define GL_PACK_SUBSAMPLE_RATE_SGIX 0x85A0 +#define GL_UNPACK_SUBSAMPLE_RATE_SGIX 0x85A1 +#define GL_PIXEL_SUBSAMPLE_4444_SGIX 0x85A2 +#define GL_PIXEL_SUBSAMPLE_2424_SGIX 0x85A3 +#define GL_PIXEL_SUBSAMPLE_4242_SGIX 0x85A4 +#endif + +#ifndef GL_SGIX_ycrcba +#define GL_SGIX_ycrcba +#define _ALLEGRO_GL_SGIX_ycrcba +#define GL_YCRCB_SGIX 0x8318 +#define GL_YCRCBA_SGIX 0x8319 +#endif + +#ifndef GL_SGI_depth_pass_instrument +#define GL_SGI_depth_pass_instrument +#define _ALLEGRO_GL_SGI_depth_pass_instrument +#define GL_DEPTH_PASS_INSTRUMENT_SGIX 0x8310 +#define GL_DEPTH_PASS_INSTRUMENT_COUNTERS_SGIX 0x8311 +#define GL_DEPTH_PASS_INSTRUMENT_MAX_SGIX 0x8312 +#endif + +#ifndef GL_3DFX_texture_compression_FXT1 +#define GL_3DFX_texture_compression_FXT1 +#define _ALLEGRO_GL_3DFX_texture_compression_FXT1 +#define GL_COMPRESSED_RGB_FXT1_3DFX 0x86B0 +#define GL_COMPRESSED_RGBA_FXT1_3DFX 0x86B1 +#endif + +#ifndef GL_3DFX_multisample +#define GL_3DFX_multisample +#define _ALLEGRO_GL_3DFX_multisample +#define GL_MULTISAMPLE_3DFX 0x86B2 +#define GL_SAMPLE_BUFFERS_3DFX 0x86B3 +#define GL_SAMPLES_3DFX 0x86B4 +#define GL_MULTISAMPLE_BIT_3DFX 0x20000000 +#endif + +#ifndef GL_3DFX_tbuffer +#define GL_3DFX_tbuffer +#ifndef ALLEGRO_GL_HEADER_NV +#define _ALLEGRO_GL_3DFX_tbuffer +#endif +#endif + +#ifndef GL_EXT_multisample +#define GL_EXT_multisample +#define _ALLEGRO_GL_EXT_multisample +#define GL_MULTISAMPLE_EXT 0x809D +#define GL_SAMPLE_ALPHA_TO_MASK_EXT 0x809E +#define GL_SAMPLE_ALPHA_TO_ONE_EXT 0x809F +#define GL_SAMPLE_MASK_EXT 0x80A0 +#define GL_1PASS_EXT 0x80A1 +#define GL_2PASS_0_EXT 0x80A2 +#define GL_2PASS_1_EXT 0x80A3 +#define GL_4PASS_0_EXT 0x80A4 +#define GL_4PASS_1_EXT 0x80A5 +#define GL_4PASS_2_EXT 0x80A6 +#define GL_4PASS_3_EXT 0x80A7 +#define GL_SAMPLE_BUFFERS_EXT 0x80A8 +#define GL_SAMPLES_EXT 0x80A9 +#define GL_SAMPLE_MASK_VALUE_EXT 0x80AA +#define GL_SAMPLE_MASK_INVERT_EXT 0x80AB +#define GL_SAMPLE_PATTERN_EXT 0x80AC +#define GL_MULTISAMPLE_BIT_EXT 0x20000000 +#endif + +#ifndef GL_SGIX_vertex_preclip +#define GL_SGIX_vertex_preclip +#define _ALLEGRO_GL_SGIX_vertex_preclip +#define GL_VERTEX_PRECLIP_SGIX 0x83EE +#define GL_VERTEX_PRECLIP_HINT_SGIX 0x83EF +#endif + +#ifndef GL_SGIX_convolution_accuracy +#define GL_SGIX_convolution_accuracy +#define _ALLEGRO_GL_SGIX_convolution_accuracy +#define GL_CONVOLUTION_HINT_SGIX 0x8316 +#endif + +#ifndef GL_SGIX_resample +#define GL_SGIX_resample +#define _ALLEGRO_GL_SGIX_resample +#define GL_PACK_RESAMPLE_SGIX 0x842C +#define GL_UNPACK_RESAMPLE_SGIX 0x842D +#define GL_RESAMPLE_REPLICATE_SGIX 0x842E +#define GL_RESAMPLE_ZERO_FILL_SGIX 0x842F +#define GL_RESAMPLE_DECIMATE_SGIX 0x8430 +#endif + +#ifndef GL_SGIS_point_line_texgen +#define GL_SGIS_point_line_texgen +#define _ALLEGRO_GL_SGIS_point_line_texgen +#define GL_EYE_DISTANCE_TO_POINT_SGIS 0x81F0 +#define GL_OBJECT_DISTANCE_TO_POINT_SGIS 0x81F1 +#define GL_EYE_DISTANCE_TO_LINE_SGIS 0x81F2 +#define GL_OBJECT_DISTANCE_TO_LINE_SGIS 0x81F3 +#define GL_EYE_POINT_SGIS 0x81F4 +#define GL_OBJECT_POINT_SGIS 0x81F5 +#define GL_EYE_LINE_SGIS 0x81F6 +#define GL_OBJECT_LINE_SGIS 0x81F7 +#endif + +#ifndef GL_SGIS_texture_color_mask +#define GL_SGIS_texture_color_mask +#ifndef ALLEGRO_GL_HEADER_NV +#define _ALLEGRO_GL_SGIS_texture_color_mask +#define GL_TEXTURE_COLOR_WRITEMASK_SGIS 0x81EF +#endif +#endif + +#ifndef GL_SGIX_igloo_interface +#define GL_SGIX_igloo_interface +#define _ALLEGRO_GL_SGIX_igloo_interface +#endif + +#ifndef GL_EXT_texture_env_dot3 +#define GL_EXT_texture_env_dot3 +#define _ALLEGRO_GL_EXT_texture_env_dot3 +/* GL_DOT3_RGB_EXT */ +/* GL_DOT3_RGBA_EXT */ +#endif + +#ifndef GL_ATI_texture_mirror_once +#define GL_ATI_texture_mirror_once +#define _ALLEGRO_GL_ATI_texture_mirror_once +#define GL_MIRROR_CLAMP_ATI 0x8742 +#define GL_MIRROR_CLAMP_TO_EDGE_ATI 0x8743 +#endif + +#ifndef GL_NV_fence +#define GL_NV_fence +#define _ALLEGRO_GL_NV_fence +#define GL_ALL_COMPLETED_NV 0x84F2 +#define GL_FENCE_STATUS_NV 0x84F3 +#define GL_FENCE_CONDITION_NV 0x84F4 +#endif + +#ifndef GL_IBM_texture_mirrored_repeat +#define GL_IBM_texture_mirrored_repeat +#define _ALLEGRO_GL_IBM_texture_mirrored_repeat +#define GL_MIRRORED_REPEAT_IBM 0x8370 +#endif + +#ifndef GL_NV_evaluators +#define GL_NV_evaluators +#define _ALLEGRO_GL_NV_evaluators +#define GL_EVAL_2D_NV 0x86C0 +#define GL_EVAL_TRIANGULAR_2D_NV 0x86C1 +#define GL_MAP_TESSELLATION_NV 0x86C2 +#define GL_MAP_ATTRIB_U_ORDER_NV 0x86C3 +#define GL_MAP_ATTRIB_V_ORDER_NV 0x86C4 +#define GL_EVAL_FRACTIONAL_TESSELLATION_NV 0x86C5 +#define GL_EVAL_VERTEX_ATTRIB0_NV 0x86C6 +#define GL_EVAL_VERTEX_ATTRIB1_NV 0x86C7 +#define GL_EVAL_VERTEX_ATTRIB2_NV 0x86C8 +#define GL_EVAL_VERTEX_ATTRIB3_NV 0x86C9 +#define GL_EVAL_VERTEX_ATTRIB4_NV 0x86CA +#define GL_EVAL_VERTEX_ATTRIB5_NV 0x86CB +#define GL_EVAL_VERTEX_ATTRIB6_NV 0x86CC +#define GL_EVAL_VERTEX_ATTRIB7_NV 0x86CD +#define GL_EVAL_VERTEX_ATTRIB8_NV 0x86CE +#define GL_EVAL_VERTEX_ATTRIB9_NV 0x86CF +#define GL_EVAL_VERTEX_ATTRIB10_NV 0x86D0 +#define GL_EVAL_VERTEX_ATTRIB11_NV 0x86D1 +#define GL_EVAL_VERTEX_ATTRIB12_NV 0x86D2 +#define GL_EVAL_VERTEX_ATTRIB13_NV 0x86D3 +#define GL_EVAL_VERTEX_ATTRIB14_NV 0x86D4 +#define GL_EVAL_VERTEX_ATTRIB15_NV 0x86D5 +#define GL_MAX_MAP_TESSELLATION_NV 0x86D6 +#define GL_MAX_RATIONAL_EVAL_ORDER_NV 0x86D7 +#endif + +#ifndef GL_NV_packed_depth_stencil +#define GL_NV_packed_depth_stencil +#define _ALLEGRO_GL_NV_packed_depth_stencil +#define GL_DEPTH_STENCIL_NV 0x84F9 +#define GL_UNSIGNED_INT_24_8_NV 0x84FA +#endif + +#ifndef GL_NV_register_combiners2 +#define GL_NV_register_combiners2 +#define _ALLEGRO_GL_NV_register_combiners2 +#define GL_PER_STAGE_CONSTANTS_NV 0x8535 +#endif + +#ifndef GL_NV_texture_rectangle +#define GL_NV_texture_rectangle +#define _ALLEGRO_GL_NV_texture_rectangle +#define GL_TEXTURE_RECTANGLE_NV 0x84F5 +#define GL_TEXTURE_BINDING_RECTANGLE_NV 0x84F6 +#define GL_PROXY_TEXTURE_RECTANGLE_NV 0x84F7 +#define GL_MAX_RECTANGLE_TEXTURE_SIZE_NV 0x84F8 +#endif + +#ifndef GL_NV_texture_shader +#define GL_NV_texture_shader +#define _ALLEGRO_GL_NV_texture_shader +#define GL_OFFSET_TEXTURE_RECTANGLE_NV 0x864C +#define GL_OFFSET_TEXTURE_RECTANGLE_SCALE_NV 0x864D +#define GL_DOT_PRODUCT_TEXTURE_RECTANGLE_NV 0x864E +#define GL_RGBA_UNSIGNED_DOT_PRODUCT_MAPPING_NV 0x86D9 +#define GL_UNSIGNED_INT_S8_S8_8_8_NV 0x86DA +#define GL_UNSIGNED_INT_8_8_S8_S8_REV_NV 0x86DB +#define GL_DSDT_MAG_INTENSITY_NV 0x86DC +#define GL_SHADER_CONSISTENT_NV 0x86DD +#define GL_TEXTURE_SHADER_NV 0x86DE +#define GL_SHADER_OPERATION_NV 0x86DF +#define GL_CULL_MODES_NV 0x86E0 +#define GL_OFFSET_TEXTURE_MATRIX_NV 0x86E1 +#define GL_OFFSET_TEXTURE_SCALE_NV 0x86E2 +#define GL_OFFSET_TEXTURE_BIAS_NV 0x86E3 +#define GL_OFFSET_TEXTURE_2D_MATRIX_NV GL_OFFSET_TEXTURE_MATRIX_NV +#define GL_OFFSET_TEXTURE_2D_SCALE_NV GL_OFFSET_TEXTURE_SCALE_NV +#define GL_OFFSET_TEXTURE_2D_BIAS_NV GL_OFFSET_TEXTURE_BIAS_NV +#define GL_PREVIOUS_TEXTURE_INPUT_NV 0x86E4 +#define GL_CONST_EYE_NV 0x86E5 +#define GL_PASS_THROUGH_NV 0x86E6 +#define GL_CULL_FRAGMENT_NV 0x86E7 +#define GL_OFFSET_TEXTURE_2D_NV 0x86E8 +#define GL_DEPENDENT_AR_TEXTURE_2D_NV 0x86E9 +#define GL_DEPENDENT_GB_TEXTURE_2D_NV 0x86EA +#define GL_DOT_PRODUCT_NV 0x86EC +#define GL_DOT_PRODUCT_DEPTH_REPLACE_NV 0x86ED +#define GL_DOT_PRODUCT_TEXTURE_2D_NV 0x86EE +#define GL_DOT_PRODUCT_TEXTURE_CUBE_MAP_NV 0x86F0 +#define GL_DOT_PRODUCT_DIFFUSE_CUBE_MAP_NV 0x86F1 +#define GL_DOT_PRODUCT_REFLECT_CUBE_MAP_NV 0x86F2 +#define GL_DOT_PRODUCT_CONST_EYE_REFLECT_CUBE_MAP_NV 0x86F3 +#define GL_HILO_NV 0x86F4 +#define GL_DSDT_NV 0x86F5 +#define GL_DSDT_MAG_NV 0x86F6 +#define GL_DSDT_MAG_VIB_NV 0x86F7 +#define GL_HILO16_NV 0x86F8 +#define GL_SIGNED_HILO_NV 0x86F9 +#define GL_SIGNED_HILO16_NV 0x86FA +#define GL_SIGNED_RGBA_NV 0x86FB +#define GL_SIGNED_RGBA8_NV 0x86FC +#define GL_SIGNED_RGB_NV 0x86FE +#define GL_SIGNED_RGB8_NV 0x86FF +#define GL_SIGNED_LUMINANCE_NV 0x8701 +#define GL_SIGNED_LUMINANCE8_NV 0x8702 +#define GL_SIGNED_LUMINANCE_ALPHA_NV 0x8703 +#define GL_SIGNED_LUMINANCE8_ALPHA8_NV 0x8704 +#define GL_SIGNED_ALPHA_NV 0x8705 +#define GL_SIGNED_ALPHA8_NV 0x8706 +#define GL_SIGNED_INTENSITY_NV 0x8707 +#define GL_SIGNED_INTENSITY8_NV 0x8708 +#define GL_DSDT8_NV 0x8709 +#define GL_DSDT8_MAG8_NV 0x870A +#define GL_DSDT8_MAG8_INTENSITY8_NV 0x870B +#define GL_SIGNED_RGB_UNSIGNED_ALPHA_NV 0x870C +#define GL_SIGNED_RGB8_UNSIGNED_ALPHA8_NV 0x870D +#define GL_HI_SCALE_NV 0x870E +#define GL_LO_SCALE_NV 0x870F +#define GL_DS_SCALE_NV 0x8710 +#define GL_DT_SCALE_NV 0x8711 +#define GL_MAGNITUDE_SCALE_NV 0x8712 +#define GL_VIBRANCE_SCALE_NV 0x8713 +#define GL_HI_BIAS_NV 0x8714 +#define GL_LO_BIAS_NV 0x8715 +#define GL_DS_BIAS_NV 0x8716 +#define GL_DT_BIAS_NV 0x8717 +#define GL_MAGNITUDE_BIAS_NV 0x8718 +#define GL_VIBRANCE_BIAS_NV 0x8719 +#define GL_TEXTURE_BORDER_VALUES_NV 0x871A +#define GL_TEXTURE_HI_SIZE_NV 0x871B +#define GL_TEXTURE_LO_SIZE_NV 0x871C +#define GL_TEXTURE_DS_SIZE_NV 0x871D +#define GL_TEXTURE_DT_SIZE_NV 0x871E +#define GL_TEXTURE_MAG_SIZE_NV 0x871F +#endif + +#ifndef GL_NV_texture_shader2 +#define GL_NV_texture_shader2 +#define _ALLEGRO_GL_NV_texture_shader2 +#define GL_DOT_PRODUCT_TEXTURE_3D_NV 0x86EF +#endif + +#ifndef GL_NV_vertex_array_range2 +#define GL_NV_vertex_array_range2 +#define _ALLEGRO_GL_NV_vertex_array_range2 +#define GL_VERTEX_ARRAY_RANGE_WITHOUT_FLUSH_NV 0x8533 +#endif + +#ifndef GL_NV_vertex_program +#define GL_NV_vertex_program +#define _ALLEGRO_GL_NV_vertex_program +#define GL_VERTEX_PROGRAM_NV 0x8620 +#define GL_VERTEX_STATE_PROGRAM_NV 0x8621 +#define GL_ATTRIB_ARRAY_SIZE_NV 0x8623 +#define GL_ATTRIB_ARRAY_STRIDE_NV 0x8624 +#define GL_ATTRIB_ARRAY_TYPE_NV 0x8625 +#define GL_CURRENT_ATTRIB_NV 0x8626 +#define GL_PROGRAM_LENGTH_NV 0x8627 +#define GL_PROGRAM_STRING_NV 0x8628 +#define GL_MODELVIEW_PROJECTION_NV 0x8629 +#define GL_IDENTITY_NV 0x862A +#define GL_INVERSE_NV 0x862B +#define GL_TRANSPOSE_NV 0x862C +#define GL_INVERSE_TRANSPOSE_NV 0x862D +#define GL_MAX_TRACK_MATRIX_STACK_DEPTH_NV 0x862E +#define GL_MAX_TRACK_MATRICES_NV 0x862F +#define GL_MATRIX0_NV 0x8630 +#define GL_MATRIX1_NV 0x8631 +#define GL_MATRIX2_NV 0x8632 +#define GL_MATRIX3_NV 0x8633 +#define GL_MATRIX4_NV 0x8634 +#define GL_MATRIX5_NV 0x8635 +#define GL_MATRIX6_NV 0x8636 +#define GL_MATRIX7_NV 0x8637 +#define GL_CURRENT_MATRIX_STACK_DEPTH_NV 0x8640 +#define GL_CURRENT_MATRIX_NV 0x8641 +#define GL_VERTEX_PROGRAM_POINT_SIZE_NV 0x8642 +#define GL_VERTEX_PROGRAM_TWO_SIDE_NV 0x8643 +#define GL_PROGRAM_PARAMETER_NV 0x8644 +#define GL_ATTRIB_ARRAY_POINTER_NV 0x8645 +#define GL_PROGRAM_TARGET_NV 0x8646 +#define GL_PROGRAM_RESIDENT_NV 0x8647 +#define GL_TRACK_MATRIX_NV 0x8648 +#define GL_TRACK_MATRIX_TRANSFORM_NV 0x8649 +#define GL_VERTEX_PROGRAM_BINDING_NV 0x864A +#define GL_PROGRAM_ERROR_POSITION_NV 0x864B +#define GL_VERTEX_ATTRIB_ARRAY0_NV 0x8650 +#define GL_VERTEX_ATTRIB_ARRAY1_NV 0x8651 +#define GL_VERTEX_ATTRIB_ARRAY2_NV 0x8652 +#define GL_VERTEX_ATTRIB_ARRAY3_NV 0x8653 +#define GL_VERTEX_ATTRIB_ARRAY4_NV 0x8654 +#define GL_VERTEX_ATTRIB_ARRAY5_NV 0x8655 +#define GL_VERTEX_ATTRIB_ARRAY6_NV 0x8656 +#define GL_VERTEX_ATTRIB_ARRAY7_NV 0x8657 +#define GL_VERTEX_ATTRIB_ARRAY8_NV 0x8658 +#define GL_VERTEX_ATTRIB_ARRAY9_NV 0x8659 +#define GL_VERTEX_ATTRIB_ARRAY10_NV 0x865A +#define GL_VERTEX_ATTRIB_ARRAY11_NV 0x865B +#define GL_VERTEX_ATTRIB_ARRAY12_NV 0x865C +#define GL_VERTEX_ATTRIB_ARRAY13_NV 0x865D +#define GL_VERTEX_ATTRIB_ARRAY14_NV 0x865E +#define GL_VERTEX_ATTRIB_ARRAY15_NV 0x865F +#define GL_MAP1_VERTEX_ATTRIB0_4_NV 0x8660 +#define GL_MAP1_VERTEX_ATTRIB1_4_NV 0x8661 +#define GL_MAP1_VERTEX_ATTRIB2_4_NV 0x8662 +#define GL_MAP1_VERTEX_ATTRIB3_4_NV 0x8663 +#define GL_MAP1_VERTEX_ATTRIB4_4_NV 0x8664 +#define GL_MAP1_VERTEX_ATTRIB5_4_NV 0x8665 +#define GL_MAP1_VERTEX_ATTRIB6_4_NV 0x8666 +#define GL_MAP1_VERTEX_ATTRIB7_4_NV 0x8667 +#define GL_MAP1_VERTEX_ATTRIB8_4_NV 0x8668 +#define GL_MAP1_VERTEX_ATTRIB9_4_NV 0x8669 +#define GL_MAP1_VERTEX_ATTRIB10_4_NV 0x866A +#define GL_MAP1_VERTEX_ATTRIB11_4_NV 0x866B +#define GL_MAP1_VERTEX_ATTRIB12_4_NV 0x866C +#define GL_MAP1_VERTEX_ATTRIB13_4_NV 0x866D +#define GL_MAP1_VERTEX_ATTRIB14_4_NV 0x866E +#define GL_MAP1_VERTEX_ATTRIB15_4_NV 0x866F +#define GL_MAP2_VERTEX_ATTRIB0_4_NV 0x8670 +#define GL_MAP2_VERTEX_ATTRIB1_4_NV 0x8671 +#define GL_MAP2_VERTEX_ATTRIB2_4_NV 0x8672 +#define GL_MAP2_VERTEX_ATTRIB3_4_NV 0x8673 +#define GL_MAP2_VERTEX_ATTRIB4_4_NV 0x8674 +#define GL_MAP2_VERTEX_ATTRIB5_4_NV 0x8675 +#define GL_MAP2_VERTEX_ATTRIB6_4_NV 0x8676 +#define GL_MAP2_VERTEX_ATTRIB7_4_NV 0x8677 +#define GL_MAP2_VERTEX_ATTRIB8_4_NV 0x8678 +#define GL_MAP2_VERTEX_ATTRIB9_4_NV 0x8679 +#define GL_MAP2_VERTEX_ATTRIB10_4_NV 0x867A +#define GL_MAP2_VERTEX_ATTRIB11_4_NV 0x867B +#define GL_MAP2_VERTEX_ATTRIB12_4_NV 0x867C +#define GL_MAP2_VERTEX_ATTRIB13_4_NV 0x867D +#define GL_MAP2_VERTEX_ATTRIB14_4_NV 0x867E +#define GL_MAP2_VERTEX_ATTRIB15_4_NV 0x867F +#endif + +#ifndef GL_SGIX_texture_coordinate_clamp +#define GL_SGIX_texture_coordinate_clamp +#define _ALLEGRO_GL_SGIX_texture_coordinate_clamp +#define GL_TEXTURE_MAX_CLAMP_S_SGIX 0x8369 +#define GL_TEXTURE_MAX_CLAMP_T_SGIX 0x836A +#define GL_TEXTURE_MAX_CLAMP_R_SGIX 0x836B +#endif + +#ifndef GL_SGIX_scalebias_hint +#define GL_SGIX_scalebias_hint +#define _ALLEGRO_GL_SGIX_scalebias_hint +#define GL_SCALEBIAS_HINT_SGIX 0x8322 +#endif + +#ifndef GL_OML_interlace +#define GL_OML_interlace +#define _ALLEGRO_GL_OML_interlace +#define GL_INTERLACE_OML 0x8980 +#define GL_INTERLACE_READ_OML 0x8981 +#endif + +#ifndef GL_OML_subsample +#define GL_OML_subsample +#define _ALLEGRO_GL_OML_subsample +#define GL_FORMAT_SUBSAMPLE_24_24_OML 0x8982 +#define GL_FORMAT_SUBSAMPLE_244_244_OML 0x8983 +#endif + +#ifndef GL_OML_resample +#define GL_OML_resample +#define _ALLEGRO_GL_OML_resample +#define GL_PACK_RESAMPLE_OML 0x8984 +#define GL_UNPACK_RESAMPLE_OML 0x8985 +#define GL_RESAMPLE_REPLICATE_OML 0x8986 +#define GL_RESAMPLE_ZERO_FILL_OML 0x8987 +#define GL_RESAMPLE_AVERAGE_OML 0x8988 +#define GL_RESAMPLE_DECIMATE_OML 0x8989 +#endif + +#ifndef GL_NV_copy_depth_to_color +#define GL_NV_copy_depth_to_color +#define _ALLEGRO_GL_NV_copy_depth_to_color +#define GL_DEPTH_STENCIL_TO_RGBA_NV 0x886E +#define GL_DEPTH_STENCIL_TO_BGRA_NV 0x886F +#endif + +#ifndef GL_ATI_envmap_bumpmap +#define GL_ATI_envmap_bumpmap +#define _ALLEGRO_GL_ATI_envmap_bumpmap +#define GL_BUMP_ROT_MATRIX_ATI 0x8775 +#define GL_BUMP_ROT_MATRIX_SIZE_ATI 0x8776 +#define GL_BUMP_NUM_TEX_UNITS_ATI 0x8777 +#define GL_BUMP_TEX_UNITS_ATI 0x8778 +#define GL_DUDV_ATI 0x8779 +#define GL_DU8DV8_ATI 0x877A +#define GL_BUMP_ENVMAP_ATI 0x877B +#define GL_BUMP_TARGET_ATI 0x877C +#endif + +#ifndef GL_ATI_fragment_shader +#define GL_ATI_fragment_shader +#define _ALLEGRO_GL_ATI_fragment_shader +#define GL_FRAGMENT_SHADER_ATI 0x8920 +#define GL_REG_0_ATI 0x8921 +#define GL_REG_1_ATI 0x8922 +#define GL_REG_2_ATI 0x8923 +#define GL_REG_3_ATI 0x8924 +#define GL_REG_4_ATI 0x8925 +#define GL_REG_5_ATI 0x8926 +#define GL_REG_6_ATI 0x8927 +#define GL_REG_7_ATI 0x8928 +#define GL_REG_8_ATI 0x8929 +#define GL_REG_9_ATI 0x892A +#define GL_REG_10_ATI 0x892B +#define GL_REG_11_ATI 0x892C +#define GL_REG_12_ATI 0x892D +#define GL_REG_13_ATI 0x892E +#define GL_REG_14_ATI 0x892F +#define GL_REG_15_ATI 0x8930 +#define GL_REG_16_ATI 0x8931 +#define GL_REG_17_ATI 0x8932 +#define GL_REG_18_ATI 0x8933 +#define GL_REG_19_ATI 0x8934 +#define GL_REG_20_ATI 0x8935 +#define GL_REG_21_ATI 0x8936 +#define GL_REG_22_ATI 0x8937 +#define GL_REG_23_ATI 0x8938 +#define GL_REG_24_ATI 0x8939 +#define GL_REG_25_ATI 0x893A +#define GL_REG_26_ATI 0x893B +#define GL_REG_27_ATI 0x893C +#define GL_REG_28_ATI 0x893D +#define GL_REG_29_ATI 0x893E +#define GL_REG_30_ATI 0x893F +#define GL_REG_31_ATI 0x8940 +#define GL_CON_0_ATI 0x8941 +#define GL_CON_1_ATI 0x8942 +#define GL_CON_2_ATI 0x8943 +#define GL_CON_3_ATI 0x8944 +#define GL_CON_4_ATI 0x8945 +#define GL_CON_5_ATI 0x8946 +#define GL_CON_6_ATI 0x8947 +#define GL_CON_7_ATI 0x8948 +#define GL_CON_8_ATI 0x8949 +#define GL_CON_9_ATI 0x894A +#define GL_CON_10_ATI 0x894B +#define GL_CON_11_ATI 0x894C +#define GL_CON_12_ATI 0x894D +#define GL_CON_13_ATI 0x894E +#define GL_CON_14_ATI 0x894F +#define GL_CON_15_ATI 0x8950 +#define GL_CON_16_ATI 0x8951 +#define GL_CON_17_ATI 0x8952 +#define GL_CON_18_ATI 0x8953 +#define GL_CON_19_ATI 0x8954 +#define GL_CON_20_ATI 0x8955 +#define GL_CON_21_ATI 0x8956 +#define GL_CON_22_ATI 0x8957 +#define GL_CON_23_ATI 0x8958 +#define GL_CON_24_ATI 0x8959 +#define GL_CON_25_ATI 0x895A +#define GL_CON_26_ATI 0x895B +#define GL_CON_27_ATI 0x895C +#define GL_CON_28_ATI 0x895D +#define GL_CON_29_ATI 0x895E +#define GL_CON_30_ATI 0x895F +#define GL_CON_31_ATI 0x8960 +#define GL_MOV_ATI 0x8961 +#define GL_ADD_ATI 0x8963 +#define GL_MUL_ATI 0x8964 +#define GL_SUB_ATI 0x8965 +#define GL_DOT3_ATI 0x8966 +#define GL_DOT4_ATI 0x8967 +#define GL_MAD_ATI 0x8968 +#define GL_LERP_ATI 0x8969 +#define GL_CND_ATI 0x896A +#define GL_CND0_ATI 0x896B +#define GL_DOT2_ADD_ATI 0x896C +#define GL_SECONDARY_INTERPOLATOR_ATI 0x896D +#define GL_NUM_FRAGMENT_REGISTERS_ATI 0x896E +#define GL_NUM_FRAGMENT_CONSTANTS_ATI 0x896F +#define GL_NUM_PASSES_ATI 0x8970 +#define GL_NUM_INSTRUCTIONS_PER_PASS_ATI 0x8971 +#define GL_NUM_INSTRUCTIONS_TOTAL_ATI 0x8972 +#define GL_NUM_INPUT_INTERPOLATOR_COMPONENTS_ATI 0x8973 +#define GL_NUM_LOOPBACK_COMPONENTS_ATI 0x8974 +#define GL_COLOR_ALPHA_PAIRING_ATI 0x8975 +#define GL_SWIZZLE_STR_ATI 0x8976 +#define GL_SWIZZLE_STQ_ATI 0x8977 +#define GL_SWIZZLE_STR_DR_ATI 0x8978 +#define GL_SWIZZLE_STQ_DQ_ATI 0x8979 +#define GL_SWIZZLE_STRQ_ATI 0x897A +#define GL_SWIZZLE_STRQ_DQ_ATI 0x897B +#define GL_RED_BIT_ATI 0x00000001 +#define GL_GREEN_BIT_ATI 0x00000002 +#define GL_BLUE_BIT_ATI 0x00000004 +#define GL_2X_BIT_ATI 0x00000001 +#define GL_4X_BIT_ATI 0x00000002 +#define GL_8X_BIT_ATI 0x00000004 +#define GL_HALF_BIT_ATI 0x00000008 +#define GL_QUARTER_BIT_ATI 0x00000010 +#define GL_EIGHTH_BIT_ATI 0x00000020 +#define GL_SATURATE_BIT_ATI 0x00000040 +#define GL_COMP_BIT_ATI 0x00000002 +#define GL_NEGATE_BIT_ATI 0x00000004 +#define GL_BIAS_BIT_ATI 0x00000008 +#endif + +#ifndef GL_ATI_pn_triangles +#define GL_ATI_pn_triangles +#define _ALLEGRO_GL_ATI_pn_triangles +#define GL_PN_TRIANGLES_ATI 0x87F0 +#define GL_MAX_PN_TRIANGLES_TESSELATION_LEVEL_ATI 0x87F1 +#define GL_PN_TRIANGLES_POINT_MODE_ATI 0x87F2 +#define GL_PN_TRIANGLES_NORMAL_MODE_ATI 0x87F3 +#define GL_PN_TRIANGLES_TESSELATION_LEVEL_ATI 0x87F4 +#define GL_PN_TRIANGLES_POINT_MODE_LINEAR_ATI 0x87F5 +#define GL_PN_TRIANGLES_POINT_MODE_CUBIC_ATI 0x87F6 +#define GL_PN_TRIANGLES_NORMAL_MODE_LINEAR_ATI 0x87F7 +#define GL_PN_TRIANGLES_NORMAL_MODE_QUADRATIC_ATI 0x87F8 +#endif + +#ifndef GL_ATI_vertex_array_object +#define GL_ATI_vertex_array_object +#define _ALLEGRO_GL_ATI_vertex_array_object +#define GL_STATIC_ATI 0x8760 +#define GL_DYNAMIC_ATI 0x8761 +#define GL_PRESERVE_ATI 0x8762 +#define GL_DISCARD_ATI 0x8763 +#define GL_OBJECT_BUFFER_SIZE_ATI 0x8764 +#define GL_OBJECT_BUFFER_USAGE_ATI 0x8765 +#define GL_ARRAY_OBJECT_BUFFER_ATI 0x8766 +#define GL_ARRAY_OBJECT_OFFSET_ATI 0x8767 +#endif + +#ifndef GL_EXT_vertex_shader +#define GL_EXT_vertex_shader +#define _ALLEGRO_GL_EXT_vertex_shader +#define GL_VERTEX_SHADER_EXT 0x8780 +#define GL_VERTEX_SHADER_BINDING_EXT 0x8781 +#define GL_OP_INDEX_EXT 0x8782 +#define GL_OP_NEGATE_EXT 0x8783 +#define GL_OP_DOT3_EXT 0x8784 +#define GL_OP_DOT4_EXT 0x8785 +#define GL_OP_MUL_EXT 0x8786 +#define GL_OP_ADD_EXT 0x8787 +#define GL_OP_MADD_EXT 0x8788 +#define GL_OP_FRAC_EXT 0x8789 +#define GL_OP_MAX_EXT 0x878A +#define GL_OP_MIN_EXT 0x878B +#define GL_OP_SET_GE_EXT 0x878C +#define GL_OP_SET_LT_EXT 0x878D +#define GL_OP_CLAMP_EXT 0x878E +#define GL_OP_FLOOR_EXT 0x878F +#define GL_OP_ROUND_EXT 0x8790 +#define GL_OP_EXP_BASE_2_EXT 0x8791 +#define GL_OP_LOG_BASE_2_EXT 0x8792 +#define GL_OP_POWER_EXT 0x8793 +#define GL_OP_RECIP_EXT 0x8794 +#define GL_OP_RECIP_SQRT_EXT 0x8795 +#define GL_OP_SUB_EXT 0x8796 +#define GL_OP_CROSS_PRODUCT_EXT 0x8797 +#define GL_OP_MULTIPLY_MATRIX_EXT 0x8798 +#define GL_OP_MOV_EXT 0x8799 +#define GL_OUTPUT_VERTEX_EXT 0x879A +#define GL_OUTPUT_COLOR0_EXT 0x879B +#define GL_OUTPUT_COLOR1_EXT 0x879C +#define GL_OUTPUT_TEXTURE_COORD0_EXT 0x879D +#define GL_OUTPUT_TEXTURE_COORD1_EXT 0x879E +#define GL_OUTPUT_TEXTURE_COORD2_EXT 0x879F +#define GL_OUTPUT_TEXTURE_COORD3_EXT 0x87A0 +#define GL_OUTPUT_TEXTURE_COORD4_EXT 0x87A1 +#define GL_OUTPUT_TEXTURE_COORD5_EXT 0x87A2 +#define GL_OUTPUT_TEXTURE_COORD6_EXT 0x87A3 +#define GL_OUTPUT_TEXTURE_COORD7_EXT 0x87A4 +#define GL_OUTPUT_TEXTURE_COORD8_EXT 0x87A5 +#define GL_OUTPUT_TEXTURE_COORD9_EXT 0x87A6 +#define GL_OUTPUT_TEXTURE_COORD10_EXT 0x87A7 +#define GL_OUTPUT_TEXTURE_COORD11_EXT 0x87A8 +#define GL_OUTPUT_TEXTURE_COORD12_EXT 0x87A9 +#define GL_OUTPUT_TEXTURE_COORD13_EXT 0x87AA +#define GL_OUTPUT_TEXTURE_COORD14_EXT 0x87AB +#define GL_OUTPUT_TEXTURE_COORD15_EXT 0x87AC +#define GL_OUTPUT_TEXTURE_COORD16_EXT 0x87AD +#define GL_OUTPUT_TEXTURE_COORD17_EXT 0x87AE +#define GL_OUTPUT_TEXTURE_COORD18_EXT 0x87AF +#define GL_OUTPUT_TEXTURE_COORD19_EXT 0x87B0 +#define GL_OUTPUT_TEXTURE_COORD20_EXT 0x87B1 +#define GL_OUTPUT_TEXTURE_COORD21_EXT 0x87B2 +#define GL_OUTPUT_TEXTURE_COORD22_EXT 0x87B3 +#define GL_OUTPUT_TEXTURE_COORD23_EXT 0x87B4 +#define GL_OUTPUT_TEXTURE_COORD24_EXT 0x87B5 +#define GL_OUTPUT_TEXTURE_COORD25_EXT 0x87B6 +#define GL_OUTPUT_TEXTURE_COORD26_EXT 0x87B7 +#define GL_OUTPUT_TEXTURE_COORD27_EXT 0x87B8 +#define GL_OUTPUT_TEXTURE_COORD28_EXT 0x87B9 +#define GL_OUTPUT_TEXTURE_COORD29_EXT 0x87BA +#define GL_OUTPUT_TEXTURE_COORD30_EXT 0x87BB +#define GL_OUTPUT_TEXTURE_COORD31_EXT 0x87BC +#define GL_OUTPUT_FOG_EXT 0x87BD +#define GL_SCALAR_EXT 0x87BE +#define GL_VECTOR_EXT 0x87BF +#define GL_MATRIX_EXT 0x87C0 +#define GL_VARIANT_EXT 0x87C1 +#define GL_INVARIANT_EXT 0x87C2 +#define GL_LOCAL_CONSTANT_EXT 0x87C3 +#define GL_LOCAL_EXT 0x87C4 +#define GL_MAX_VERTEX_SHADER_INSTRUCTIONS_EXT 0x87C5 +#define GL_MAX_VERTEX_SHADER_VARIANTS_EXT 0x87C6 +#define GL_MAX_VERTEX_SHADER_INVARIANTS_EXT 0x87C7 +#define GL_MAX_VERTEX_SHADER_LOCAL_CONSTANTS_EXT 0x87C8 +#define GL_MAX_VERTEX_SHADER_LOCALS_EXT 0x87C9 +#define GL_MAX_OPTIMIZED_VERTEX_SHADER_INSTRUCTIONS_EXT 0x87CA +#define GL_MAX_OPTIMIZED_VERTEX_SHADER_VARIANTS_EXT 0x87CB +#define GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCAL_CONSTANTS_EXT 0x87CC +#define GL_MAX_OPTIMIZED_VERTEX_SHADER_INVARIANTS_EXT 0x87CD +#define GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCALS_EXT 0x87CE +#define GL_VERTEX_SHADER_INSTRUCTIONS_EXT 0x87CF +#define GL_VERTEX_SHADER_VARIANTS_EXT 0x87D0 +#define GL_VERTEX_SHADER_INVARIANTS_EXT 0x87D1 +#define GL_VERTEX_SHADER_LOCAL_CONSTANTS_EXT 0x87D2 +#define GL_VERTEX_SHADER_LOCALS_EXT 0x87D3 +#define GL_VERTEX_SHADER_OPTIMIZED_EXT 0x87D4 +#define GL_X_EXT 0x87D5 +#define GL_Y_EXT 0x87D6 +#define GL_Z_EXT 0x87D7 +#define GL_W_EXT 0x87D8 +#define GL_NEGATIVE_X_EXT 0x87D9 +#define GL_NEGATIVE_Y_EXT 0x87DA +#define GL_NEGATIVE_Z_EXT 0x87DB +#define GL_NEGATIVE_W_EXT 0x87DC +#define GL_ZERO_EXT 0x87DD +#define GL_ONE_EXT 0x87DE +#define GL_NEGATIVE_ONE_EXT 0x87DF +#define GL_NORMALIZED_RANGE_EXT 0x87E0 +#define GL_FULL_RANGE_EXT 0x87E1 +#define GL_CURRENT_VERTEX_EXT 0x87E2 +#define GL_MVP_MATRIX_EXT 0x87E3 +#define GL_VARIANT_VALUE_EXT 0x87E4 +#define GL_VARIANT_DATATYPE_EXT 0x87E5 +#define GL_VARIANT_ARRAY_STRIDE_EXT 0x87E6 +#define GL_VARIANT_ARRAY_TYPE_EXT 0x87E7 +#define GL_VARIANT_ARRAY_EXT 0x87E8 +#define GL_VARIANT_ARRAY_POINTER_EXT 0x87E9 +#define GL_INVARIANT_VALUE_EXT 0x87EA +#define GL_INVARIANT_DATATYPE_EXT 0x87EB +#define GL_LOCAL_CONSTANT_VALUE_EXT 0x87EC +#define GL_LOCAL_CONSTANT_DATATYPE_EXT 0x87ED +#endif + +#ifndef GL_ATI_vertex_streams +#define GL_ATI_vertex_streams +#define _ALLEGRO_GL_ATI_vertex_streams +#define GL_MAX_VERTEX_STREAMS_ATI 0x876B +#define GL_VERTEX_STREAM0_ATI 0x876C +#define GL_VERTEX_STREAM1_ATI 0x876D +#define GL_VERTEX_STREAM2_ATI 0x876E +#define GL_VERTEX_STREAM3_ATI 0x876F +#define GL_VERTEX_STREAM4_ATI 0x8770 +#define GL_VERTEX_STREAM5_ATI 0x8771 +#define GL_VERTEX_STREAM6_ATI 0x8772 +#define GL_VERTEX_STREAM7_ATI 0x8773 +#define GL_VERTEX_SOURCE_ATI 0x8774 +#endif + +#ifndef GL_ATI_element_array +#define GL_ATI_element_array +#define _ALLEGRO_GL_ATI_element_array +#define GL_ELEMENT_ARRAY_ATI 0x8768 +#define GL_ELEMENT_ARRAY_TYPE_ATI 0x8769 +#define GL_ELEMENT_ARRAY_POINTER_ATI 0x876A +#endif + +#ifndef GL_SUN_mesh_array +#define GL_SUN_mesh_array +#define _ALLEGRO_GL_SUN_mesh_array +#define GL_QUAD_MESH_SUN 0x8614 +#define GL_TRIANGLE_MESH_SUN 0x8615 +#endif + +#ifndef GL_SUN_slice_accum +#define GL_SUN_slice_accum +#define _ALLEGRO_GL_SUN_slice_accum +#define GL_SLICE_ACCUM_SUN 0x85CC +#endif + +#ifndef GL_NV_multisample_filter_hint +#define GL_NV_multisample_filter_hint +#define _ALLEGRO_GL_NV_multisample_filter_hint +#define GL_MULTISAMPLE_FILTER_HINT_NV 0x8534 +#endif + +#ifndef GL_NV_depth_clamp +#define GL_NV_depth_clamp +#define _ALLEGRO_GL_NV_depth_clamp +#define GL_DEPTH_CLAMP_NV 0x864F +#endif + +#ifndef GL_NV_occlusion_query +#define GL_NV_occlusion_query +#define _ALLEGRO_GL_NV_occlusion_query +#define GL_PIXEL_COUNTER_BITS_NV 0x8864 +#define GL_CURRENT_OCCLUSION_QUERY_ID_NV 0x8865 +#define GL_PIXEL_COUNT_NV 0x8866 +#define GL_PIXEL_COUNT_AVAILABLE_NV 0x8867 +#endif + +#ifndef GL_NV_point_sprite +#define GL_NV_point_sprite +#define _ALLEGRO_GL_NV_point_sprite +#define GL_POINT_SPRITE_NV 0x8861 +#define GL_COORD_REPLACE_NV 0x8862 +#define GL_POINT_SPRITE_R_MODE_NV 0x8863 +#endif + +#ifndef GL_NV_texture_shader3 +#define GL_NV_texture_shader3 +#define _ALLEGRO_GL_NV_texture_shader3 +#define GL_OFFSET_PROJECTIVE_TEXTURE_2D_NV 0x8850 +#define GL_OFFSET_PROJECTIVE_TEXTURE_2D_SCALE_NV 0x8851 +#define GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_NV 0x8852 +#define GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_SCALE_NV 0x8853 +#define GL_OFFSET_HILO_TEXTURE_2D_NV 0x8854 +#define GL_OFFSET_HILO_TEXTURE_RECTANGLE_NV 0x8855 +#define GL_OFFSET_HILO_PROJECTIVE_TEXTURE_2D_NV 0x8856 +#define GL_OFFSET_HILO_PROJECTIVE_TEXTURE_RECTANGLE_NV 0x8857 +#define GL_DEPENDENT_HILO_TEXTURE_2D_NV 0x8858 +#define GL_DEPENDENT_RGB_TEXTURE_3D_NV 0x8859 +#define GL_DEPENDENT_RGB_TEXTURE_CUBE_MAP_NV 0x885A +#define GL_DOT_PRODUCT_PASS_THROUGH_NV 0x885B +#define GL_DOT_PRODUCT_TEXTURE_1D_NV 0x885C +#define GL_DOT_PRODUCT_AFFINE_DEPTH_REPLACE_NV 0x885D +#define GL_HILO8_NV 0x885E +#define GL_SIGNED_HILO8_NV 0x885F +#define GL_FORCE_BLUE_TO_ONE_NV 0x8860 +#endif + +#ifndef GL_EXT_stencil_two_side +#define GL_EXT_stencil_two_side +#define _ALLEGRO_GL_EXT_stencil_two_side +#define GL_STENCIL_TEST_TWO_SIDE_EXT 0x8910 +#define GL_ACTIVE_STENCIL_FACE_EXT 0x8911 +#endif + +#ifndef GL_ATI_text_fragment_shader +#define GL_ATI_text_fragment_shader +#define _ALLEGRO_GL_ATI_text_fragment_shader +#define GL_TEXT_FRAGMENT_SHADER_ATI 0x8200 +#endif + +#ifndef GL_APPLE_client_storage +#define GL_APPLE_client_storage +#define _ALLEGRO_GL_APPLE_client_storage +#define GL_UNPACK_CLIENT_STORAGE_APPLE 0x85B2 +#endif + +#ifndef GL_APPLE_element_array +#define GL_APPLE_element_array +#define _ALLEGRO_GL_APPLE_element_array +#define GL_ELEMENT_ARRAY_APPLE 0x8768 +#define GL_ELEMENT_ARRAY_TYPE_APPLE 0x8769 +#define GL_ELEMENT_ARRAY_POINTER_APPLE 0x876A +#endif + +#ifndef GL_APPLE_fence +#define GL_APPLE_fence +#define _ALLEGRO_GL_APPLE_fence +#define GL_DRAW_PIXELS_APPLE 0x8A0A +#define GL_FENCE_APPLE 0x8A0B +#endif + +#ifndef GL_APPLE_vertex_array_object +#define GL_APPLE_vertex_array_object +#define _ALLEGRO_GL_APPLE_vertex_array_object +#define GL_VERTEX_ARRAY_BINDING_APPLE 0x85B5 +#endif + +#ifndef GL_APPLE_vertex_array_range +#define GL_APPLE_vertex_array_range +#define _ALLEGRO_GL_APPLE_vertex_array_range +#define GL_VERTEX_ARRAY_RANGE_APPLE 0x851D +#define GL_VERTEX_ARRAY_RANGE_LENGTH_APPLE 0x851E +#define GL_VERTEX_ARRAY_STORAGE_HINT_APPLE 0x851F +#define GL_VERTEX_ARRAY_RANGE_POINTER_APPLE 0x8521 +#define GL_STORAGE_CACHED_APPLE 0x85BE +#define GL_STORAGE_SHARED_APPLE 0x85BF +#endif + +#ifndef GL_APPLE_ycbcr_422 +#define GL_APPLE_ycbcr_422 +#define _ALLEGRO_GL_APPLE_ycbcr_422 +#define GL_YCBCR_422_APPLE 0x85B9 +#define GL_UNSIGNED_SHORT_8_8_APPLE 0x85BA +#define GL_UNSIGNED_SHORT_8_8_REV_APPLE 0x85BB +#endif + +#ifndef GL_S3_s3tc +#define GL_S3_s3tc +#define _ALLEGRO_GL_S3_s3tc +#define GL_RGB_S3TC 0x83A0 +#define GL_RGB4_S3TC 0x83A1 +#define GL_RGBA_S3TC 0x83A2 +#define GL_RGBA4_S3TC 0x83A3 +#endif + +#ifndef GL_ATI_draw_buffers +#define GL_ATI_draw_buffers +#define _ALLEGRO_GL_ATI_draw_buffers +#define GL_MAX_DRAW_BUFFERS_ATI 0x8824 +#define GL_DRAW_BUFFER0_ATI 0x8825 +#define GL_DRAW_BUFFER1_ATI 0x8826 +#define GL_DRAW_BUFFER2_ATI 0x8827 +#define GL_DRAW_BUFFER3_ATI 0x8828 +#define GL_DRAW_BUFFER4_ATI 0x8829 +#define GL_DRAW_BUFFER5_ATI 0x882A +#define GL_DRAW_BUFFER6_ATI 0x882B +#define GL_DRAW_BUFFER7_ATI 0x882C +#define GL_DRAW_BUFFER8_ATI 0x882D +#define GL_DRAW_BUFFER9_ATI 0x882E +#define GL_DRAW_BUFFER10_ATI 0x882F +#define GL_DRAW_BUFFER11_ATI 0x8830 +#define GL_DRAW_BUFFER12_ATI 0x8831 +#define GL_DRAW_BUFFER13_ATI 0x8832 +#define GL_DRAW_BUFFER14_ATI 0x8833 +#define GL_DRAW_BUFFER15_ATI 0x8834 +#endif + +#ifndef GL_ATI_texture_env_combine3 +#define GL_ATI_texture_env_combine3 +#define _ALLEGRO_GL_ATI_texture_env_combine3 +#define GL_MODULATE_ADD_ATI 0x8744 +#define GL_MODULATE_SIGNED_ADD_ATI 0x8745 +#define GL_MODULATE_SUBTRACT_ATI 0x8746 +#endif + +#ifndef GL_ATI_texture_float +#define GL_ATI_texture_float +#define _ALLEGRO_GL_ATI_texture_float +#define GL_RGBA_FLOAT32_ATI 0x8814 +#define GL_RGB_FLOAT32_ATI 0x8815 +#define GL_ALPHA_FLOAT32_ATI 0x8816 +#define GL_INTENSITY_FLOAT32_ATI 0x8817 +#define GL_LUMINANCE_FLOAT32_ATI 0x8818 +#define GL_LUMINANCE_ALPHA_FLOAT32_ATI 0x8819 +#define GL_RGBA_FLOAT16_ATI 0x881A +#define GL_RGB_FLOAT16_ATI 0x881B +#define GL_ALPHA_FLOAT16_ATI 0x881C +#define GL_INTENSITY_FLOAT16_ATI 0x881D +#define GL_LUMINANCE_FLOAT16_ATI 0x881E +#define GL_LUMINANCE_ALPHA_FLOAT16_ATI 0x881F +#endif + +#ifndef GL_NV_float_buffer +#define GL_NV_float_buffer +#define _ALLEGRO_GL_NV_float_buffer +#define GL_FLOAT_R_NV 0x8880 +#define GL_FLOAT_RG_NV 0x8881 +#define GL_FLOAT_RGB_NV 0x8882 +#define GL_FLOAT_RGBA_NV 0x8883 +#define GL_FLOAT_R16_NV 0x8884 +#define GL_FLOAT_R32_NV 0x8885 +#define GL_FLOAT_RG16_NV 0x8886 +#define GL_FLOAT_RG32_NV 0x8887 +#define GL_FLOAT_RGB16_NV 0x8888 +#define GL_FLOAT_RGB32_NV 0x8889 +#define GL_FLOAT_RGBA16_NV 0x888A +#define GL_FLOAT_RGBA32_NV 0x888B +#define GL_TEXTURE_FLOAT_COMPONENTS_NV 0x888C +#define GL_FLOAT_CLEAR_COLOR_VALUE_NV 0x888D +#define GL_FLOAT_RGBA_MODE_NV 0x888E +#endif + +#ifndef GL_NV_fragment_program +#define GL_NV_fragment_program +#define _ALLEGRO_GL_NV_fragment_program +#define GL_MAX_FRAGMENT_PROGRAM_LOCAL_PARAMETERS_NV 0x8868 +#define GL_FRAGMENT_PROGRAM_NV 0x8870 +#define GL_MAX_TEXTURE_COORDS_NV 0x8871 +#define GL_MAX_TEXTURE_IMAGE_UNITS_NV 0x8872 +#define GL_FRAGMENT_PROGRAM_BINDING_NV 0x8873 +#define GL_PROGRAM_ERROR_STRING_NV 0x8874 +#endif + +#ifndef GL_NV_half_float +#define GL_NV_half_float +#define _ALLEGRO_GL_NV_half_float +typedef short GLhalfNV; +#define GL_HALF_FLOAT_NV 0x140B +#endif + +#ifndef GL_NV_pixel_data_range +#define GL_NV_pixel_data_range +#define _ALLEGRO_GL_NV_pixel_data_range +#define GL_WRITE_PIXEL_DATA_RANGE_NV 0x8878 +#define GL_READ_PIXEL_DATA_RANGE_NV 0x8879 +#define GL_WRITE_PIXEL_DATA_RANGE_LENGTH_NV 0x887A +#define GL_READ_PIXEL_DATA_RANGE_LENGTH_NV 0x887B +#define GL_WRITE_PIXEL_DATA_RANGE_POINTER_NV 0x887C +#define GL_READ_PIXEL_DATA_RANGE_POINTER_NV 0x887D +#endif + +#ifndef GL_NV_primitive_restart +#define GL_NV_primitive_restart +#define _ALLEGRO_GL_NV_primitive_restart +#define GL_PRIMITIVE_RESTART_NV 0x8558 +#define GL_PRIMITIVE_RESTART_INDEX_NV 0x8559 +#endif + +#ifndef GL_NV_texture_expand_normal +#define GL_NV_texture_expand_normal +#define _ALLEGRO_GL_NV_texture_expand_normal +#define GL_TEXTURE_UNSIGNED_REMAP_MODE_NV 0x888F +#endif + +#ifndef GL_ATI_map_object_buffer +#define GL_ATI_map_object_buffer +#define _ALLEGRO_GL_ATI_map_object_buffer +#endif + +#ifndef GL_ATI_separate_stencil +#define GL_ATI_separate_stencil +#define GL_STENCIL_BACK_FUNC_ATI 0x8800 +#define GL_STENCIL_BACK_FAIL_ATI 0x8801 +#define GL_STENCIL_BACK_PASS_DEPTH_FAIL_ATI 0x8802 +#define GL_STENCIL_BACK_PASS_DEPTH_PASS_ATI 0x8803 +#endif + +#ifndef GL_ATI_vertex_attrib_array_object +#define GL_ATI_vertex_attrib_array_object +#define _ALLEGRO_GL_ATI_vertex_attrib_array_object +#endif + +#ifndef GL_OES_byte_coordinates +#define GL_OES_byte_coordinates +#define _ALLEGRO_GL_OES_byte_coordinates +/* GL_BYTE */ +#endif + +#ifndef GL_OES_fixed_point +#define GL_OES_fixed_point +#define _ALLEGRO_GL_OES_fixed_point +typedef int GLfixed; +typedef int GLclampx; +#define GL_FIXED_OES 0x140C +#endif + +#ifndef GL_OES_single_precision +#define GL_OES_single_precision +#define _ALLEGRO_GL_OES_single_precision +#endif + +#ifndef GL_OES_compressed_paletted_texture +#define GL_OES_compressed_paletted_texture +#define _ALLEGRO_GL_OES_compressed_paletted_texture +#define GL_PALETTE4_RGB8_OES 0x8B90 +#define GL_PALETTE4_RGBA8_OES 0x8B91 +#define GL_PALETTE4_R5_G6_B5_OES 0x8B92 +#define GL_PALETTE4_RGBA4_OES 0x8B93 +#define GL_PALETTE4_RGB5_A1_OES 0x8B94 +#define GL_PALETTE8_RGB8_OES 0x8B95 +#define GL_PALETTE8_RGBA8_OES 0x8B96 +#define GL_PALETTE8_R5_G6_B5_OES 0x8B97 +#define GL_PALETTE8_RGBA4_OES 0x8B98 +#define GL_PALETTE8_RGB5_A1_OES 0x8B99 +#endif + +#ifndef GL_OES_read_format +#define GL_OES_read_format +#define _ALLEGRO_GL_OES_read_format +#define GL_IMPLEMENTATION_COLOR_READ_TYPE_OES 0x8B9A +#define GL_IMPLEMENTATION_COLOR_READ_FORMAT_OES 0x8B9B +#endif + +#ifndef GL_OES_query_matrix +#define GL_OES_query_matrix +#define _ALLEGRO_GL_OES_query_matrix +#endif + +#ifndef GL_OES_framebuffer_object +#define GL_OES_framebuffer_object +#define GL_FRAMEBUFFER_OES 0x8D40 +#define GL_RENDERBUFFER_OES 0x8D41 +#define GL_DEPTH_COMPONENT16_OES 0x81A5 +#define GL_RGBA4_OES 0x8056 +#define GL_RGB5_A1_OES 0x8057 +#define GL_RGB565_OES 0x8D62 +#define GL_STENCIL_INDEX1_OES 0x8D46 +#define GL_STENCIL_INDEX4_OES 0x8D47 +#define GL_STENCIL_INDEX8_OES 0x8D48 +#define GL_RENDERBUFFER_WIDTH_OES 0x8D42 +#define GL_RENDERBUFFER_HEIGHT_OES 0x8D43 +#define GL_RENDERBUFFER_INTERNAL_FORMAT_OES 0x8D44 +#define GL_RENDERBUFFER_RED_SIZE_OES 0x8D50 +#define GL_RENDERBUFFER_GREEN_SIZE_OES 0x8D51 +#define GL_RENDERBUFFER_BLUE_SIZE_OES 0x8D52 +#define GL_RENDERBUFFER_ALPHA_SIZE_OES 0x8D53 +#define GL_RENDERBUFFER_DEPTH_SIZE_OES 0x8D54 +#define GL_RENDERBUFFER_STENCIL_SIZE_OES 0x8D55 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE_OES 0x8CD0 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME_OES 0x8CD1 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL_OES 0x8CD2 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE_OES 0x8CD3 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_OES 0x8CD4 +#define GL_COLOR_ATTACHMENT0_OES 0x8CE0 +#define GL_DEPTH_ATTACHMENT_OES 0x8D00 +#define GL_STENCIL_ATTACHMENT_OES 0x8D20 +#define GL_GL_NONE_OES 0 +#define GL_FRAMEBUFFER_COMPLETE_OES 0x8CD5 +#define GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT_OES 0x8CD6 +#define GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT_OES 0x8CD7 +#define GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS_OES 0x8CD9 +#define GL_FRAMEBUFFER_INCOMPLETE_FORMATS_OES 0x8CDA +#define GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER_OES 0x8CDB +#define GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER_OES 0x8CDC +#define GL_FRAMEBUFFER_UNSUPPORTED_OES 0x8CDD +#define GL_FRAMEBUFFER_BINDING_OES 0x8CA6 +#define GL_RENDERBUFFER_BINDING_OES 0x8CA7 +#define GL_MAX_RENDERBUFFER_SIZE_OES 0x84E8 +#define GL_INVALID_FRAMEBUFFER_OPERATION_OES 0x0506 +#endif + +#ifndef GL_OES_depth24 +#define GL_OES_depth24 +#define DEPTH_COMPONENT24_OES 0x81A6 +#endif + +#ifndef GL_EXT_depth_bounds_test +#define GL_EXT_depth_bounds_test +#define _ALLEGRO_GL_EXT_depth_bounds_test +#define GL_DEPTH_BOUNDS_TEST_EXT 0x8890 +#define GL_DEPTH_BOUNDS_EXT 0x8891 +#endif + +#ifndef GL_EXT_texture_mirror_clamp +#define GL_EXT_texture_mirror_clamp +#define _ALLEGRO_GL_EXT_texture_mirror_clamp +#define GL_MIRROR_CLAMP_EXT 0x8742 +#define GL_MIRROR_CLAMP_TO_EDGE_EXT 0x8743 +#define GL_MIRROR_CLAMP_TO_BORDER_EXT 0x8912 +#endif + +#ifndef GL_EXT_blend_equation_separate +#define GL_EXT_blend_equation_separate +#define _ALLEGRO_GL_EXT_blend_equation_separate +#define GL_BLEND_EQUATION_RGB_EXT 0x8009 /* Same as GL_BLEND_EQUATION */ +#define GL_BLEND_EQUATION_ALPHA_EXT 0x883D +#endif + +#ifndef GL_MESA_pack_invert +#define GL_MESA_pack_invert +#define _ALLEGRO_GL_MESA_pack_invert +#define GL_PACK_INVERT_MESA 0x8758 +#endif + +#ifndef GL_MESA_ycbcr_texture +#define GL_MESA_ycbcr_texture +#define _ALLEGRO_GL_MESA_ycbcr_texture +#define GL_YCBCR_MESA 0x8757 +/* Same as GL_UNSIGNED_SHORT_8_8_APPLE and GL_UNSIGNED_SHORT_8_8_REV_APPLE */ +#define GL_UNSIGNED_SHORT_8_8_MESA 0x85BA +#define GL_UNSIGNED_SHORT_8_8_REV_MESA 0x85BB +#endif + + +#ifndef GL_EXT_pixel_buffer_object +#define GL_EXT_pixel_buffer_object +#define _ALLEGRO_GL_EXT_pixel_buffer_object +#define GL_PIXEL_PACK_BUFFER_EXT 0x88EB +#define GL_PIXEL_UNPACK_BUFFER_EXT 0x88EC +#define GL_PIXEL_PACK_BUFFER_BINDING_EXT 0x88ED +#define GL_PIXEL_UNPACK_BUFFER_BINDING_EXT 0x88EF +#endif + + + +#ifndef GL_NV_fragment_program_option +#define GL_NV_fragment_program_option +#define _ALLEGRO_GL_NV_fragment_program_option +#endif + + + +#ifndef GL_NV_fragment_program2 +#define GL_NV_fragment_program2 +#define _ALLEGRO_GL_NV_fragment_program2 +#define GL_MAX_PROGRAM_EXEC_INSTRUCTIONS_NV 0x88F4 +#define GL_MAX_PROGRAM_CALL_DEPTH_NV 0x88F5 +#define GL_MAX_PROGRAM_IF_DEPTH_NV 0x88F6 +#define GL_MAX_PROGRAM_LOOP_DEPTH_NV 0x88F7 +#define GL_MAX_PROGRAM_LOOP_COUNT_NV 0x88F8 +#endif + + + +#ifndef GL_NV_vertex_program2_option +#define GL_NV_vertex_program2_option +#define _ALLEGRO_GL_NV_vertex_program2_option +#define GL_MAX_PROGRAM_EXEC_INSTRUCTIONS_NV 0x88F4 +#define GL_MAX_PROGRAM_CALL_DEPTH_NV 0x88F5 +#endif + + + +#ifndef GL_NV_vertex_program3 +#define GL_NV_vertex_program3 +#define _ALLEGRO_GL_NV_vertex_program3 +#define GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB 0x8B4C +#endif + + +#ifndef GL_EXT_texture_compression_dxt1 +#define GL_EXT_texture_compression_dxt1 +#define _ALLEGRO_GL_EXT_texture_compression_dxt1 +#ifndef ALLEGRO_GL_EXT_texture_compression_s3tc +#define GL_COMPRESSED_RGB_S3TC_DXT1_EXT 0x83F0 +#define GL_COMPRESSED_RGBA_S3TC_DXT1_EXT 0x83F1 +#endif +#endif + + +#ifndef GL_EXT_framebuffer_object +#define GL_EXT_framebuffer_object +#define _ALLEGRO_GL_EXT_framebuffer_object +#define GL_FRAMEBUFFER_EXT 0x8D40 +#define GL_RENDERBUFFER_EXT 0x8D41 +#define GL_STENCIL_INDEX_EXT 0x8D45 +#define GL_STENCIL_INDEX1_EXT 0x8D46 +#define GL_STENCIL_INDEX4_EXT 0x8D47 +#define GL_STENCIL_INDEX8_EXT 0x8D48 +#define GL_STENCIL_INDEX16_EXT 0x8D49 +#define GL_RENDERBUFFER_WIDTH_EXT 0x8D42 +#define GL_RENDERBUFFER_HEIGHT_EXT 0x8D43 +#define GL_RENDERBUFFER_INTERNAL_FORMAT_EXT 0x8D44 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE_EXT 0x8CD0 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME_EXT 0x8CD1 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL_EXT 0x8CD2 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE_EXT 0x8CD3 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_EXT 0x8CD4 +#define GL_COLOR_ATTACHMENT0_EXT 0x8CE0 +#define GL_COLOR_ATTACHMENT1_EXT 0x8CE1 +#define GL_COLOR_ATTACHMENT2_EXT 0x8CE2 +#define GL_COLOR_ATTACHMENT3_EXT 0x8CE3 +#define GL_COLOR_ATTACHMENT4_EXT 0x8CE4 +#define GL_COLOR_ATTACHMENT5_EXT 0x8CE5 +#define GL_COLOR_ATTACHMENT6_EXT 0x8CE6 +#define GL_COLOR_ATTACHMENT7_EXT 0x8CE7 +#define GL_COLOR_ATTACHMENT8_EXT 0x8CE8 +#define GL_COLOR_ATTACHMENT9_EXT 0x8CE9 +#define GL_COLOR_ATTACHMENT10_EXT 0x8CEA +#define GL_COLOR_ATTACHMENT11_EXT 0x8CEB +#define GL_COLOR_ATTACHMENT12_EXT 0x8CEC +#define GL_COLOR_ATTACHMENT13_EXT 0x8CED +#define GL_COLOR_ATTACHMENT14_EXT 0x8CEE +#define GL_COLOR_ATTACHMENT15_EXT 0x8CEF +#define GL_DEPTH_ATTACHMENT_EXT 0x8D00 +#define GL_STENCIL_ATTACHMENT_EXT 0x8D20 +#define GL_FRAMEBUFFER_COMPLETE_EXT 0x8CD5 +#define GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT_EXT 0x8CD6 +#define GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT_EXT 0x8CD7 +#define GL_FRAMEBUFFER_INCOMPLETE_DUPLICATE_ATTACHMENT_EXT 0x8CD8 +#define GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS_EXT 0x8CD9 +#define GL_FRAMEBUFFER_INCOMPLETE_FORMATS_EXT 0x8CDA +#define GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER_EXT 0x8CDB +#define GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER_EXT 0x8CDC +#define GL_FRAMEBUFFER_UNSUPPORTED_EXT 0x8CDD +#define GL_FRAMEBUFFER_STATUS_ERROR_EXT 0x8CDE +#define GL_FRAMEBUFFER_BINDING_EXT 0x8CA6 +#define GL_RENDERBUFFER_BINDING_EXT 0x8CA7 +#define GL_MAX_COLOR_ATTACHMENTS_EXT 0x8CDF +#define GL_MAX_RENDERBUFFER_SIZE_EXT 0x84E8 +#define GL_INVALID_FRAMEBUFFER_OPERATION_EXT 0x0506 +#endif + + +#ifndef GL_GREMEDY_string_marker +#define GL_GREMEDY_string_marker +#define _ALLEGRO_GL_GREMEDY_string_marker +#endif + + +#ifndef GL_EXT_packed_depth_stencil +#define GL_EXT_packed_depth_stencil +#define _ALLEGRO_GL_EXT_packed_depth_stencil +#define GL_DEPTH_STENCIL_EXT 0x84F9 +#define GL_UNSIGNED_INT_24_8_EXT 0x84FA +#define GL_DEPTH24_STENCIL8_EXT 0x88F0 +#define GL_TEXTURE_STENCIL_SIZE_EXT 0x88F1 +#endif + +#ifndef GL_EXT_stencil_clear_tag +#define GL_EXT_stencil_clear_tag +#define _ALLEGRO_GL_EXT_stencil_clear_tag +#define GL_STENCIL_TAG_BITS_EXT 0x88F2 +#define GL_STENCIL_CLEAR_TAG_VALUE_EXT 0x88F3 +#endif + +#ifndef GL_EXT_texture_sRGB +#define GL_EXT_texture_sRGB +#define _ALLEGRO_GL_EXT_texture_sRGB +#define GL_SRGB_EXT 0x8C40 +#define GL_SRGB8_EXT 0x8C41 +#define GL_SRGB_ALPHA_EXT 0x8C42 +#define GL_SRGB8_ALPHA8_EXT 0x8C43 +#define GL_SLUMINANCE_ALPHA_EXT 0x8C44 +#define GL_SLUMINANCE8_ALPHA8_EXT 0x8C45 +#define GL_SLUMINANCE_EXT 0x8C46 +#define GL_SLUMINANCE8_EXT 0x8C47 +#define GL_COMPRESSED_SRGB_EXT 0x8C48 +#define GL_COMPRESSED_SRGB_ALPHA_EXT 0x8C49 +#define GL_COMPRESSED_SLUMINANCE_EXT 0x8C4A +#define GL_COMPRESSED_SLUMINANCE_ALPHA_EXT 0x8C4B +#define GL_COMPRESSED_SRGB_S3TC_DXT1_EXT 0x8C4C +#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT 0x8C4D +#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT 0x8C4E +#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT 0x8C4F +#endif + +#ifndef GL_EXT_framebuffer_blit +#define GL_EXT_framebuffer_blit +#define _ALLEGRO_GL_EXT_framebuffer_blit +#define GL_READ_FRAMEBUFFER_EXT 0x8CA8 +#define GL_DRAW_FRAMEBUFFER_EXT 0x8CA9 +#define GL_READ_FRAMEBUFFER_BINDING_EXT GL_FRAMEBUFFER_BINDING_EXT +#define GL_DRAW_FRAMEBUFFER_BINDING_EXT 0x8CAA +#endif + +#ifndef GL_EXT_framebuffer_multisample +#define GL_EXT_framebuffer_multisample +#define _ALLEGRO_GL_EXT_framebuffer_multisample +#define GL_RENDERBUFFER_SAMPLES_EXT 0x8CAB +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_EXT 0x8D56 +#define GL_MAX_SAMPLES_EXT 0x8D57 +#endif + +#ifndef GL_MESAX_texture_stack +#define GL_MESAX_texture_stack +#define _ALLEGRO_GL_MESAX_texture_stack +#define GL_TEXTURE_1D_STACK_MESAX 0x8759 +#define GL_TEXTURE_2D_STACK_MESAX 0x875A +#define GL_PROXY_TEXTURE_1D_STACK_MESAX 0x875B +#define GL_PROXY_TEXTURE_2D_STACK_MESAX 0x875C +#define GL_TEXTURE_1D_STACK_BINDING_MESAX 0x875D +#define GL_TEXTURE_2D_STACK_BINDING_MESAX 0x875E +#endif + +#ifndef GL_EXT_timer_query +#define GL_EXT_timer_query +#define _ALLEGRO_GL_EXT_timer_query +#if (defined _MSC_VER) && (_MSC_VER < 1400) +typedef __int64 GLint64EXT; +typedef unsigned __int64 GLuint64EXT; +#else +typedef int64_t GLint64EXT; +typedef uint64_t GLuint64EXT; +#endif +#define GL_TIME_ELAPSED_EXT 0x88BF +#endif + +#ifndef GL_EXT_gpu_program_parameters +#define GL_EXT_gpu_program_parameters +#define _ALLEGRO_GL_EXT_gpu_program_parameters +#endif + +#ifndef GL_APPLE_flush_buffer_range +#define GL_APPLE_flush_buffer_range +#define _ALLEGRO_GL_APPLE_flush_buffer_range +#define GL_BUFFER_SERIALIZED_MODIFY_APPLE 0x8A12 +#define GL_BUFFER_FLUSHING_UNMAP_APPLE 0x8A13 +#endif + +#ifndef GL_EXT_bindable_uniform +#define GL_EXT_bindable_uniform +#define _ALLEGRO_GL_EXT_bindable_uniform +#define GL_MAX_VERTEX_BINDABLE_UNIFORMS_EXT 0x8DE2 +#define GL_MAX_FRAGMENT_BINDABLE_UNIFORMS_EXT 0x8DE3 +#define GL_MAX_GEOMETRY_BINDABLE_UNIFORMS_EXT 0x8DE4 +#define GL_MAX_BINDABLE_UNIFORM_SIZE_EXT 0x8DED +#define GL_UNIFORM_BUFFER_BINDING_EXT 0x8DEF +#define GL_UNIFORM_BUFFER_EXT 0x8DEE +#endif + +#ifndef GL_EXT_draw_buffers2 +#define GL_EXT_draw_buffers2 +#define _ALLEGRO_GL_EXT_draw_buffers2 +#endif + +#ifndef GL_EXT_draw_instanced +#define GL_EXT_draw_instanced +#define _ALLEGRO_GL_EXT_draw_instanced +#endif + +#ifndef GL_EXT_framebuffer_sRGB +#define GL_EXT_framebuffer_sRGB +#define _ALLEGRO_GL_EXT_framebuffer_sRGB +#define GL_FRAMEBUFFER_SRGB_EXT 0x8DB9 +#define GL_FRAMEBUFFER_SRGB_CAPABLE_EXT 0x8DBA +#endif + +#ifndef GL_EXT_geometry_shader4 +#define GL_EXT_geometry_shader4 +#define _ALLEGRO_GL_EXT_geometry_shader4 +#define GL_GEOMETRY_SHADER_EXT 0x8DD9 +#define GL_GEOMETRY_VERTICES_OUT_EXT 0x8DDA +#define GL_GEOMETRY_INPUT_TYPE_EXT 0x8DDB +#define GL_GEOMETRY_OUTPUT_TYPE_EXT 0x8DDC +#define GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_EXT 0x8C29 +#define GL_MAX_GEOMETRY_VARYING_COMPONENTS_EXT 0x8DDD +#define GL_MAX_VERTEX_VARYING_COMPONENTS_EXT 0x8DDE +#define GL_MAX_VARYING_COMPONENTS_EXT 0x8B4B +#define GL_MAX_GEOMETRY_UNIFORM_COMPONENTS_EXT 0x8DDF +#define GL_MAX_GEOMETRY_OUTPUT_VERTICES_EXT 0x8DE0 +#define GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_EXT 0x8DE1 +#define GL_LINES_ADJACENCY_EXT 0xA +#define GL_LINE_STRIP_ADJACENCY_EXT 0xB +#define GL_TRIANGLES_ADJACENCY_EXT 0xC +#define GL_TRIANGLE_STRIP_ADJACENCY_EXT 0xD +#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_EXT 0x8DA8 +#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_EXT 0x8DA9 +#define GL_FRAMEBUFFER_ATTACHMENT_LAYERED_EXT 0x8DA7 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT 0x8CD4 +#define GL_PROGRAM_POINT_SIZE_EXT 0x8642 +#endif + +#ifndef GL_EXT_gpu_shader4 +#define GL_EXT_gpu_shader4 +#define _ALLEGRO_GL_EXT_gpu_shader4 +#define GL_VERTEX_ATTRIB_ARRAY_INTEGER_EXT 0x88FD +#define GL_SAMPLER_1D_ARRAY_EXT 0x8DC0 +#define GL_SAMPLER_2D_ARRAY_EXT 0x8DC1 +#define GL_SAMPLER_BUFFER_EXT 0x8DC2 +#define GL_SAMPLER_1D_ARRAY_SHADOW_EXT 0x8DC3 +#define GL_SAMPLER_2D_ARRAY_SHADOW_EXT 0x8DC4 +#define GL_SAMPLER_CUBE_SHADOW_EXT 0x8DC5 +#define GL_UNSIGNED_INT 0x1405 +#define GL_UNSIGNED_INT_VEC2_EXT 0x8DC6 +#define GL_UNSIGNED_INT_VEC3_EXT 0x8DC7 +#define GL_UNSIGNED_INT_VEC4_EXT 0x8DC8 +#define GL_INT_SAMPLER_1D_EXT 0x8DC9 +#define GL_INT_SAMPLER_2D_EXT 0x8DCA +#define GL_INT_SAMPLER_3D_EXT 0x8DCB +#define GL_INT_SAMPLER_CUBE_EXT 0x8DCC +#define GL_INT_SAMPLER_2D_RECT_EXT 0x8DCD +#define GL_INT_SAMPLER_1D_ARRAY_EXT 0x8DCE +#define GL_INT_SAMPLER_2D_ARRAY_EXT 0x8DCF +#define GL_INT_SAMPLER_BUFFER_EXT 0x8DD0 +#define GL_UNSIGNED_INT_SAMPLER_1D_EXT 0x8DD1 +#define GL_UNSIGNED_INT_SAMPLER_2D_EXT 0x8DD2 +#define GL_UNSIGNED_INT_SAMPLER_3D_EXT 0x8DD3 +#define GL_UNSIGNED_INT_SAMPLER_CUBE_EXT 0x8DD4 +#define GL_UNSIGNED_INT_SAMPLER_2D_RECT_EXT 0x8DD5 +#define GL_UNSIGNED_INT_SAMPLER_1D_ARRAY_EXT 0x8DD6 +#define GL_UNSIGNED_INT_SAMPLER_2D_ARRAY_EXT 0x8DD7 +#define GL_UNSIGNED_INT_SAMPLER_BUFFER_EXT 0x8DD8 +#define GL_MIN_PROGRAM_TEXEL_OFFSET_EXT 0x8904 +#define GL_MAX_PROGRAM_TEXEL_OFFSET_EXT 0x8905 +#endif + +#ifndef GL_EXT_packed_float +#define GL_EXT_packed_float +#define _ALLEGRO_GL_EXT_packed_float +#define GL_R11F_G11F_B10F_EXT 0x8C3A +#define GL_UNSIGNED_INT_10F_11F_11F_REV_EXT 0x8C3B +#define GL_RGBA_SIGNED_COMPONENTS_EXT 0x8C3C +#endif + +#ifndef GL_EXT_texture_array +#define GL_EXT_texture_array +#define _ALLEGRO_GL_EXT_texture_array +#define GL_TEXTURE_1D_ARRAY_EXT 0x8C18 +#define GL_TEXTURE_2D_ARRAY_EXT 0x8C1A +#define GL_PROXY_TEXTURE_2D_ARRAY_EXT 0x8C1B +#define GL_PROXY_TEXTURE_1D_ARRAY_EXT 0x8C19 +#define GL_TEXTURE_BINDING_1D_ARRAY_EXT 0x8C1C +#define GL_TEXTURE_BINDING_2D_ARRAY_EXT 0x8C1D +#define GL_MAX_ARRAY_TEXTURE_LAYERS_EXT 0x88FF +#define GL_COMPARE_REF_DEPTH_TO_TEXTURE_EXT 0x884E +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT 0x8CD4 +#define GL_SAMPLER_1D_ARRAY_EXT 0x8DC0 +#define GL_SAMPLER_2D_ARRAY_EXT 0x8DC1 +#define GL_SAMPLER_1D_ARRAY_SHADOW_EXT 0x8DC3 +#define GL_SAMPLER_2D_ARRAY_SHADOW_EXT 0x8DC4 +#endif + +#ifndef GL_EXT_texture_buffer_object +#define GL_EXT_texture_buffer_object +#define _ALLEGRO_GL_EXT_texture_buffer_object +#define GL_TEXTURE_BUFFER_EXT 0x8C2A +#define GL_MAX_TEXTURE_BUFFER_SIZE_EXT 0x8C2B +#define GL_TEXTURE_BINDING_BUFFER_EXT 0x8C2C +#define GL_TEXTURE_BUFFER_DATA_STORE_BINDING_EXT 0x8C2D +#define GL_TEXTURE_BUFFER_FORMAT_EXT 0x8C2E +#endif + +#ifndef GL_EXT_texture_compression_latc +#define GL_EXT_texture_compression_latc +#define _ALLEGRO_GL_EXT_texture_compression_latc +#define GL_COMPRESSED_LUMINANCE_LATC1_EXT 0x8C70 +#define GL_COMPRESSED_SIGNED_LUMINANCE_LATC1_EXT 0x8C71 +#define GL_COMPRESSED_LUMINANCE_ALPHA_LATC2_EXT 0x8C72 +#define GL_COMPRESSED_SIGNED_LUMINANCE_ALPHA_LATC2_EXT 0x8C73 +#endif + +#ifndef GL_EXT_texture_compression_rgtc +#define GL_EXT_texture_compression_rgtc +#define _ALLEGRO_GL_EXT_texture_compression_rgtc +#define GL_COMPRESSED_RED_RGTC1_EXT 0x8DBB +#define GL_COMPRESSED_SIGNED_RED_RGTC1_EXT 0x8DBC +#define GL_COMPRESSED_RED_GREEN_RGTC2_EXT 0x8DBD +#define GL_COMPRESSED_SIGNED_RED_GREEN_RGTC2_EXT 0x8DBE +#endif + +#ifndef GL_EXT_texture_integer +#define GL_EXT_texture_integer +#define _ALLEGRO_GL_EXT_texture_integer +#define GL_RGBA_INTEGER_MODE_EXT 0x8D9E +#define GL_RGBA32UI_EXT 0x8D70 +#define GL_RGB32UI_EXT 0x8D71 +#define GL_ALPHA32UI_EXT 0x8D72 +#define GL_INTENSITY32UI_EXT 0x8D73 +#define GL_LUMINANCE32UI_EXT 0x8D74 +#define GL_LUMINANCE_ALPHA32UI_EXT 0x8D75 +#define GL_RGBA16UI_EXT 0x8D76 +#define GL_RGB16UI_EXT 0x8D77 +#define GL_ALPHA16UI_EXT 0x8D78 +#define GL_INTENSITY16UI_EXT 0x8D79 +#define GL_LUMINANCE16UI_EXT 0x8D7A +#define GL_LUMINANCE_ALPHA16UI_EXT 0x8D7B +#define GL_RGBA8UI_EXT 0x8D7C +#define GL_RGB8UI_EXT 0x8D7D +#define GL_ALPHA8UI_EXT 0x8D7E +#define GL_INTENSITY8UI_EXT 0x8D7F +#define GL_LUMINANCE8UI_EXT 0x8D80 +#define GL_LUMINANCE_ALPHA8UI_EXT 0x8D81 +#define GL_RGBA32I_EXT 0x8D82 +#define GL_RGB32I_EXT 0x8D83 +#define GL_ALPHA32I_EXT 0x8D84 +#define GL_INTENSITY32I_EXT 0x8D85 +#define GL_LUMINANCE32I_EXT 0x8D86 +#define GL_LUMINANCE_ALPHA32I_EXT 0x8D87 +#define GL_RGBA16I_EXT 0x8D88 +#define GL_RGB16I_EXT 0x8D89 +#define GL_ALPHA16I_EXT 0x8D8A +#define GL_INTENSITY16I_EXT 0x8D8B +#define GL_LUMINANCE16I_EXT 0x8D8C +#define GL_LUMINANCE_ALPHA16I_EXT 0x8D8D +#define GL_RGBA8I_EXT 0x8D8E +#define GL_RGB8I_EXT 0x8D8F +#define GL_ALPHA8I_EXT 0x8D90 +#define GL_INTENSITY8I_EXT 0x8D91 +#define GL_LUMINANCE8I_EXT 0x8D92 +#define GL_LUMINANCE_ALPHA8I_EXT 0x8D93 +#define GL_RED_INTEGER_EXT 0x8D94 +#define GL_GREEN_INTEGER_EXT 0x8D95 +#define GL_BLUE_INTEGER_EXT 0x8D96 +#define GL_ALPHA_INTEGER_EXT 0x8D97 +#define GL_RGB_INTEGER_EXT 0x8D98 +#define GL_RGBA_INTEGER_EXT 0x8D99 +#define GL_BGR_INTEGER_EXT 0x8D9A +#define GL_BGRA_INTEGER_EXT 0x8D9B +#define GL_LUMINANCE_INTEGER_EXT 0x8D9C +#define GL_LUMINANCE_ALPHA_INTEGER_EXT 0x8D9D +#endif + +#ifndef GL_EXT_texture_shared_exponent +#define GL_EXT_texture_shared_exponent +#define _ALLEGRO_GL_EXT_texture_shared_exponent +#define GL_RGB9_E5_EXT 0x8C3D +#define GL_UNSIGNED_INT_5_9_9_9_REV_EXT 0x8C3E +#define GL_TEXTURE_SHARED_SIZE_EXT 0x8C3F +#endif + +#ifndef GL_NV_depth_buffer_float +#define GL_NV_depth_buffer_float +#define _ALLEGRO_GL_NV_depth_buffer_float +#define GL_DEPTH_COMPONENT32F_NV 0x8DAB +#define GL_DEPTH32F_STENCIL8_NV 0x8DAC +#define GL_FLOAT_32_UNSIGNED_INT_24_8_REV_NV 0x8DAD +#define GL_DEPTH_BUFFER_FLOAT_MODE_NV 0x8DAF +#endif + +#ifndef GL_NV_fragment_program4 +#define GL_NV_fragment_program4 +#define _ALLEGRO_GL_NV_fragment_program4 +#endif + +#ifndef GL_NV_framebuffer_multisample_coverage +#define GL_NV_framebuffer_multisample_coverage +#define _ALLEGRO_GL_NV_framebuffer_multisample_coverage +#define GL_RENDERBUFFER_COVERAGE_SAMPLES_NV 0x8CAB +#define GL_RENDERBUFFER_COLOR_SAMPLES_NV 0x8E10 +#endif + +#ifndef GL_NV_geometry_program4 +#define GL_NV_geometry_program4 +#define _ALLEGRO_GL_NV_geometry_program4 +#define GL_GEOMETRY_PROGRAM_NV 0x8C26 +#define GL_MAX_PROGRAM_OUTPUT_VERTICES_NV 0x8C27 +#define GL_MAX_PROGRAM_TOTAL_OUTPUT_COMPONENTS_NV 0x8C28 +#if !defined GL_EXT_geometry_shader4 +#define GL_GEOMETRY_VERTICES_OUT_EXT 0x8DDA +#define GL_GEOMETRY_INPUT_TYPE_EXT 0x8DDB +#define GL_GEOMETRY_OUTPUT_TYPE_EXT 0x8DDC +#define GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_EXT 0x8C29 +#define GL_LINES_ADJACENCY_EXT 0xA +#define GL_LINE_STRIP_ADJACENCY_EXT 0xB +#define GL_TRIANGLES_ADJACENCY_EXT 0xC +#define GL_TRIANGLE_STRIP_ADJACENCY_EXT 0xD +#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_EXT 0x8DA8 +#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_EXT 0x8DA9 +#define GL_FRAMEBUFFER_ATTACHMENT_LAYERED_EXT 0x8DA7 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT 0x8CD4 +#define GL_PROGRAM_POINT_SIZE_EXT 0x8642 +#endif +#endif + +#ifndef GL_NV_gpu_program4 +#define GL_NV_gpu_program4 +#define _ALLEGRO_GL_NV_gpu_program4 +#define GL_MIN_PROGRAM_TEXEL_OFFSET_EXT 0x8904 +#define GL_MAX_PROGRAM_TEXEL_OFFSET_EXT 0x8905 +#define GL_PROGRAM_ATTRIB_COMPONENTS_NV 0x8906 +#define GL_PROGRAM_RESULT_COMPONENTS_NV 0x8907 +#define GL_MAX_PROGRAM_ATTRIB_COMPONENTS_NV 0x8908 +#define GL_MAX_PROGRAM_RESULT_COMPONENTS_NV 0x8909 +#define GL_MAX_PROGRAM_GENERIC_ATTRIBS_NV 0x8DA5 +#define GL_MAX_PROGRAM_GENERIC_RESULTS_NV 0x8DA6 +#endif + +#ifndef GL_NV_parameter_buffer_object +#define GL_NV_parameter_buffer_object +#define _ALLEGRO_GL_NV_parameter_buffer_object +#define GL_MAX_PROGRAM_PARAMETER_BUFFER_BINDINGS_NV 0x8DA0 +#define GL_MAX_PROGRAM_PARAMETER_BUFFER_SIZE_NV 0x8DA1 +#define GL_VERTEX_PROGRAM_PARAMETER_BUFFER_NV 0x8DA2 +#define GL_GEOMETRY_PROGRAM_PARAMETER_BUFFER_NV 0x8DA3 +#define GL_FRAGMENT_PROGRAM_PARAMETER_BUFFER_NV 0x8DA4 +#endif + +#ifndef GL_NV_transform_feedback +#define GL_NV_transform_feedback +#define _ALLEGRO_GL_NV_transform_feedback +#define GL_TRANSFORM_FEEDBACK_BUFFER_NV 0x8C8E +#define GL_TRANSFORM_FEEDBACK_BUFFER_START_NV 0x8C84 +#define GL_TRANSFORM_FEEDBACK_BUFFER_SIZE_NV 0x8C85 +#define GL_TRANSFORM_FEEDBACK_RECORD_NV 0x8C86 +#define GL_TRANSFORM_FEEDBACK_BUFFER_BINDING_NV 0x8C8F +#define GL_INTERLEAVED_ATTRIBS_NV 0x8C8C +#define GL_SEPARATE_ATTRIBS_NV 0x8C8D +#define GL_PRIMITIVES_GENERATED_NV 0x8C87 +#define GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN_NV 0x8C88 +#define GL_RASTERIZER_DISCARD_NV 0x8C89 +#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS_NV 0x8C8A +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS_NV 0x8C8B +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS_NV 0x8C80 +#define GL_TRANSFORM_FEEDBACK_ATTRIBS_NV 0x8C7E +#define GL_ACTIVE_VARYINGS_NV 0x8C81 +#define GL_ACTIVE_VARYING_MAX_LENGTH_NV 0x8C82 +#define GL_TRANSFORM_FEEDBACK_VARYINGS_NV 0x8C83 +#define GL_TRANSFORM_FEEDBACK_BUFFER_MODE_NV 0x8C7F +#define GL_BACK_PRIMARY_COLOR_NV 0x8C77 +#define GL_BACK_SECONDARY_COLOR_NV 0x8C78 +#define GL_TEXTURE_COORD_NV 0x8C79 +#define GL_CLIP_DISTANCE_NV 0x8C7A +#define GL_VERTEX_ID_NV 0x8C7B +#define GL_PRIMITIVE_ID_NV 0x8C7C +#define GL_GENERIC_ATTRIB_NV 0x8C7D +#if !defined GL_NV_register_combiners +#define GL_SECONDARY_COLOR_NV 0x852D +#endif +#if !defined GL_EXT_gpu_shader4 +#define GL_UNSIGNED_INT_VEC2_EXT 0x8DC6 +#define GL_UNSIGNED_INT_VEC3_EXT 0x8DC7 +#define GL_UNSIGNED_INT_VEC4_EXT 0x8DC8 +#endif +#endif + +#ifndef GL_NV_vertex_program4 +#define GL_NV_vertex_program4 +#define _ALLEGRO_GL_NV_vertex_program4 +#if !defined GL_EXT_vertex_shader4 +#define GL_VERTEX_ATTRIB_ARRAY_INTEGER_EXT 0x88FD +#endif +#endif + +#ifndef GL_GREMEDY_frame_terminator +#define GL_GREMEDY_frame_terminator +#define _ALLEGRO_GL_GREMEDY_frame_terminator +#endif + +#ifndef GL_NV_conditional_render +#define GL_NV_conditional_render +#define _ALLEGRO_GL_NV_conditional_render +#define GL_QUERY_WAIT_NV 0x8E13 +#define GL_QUERY_NO_WAIT_NV 0x8E14 +#define GL_QUERY_BY_REGION_WAIT_NV 0x8E15 +#define GL_QUERY_BY_REGION_NO_WAIT_NV 0x8E16 +#endif + +#ifndef GL_NV_present_video +#define GL_NV_present_video +#define _ALLEGRO_GL_NV_present_video +#define GL_FRAME_NV 0x8E26 +#define GL_FIELDS_NV 0x8E27 +#define GL_CURRENT_TIME_NV 0x8E28 +#define GL_NUM_FILL_STREAMS_NV 0x8E29 +#define GL_PRESENT_TIME_NV 0x8E2A +#define GL_PRESENT_DURATION_NV 0x8E2B +#endif + +#ifndef GL_EXT_transform_feedback +#define GL_EXT_transform_feedback +#define _ALLEGRO_GL_EXT_transform_feedback +#define GL_TRANSFORM_FEEDBACK_BUFFER_EXT 0x8C8E +#define GL_TRANSFORM_FEEDBACK_BUFFER_START_EXT 0x8C84 +#define GL_TRANSFORM_FEEDBACK_BUFFER_SIZE_EXT 0x8C85 +#define GL_TRANSFORM_FEEDBACK_BUFFER_BINDING_EXT 0x8C8F +#define GL_INTERLEAVED_ATTRIBS_EXT 0x8C8C +#define GL_SEPARATE_ATTRIBS_EXT 0x8C8D +#define GL_PRIMITIVES_GENERATED_EXT 0x8C87 +#define GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN_EXT 0x8C88 +#define GL_RASTERIZER_DISCARD_EXT 0x8C89 +#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS_EXT 0x8C8A +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS_EXT 0x8C8B +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS_EXT 0x8C80 +#define GL_TRANSFORM_FEEDBACK_VARYINGS_EXT 0x8C83 +#define GL_TRANSFORM_FEEDBACK_BUFFER_MODE_EXT 0x8C7F +#define GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH_EXT 0x8C76 +#endif + +#ifndef GL_EXT_direct_state_access +#define GL_EXT_direct_state_access +#define _ALLEGRO_GL_EXT_direct_state_access +#define GL_PROGRAM_MATRIX_EXT 0x8E2D +#define GL_TRANSPOSE_PROGRAM_MATRIX_EXT 0x8E2E +#define GL_PROGRAM_MATRIX_STACK_DEPTH_EXT 0x8E2F +#endif + +#ifndef GL_EXT_texture_swizzle +#define GL_EXT_texture_swizzle +#define _ALLEGRO_GL_EXT_texture_swizzle +#define GL_TEXTURE_SWIZZLE_R_EXT 0x8E42 +#define GL_TEXTURE_SWIZZLE_G_EXT 0x8E43 +#define GL_TEXTURE_SWIZZLE_B_EXT 0x8E44 +#define GL_TEXTURE_SWIZZLE_A_EXT 0x8E45 +#define GL_TEXTURE_SWIZZLE_RGBA_EXT 0x8E46 +#endif + +#ifndef GL_NV_explicit_multisample +#define GL_NV_explicit_multisample +#define _ALLEGRO_GL_NV_explicit_multisample +#define GL_SAMPLE_POSITION_NV 0x8E50 +#define GL_SAMPLE_MASK_NV 0x8E51 +#define GL_SAMPLE_MASK_VALUE_NV 0x8E52 +#define GL_TEXTURE_BINDING_RENDERBUFFER_NV 0x8E53 +#define GL_TEXTURE_RENDERBUFFER_DATA_STORE_BINDING_NV 0x8E54 +#define GL_MAX_SAMPLE_MASK_WORDS_NV 0x8E59 +#define GL_TEXTURE_RENDERBUFFER_NV 0x8E55 +#define GL_SAMPLER_RENDERBUFFER_NV 0x8E56 +#define GL_INT_SAMPLER_RENDERBUFFER_NV 0x8E57 +#define GL_UNSIGNED_INT_SAMPLER_RENDERBUFFER_NV 0x8E58 +#endif + +#ifndef GL_NV_transform_feedback2 +#define GL_NV_transform_feedback2 +#define _ALLEGRO_GL_NV_transform_feedback2 +#define GL_TRANSFORM_FEEDBACK_NV 0x8E22 +#define GL_TRANSFORM_FEEDBACK_BUFFER_PAUSED_NV 0x8E23 +#define GL_TRANSFORM_FEEDBACK_BUFFER_ACTIVE_NV 0x8E24 +#define GL_TRANSFORM_FEEDBACK_BINDING_NV 0x8E25 +#endif + +#ifndef GL_ATI_meminfo +#define GL_ATI_meminfo +#define _ALLEGRO_GL_ATI_meminfo +#define GL_VBO_FREE_MEMORY_ATI 0x87FB +#define GL_TEXTURE_FREE_MEMORY_ATI 0x87FC +#define GL_RENDERBUFFER_FREE_MEMORY_ATI 0x87FD +#endif + +#ifndef GL_AMD_performance_monitor +#define GL_AMD_performance_monitor +#define _ALLEGRO_GL_AMD_performance_monitor +#define GL_COUNTER_TYPE_AMD 0x8BC0 +#define GL_COUNTER_RANGE_AMD 0x8BC1 +#define GL_UNSIGNED_INT64_AMD 0x8BC2 +#define GL_PERCENTAGE_AMD 0x8BC3 +#define GL_PERFMON_RESULT_AVAILABLE_AMD 0x8BC4 +#define GL_PERFMON_RESULT_SIZE_AMD 0x8BC5 +#define GL_PERFMON_RESULT_AMD 0x8BC6 +#endif + +#ifndef GL_AMD_texture_texture4 +#define GL_AMD_texture_texture4 +#define _ALLEGRO_GL_AMD_texture_texture4 +#endif + +#ifndef GL_AMD_vertex_shader_tesselator +#define GL_AMD_vertex_shader_tesselator +#define _ALLEGRO_GL_AMD_vertex_shader_tesselator +#define GL_SAMPLER_BUFFER_AMD 0x9001 +#define GL_INT_SAMPLER_BUFFER_AMD 0x9002 +#define GL_UNSIGNED_INT_SAMPLER_BUFFER_AMD 0x9003 +#define GL_TESSELLATION_MODE_AMD 0x9004 +#define GL_TESSELLATION_FACTOR_AMD 0x9005 +#define GL_DISCRETE_AMD 0x9006 +#define GL_CONTINUOUS_AMD 0x9007 +#endif + +#ifndef GL_EXT_provoking_vertex +#define GL_EXT_provoking_vertex +#define _ALLEGRO_GL_EXT_provoking_vertex +#define GL_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION_EXT 0x8E4C +#define GL_FIRST_VERTEX_CONVENTION_EXT 0x8E4D +#define GL_LAST_VERTEX_CONVENTION_EXT 0x8E4E +#define GL_PROVOKING_VERTEX_EXT 0x8E4F +#endif + +#ifndef GL_EXT_texture_snorm +#define GL_EXT_texture_snorm +#define _ALLEGRO_GL_EXT_texture_snorm +#define GL_ALPHA_SNORM 0x9010 +#define GL_LUMINANCE_SNORM 0x9011 +#define GL_LUMINANCE_ALPHA_SNORM 0x9012 +#define GL_INTENSITY_SNORM 0x9013 +#define GL_ALPHA8_SNORM 0x9014 +#define GL_LUMINANCE8_SNORM 0x9015 +#define GL_LUMINANCE8_ALPHA8_SNORM 0x9016 +#define GL_INTENSITY8_SNORM 0x9017 +#define GL_ALPHA16_SNORM 0x9018 +#define GL_LUMINANCE16_SNORM 0x9019 +#define GL_LUMINANCE16_ALPHA16_SNORM 0x901A +#define GL_INTENSITY16_SNORM 0x901B +/* reuse GL_RED_SNORM */ +/* reuse GL_RG_SNORM */ +/* reuse GL_RGB_SNORM */ +/* reuse GL_RGBA_SNORM */ +/* reuse GL_R8_SNORM */ +/* reuse GL_RG8_SNORM */ +/* reuse GL_RGB8_SNORM */ +/* reuse GL_RGBA8_SNORM */ +/* reuse GL_R16_SNORM */ +/* reuse GL_RG16_SNORM */ +/* reuse GL_RGB16_SNORM */ +/* reuse GL_RGBA16_SNORM */ +/* reuse GL_SIGNED_NORMALIZED */ +#endif + +#ifndef GL_AMD_draw_buffers_blend +#define GL_AMD_draw_buffers_blend +#define _ALLEGRO_GL_AMD_draw_buffers_blend +#endif + +#ifndef GL_APPLE_texture_range +#define GL_APPLE_texture_range +#define _ALLEGRO_GL_APPLE_texture_range +#define GL_TEXTURE_RANGE_LENGTH_APPLE 0x85B7 +#define GL_TEXTURE_RANGE_POINTER_APPLE 0x85B8 +#define GL_TEXTURE_STORAGE_HINT_APPLE 0x85BC +#define GL_STORAGE_PRIVATE_APPLE 0x85BD +/* reuse GL_STORAGE_CACHED_APPLE */ +/* reuse GL_STORAGE_SHARED_APPLE */ +#endif + +#ifndef GL_APPLE_float_pixels +#define GL_APPLE_float_pixels +#define _ALLEGRO_GL_APPLE_float_pixels +#define GL_HALF_APPLE 0x140B +#define GL_RGBA_FLOAT32_APPLE 0x8814 +#define GL_RGB_FLOAT32_APPLE 0x8815 +#define GL_ALPHA_FLOAT32_APPLE 0x8816 +#define GL_INTENSITY_FLOAT32_APPLE 0x8817 +#define GL_LUMINANCE_FLOAT32_APPLE 0x8818 +#define GL_LUMINANCE_ALPHA_FLOAT32_APPLE 0x8819 +#define GL_RGBA_FLOAT16_APPLE 0x881A +#define GL_RGB_FLOAT16_APPLE 0x881B +#define GL_ALPHA_FLOAT16_APPLE 0x881C +#define GL_INTENSITY_FLOAT16_APPLE 0x881D +#define GL_LUMINANCE_FLOAT16_APPLE 0x881E +#define GL_LUMINANCE_ALPHA_FLOAT16_APPLE 0x881F +#define GL_COLOR_FLOAT_APPLE 0x8A0F +#endif + +#ifndef GL_APPLE_vertex_program_evaluators +#define GL_APPLE_vertex_program_evaluators +#define _ALLEGRO_GL_APPLE_vertex_program_evaluators +#define GL_VERTEX_ATTRIB_MAP1_APPLE 0x8A00 +#define GL_VERTEX_ATTRIB_MAP2_APPLE 0x8A01 +#define GL_VERTEX_ATTRIB_MAP1_SIZE_APPLE 0x8A02 +#define GL_VERTEX_ATTRIB_MAP1_COEFF_APPLE 0x8A03 +#define GL_VERTEX_ATTRIB_MAP1_ORDER_APPLE 0x8A04 +#define GL_VERTEX_ATTRIB_MAP1_DOMAIN_APPLE 0x8A05 +#define GL_VERTEX_ATTRIB_MAP2_SIZE_APPLE 0x8A06 +#define GL_VERTEX_ATTRIB_MAP2_COEFF_APPLE 0x8A07 +#define GL_VERTEX_ATTRIB_MAP2_ORDER_APPLE 0x8A08 +#define GL_VERTEX_ATTRIB_MAP2_DOMAIN_APPLE 0x8A09 +#endif + +#ifndef GL_APPLE_aux_depth_stencil +#define GL_APPLE_aux_depth_stencil +#define _ALLEGRO_GL_APPLE_aux_depth_stencil +#define GL_AUX_DEPTH_STENCIL_APPLE 0x8A14 +#endif + +#ifndef GL_APPLE_object_purgeable +#define GL_APPLE_object_purgeable +#define _ALLEGRO_GL_APPLE_object_purgeable +#define GL_BUFFER_OBJECT_APPLE 0x85B3 +#define GL_RELEASED_APPLE 0x8A19 +#define GL_VOLATILE_APPLE 0x8A1A +#define GL_RETAINED_APPLE 0x8A1B +#define GL_UNDEFINED_APPLE 0x8A1C +#define GL_PURGEABLE_APPLE 0x8A1D +#endif + +#ifndef GL_APPLE_row_bytes +#define GL_APPLE_row_bytes +#define _ALLEGRO_GL_APPLE_row_bytes +#define GL_PACK_ROW_BYTES_APPLE 0x8A15 +#define GL_UNPACK_ROW_BYTES_APPLE 0x8A16 +#endif + +#ifndef GL_APPLE_rgb_422 +#define GL_APPLE_rgb_422 +#define _ALLEGRO_GL_APPLE_rgb_422 +#define GL_RGB_422_APPLE 0x8A1F +/* reuse GL_UNSIGNED_SHORT_8_8_APPLE */ +/* reuse GL_UNSIGNED_SHORT_8_8_REV_APPLE */ +#endif + +#ifndef GL_NV_video_capture +#define GL_NV_video_capture +#define _ALLEGRO_GL_NV_video_capture +#define GL_VIDEO_BUFFER_NV 0x9020 +#define GL_VIDEO_BUFFER_BINDING_NV 0x9021 +#define GL_FIELD_UPPER_NV 0x9022 +#define GL_FIELD_LOWER_NV 0x9023 +#define GL_NUM_VIDEO_CAPTURE_STREAMS_NV 0x9024 +#define GL_NEXT_VIDEO_CAPTURE_BUFFER_STATUS_NV 0x9025 +#define GL_VIDEO_CAPTURE_TO_422_SUPPORTED_NV 0x9026 +#define GL_LAST_VIDEO_CAPTURE_STATUS_NV 0x9027 +#define GL_VIDEO_BUFFER_PITCH_NV 0x9028 +#define GL_VIDEO_COLOR_CONVERSION_MATRIX_NV 0x9029 +#define GL_VIDEO_COLOR_CONVERSION_MAX_NV 0x902A +#define GL_VIDEO_COLOR_CONVERSION_MIN_NV 0x902B +#define GL_VIDEO_COLOR_CONVERSION_OFFSET_NV 0x902C +#define GL_VIDEO_BUFFER_INTERNAL_FORMAT_NV 0x902D +#define GL_PARTIAL_SUCCESS_NV 0x902E +#define GL_SUCCESS_NV 0x902F +#define GL_FAILURE_NV 0x9030 +#define GL_YCBYCR8_422_NV 0x9031 +#define GL_YCBAYCR8A_4224_NV 0x9032 +#define GL_Z6Y10Z6CB10Z6Y10Z6CR10_422_NV 0x9033 +#define GL_Z6Y10Z6CB10Z6A10Z6Y10Z6CR10Z6A10_4224_NV 0x9034 +#define GL_Z4Y12Z4CB12Z4Y12Z4CR12_422_NV 0x9035 +#define GL_Z4Y12Z4CB12Z4A12Z4Y12Z4CR12Z4A12_4224_NV 0x9036 +#define GL_Z4Y12Z4CB12Z4CR12_444_NV 0x9037 +#define GL_VIDEO_CAPTURE_FRAME_WIDTH_NV 0x9038 +#define GL_VIDEO_CAPTURE_FRAME_HEIGHT_NV 0x9039 +#define GL_VIDEO_CAPTURE_FIELD_UPPER_HEIGHT_NV 0x903A +#define GL_VIDEO_CAPTURE_FIELD_LOWER_HEIGHT_NV 0x903B +#define GL_VIDEO_CAPTURE_SURFACE_ORIGIN_NV 0x903C +#endif + +#ifndef GL_EXT_separate_shader_objects +#define GL_EXT_separate_shader_objects +#define _ALLEGRO_GL_EXT_separate_shader_objects +#define GL_ACTIVE_PROGRAM_EXT 0x8B8D +#endif + +#ifndef GL_NV_parameter_buffer_object2 +#define GL_NV_parameter_buffer_object2 +#define _ALLEGRO_GL_NV_parameter_buffer_object2 +#endif + +#ifndef GL_NV_shader_buffer_load +#define GL_NV_shader_buffer_load +#define _ALLEGRO_GL_NV_shader_buffer_load +#define GL_BUFFER_GPU_ADDRESS_NV 0x8F1D +#define GL_GPU_ADDRESS_NV 0x8F34 +#define GL_MAX_SHADER_BUFFER_ADDRESS_NV 0x8F35 +#endif + +#ifndef GL_NV_vertex_buffer_unified_memory +#define GL_NV_vertex_buffer_unified_memory +#define _ALLEGRO_GL_NV_vertex_buffer_unified_memory +#define GL_VERTEX_ATTRIB_ARRAY_UNIFIED_NV 0x8F1E +#define GL_ELEMENT_ARRAY_UNIFIED_NV 0x8F1F +#define GL_VERTEX_ATTRIB_ARRAY_ADDRESS_NV 0x8F20 +#define GL_VERTEX_ARRAY_ADDRESS_NV 0x8F21 +#define GL_NORMAL_ARRAY_ADDRESS_NV 0x8F22 +#define GL_COLOR_ARRAY_ADDRESS_NV 0x8F23 +#define GL_INDEX_ARRAY_ADDRESS_NV 0x8F24 +#define GL_TEXTURE_COORD_ARRAY_ADDRESS_NV 0x8F25 +#define GL_EDGE_FLAG_ARRAY_ADDRESS_NV 0x8F26 +#define GL_SECONDARY_COLOR_ARRAY_ADDRESS_NV 0x8F27 +#define GL_FOG_COORD_ARRAY_ADDRESS_NV 0x8F28 +#define GL_ELEMENT_ARRAY_ADDRESS_NV 0x8F29 +#define GL_VERTEX_ATTRIB_ARRAY_LENGTH_NV 0x8F2A +#define GL_VERTEX_ARRAY_LENGTH_NV 0x8F2B +#define GL_NORMAL_ARRAY_LENGTH_NV 0x8F2C +#define GL_COLOR_ARRAY_LENGTH_NV 0x8F2D +#define GL_INDEX_ARRAY_LENGTH_NV 0x8F2E +#define GL_TEXTURE_COORD_ARRAY_LENGTH_NV 0x8F2F +#define GL_EDGE_FLAG_ARRAY_LENGTH_NV 0x8F30 +#define GL_SECONDARY_COLOR_ARRAY_LENGTH_NV 0x8F31 +#define GL_FOG_COORD_ARRAY_LENGTH_NV 0x8F32 +#define GL_ELEMENT_ARRAY_LENGTH_NV 0x8F33 +#endif + +#ifndef GL_NV_texture_barrier +#define GL_NV_texture_barrier +#define _ALLEGRO_GL_NV_texture_barrier +#endif + +#ifndef GL_AMD_shader_stencil_export +#define GL_AMD_shader_stencil_export +#define _ALLEGRO_GL_AMD_shader_stencil_export +#endif + +#ifndef GL_AMD_seamless_cubemap_per_texture +#define GL_AMD_seamless_cubemap_per_texture +#define _ALLEGRO_GL_AMD_seamless_cubemap_per_texture +/* reuse GL_TEXTURE_CUBE_MAP_SEAMLESS_ARB */ +#endif + +#ifndef GL_AMD_conservative_depth +#define GL_AMD_conservative_depth +#define _ALLEGRO_GL_AMD_conservative_depth +#endif diff --git a/common/allegro/include/allegro5/opengl/GLext/gl_ext_list.h b/common/allegro/include/allegro5/opengl/GLext/gl_ext_list.h new file mode 100644 index 00000000..e4e4b342 --- /dev/null +++ b/common/allegro/include/allegro5/opengl/GLext/gl_ext_list.h @@ -0,0 +1,359 @@ +AGL_EXT(ARB_imaging, 0) +AGL_EXT(ARB_multitexture, 1_2_1) +AGL_EXT(ARB_transpose_matrix, 1_3) +AGL_EXT(ARB_multisample, 1_3) +AGL_EXT(ARB_texture_env_add, 1_3) +AGL_EXT(ARB_texture_cube_map, 1_3) +AGL_EXT(ARB_texture_compression, 1_3) +AGL_EXT(ARB_texture_border_clamp, 1_3) +AGL_EXT(ARB_point_parameters, 1_4) +AGL_EXT(ARB_vertex_blend, 0) +AGL_EXT(ARB_texture_env_combine, 1_3) +AGL_EXT(ARB_texture_env_crossbar, 1_4) +AGL_EXT(ARB_texture_env_dot3, 1_3) +AGL_EXT(ARB_texture_mirrored_repeat, 1_4) +AGL_EXT(ARB_depth_texture, 1_4) +AGL_EXT(ARB_shadow, 1_4) +AGL_EXT(ARB_shadow_ambient, 0) +AGL_EXT(ARB_window_pos, 1_4) +AGL_EXT(ARB_vertex_program, 0) +AGL_EXT(ARB_fragment_program, 0) +AGL_EXT(ARB_vertex_buffer_object, 1_5) +AGL_EXT(ARB_occlusion_query, 1_5) +AGL_EXT(ARB_shader_objects, 0) /* Those were promoted to Core in */ +AGL_EXT(ARB_vertex_shader, 0) /* 2.0 with modifications. */ +AGL_EXT(ARB_fragment_shader, 0) /* */ +AGL_EXT(ARB_shading_language_100, 0) /* */ +AGL_EXT(ARB_texture_non_power_of_two,2_0) +AGL_EXT(ARB_point_sprite, 2_0) +AGL_EXT(ARB_fragment_program_shadow, 0) +AGL_EXT(ARB_draw_buffers, 2_0) +AGL_EXT(ARB_texture_rectangle, 3_1) +AGL_EXT(ARB_color_buffer_float, 3_0) +AGL_EXT(ARB_half_float_pixel, 3_0) +AGL_EXT(ARB_texture_float, 3_0) +AGL_EXT(ARB_pixel_buffer_object, 2_1) +AGL_EXT(ARB_instanced_arrays, 0) +AGL_EXT(ARB_draw_instanced, 3_1) +AGL_EXT(ARB_geometry_shader4, 0) +AGL_EXT(ARB_texture_buffer_object, 3_1) +AGL_EXT(ARB_depth_buffer_float, 3_0) +AGL_EXT(ARB_framebuffer_object, 3_0) +AGL_EXT(ARB_framebuffer_sRGB, 3_0) +AGL_EXT(ARB_half_float_vertex, 3_0) +AGL_EXT(ARB_map_buffer_range, 3_0) +AGL_EXT(ARB_texture_compression_rgtc,3_0) +AGL_EXT(ARB_texture_rg, 3_0) +AGL_EXT(ARB_vertex_array_object, 3_0) +AGL_EXT(ARB_copy_buffer, 3_1) +AGL_EXT(ARB_compatibility, 0) +AGL_EXT(ARB_uniform_buffer_object, 3_1) +AGL_EXT(ARB_shader_texture_lod, 0) +AGL_EXT(ARB_depth_clamp, 3_2) +AGL_EXT(ARB_draw_elements_base_vertex, 3_2) +AGL_EXT(ARB_fragment_coord_conventions, 3_2) +AGL_EXT(ARB_provoking_vertex, 3_2) +AGL_EXT(ARB_seamless_cube_map, 3_2) +AGL_EXT(ARB_sync, 3_2) +AGL_EXT(ARB_texture_multisample, 3_2) +AGL_EXT(ARB_vertex_array_bgra, 0) +AGL_EXT(ARB_draw_buffers_blend, 0) +AGL_EXT(ARB_sample_shading, 0) +AGL_EXT(ARB_texture_cube_map_array, 0) +AGL_EXT(ARB_texture_gather, 0) +AGL_EXT(ARB_texture_query_lod, 0) +AGL_EXT(ARB_shading_language_include, 0) +AGL_EXT(ARB_texture_compression_bptc, 0) +AGL_EXT(ARB_blend_func_extended, 3_3) +AGL_EXT(ARB_explicit_attrib_location, 3_3) +AGL_EXT(ARB_occlusion_query2, 3_3) +AGL_EXT(ARB_sampler_objects, 3_3) +AGL_EXT(ARB_shader_bit_encoding, 3_3) +AGL_EXT(ARB_texture_rgb10_a2ui, 3_3) +AGL_EXT(ARB_texture_swizzle, 3_3) +AGL_EXT(ARB_timer_query, 3_3) +AGL_EXT(ARB_vertex_type_2_10_10_10_rev, 3_3) +AGL_EXT(ARB_draw_indirect, 4_0) +AGL_EXT(ARB_gpu_shader5, 4_0) +AGL_EXT(ARB_gpu_shader_fp64, 4_0) +AGL_EXT(ARB_shader_subroutine, 4_0) +AGL_EXT(ARB_tessellation_shader, 4_0) +AGL_EXT(ARB_texture_buffer_object_rgb32, 4_0) +AGL_EXT(ARB_transform_feedback2, 4_0) +AGL_EXT(ARB_transform_feedback3, 4_0) + +AGL_EXT(EXT_abgr, 0) +AGL_EXT(EXT_blend_color, 1_1) +AGL_EXT(EXT_polygon_offset, 1_1) +AGL_EXT(EXT_texture, 1_1) +AGL_EXT(EXT_texture3D, 1_2) +AGL_EXT(SGIS_texture_filter4, 0) +AGL_EXT(EXT_subtexture, 1_1) +AGL_EXT(EXT_copy_texture, 1_1) +AGL_EXT(EXT_histogram, 0) +AGL_EXT(EXT_convolution, 0) +AGL_EXT(SGI_color_matrix, 0) +AGL_EXT(SGI_color_table, 0) +AGL_EXT(SGIS_pixel_texture, 0) +AGL_EXT(SGIX_pixel_texture, 0) +AGL_EXT(SGIS_texture4D, 0) +AGL_EXT(SGI_texture_color_table, 0) +AGL_EXT(EXT_cmyka, 0) +AGL_EXT(EXT_texture_object, 1_1) +AGL_EXT(SGIS_detail_texture, 0) +AGL_EXT(SGIS_sharpen_texture, 0) +AGL_EXT(EXT_packed_pixels, 1_2) +AGL_EXT(SGIS_texture_lod, 1_2) +AGL_EXT(SGIS_multisample, 1_3) +AGL_EXT(EXT_rescale_normal, 1_2) +AGL_EXT(EXT_vertex_array, 1_1) +AGL_EXT(EXT_misc_attribute, 0) +AGL_EXT(SGIS_generate_mipmap, 1_4) +AGL_EXT(SGIX_clipmap, 0) +AGL_EXT(SGIX_shadow, 0) +AGL_EXT(SGIS_texture_edge_clamp, 1_2) +AGL_EXT(SGIS_texture_border_clamp, 0) +AGL_EXT(EXT_blend_minmax, 0) +AGL_EXT(EXT_blend_subtract, 0) +AGL_EXT(EXT_blend_logic_op, 1_1) +AGL_EXT(SGIX_interlace, 0) +AGL_EXT(SGIS_texture_select, 0) +AGL_EXT(SGIX_sprite, 0) +AGL_EXT(SGIX_texture_multi_buffer, 0) +AGL_EXT(EXT_point_parameters, 0) +AGL_EXT(SGIX_instruments, 0) +AGL_EXT(SGIX_texture_scale_bias, 0) +AGL_EXT(SGIX_framezoom, 0) +AGL_EXT(SGIX_tag_sample_buffer, 0) +AGL_EXT(SGIX_reference_plane, 0) +AGL_EXT(SGIX_flush_raster, 0) +AGL_EXT(SGIX_depth_texture, 0) +AGL_EXT(SGIS_fog_function, 0) +AGL_EXT(SGIX_fog_offset, 0) +AGL_EXT(HP_image_transform, 0) +AGL_EXT(HP_convolution_border_modes, 0) +AGL_EXT(SGIX_texture_add_env, 0) +AGL_EXT(EXT_color_subtable, 0) +AGL_EXT(PGI_vertex_hints, 0) +AGL_EXT(PGI_misc_hints, 0) +AGL_EXT(EXT_paletted_texture, 0) +AGL_EXT(EXT_clip_volume_hint, 0) +AGL_EXT(SGIX_list_priority, 0) +AGL_EXT(SGIX_ir_instrument1, 0) +AGL_EXT(SGIX_texture_lod_bias, 0) +AGL_EXT(SGIX_shadow_ambient, 0) +AGL_EXT(EXT_index_texture, 0) +AGL_EXT(EXT_index_material, 0) +AGL_EXT(EXT_index_func, 0) +AGL_EXT(EXT_index_array_formats, 0) +AGL_EXT(EXT_compiled_vertex_array, 0) +AGL_EXT(EXT_cull_vertex, 0) +AGL_EXT(SGIX_ycrcb, 0) +AGL_EXT(EXT_fragment_lighting, 0) +AGL_EXT(IBM_rasterpos_clip, 0) +AGL_EXT(HP_texture_lighting, 0) +AGL_EXT(EXT_draw_range_elements, 0) +AGL_EXT(WIN_phong_shading, 0) +AGL_EXT(WIN_specular_fog, 0) +AGL_EXT(EXT_light_texture, 0) +AGL_EXT(SGIX_blend_alpha_minmax, 0) +AGL_EXT(EXT_scene_marker, 0) +AGL_EXT(SGIX_pixel_texture_bits, 0) +AGL_EXT(EXT_bgra, 1_2) +AGL_EXT(SGIX_async, 0) +AGL_EXT(SGIX_async_pixel, 0) +AGL_EXT(SGIX_async_histogram, 0) +AGL_EXT(INTEL_texture_scissor, 0) +AGL_EXT(INTEL_parallel_arrays, 0) +AGL_EXT(HP_occlusion_test, 0) +AGL_EXT(EXT_pixel_transform, 0) +AGL_EXT(EXT_pixel_transform_color_table, 0) +AGL_EXT(EXT_shared_texture_palette, 0) +AGL_EXT(EXT_separate_specular_color, 1_2) +AGL_EXT(EXT_secondary_color, 1_4) +AGL_EXT(EXT_texture_env, 0) +AGL_EXT(EXT_texture_perturb_normal, 0) +AGL_EXT(EXT_multi_draw_arrays, 1_4) +AGL_EXT(EXT_fog_coord, 1_4) +AGL_EXT(REND_screen_coordinates, 0) +AGL_EXT(EXT_coordinate_frame, 0) +AGL_EXT(EXT_texture_env_combine, 0) +AGL_EXT(APPLE_specular_vector, 0) +AGL_EXT(APPLE_transform_hint, 0) +AGL_EXT(SUNX_constant_data, 0) +AGL_EXT(SUN_global_alpha, 0) +AGL_EXT(SUN_triangle_list, 0) +AGL_EXT(SUN_vertex, 0) +AGL_EXT(EXT_blend_func_separate, 1_4) +AGL_EXT(INGR_color_clamp, 0) +AGL_EXT(INGR_interlace_read, 0) +AGL_EXT(EXT_stencil_wrap, 1_4) +AGL_EXT(EXT_422_pixels, 0) +AGL_EXT(NV_texgen_reflection, 0) +AGL_EXT(SGIX_texture_range, 0) +AGL_EXT(SUN_convolution_border_modes, 0) +AGL_EXT(EXT_texture_env_add, 0) +AGL_EXT(EXT_texture_lod_bias, 1_4) +AGL_EXT(EXT_texture_filter_anisotropic, 0) +AGL_EXT(EXT_vertex_weighting, 0) +AGL_EXT(NV_light_max_exponent, 0) +AGL_EXT(NV_vertex_array_range, 0) +AGL_EXT(NV_register_combiners, 0) +AGL_EXT(NV_fog_distance, 0) +AGL_EXT(NV_texgen_emboss, 0) +AGL_EXT(NV_blend_square, 1_4) +AGL_EXT(NV_texture_env_combine4, 0) +AGL_EXT(MESA_resize_buffers, 0) +AGL_EXT(MESA_window_pos, 0) +AGL_EXT(EXT_texture_compression_s3tc, 0) +AGL_EXT(IBM_cull_vertex, 0) +AGL_EXT(IBM_multimode_draw_arrays, 0) +AGL_EXT(IBM_vertex_array_lists, 0) +AGL_EXT(3DFX_texture_compression_FXT1, 0) +AGL_EXT(3DFX_multisample, 0) +AGL_EXT(3DFX_tbuffer, 0) +AGL_EXT(SGIX_vertex_preclip, 0) +AGL_EXT(SGIX_resample, 0) +AGL_EXT(SGIS_texture_color_mask, 0) +AGL_EXT(EXT_texture_env_dot3, 0) +AGL_EXT(ATI_texture_mirror_once, 0) +AGL_EXT(NV_fence, 0) +AGL_EXT(IBM_static_data, 0) +AGL_EXT(IBM_texture_mirrored_repeat, 0) +AGL_EXT(NV_evaluators, 0) +AGL_EXT(NV_packed_depth_stencil, 3_0) +AGL_EXT(NV_register_combiners2, 0) +AGL_EXT(NV_texture_compression_vtc, 0) +AGL_EXT(NV_texture_rectangle, 0) +AGL_EXT(NV_texture_shader, 0) +AGL_EXT(NV_texture_shader2, 0) +AGL_EXT(NV_vertex_array_range2, 0) +AGL_EXT(NV_vertex_program, 0) +AGL_EXT(SGIX_texture_coordinate_clamp, 0) +AGL_EXT(OML_interlace, 0) +AGL_EXT(OML_subsample, 0) +AGL_EXT(OML_resample, 0) +AGL_EXT(NV_copy_depth_to_color, 0) +AGL_EXT(ATI_envmap_bumpmap, 0) +AGL_EXT(ATI_fragment_shader, 0) +AGL_EXT(ATI_pn_triangles, 0) +AGL_EXT(ATI_vertex_array_object, 0) +AGL_EXT(EXT_vertex_shader, 0) +AGL_EXT(ATI_vertex_streams, 0) +AGL_EXT(ATI_element_array, 0) +AGL_EXT(SUN_mesh_array, 0) +AGL_EXT(SUN_slice_accum, 0) +AGL_EXT(NV_multisample_filter_hint, 0) +AGL_EXT(NV_depth_clamp, 0) +AGL_EXT(NV_occlusion_query, 0) +AGL_EXT(NV_point_sprite, 0) +AGL_EXT(NV_texture_shader3, 0) +AGL_EXT(NV_vertex_program1_1, 0) +AGL_EXT(EXT_shadow_funcs, 1_5) +AGL_EXT(EXT_stencil_two_side, 0) +AGL_EXT(ATI_text_fragment_shader, 0) +AGL_EXT(APPLE_client_storage, 0) +AGL_EXT(APPLE_element_array, 0) +AGL_EXT(APPLE_fence, 0) +AGL_EXT(APPLE_vertex_array_object, 3_0) +AGL_EXT(APPLE_vertex_array_range, 0) +AGL_EXT(APPLE_ycbcr_422, 0) +AGL_EXT(S3_s3tc, 0) +AGL_EXT(ATI_draw_buffers, 0) +AGL_EXT(ATI_texture_env_combine3, 0) +AGL_EXT(ATI_texture_float, 0) +AGL_EXT(NV_float_buffer, 0) +AGL_EXT(NV_fragment_program, 0) +AGL_EXT(NV_half_float, 3_0) +AGL_EXT(NV_pixel_data_range, 0) +AGL_EXT(NV_primitive_restart, 3_1) +AGL_EXT(NV_texture_expand_normal, 0) +AGL_EXT(NV_vertex_program2, 0) +AGL_EXT(ATI_map_object_buffer, 0) +AGL_EXT(ATI_separate_stencil, 2_0) +AGL_EXT(ATI_vertex_attrib_array_object, 0) +AGL_EXT(OES_byte_coordinates, 0) +AGL_EXT(OES_fixed_point, 0) +AGL_EXT(OES_single_precision, 0) +AGL_EXT(OES_compressed_paletted_texture, 0) +AGL_EXT(OES_read_format, 0) +AGL_EXT(OES_query_matrix, 0) +AGL_EXT(OES_framebuffer_object, 0) +AGL_EXT(OES_texture_npot, 0) +AGL_EXT(EXT_depth_bounds_test, 0) +AGL_EXT(EXT_texture_mirror_clamp, 0) +AGL_EXT(EXT_blend_equation_separate, 0) +AGL_EXT(MESA_pack_invert, 0) +AGL_EXT(MESA_ycbcr_texture, 0) +AGL_EXT(EXT_pixel_buffer_object, 0) +AGL_EXT(NV_fragment_program_option, 0) +AGL_EXT(NV_fragment_program2, 0) +AGL_EXT(NV_vertex_program2_option, 0) +AGL_EXT(NV_vertex_program3, 0) +AGL_EXT(EXT_texture_compression_dxt1, 0) +AGL_EXT(EXT_framebuffer_object, 3_0) +AGL_EXT(GREMEDY_string_marker, 0) +AGL_EXT(EXT_packed_depth_stencil, 0) +AGL_EXT(EXT_stencil_clear_tag, 0) +AGL_EXT(EXT_texture_sRGB, 2_1) +AGL_EXT(EXT_framebuffer_blit, 3_0) +AGL_EXT(EXT_framebuffer_multisample, 3_0) +AGL_EXT(MESAX_texture_stack, 0) +AGL_EXT(EXT_timer_query, 0) +AGL_EXT(EXT_gpu_program_parameters, 0) +AGL_EXT(APPLE_flush_buffer_range, 0) +#ifdef ALLEGRO_MACOSX +AGL_EXT(EXT_texture_rectangle, 0) +#endif +AGL_EXT(EXT_bindable_uniform, 0) +AGL_EXT(EXT_draw_buffers2, 3_0) +AGL_EXT(EXT_draw_instanced, 0) +AGL_EXT(EXT_framebuffer_sRGB, 3_0) +AGL_EXT(EXT_geometry_shader4, 0) +AGL_EXT(EXT_gpu_shader4, 3_0) +AGL_EXT(EXT_packed_float, 3_0) +AGL_EXT(EXT_texture_array, 3_0) +AGL_EXT(EXT_texture_buffer_object, 0) +AGL_EXT(EXT_texture_compression_latc, 0) +AGL_EXT(EXT_texture_compression_rgtc,3_0) +AGL_EXT(EXT_texture_integer, 3_0) +AGL_EXT(EXT_texture_shared_exponent, 3_0) +AGL_EXT(NV_depth_buffer_float, 3_0) +AGL_EXT(NV_fragment_program4, 0) +AGL_EXT(NV_framebuffer_multisample_coverage, 0) +AGL_EXT(NV_geometry_program4, 0) +AGL_EXT(NV_gpu_program4, 0) +AGL_EXT(NV_parameter_buffer_object, 0) +AGL_EXT(NV_transform_feedback, 0) +AGL_EXT(NV_vertex_program4, 0) +AGL_EXT(GREMEDY_frame_terminator, 0) +AGL_EXT(NV_conditional_render, 3_0) +AGL_EXT(NV_present_video, 0) +AGL_EXT(EXT_direct_state_access, 0) +AGL_EXT(EXT_transform_feedback, 3_0) +AGL_EXT(EXT_texture_swizzle, 0) +AGL_EXT(NV_explicit_multisample, 0) +AGL_EXT(NV_transform_feedback2, 0) +AGL_EXT(ATI_meminfo, 0) +AGL_EXT(AMD_performance_monitor, 0) +AGL_EXT(AMD_texture_texture4, 0) +AGL_EXT(AMD_vertex_shader_tesselator, 0) +AGL_EXT(EXT_provoking_vertex, 0) +AGL_EXT(EXT_texture_snorm, 0) +AGL_EXT(AMD_draw_buffers_blend, 0) +AGL_EXT(APPLE_texture_range, 0) +AGL_EXT(APPLE_float_pixels, 0) +AGL_EXT(APPLE_vertex_program_evaluators, 0) +AGL_EXT(APPLE_aux_depth_stencil, 0) +AGL_EXT(APPLE_object_purgeable, 0) +AGL_EXT(APPLE_row_bytes, 0) +AGL_EXT(APPLE_rgb_422, 0) +AGL_EXT(NV_video_capture, 0) +AGL_EXT(EXT_separate_shader_objects, 0) +AGL_EXT(NV_parameter_buffer_object2, 0) +AGL_EXT(NV_shader_buffer_load, 0) +AGL_EXT(NV_vertex_buffer_unified_memory, 0) +AGL_EXT(NV_texture_barrier, 0) +AGL_EXT(AMD_shader_stencil_export, 0) +AGL_EXT(AMD_seamless_cubemap_per_texture, 0) +AGL_EXT(AMD_conservative_depth, 0) diff --git a/common/allegro/include/allegro5/opengl/GLext/glx_ext_alias.h b/common/allegro/include/allegro5/opengl/GLext/glx_ext_alias.h new file mode 100644 index 00000000..0194ccba --- /dev/null +++ b/common/allegro/include/allegro5/opengl/GLext/glx_ext_alias.h @@ -0,0 +1,217 @@ +/*Automatically generated by gl_mkalias.sh DO NOT EDIT!*/ +#ifdef _ALLEGRO_GLX_VERSION_1_3 +/*GLX1.3*/ +#define glXGetFBConfigs _al_glXGetFBConfigs +#define glXChooseFBConfig _al_glXChooseFBConfig +#define glXGetFBConfigAttrib _al_glXGetFBConfigAttrib +#define glXGetVisualFromFBConfig _al_glXGetVisualFromFBConfig +#define glXCreateWindow _al_glXCreateWindow +#define glXDestroyWindow _al_glXDestroyWindow +#define glXCreatePixmap _al_glXCreatePixmap +#define glXDestroyPixmap _al_glXDestroyPixmap +#define glXCreatePbuffer _al_glXCreatePbuffer +#define glXDestroyPbuffer _al_glXDestroyPbuffer +#define glXQueryDrawable _al_glXQueryDrawable +#define glXCreateNewContext _al_glXCreateNewContext +#define glXMakeContextCurrent _al_glXMakeContextCurrent +#define glXGetCurrentReadDrawable _al_glXGetCurrentReadDrawable +#define glXGetCurrentDisplay _al_glXGetCurrentDisplay +#define glXQueryContext _al_glXQueryContext +#define glXSelectEvent _al_glXSelectEvent +#define glXGetSelectedEvent _al_glXGetSelectedEvent +#endif +#ifdef _ALLEGRO_GLX_VERSION_1_4 +/*GLX1.4*/ +#define glXGetProcAddress _al_glXGetProcAddress +#endif + +#ifdef _ALLEGRO_GLX_ARB_get_proc_address +/*GLX_ARB_get_proc_address*/ +#define glXGetProcAddressARB _al_glXGetProcAddressARB +#endif + +#ifdef _ALLEGRO_GLX_ARB_create_context +#define glXCreateContextAttribsARB _al_glXCreateContextAttribsARB +#endif + +#ifdef _ALLEGRO_GLX_SGI_swap_control +/*GLX_SGI_swap_control*/ +#define glXSwapIntervalSGI _al_glXSwapIntervalSGI +#endif + +#ifdef _ALLEGRO_GLX_SGI_video_sync +/*GLX_SGI_video_sync*/ +#define glXGetVideoSyncSGI _al_glXGetVideoSyncSGI +#define glXWaitVideoSyncSGI _al_glXWaitVideoSyncSGI +#endif + +#ifdef _ALLEGRO_GLX_SGI_make_current_read +/*GLX_SGI_make_current_read*/ +#define glXMakeCurrentReadSGI _al_glXMakeCurrentReadSGI +#define glXGetCurrentReadDrawableSGI _al_glXGetCurrentReadDrawableSGI +#endif + +#ifdef _ALLEGRO_GLX_SGIX_video_source +/*GLX_SGIX_video_source*/ +/*ThisoneneedsSGI'sheaderfiletobeincludedfirst*/ +#ifdef _VL_H_ +#define glXCreateGLXVideoSourceSGIX _al_glXCreateGLXVideoSourceSGIX +#define glXDestroyGLXVideoSourceSGIX _al_glXDestroyGLXVideoSourceSGIX +#endif +#endif + +#ifdef _ALLEGRO_GLX_EXT_import_context +/*GLX_EXT_import_context*/ +#define glXGetCurrentDisplayEXT _al_glXGetCurrentDisplayEXT +#define glXQueryContextInfoEXT _al_glXQueryContextInfoEXT +#define glXGetContextIDEXT _al_glXGetContextIDEXT +#define glXImportContextEXT _al_glXImportContextEXT +#define glXFreeContextEXT _al_glXFreeContextEXT +#endif + +#ifdef _ALLEGRO_GLX_SGIX_fbconfig +/*GLX_SGIX_fbconfig*/ +#define glXGetFBConfigAttribSGIX _al_glXGetFBConfigAttribSGIX +#define glXChooseFBConfigSGIX _al_glXChooseFBConfigSGIX +#define glXCreateGLXPixmapWithConfigSGIX _al_glXCreateGLXPixmapWithConfigSGIX +#define glXCreateContextWithConfigSGIX _al_glXCreateContextWithConfigSGIX +#define glXGetVisualFromFBConfigSGIX _al_glXGetVisualFromFBConfigSGIX +#define glXGetFBConfigFromVisualSGIX _al_glXGetFBConfigFromVisualSGIX +#endif + +#ifdef _ALLEGRO_GLX_SGIX_pbuffer +/*GLX_SGIX_pbuffer*/ +#define glXCreateGLXPbufferSGIX _al_glXCreateGLXPbufferSGIX +#define glXDestroyGLXPbufferSGIX _al_glXDestroyGLXPbufferSGIX +#define glXQueryGLXPbufferSGIX _al_glXQueryGLXPbufferSGIX +#define glXSelectEventSGIX _al_glXSelectEventSGIX +#define glXGetSelectedEventSGIX _al_glXGetSelectedEventSGIX +#endif + +#ifdef _ALLEGRO_GLX_SGI_cushion +/*GLX_SGI_cushion*/ +#define glXCushionSGI _al_glXCushionSGI +#endif + +#ifdef _ALLEGRO_GLX_SGIX_video_resize +/*GLX_SGIX_video_resize*/ +#define glXBindChannelToWindowSGIX _al_glXBindChannelToWindowSGIX +#define glXChannelRectSGIX _al_glXChannelRectSGIX +#define glXQueryChannelRectSGIX _al_glXQueryChannelRectSGIX +#define glXQueryChannelDeltasSGIX _al_glXQueryChannelDeltasSGIX +#define glXChannelRectSyncSGIX _al_glXChannelRectSyncSGIX +#endif + +#ifdef _ALLEGRO_GLX_SGIX_dmbuffer +/*GLX_SGIX_dmbuffer*/ +/*ThisoneneedsSGI'sheaderfiletobeincludedfirst*/ +#ifdef _DM_BUFFER_H_ +#define glXAssociateDMPbufferSGIX _al_glXAssociateDMPbufferSGIX +#endif +#endif + +#ifdef _ALLEGRO_GLX_SGIX_swap_group +/*GLX_SGIX_swap_group*/ +#define glXJoinSwapGroupSGIX _al_glXJoinSwapGroupSGIX +#endif + +#ifdef _ALLEGRO_GLX_SGIX_swap_barrier +/*GLX_SGIX_swap_barrier*/ +#define glXBindSwapBarrierSGIX _al_glXBindSwapBarrierSGIX +#define glXQueryMaxSwapBarriersSGIX _al_glXQueryMaxSwapBarriersSGIX +#endif + +#ifdef _ALLEGRO_GLX_SUN_get_transparent_index +/*GLX_SUN_get_transparent_index*/ +#define glXGetTransparentIndexSUN _al_glXGetTransparentIndexSUN +#endif + +#ifdef _ALLEGRO_GLX_MESA_copy_sub_buffer +/*GLX_MESA_copy_sub_buffer*/ +#define glXCopySubBufferMESA _al_glXCopySubBufferMESA +#endif + +#ifdef _ALLEGRO_GLX_MESA_pixmap_colormap +/*GLX_MESA_pixmap_colormap*/ +#define glXCreateGLXPixmapMESA _al_glXCreateGLXPixmapMESA +#endif + +#ifdef _ALLEGRO_GLX_MESA_release_buffers +/*GLX_MESA_release_buffers*/ +#define glXReleaseBuffersMESA _al_glXReleaseBuffersMESA +#endif + +#ifdef _ALLEGRO_GLX_MESA_set_3dfx_mode +/*GLX_MESA_set_3dfx_mode*/ +#define glXSet3DfxModeMESA _al_glXSet3DfxModeMESA +#endif + +#ifdef _ALLEGRO_GLX_OML_sync_control +/*GLX_OML_sync_control*/ +#define glXGetSyncValuesOML _al_glXGetSyncValuesOML +#define glXGetMscRateOML _al_glXGetMscRateOML +#define glXSwapBuffersMscOML _al_glXSwapBuffersMscOML +#define glXWaitForMscOML _al_glXWaitForMscOML +#define glXWaitForSbcOML _al_glXWaitForSbcOML +#endif + + +#ifdef _ALLEGRO_GLX_SGIX_hyperpipe +#define glXQueryHyperpipeNetworkSGIX _al_glXQueryHyperpipeNetworkSGIX +#define glXHyperpipeConfigSGIX _al_glXHyperpipeConfigSGIX +#define glXQueryHyperpipeConfigSGIX _al_glXQueryHyperpipeConfigSGIX +#define glXDestroyHyperpipeConfigSGIX _al_glXDestroyHyperpipeConfigSGIX +#define glXBindHyperpipeSGIX _al_glXBindHyperpipeSGIX +#define glXQueryHyperpipeBestAttribSGIX _al_glXQueryHyperpipeBestAttribSGIX +#define glXHyperpipeAttribSGIX _al_glXHyperpipeAttribSGIX +#define glXQueryHyperpipeAttribSGIX _al_glXQueryHyperpipeAttribSGIX +#endif + + +#ifdef _ALLEGRO_GLX_MESA_agp_offset +#define glXGetAGPOffsetMESA _al_glXGetAGPOffsetMESA +#endif + + +#ifdef _ALLEGRO_GLX_EXT_texture_from_pixmap +#define glXBindTexImageEXT _al_glXBindTexImageEXT +#define glXReleaseTextImageEXT _al_glXReleaseTextImageEXT +#endif + +#ifdef _ALLEGRO_GLX_NV_video_output +#define glXGetVideoDeviceNV _al_glXGetVideoDeviceNV +#define glXReleaseVideoDeviceNV _al_glXReleaseVideoDeviceNV +#define glXBindVideoImageNV _al_glXBindVideoImageNV +#define glXReleaseVideoImageNV _al_glXReleaseVideoImageNV +#define glXSendPbufferToVideoNV _al_glXSendPbufferToVideoNV +#define glXGetVideoInfoNV _al_glXGetVideoInfoNV +#endif + +#ifdef _ALLEGRO_GLX_NV_swap_group +#define glXJoinSwapGroupNV _al_glXJoinSwapGroupNV +#define glXBindSwapBarrierNV _al_glXBindSwapBarrierNV +#define glXQuerySwapGroupNV _al_glXQuerySwapGroupNV +#define glXQueryMaxSwapGroupsNV _al_glXQueryMaxSwapGroupsNV +#define glXQueryFrameCountNV _al_glXQueryFrameCountNV +#define glXResetFrameCountNV _al_glXResetFrameCountNV +#endif + +#ifdef _ALLEGRO_GLX_NV_video_capture +#define glXBindVideoCaptureDeviceNV _al_glXBindVideoCaptureDeviceNV +#define glXEnumerateVideoCaptureDevicesNV _al_glXEnumerateVideoCaptureDevicesNV +#define glXLockVideoCaptureDeviceNV _al_glXLockVideoCaptureDeviceNV +#define glXQueryVideoCaptureDeviceNV _al_glXQueryVideoCaptureDeviceNV +#define glXReleaseVideoCaptureDeviceNV _al_glXReleaseVideoCaptureDeviceNV +#endif + +#ifdef _ALLEGRO_GLX_EXT_swap_control +#define glXSwapIntervalEXT _al_glXSwapIntervalEXT +#endif + +#ifdef _ALLEGRO_GLX_NV_copy_image +#define glXCopyImageSubDataNV _al_glXCopyImageSubDataNV +#endif + +#ifdef _ALLEGRO_GLX_EXT_create_context_es_profile +//nofunctions +#endif diff --git a/common/allegro/include/allegro5/opengl/GLext/glx_ext_api.h b/common/allegro/include/allegro5/opengl/GLext/glx_ext_api.h new file mode 100644 index 00000000..8694bc2f --- /dev/null +++ b/common/allegro/include/allegro5/opengl/GLext/glx_ext_api.h @@ -0,0 +1,216 @@ +#ifdef _ALLEGRO_GLX_VERSION_1_3 +/* GLX 1.3 */ +AGL_API(GLXFBConfig *, GetFBConfigs, (Display *, int, int *)) +AGL_API(GLXFBConfig *, ChooseFBConfig, (Display *, int, const int *, int *)) +AGL_API(int, GetFBConfigAttrib, (Display *, GLXFBConfig, int, int *)) +AGL_API(XVisualInfo *, GetVisualFromFBConfig, (Display *, GLXFBConfig)) +AGL_API(GLXWindow, CreateWindow, (Display *, GLXFBConfig, Window, const int *)) +AGL_API(void, DestroyWindow, (Display *, GLXWindow)) +AGL_API(GLXPixmap, CreatePixmap, (Display *, GLXFBConfig, Pixmap, const int *)) +AGL_API(void, DestroyPixmap, (Display *, GLXPixmap)) +AGL_API(GLXPbuffer, CreatePbuffer, (Display *, GLXFBConfig, const int *)) +AGL_API(void, DestroyPbuffer, (Display *, GLXPbuffer)) +AGL_API(void, QueryDrawable, (Display *, GLXDrawable, int, unsigned int *)) +AGL_API(GLXContext, CreateNewContext, (Display *, GLXFBConfig, int, GLXContext, Bool)) +AGL_API(Bool, MakeContextCurrent, (Display *, GLXDrawable, GLXDrawable, GLXContext)) +AGL_API(GLXDrawable, GetCurrentReadDrawable, (void)) +AGL_API(Display *, GetCurrentDisplay, (void)) +AGL_API(int, QueryContext, (Display *, GLXContext, int, int *)) +AGL_API(void, SelectEvent, (Display *, GLXDrawable, unsigned long)) +AGL_API(void, GetSelectedEvent, (Display *, GLXDrawable, unsigned long *)) +#endif +#ifdef _ALLEGRO_GLX_VERSION_1_4 +/* GLX 1.4 */ +AGL_API(__GLXextFuncPtr, GetProcAddress, (const GLubyte *)) +#endif + +#ifdef _ALLEGRO_GLX_ARB_get_proc_address +/* GLX_ARB_get_proc_address */ +AGL_API(__GLXextFuncPtr, GetProcAddressARB, (const GLubyte *)) +#endif + +#ifdef _ALLEGRO_GLX_ARB_create_context +AGL_API(GLXContext, CreateContextAttribsARB, (Display *, GLXFBConfig, GLXContext, Bool, const int *)) +#endif + +#ifdef _ALLEGRO_GLX_SGI_swap_control +/* GLX_SGI_swap_control */ +AGL_API(int, SwapIntervalSGI, (int)) +#endif + +#ifdef _ALLEGRO_GLX_SGI_video_sync +/* GLX_SGI_video_sync */ +AGL_API(int, GetVideoSyncSGI, (unsigned int *)) +AGL_API(int, WaitVideoSyncSGI, (int, int, unsigned int *)) +#endif + +#ifdef _ALLEGRO_GLX_SGI_make_current_read +/* GLX_SGI_make_current_read */ +AGL_API(Bool, MakeCurrentReadSGI, (Display *, GLXDrawable, GLXDrawable, GLXContext)) +AGL_API(GLXDrawable, GetCurrentReadDrawableSGI, (void)) +#endif + +#ifdef _ALLEGRO_GLX_SGIX_video_source +/* GLX_SGIX_video_source */ +/* This one needs SGI's header file to be included first */ +#ifdef _VL_H_ +AGL_API(GLXVideoSourceSGIX, CreateGLXVideoSourceSGIX, (Display *, int, VLServer, VLPath, int, VLNode)) +AGL_API(void, DestroyGLXVideoSourceSGIX, (Display *, GLXVideoSourceSGIX)) +#endif +#endif + +#ifdef _ALLEGRO_GLX_EXT_import_context +/* GLX_EXT_import_context */ +AGL_API(Display *, GetCurrentDisplayEXT, (void)) +AGL_API(int, QueryContextInfoEXT, (Display *, GLXContext, int, int *)) +AGL_API(GLXContextID, GetContextIDEXT, (const GLXContext)) +AGL_API(GLXContext, ImportContextEXT, (Display *, GLXContextID)) +AGL_API(void, FreeContextEXT, (Display *, GLXContext)) +#endif + +#ifdef _ALLEGRO_GLX_SGIX_fbconfig +/* GLX_SGIX_fbconfig */ +AGL_API(int, GetFBConfigAttribSGIX, (Display *, GLXFBConfigSGIX, int, int *)) +AGL_API(GLXFBConfigSGIX *, ChooseFBConfigSGIX, (Display *, int, int *, int *)) +AGL_API(GLXPixmap, CreateGLXPixmapWithConfigSGIX, (Display *, GLXFBConfigSGIX, Pixmap)) +AGL_API(GLXContext, CreateContextWithConfigSGIX, (Display *, GLXFBConfigSGIX, int, GLXContext, Bool)) +AGL_API(XVisualInfo *, GetVisualFromFBConfigSGIX, (Display *, GLXFBConfigSGIX)) +AGL_API(GLXFBConfigSGIX, GetFBConfigFromVisualSGIX, (Display *, XVisualInfo *)) +#endif + +#ifdef _ALLEGRO_GLX_SGIX_pbuffer +/* GLX_SGIX_pbuffer */ +AGL_API(GLXPbufferSGIX, CreateGLXPbufferSGIX, (Display *, GLXFBConfigSGIX, unsigned int, unsigned int, int *)) +AGL_API(void, DestroyGLXPbufferSGIX, (Display *, GLXPbufferSGIX)) +AGL_API(int, QueryGLXPbufferSGIX, (Display *, GLXPbufferSGIX, int, unsigned int *)) +AGL_API(void, SelectEventSGIX, (Display *, GLXDrawable, unsigned long)) +AGL_API(void, GetSelectedEventSGIX, (Display *, GLXDrawable, unsigned long *)) +#endif + +#ifdef _ALLEGRO_GLX_SGI_cushion +/* GLX_SGI_cushion */ +AGL_API(void, CushionSGI, (Display *, Window, float)) +#endif + +#ifdef _ALLEGRO_GLX_SGIX_video_resize +/* GLX_SGIX_video_resize */ +AGL_API(int, BindChannelToWindowSGIX, (Display *, int, int, Window)) +AGL_API(int, ChannelRectSGIX, (Display *, int, int, int, int, int, int)) +AGL_API(int, QueryChannelRectSGIX, (Display *, int, int, int *, int *, int *, int *)) +AGL_API(int, QueryChannelDeltasSGIX, (Display *, int, int, int *, int *, int *, int *)) +AGL_API(int, ChannelRectSyncSGIX, (Display *, int, int, GLenum)) +#endif + +#ifdef _ALLEGRO_GLX_SGIX_dmbuffer +/* GLX_SGIX_dmbuffer */ +/* This one needs SGI's header file to be included first */ +#ifdef _DM_BUFFER_H_ +AGL_API(Bool, AssociateDMPbufferSGIX, (Display *, GLXPbufferSGIX, DMparams *, DMbuffer)) +#endif +#endif + +#ifdef _ALLEGRO_GLX_SGIX_swap_group +/* GLX_SGIX_swap_group */ +AGL_API(void, JoinSwapGroupSGIX, (Display *, GLXDrawable, GLXDrawable)) +#endif + +#ifdef _ALLEGRO_GLX_SGIX_swap_barrier +/* GLX_SGIX_swap_barrier */ +AGL_API(void, BindSwapBarrierSGIX, (Display *, GLXDrawable, int)) +AGL_API(Bool, QueryMaxSwapBarriersSGIX, (Display *, int, int *)) +#endif + +#ifdef _ALLEGRO_GLX_SUN_get_transparent_index +/* GLX_SUN_get_transparent_index */ +AGL_API(Status, GetTransparentIndexSUN, (Display *, Window, Window, long *)) +#endif + +#ifdef _ALLEGRO_GLX_MESA_copy_sub_buffer +/* GLX_MESA_copy_sub_buffer */ +AGL_API(void, CopySubBufferMESA, (Display *, GLXDrawable, int, int, int, int)) +#endif + +#ifdef _ALLEGRO_GLX_MESA_pixmap_colormap +/* GLX_MESA_pixmap_colormap */ +AGL_API(GLXPixmap, CreateGLXPixmapMESA, (Display *, XVisualInfo *, Pixmap, Colormap)) +#endif + +#ifdef _ALLEGRO_GLX_MESA_release_buffers +/* GLX_MESA_release_buffers */ +AGL_API(Bool, ReleaseBuffersMESA, (Display *, GLXDrawable)) +#endif + +#ifdef _ALLEGRO_GLX_MESA_set_3dfx_mode +/* GLX_MESA_set_3dfx_mode */ +AGL_API(Bool, Set3DfxModeMESA, (int)) +#endif + +#ifdef _ALLEGRO_GLX_OML_sync_control +/* GLX_OML_sync_control */ +AGL_API(Bool, GetSyncValuesOML, (Display *, GLXDrawable, int64_t *, int64_t *, int64_t *)) +AGL_API(Bool, GetMscRateOML, (Display *, GLXDrawable, int32_t *, int32_t *)) +AGL_API(int64_t, SwapBuffersMscOML, (Display *, GLXDrawable, int64_t, int64_t, int64_t)) +AGL_API(Bool, WaitForMscOML, (Display *, GLXDrawable, int64_t, int64_t, int64_t, int64_t *, int64_t *, int64_t *)) +AGL_API(Bool, WaitForSbcOML, (Display *, GLXDrawable, int64_t, int64_t *, int64_t *, int64_t *)) +#endif + + +#ifdef _ALLEGRO_GLX_SGIX_hyperpipe +AGL_API(GLXHyperpipeNetworkSGIX *, QueryHyperpipeNetworkSGIX, (Display *dpy, int *npipes)) +AGL_API(int, HyperpipeConfigSGIX, (Display *dpy, int networkId, int npipes, GLXHyperpipeConfigSGIX *cfg, int *hpId)) +AGL_API(GLXHyperpipeConfigSGIX *, QueryHyperpipeConfigSGIX, (Display *dpy, int hpId, int *npipes)) +AGL_API(int, DestroyHyperpipeConfigSGIX, (Display * dpy, int hpId)) +AGL_API(int, BindHyperpipeSGIX, (Display *dpy, int hpId)) +AGL_API(int, QueryHyperpipeBestAttribSGIX, (Display *dpy, int timeSlice, int attrib, int size, void *attribList, void *returnAttribList)) +AGL_API(int, HyperpipeAttribSGIX, (Display *dpy, int timeSlice, int attrib, int size, void *attribList)) +AGL_API(int, QueryHyperpipeAttribSGIX, (Display *dpy, int timeSlice, int attrib, int size, void *returnAttribList)) +#endif + + +#ifdef _ALLEGRO_GLX_MESA_agp_offset +AGL_API(unsigned int, GetAGPOffsetMESA, (const void *pointer)) +#endif + + +#ifdef _ALLEGRO_GLX_EXT_texture_from_pixmap +AGL_API(void, BindTexImageEXT, (Display *dpy, GLXDrawable drawable, int buffer, const int *attrib_list)) +AGL_API(void, ReleaseTextImageEXT, (Display *dpy, GLXDrawable drawable, int buffer)) +#endif + +#ifdef _ALLEGRO_GLX_NV_video_output +AGL_API(int, GetVideoDeviceNV, (Display *dpy, int screen, int numVideoDevices, GLXVideoDeviceNV *pVideoDevice)) +AGL_API(int, ReleaseVideoDeviceNV, (Display *dpy, int screen, GLXVideoDeviceNV VideoDevice)) +AGL_API(int, BindVideoImageNV, (Display *dpy, GLXVideoDeviceNV VideoDevice, GLXPbuffer pbuf, int iVideoBuffer)) +AGL_API(int, ReleaseVideoImageNV, (Display *dpy, GLXPbuffer pbuf)) +AGL_API(int, SendPbufferToVideoNV, (Display *dpy, GLXPbuffer pbuf, int iBufferType, unsigned long *pulCounterPbuffer, GLboolean bBlock)) +AGL_API(int, GetVideoInfoNV, (Display *dpy, int screen, GLXVideoDeviceNV VideoDevice, unsigned long *pulCounterOutputVideo, unsigned long *pulCounterOutputPbuffer)) +#endif + +#ifdef _ALLEGRO_GLX_NV_swap_group +AGL_API(Bool, JoinSwapGroupNV, (Display *dpy, GLXDrawable drawable, GLuint group)) +AGL_API(Bool, BindSwapBarrierNV, (Display *dpy, GLuint group, GLuint barrier)) +AGL_API(Bool, QuerySwapGroupNV, (Display *dpy, GLXDrawable drawable, GLuint *group, GLuint *barrier)) +AGL_API(Bool, QueryMaxSwapGroupsNV, (Display *dpy, int screen, GLuint *maxGroups, GLuint *maxBarriers)) +AGL_API(Bool, QueryFrameCountNV, (Display *dpy, int screen, GLuint *count)) +AGL_API(Bool, ResetFrameCountNV, (Display *dpy, int screen)) +#endif + +#ifdef _ALLEGRO_GLX_NV_video_capture +AGL_API(int, BindVideoCaptureDeviceNV, (Display *dpy, unsigned int video_capture_slot, GLXVideoCaptureDeviceNV device)) +AGL_API(GLXVideoCaptureDeviceNV *, EnumerateVideoCaptureDevicesNV, (Display *dpy, int screen, int *nelements)) +AGL_API(void, LockVideoCaptureDeviceNV, (Display *dpy, GLXVideoCaptureDeviceNV device)) +AGL_API(int, QueryVideoCaptureDeviceNV, (Display *dpy, GLXVideoCaptureDeviceNV device, int attribute, int *value)) +AGL_API(void, ReleaseVideoCaptureDeviceNV, (Display *dpy, GLXVideoCaptureDeviceNV device)) +#endif + +#ifdef _ALLEGRO_GLX_EXT_swap_control +AGL_API(int, SwapIntervalEXT, (Display *dpy, GLXDrawable drawable, int interval)) +#endif + +#ifdef _ALLEGRO_GLX_NV_copy_image +AGL_API(void, CopyImageSubDataNV, (Display *dpy, GLXContext srcCtx, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLXContext dstCtx, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei width, GLsizei height, GLsizei depth)) +#endif + +#ifdef _ALLEGRO_GLX_EXT_create_context_es_profile +// no functions +#endif diff --git a/common/allegro/include/allegro5/opengl/GLext/glx_ext_defs.h b/common/allegro/include/allegro5/opengl/GLext/glx_ext_defs.h new file mode 100644 index 00000000..49c50209 --- /dev/null +++ b/common/allegro/include/allegro5/opengl/GLext/glx_ext_defs.h @@ -0,0 +1,513 @@ +/* HACK: Prevent both Mesa and SGI's broken headers from screwing us */ +#define __glxext_h_ +#include +#undef __glxext_h_ + +#ifndef GLX_VERSION_1_3 +#define _ALLEGRO_GLX_VERSION_1_3 +#define GLX_VERSION_1_3 +#define GLX_WINDOW_BIT 0x00000001 +#define GLX_PIXMAP_BIT 0x00000002 +#define GLX_PBUFFER_BIT 0x00000004 +#define GLX_RGBA_BIT 0x00000001 +#define GLX_COLOR_INDEX_BIT 0x00000002 +#define GLX_PBUFFER_CLOBBER_MASK 0x08000000 +#define GLX_FRONT_LEFT_BUFFER_BIT 0x00000001 +#define GLX_FRONT_RIGHT_BUFFER_BIT 0x00000002 +#define GLX_BACK_LEFT_BUFFER_BIT 0x00000004 +#define GLX_BACK_RIGHT_BUFFER_BIT 0x00000008 +#define GLX_AUX_BUFFERS_BIT 0x00000010 +#define GLX_DEPTH_BUFFER_BIT 0x00000020 +#define GLX_STENCIL_BUFFER_BIT 0x00000040 +#define GLX_ACCUM_BUFFER_BIT 0x00000080 +#define GLX_CONFIG_CAVEAT 0x20 +#define GLX_X_VISUAL_TYPE 0x22 +#define GLX_TRANSPARENT_TYPE 0x23 +#define GLX_TRANSPARENT_INDEX_VALUE 0x24 +#define GLX_TRANSPARENT_RED_VALUE 0x25 +#define GLX_TRANSPARENT_GREEN_VALUE 0x26 +#define GLX_TRANSPARENT_BLUE_VALUE 0x27 +#define GLX_TRANSPARENT_ALPHA_VALUE 0x28 +#define GLX_DONT_CARE 0xFFFFFFFF +#define GLX_NONE 0x8000 +#define GLX_SLOW_CONFIG 0x8001 +#define GLX_TRUE_COLOR 0x8002 +#define GLX_DIRECT_COLOR 0x8003 +#define GLX_PSEUDO_COLOR 0x8004 +#define GLX_STATIC_COLOR 0x8005 +#define GLX_GRAY_SCALE 0x8006 +#define GLX_STATIC_GRAY 0x8007 +#define GLX_TRANSPARENT_RGB 0x8008 +#define GLX_TRANSPARENT_INDEX 0x8009 +#define GLX_VISUAL_ID 0x800B +#define GLX_SCREEN 0x800C +#define GLX_NON_CONFORMANT_CONFIG 0x800D +#define GLX_DRAWABLE_TYPE 0x8010 +#define GLX_RENDER_TYPE 0x8011 +#define GLX_X_RENDERABLE 0x8012 +#define GLX_FBCONFIG_ID 0x8013 +#define GLX_RGBA_TYPE 0x8014 +#define GLX_COLOR_INDEX_TYPE 0x8015 +#define GLX_MAX_PBUFFER_WIDTH 0x8016 +#define GLX_MAX_PBUFFER_HEIGHT 0x8017 +#define GLX_MAX_PBUFFER_PIXELS 0x8018 +#define GLX_PRESERVED_CONTENTS 0x801B +#define GLX_LARGEST_PBUFFER 0x801C +#define GLX_WIDTH 0x801D +#define GLX_HEIGHT 0x801E +#define GLX_EVENT_MASK 0x801F +#define GLX_DAMAGED 0x8020 +#define GLX_SAVED 0x8021 +#define GLX_WINDOW 0x8022 +#define GLX_PBUFFER 0x8023 +#define GLX_PBUFFER_HEIGHT 0x8040 +#define GLX_PBUFFER_WIDTH 0x8041 +#endif + +#ifndef GLX_VERSION_1_4 +#define _ALLEGRO_GLX_VERSION_1_4 +#define GLX_VERSION_1_4 +#define GLX_SAMPLE_BUFFERS 100000 +#define GLX_SAMPLES 100001 +#endif + +#ifndef GLX_ARB_get_proc_address +#define _ALLEGRO_GLX_ARB_get_proc_address +#define GLX_ARB_get_proc_address +typedef void (*__GLXextFuncPtr)(void); +#endif + +#ifndef GLX_ARB_multisample +#define _ALLEGRO_GLX_ARB_multisample +#define GLX_ARB_multisample +#define GLX_SAMPLE_BUFFERS_ARB 100000 +#define GLX_SAMPLES_ARB 100001 +#endif + +#ifndef GLX_ARB_vertex_buffer_object +#define GLX_ARB_vertex_buffer_object +#define _ALLEGRO_GLX_ARB_vertex_buffer_object +#define GLX_CONTEXT_ALLOW_BUFFER_BYTE_ORDER_MISMATCH_ARB 0x2095 +#endif + +#ifndef GLX_ARB_fbconfig_float +#define GLX_ARB_fbconfig_float +#define _ALLEGRO_GLX_ARB_fbconfig_float +#define GLX_RGBA_FLOAT_TYPE_ARB 0x20B9 +#define GLX_RGBA_FLOAT_BIT_ARB 0x00000004 +#endif + +#ifndef GLX_ARB_create_context +#define GLX_ARB_create_context +#define _ALLEGRO_GLX_ARB_create_context +#define GLX_CONTEXT_DEBUG_BIT_ARB 0x00000001 +#define GLX_CONTEXT_FORWARD_COMPATIBLE_BIT_ARB 0x00000002 +#define GLX_CONTEXT_MAJOR_VERSION_ARB 0x2091 +#define GLX_CONTEXT_MINOR_VERSION_ARB 0x2092 +#define GLX_CONTEXT_FLAGS_ARB 0x2094 +#endif + +#ifndef GLX_ARB_create_context_profile +#define GLX_ARB_create_context_profile +#define _ALLEGRO_GLX_ARB_create_context_profile +#define GLX_CONTEXT_CORE_PROFILE_BIT_ARB 0x00000001 +#define GLX_CONTEXT_COMPATIBILITY_PROFILE_BIT_ARB 0x00000002 +#define GLX_CONTEXT_PROFILE_MASK_ARB 0x9126 +#endif + +#ifndef GLX_SGIS_multisample +#define _ALLEGRO_GLX_SGIS_multisample +#define GLX_SGIS_multisample +#define GLX_SAMPLE_BUFFERS_SGIS 100000 +#define GLX_SAMPLES_SGIS 100001 +#endif + +/* Fix for system headers that define GLX_VERSION_1_4 but do not define + * GLX_SAMPLES and GLX_SAMPLE_BUFFERS. */ +#ifndef GLX_SAMPLES +#define GLX_SAMPLE_BUFFERS 100000 +#define GLX_SAMPLES 100001 +#endif + +#ifndef GLX_EXT_visual_info +#define _ALLEGRO_GLX_EXT_visual_info +#define GLX_EXT_visual_info +#define GLX_X_VISUAL_TYPE_EXT 0x22 +#define GLX_TRANSPARENT_TYPE_EXT 0x23 +#define GLX_TRANSPARENT_INDEX_VALUE_EXT 0x24 +#define GLX_TRANSPARENT_RED_VALUE_EXT 0x25 +#define GLX_TRANSPARENT_GREEN_VALUE_EXT 0x26 +#define GLX_TRANSPARENT_BLUE_VALUE_EXT 0x27 +#define GLX_TRANSPARENT_ALPHA_VALUE_EXT 0x28 +#define GLX_NONE_EXT 0x8000 +#define GLX_TRUE_COLOR_EXT 0x8002 +#define GLX_DIRECT_COLOR_EXT 0x8003 +#define GLX_PSEUDO_COLOR_EXT 0x8004 +#define GLX_STATIC_COLOR_EXT 0x8005 +#define GLX_GRAY_SCALE_EXT 0x8006 +#define GLX_STATIC_GRAY_EXT 0x8007 +#define GLX_TRANSPARENT_RGB_EXT 0x8008 +#define GLX_TRANSPARENT_INDEX_EXT 0x8009 +#endif + +#ifndef GLX_EXT_visual_rating +#define _ALLEGRO_GLX_EXT_visual_rating +#define GLX_EXT_visual_rating +#define GLX_VISUAL_CAVEAT_EXT 0x20 +#define GLX_SLOW_VISUAL_EXT 0x8001 +#define GLX_NON_CONFORMANT_VISUAL_EXT 0x800D +/* GLX_NONE_EXT */ +#endif + +#ifndef GLX_EXT_import_context +#define _ALLEGRO_GLX_EXT_import_context +#define GLX_EXT_import_context +#define GLX_SHARE_CONTEXT_EXT 0x800A +#define GLX_VISUAL_ID_EXT 0x800B +#define GLX_SCREEN_EXT 0x800C +#endif + +#ifndef GLX_SGIX_fbconfig +#define _ALLEGRO_GLX_SGIX_fbconfig +#define GLX_SGIX_fbconfig +typedef XID GLXFBConfigIDSGIX; +typedef struct __GLXFBConfigRec *GLXFBConfigSGIX; +#define GLX_WINDOW_BIT_SGIX 0x00000001 +#define GLX_PIXMAP_BIT_SGIX 0x00000002 +#define GLX_RGBA_BIT_SGIX 0x00000001 +#define GLX_COLOR_INDEX_BIT_SGIX 0x00000002 +#define GLX_DRAWABLE_TYPE_SGIX 0x8010 +#define GLX_RENDER_TYPE_SGIX 0x8011 +#define GLX_X_RENDERABLE_SGIX 0x8012 +#define GLX_FBCONFIG_ID_SGIX 0x8013 +#define GLX_RGBA_TYPE_SGIX 0x8014 +#define GLX_COLOR_INDEX_TYPE_SGIX 0x8015 +/* GLX_SCREEN_EXT */ +#endif + +#ifndef GLX_SGIX_pbuffer +#define _ALLEGRO_GLX_SGIX_pbuffer +#define GLX_SGIX_pbuffer +typedef XID GLXPbufferSGIX; +typedef struct { + int type; + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came for SendEvent request */ + Display *display; /* display the event was read from */ + GLXDrawable drawable; /* i.d. of Drawable */ + int event_type; /* GLX_DAMAGED_SGIX or GLX_SAVED_SGIX */ + int draw_type; /* GLX_WINDOW_SGIX or GLX_PBUFFER_SGIX */ + unsigned int mask; /* mask indicating which buffers are affected*/ + int x, y; + int width, height; + int count; /* if nonzero, at least this many more */ +} GLXBufferClobberEventSGIX; +#define GLX_PBUFFER_BIT_SGIX 0x00000004 +#define GLX_BUFFER_CLOBBER_MASK_SGIX 0x08000000 +#define GLX_FRONT_LEFT_BUFFER_BIT_SGIX 0x00000001 +#define GLX_FRONT_RIGHT_BUFFER_BIT_SGIX 0x00000002 +#define GLX_BACK_LEFT_BUFFER_BIT_SGIX 0x00000004 +#define GLX_BACK_RIGHT_BUFFER_BIT_SGIX 0x00000008 +#define GLX_AUX_BUFFERS_BIT_SGIX 0x00000010 +#define GLX_DEPTH_BUFFER_BIT_SGIX 0x00000020 +#define GLX_STENCIL_BUFFER_BIT_SGIX 0x00000040 +#define GLX_ACCUM_BUFFER_BIT_SGIX 0x00000080 +#define GLX_SAMPLE_BUFFERS_BIT_SGIX 0x00000100 +#define GLX_MAX_PBUFFER_WIDTH_SGIX 0x8016 +#define GLX_MAX_PBUFFER_HEIGHT_SGIX 0x8017 +#define GLX_MAX_PBUFFER_PIXELS_SGIX 0x8018 +#define GLX_OPTIMAL_PBUFFER_WIDTH_SGIX 0x8019 +#define GLX_OPTIMAL_PBUFFER_HEIGHT_SGIX 0x801A +#define GLX_PRESERVED_CONTENTS_SGIX 0x801B +#define GLX_LARGEST_PBUFFER_SGIX 0x801C +#define GLX_WIDTH_SGIX 0x801D +#define GLX_HEIGHT_SGIX 0x801E +#define GLX_EVENT_MASK_SGIX 0x801F +#define GLX_DAMAGED_SGIX 0x8020 +#define GLX_SAVED_SGIX 0x8021 +#define GLX_WINDOW_SGIX 0x8022 +#define GLX_PBUFFER_SGIX 0x8023 +#endif + +#ifndef GLX_SGIX_video_resize +#define _ALLEGRO_GLX_SGIX_video_resize +#define GLX_SGIX_video_resize +#define GLX_SYNC_FRAME_SGIX 0x00000000 +#define GLX_SYNC_SWAP_SGIX 0x00000001 +#endif + +#ifndef GLX_SGIX_dmbuffer +#define _ALLEGRO_GLX_SGIX_dmbuffer +#define GLX_SGIX_dmbuffer +#define GLX_DIGITAL_MEDIA_PBUFFER_SGIX 0x8024 +#endif + +#ifndef GLX_SGIS_blended_overlay +#define _ALLEGRO_GLX_SGIS_blended_overlay +#define GLX_SGIS_blended_overlay +#define GLX_BLENDED_RGBA_SGIS 0x8025 +#endif + +#ifndef GLX_SGIS_shared_multisample +#define _ALLEGRO_GLX_SGIS_shared_multisample +#define GLX_SGIS_shared_multisample +#define GLX_MULTISAMPLE_SUB_RECT_WIDTH_SGIS 0x8026 +#define GLX_MULTISAMPLE_SUB_RECT_HEIGHT_SGIS 0x8027 +#endif + +#ifndef GLX_3DFX_multisample +#define _ALLEGRO_GLX_3DFX_multisample +#define GLX_3DFX_multisample +#define GLX_SAMPLE_BUFFERS_3DFX 0x8050 +#define GLX_SAMPLES_3DFX 0x8051 +#endif + +#ifndef GLX_MESA_set_3dfx_mode +#define _ALLEGRO_GLX_MESA_set_3dfx_mode +#define GLX_MESA_set_3dfx_mode +#define GLX_3DFX_WINDOW_MODE_MESA 0x1 +#define GLX_3DFX_FULLSCREEN_MODE_MESA 0x2 +#endif + +#ifndef GLX_SGIX_visual_select_group +#define _ALLEGRO_GLX_SGIX_visual_select_group +#define GLX_SGIX_visual_select_group +#define GLX_VISUAL_SELECT_GROUP_SGIX 0x8028 +#endif + +#ifndef GLX_OML_swap_method +#define _ALLEGRO_GLX_OML_swap_method +#define GLX_OML_swap_method +#define GLX_SWAP_METHOD_OML 0x8060 +#define GLX_SWAP_EXCHANGE_OML 0x8061 +#define GLX_SWAP_COPY_OML 0x8062 +#define GLX_SWAP_UNDEFINED_OML 0x8063 +#endif + +#ifndef GLX_SGIX_video_source +#define _ALLEGRO_GLX_SGIX_video_source +#define GLX_SGIX_video_source +typedef XID GLXVideoSourceSGIX; +#endif + +#ifndef GLX_SGI_video_sync +#define GLX_SGI_video_sync +#define _ALLEGRO_GLX_SGI_video_sync +#endif + +#ifndef GLX_SGI_swap_control +#define GLX_SGI_swap_control +#define _ALLEGRO_GLX_SGI_swap_control +#endif + +#ifndef GLX_SGI_make_current_read +#define GLX_SGI_make_current_read +#define _ALLEGRO_GLX_SGI_make_current_read +#endif + +#ifndef GLX_SGI_cushion +#define GLX_SGI_cushion +#define _ALLEGRO_GLX_SGI_cushion +#endif + +#ifndef GLX_SGIX_swap_group +#define GLX_SGIX_swap_group +#define _ALLEGRO_GLX_SGIX_swap_group +#endif + +#ifndef GLX_SGIX_swap_barrier +#define GLX_SGIX_swap_barrier +#define _ALLEGRO_GLX_SGIX_swap_barrier +#endif + +#ifndef GLX_SUN_get_transparent_index +#define GLX_SUN_get_transparent_index +#define _ALLEGRO_GLX_SUN_get_transparent_index +#endif + +#ifndef GLX_MESA_copy_sub_buffer +#define GLX_MESA_copy_sub_buffer +#define _ALLEGRO_GLX_MESA_copy_sub_buffer +#endif + +#ifndef GLX_MESA_pixmap_colormap +#define GLX_MESA_pixmap_colormap +#define _ALLEGRO_GLX_MESA_pixmap_colormap +#endif + +#ifndef GLX_MESA_release_buffers +#define GLX_MESA_release_buffers +#define _ALLEGRO_GLX_MESA_release_buffers +#endif + +#ifndef GLX_OML_sync_control +#define GLX_OML_sync_control +#define _ALLEGRO_GLX_OML_sync_control +#endif + +#ifndef GLX_SGIX_hyperpipe +#define GLX_SGIX_hyperpipe +#define _ALLEGRO_GLX_SGIX_hyperpipe +#define GLX_HYPERPIPE_ID_SGIX 0x8030 +#define GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX 80 +#define GLX_HYPERPIPE_DISPLAY_PIPE_SGIX 0x00000001 +#define GLX_HYPERPIPE_RENDER_PIPE_SGIX 0x00000002 +#define GLX_PIPE_RECT_SGIX 0x00000001 +#define GLX_PIPE_RECT_LIMITS_SGIX 0x00000002 +#define GLX_HYPERPIPE_STEREO_SGIX 0x00000003 +#define GLX_HYPERPIPE_PIXEL_AVERAGE_SGIX 0x00000004 +#define GLX_BAD_HYPERPIPE_CONFIG_SGIX 91 +#define GLX_BAD_HYPERPIPE_SGIX 92 + +typedef struct { + char pipeName[GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX]; + int networkId; +} GLXHyperpipeNetworkSGIX; + +typedef struct { + char pipeName[GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX]; + int channel; + unsigned int participationType; + int timeSlice; +} GLXHyperpipeConfigSGIX; + +typedef struct { + char pipeName[GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX]; + int srcXOrigin; + int srcYOrigin; + int srcWidth; + int srcHeight; + int destXOrigin; + int destYOrigin; + int destWidth; + int destHeight; +} GLXPipeRect; + +typedef struct { + char pipeName[GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX]; + int XOrigin; + int YOrigin; + int maxHeight; + int maxWidth; +} GLXPipeRectLimits; +#endif + + +#ifndef GLX_MESA_agp_offset +#define GLX_MESA_agp_offset +#define _ALLEGRO_GLX_MESA_agp_offset +#endif + +#ifndef GLX_EXT_framebuffer_sRGB +#define GLX_EXT_framebuffer_sRGB +#define _ALLEGRO_GLX_EXT_framebuffer_sRGB +#define GLX_FRAMEBUFFER_SRGB_CAPABLE_EXT 0x20B2 +#endif + +#ifndef GLX_EXT_fbconfig_packed_float +#define GLX_EXT_fbconfig_packed_float +#define _ALLEGRO_GLX_EXT_fbconfig_packed_float +#define GLX_RGBA_UNSIGNED_FLOAT_TYPE_EXT 0x20B1 +#define GLX_RGBA_UNSIGNED_FLOAT_BIT_EXT 0x00000008 +#endif + +#ifndef GLX_EXT_texture_from_pixmap +#define GLX_EXT_texture_from_pixmap +#define _ALLEGRO_GLX_EXT_texture_from_pixmap +#define GLX_BIND_TO_TEXTURE_RGB_EXT 0x20D0 +#define GLX_BIND_TO_TEXTURE_RGBA_EXT 0x20D1 +#define GLX_BIND_TO_MIPMAP_TEXTURE_EXT 0x20D2 +#define GLX_BIND_TO_TEXTURE_TARGETS_EXT 0x20D3 +#define GLX_Y_INVERTED_EXT 0x20D4 +#define GLX_TEXTURE_FORMAT_EXT 0x20D5 +#define GLX_TEXTURE_TARGET_EXT 0x20D6 +#define GLX_MIPMAP_TEXTURE_EXT 0x20D7 +#define GLX_TEXTURE_FORMAT_NONE_EXT 0x20D8 +#define GLX_TEXTURE_FORMAT_RGB_EXT 0x20D9 +#define GLX_TEXTURE_FORMAT_RGBA_EXT 0x20DA +#define GLX_TEXTURE_1D_BIT_EXT 0x00000001 +#define GLX_TEXTURE_2D_BIT_EXT 0x00000002 +#define GLX_TEXTURE_RECTANGLE_BIT_EXT 0x00000004 +#define GLX_TEXTURE_1D_EXT 0x20DB +#define GLX_TEXTURE_2D_EXT 0x20DC +#define GLX_TEXTURE_RECTANGLE_EXT 0x20DD +#define GLX_FRONT_LEFT_EXT 0x20DE +#define GLX_FRONT_RIGHT_EXT 0x20DF +#define GLX_BACK_LEFT_EXT 0x20E0 +#define GLX_BACK_RIGHT_EXT 0x20E1 +#define GLX_FRONT_EXT GLX_FRONT_LEFT_EXT +#define GLX_BACK_EXT GLX_BACK_LEFT_EXT +#define GLX_AUX0_EXT 0x20E2 +#define GLX_AUX1_EXT 0x20E3 +#define GLX_AUX2_EXT 0x20E4 +#define GLX_AUX3_EXT 0x20E5 +#define GLX_AUX4_EXT 0x20E6 +#define GLX_AUX5_EXT 0x20E7 +#define GLX_AUX6_EXT 0x20E8 +#define GLX_AUX7_EXT 0x20E9 +#define GLX_AUX8_EXT 0x20EA +#define GLX_AUX9_EXT 0x20EB +#endif + +#ifndef GLX_NV_present_video +#define GLX_NV_present_video +#define _ALLEGRO_GLX_NV_present_video +#define GLX_GLX_NUM_VIDEO_SLOTS_NV 0x20F0 +#endif + +#ifndef GLX_NV_video_output +#define GLX_NV_video_output +#define _ALLEGRO_GLX_NV_video_output +#define GLX_VIDEO_OUT_COLOR_NV 0x20C3 +#define GLX_VIDEO_OUT_ALPHA_NV 0x20C4 +#define GLX_VIDEO_OUT_DEPTH_NV 0x20C5 +#define GLX_VIDEO_OUT_COLOR_AND_ALPHA_NV 0x20C6 +#define GLX_VIDEO_OUT_COLOR_AND_DEPTH_NV 0x20C7 +#define GLX_VIDEO_OUT_FRAME_NV 0x20C8 +#define GLX_VIDEO_OUT_FIELD_1_NV 0x20C9 +#define GLX_VIDEO_OUT_FIELD_2_NV 0x20CA +typedef unsigned int GLXVideoDeviceNV; +#endif + +#ifndef GLX_NV_swap_group +#define GLX_NV_swap_group +#define _ALLEGRO_GLX_NV_swap_group +#endif + +#ifndef GLX_NV_video_capture +#define GLX_NV_video_capture +#define _ALLEGRO_GLX_NV_video_capture +#define GLX_DEVICE_ID_NV 0x20CD +#define GLX_UNIQUE_ID_NV 0x20CE +#define GLX_NUM_VIDEO_CAPTURE_SLOTS_NV 0x20CF +typedef XID GLXVideoCaptureDeviceNV; +#endif + +#ifndef GLX_EXT_swap_control +#define GLX_EXT_swap_control +#define _ALLEGRO_GLX_EXT_swap_control +#define GLX_SWAP_INTERVAL_EXT 0x20F1 +#define GLX_MAX_SWAP_INTERVAL_EXT 0x20F2 +#endif + +#ifndef GLX_NV_copy_image +#define GLX_NV_copy_image +#define _ALLEGRO_GLX_NV_copy_image +#endif + +#ifndef GLX_INTEL_swap_event +#define GLX_INTEL_swap_event +#define _ALLEGRO_GLX_INTEL_swap_event +#define GLX_BUFFER_SWAP_COMPLETE_INTEL_MASK 0x04000000 +#define GLX_EXCHANGE_COMPLETE_INTEL 0x8180 +#define GLX_COPY_COMPLETE_INTEL 0x8181 +#define GLX_FLIP_COMPLETE_INTEL 0x8182 +#endif + +#ifndef GLX_EXT_create_context_es_profile +#define GLX_EXT_create_context_es_profile +#define GLX_EXT_create_context_es2_profile +#define _ALLEGRO_GLX_EXT_create_context_es_profile +#define GLX_CONTEXT_ES_PROFILE_BIT_EXT 0x00000004 +#define GLX_CONTEXT_ES2_PROFILE_BIT_EXT 0x00000004 +#endif diff --git a/common/allegro/include/allegro5/opengl/GLext/glx_ext_list.h b/common/allegro/include/allegro5/opengl/GLext/glx_ext_list.h new file mode 100644 index 00000000..098f74ce --- /dev/null +++ b/common/allegro/include/allegro5/opengl/GLext/glx_ext_list.h @@ -0,0 +1,41 @@ +AGL_EXT(ARB_get_proc_address, 0) +AGL_EXT(ARB_multisample, 0) +AGL_EXT(ARB_fbconfig_float, 0) +AGL_EXT(ARB_create_context, 0) +AGL_EXT(ARB_vertex_buffer_object, 0) +AGL_EXT(EXT_visual_info, 0) +AGL_EXT(SGI_swap_control, 0) +AGL_EXT(SGI_video_sync, 0) +AGL_EXT(SGI_make_current_read, 0) +AGL_EXT(SGIX_video_source, 0) +AGL_EXT(EXT_visual_rating, 0) +AGL_EXT(EXT_import_context, 0) +AGL_EXT(SGIX_fbconfig, 0) +AGL_EXT(SGIX_pbuffer, 0) +AGL_EXT(SGI_cushion, 0) +AGL_EXT(SGIX_video_resize, 0) +AGL_EXT(SGIX_dm_buffer, 0) +AGL_EXT(SGIX_swap_group, 0) +AGL_EXT(SGIX_swap_barrier, 0) +AGL_EXT(SGIS_color_range, 0) +AGL_EXT(SGIS_blended_overlay, 0) +AGL_EXT(SUN_get_transparent_index, 0) +AGL_EXT(MESA_copy_sub_buffer, 0) +AGL_EXT(MESA_pixmap_colormap, 0) +AGL_EXT(MESA_release_buffers, 0) +AGL_EXT(MESA_set_3dfx_mode, 0) +AGL_EXT(SGIX_visual_select_group, 0) +AGL_EXT(OML_swap_method, 0) +AGL_EXT(OML_sync_control, 0) +AGL_EXT(SGIX_hyperpipe, 0) +AGL_EXT(MESA_agp_offset, 0) +AGL_EXT(EXT_framebuffer_sRGB, 0) +AGL_EXT(EXT_packed_float, 0) +AGL_EXT(EXT_texture_from_pixmap, 0) +AGL_EXT(NV_video_output, 0) +AGL_EXT(NV_swap_group, 0) +AGL_EXT(NV_video_capture, 0) +AGL_EXT(EXT_swap_control, 0) +AGL_EXT(NV_copy_image, 0) +AGL_EXT(INTEL_swap_event, 0) +AGL_EXT(EXT_create_context_es_profile, 0) diff --git a/common/allegro/include/allegro5/opengl/GLext/wgl_ext_alias.h b/common/allegro/include/allegro5/opengl/GLext/wgl_ext_alias.h new file mode 100644 index 00000000..ab0cf1f2 --- /dev/null +++ b/common/allegro/include/allegro5/opengl/GLext/wgl_ext_alias.h @@ -0,0 +1,168 @@ +/*Automatically generated by gl_mkalias.sh DO NOT EDIT!*/ +/*WGL_ARB_buffer_region*/ +#define wglCreateBufferRegionARB _al_wglCreateBufferRegionARB +#define wglDeleteBufferRegionARB _al_wglDeleteBufferRegionARB +#define wglSaveBufferRegionARB _al_wglSaveBufferRegionARB +#define wglRestoreBufferRegionARB _al_wglRestoreBufferRegionARB + +/*WGL_ARB_extensions_string*/ +#define wglGetExtensionsStringARB _al_wglGetExtensionsStringARB + +/*WGL_ARB_pixel_format*/ +#define wglGetPixelFormatAttribivARB _al_wglGetPixelFormatAttribivARB +#define wglGetPixelFormatAttribfvARB _al_wglGetPixelFormatAttribfvARB +#define wglChoosePixelFormatARB _al_wglChoosePixelFormatARB + +/*WGL_ARB_make_current_read*/ +#define wglMakeContextCurrentARB _al_wglMakeContextCurrentARB +#define wglGetCurrentReadDCARB _al_wglGetCurrentReadDCARB + +/*WGL_ARB_pbuffer*/ +#define wglCreatePbufferARB _al_wglCreatePbufferARB +#define wglGetPbufferDCARB _al_wglGetPbufferDCARB +#define wglReleasePbufferDCARB _al_wglReleasePbufferDCARB +#define wglDestroyPbufferARB _al_wglDestroyPbufferARB +#define wglQueryPbufferARB _al_wglQueryPbufferARB + +/*WGL_ARB_render_texture*/ +#define wglBindTexImageARB _al_wglBindTexImageARB +#define wglReleaseTexImageARB _al_wglReleaseTexImageARB +#define wglSetPbufferAttribARB _al_wglSetPbufferAttribARB + +/*WGL_ARB_create_context*/ +#define wglCreateContextAttribsARB _al_wglCreateContextAttribsARB + +/*WGL_EXT_display_color_table*/ +#define wglCreateDisplayColorTableEXT _al_wglCreateDisplayColorTableEXT +#define wglLoadDisplayColorTableEXT _al_wglLoadDisplayColorTableEXT +#define wglBindDisplayColorTableEXT _al_wglBindDisplayColorTableEXT +#define wglDestroyDisplayColorTableEXT _al_wglDestroyDisplayColorTableEXT + +/*WGL_EXT_extensions_string*/ +#define wglGetExtensionsStringEXT _al_wglGetExtensionsStringEXT + +/*WGL_EXT_make_current_read*/ +#define wglMakeContextCurrentEXT _al_wglMakeContextCurrentEXT +#define wglGetCurrentReadDCEXT _al_wglGetCurrentReadDCEXT + +/*WGL_EXT_pbuffer*/ +#define wglCreatePbufferEXT _al_wglCreatePbufferEXT +#define wglGetPbufferDCEXT _al_wglGetPbufferDCEXT +#define wglReleasePbufferDCEXT _al_wglReleasePbufferDCEXT +#define wglDestroyPbufferEXT _al_wglDestroyPbufferEXT +#define wglQueryPbufferEXT _al_wglQueryPbufferEXT + +/*WGL_EXT_pixel_format*/ +#define wglGetPixelFormatAttribivEXT _al_wglGetPixelFormatAttribivEXT +#define wglGetPixelFormatAttribfvEXT _al_wglGetPixelFormatAttribfvEXT +#define wglChoosePixelFormatEXT _al_wglChoosePixelFormatEXT + +/*WGL_EXT_swap_control*/ +#define wglSwapIntervalEXT _al_wglSwapIntervalEXT +#define wglGetSwapIntervalEXT _al_wglGetSwapIntervalEXT + +/*WGL_NV_vertex_array_range*/ +#define wglAllocateMemoryNV _al_wglAllocateMemoryNV +#define wglFreeMemoryNV _al_wglFreeMemoryNV + +/*WGL_OML_sync_control*/ +#define wglGetSyncValuesOML _al_wglGetSyncValuesOML +#define wglGetMscRateOML _al_wglGetMscRateOML +#define wglSwapBuffersMscOML _al_wglSwapBuffersMscOML +#define wglSwapLayerBuffersMscOML _al_wglSwapLayerBuffersMscOML +#define wglWaitForMscOML _al_wglWaitForMscOML +#define wglWaitForSbcOML _al_wglWaitForSbcOML + +/*WGL_I3D_digital_video_control*/ +#define wglGetDigitalVideoParametersI3D _al_wglGetDigitalVideoParametersI3D +#define wglSetDigitalVideoParametersI3D _al_wglSetDigitalVideoParametersI3D + +/*WGL_I3D_gamma*/ +#define wglGetGammaTableParametersI3D _al_wglGetGammaTableParametersI3D +#define wglSetGammaTableParametersI3D _al_wglSetGammaTableParametersI3D +#define wglGetGammaTableI3D _al_wglGetGammaTableI3D +#define wglSetGammaTableI3D _al_wglSetGammaTableI3D + +/*WGL_I3D_genlock*/ +#define wglEnableGenlockI3D _al_wglEnableGenlockI3D +#define wglDisableGenlockI3D _al_wglDisableGenlockI3D +#define wglIsEnabledGenlockI3D _al_wglIsEnabledGenlockI3D +#define wglGenlockSourceI3D _al_wglGenlockSourceI3D +#define wglGetGenlockSourceI3D _al_wglGetGenlockSourceI3D +#define wglGenlockSourceEdgeI3D _al_wglGenlockSourceEdgeI3D +#define wglGetGenlockSourceEdgeI3D _al_wglGetGenlockSourceEdgeI3D +#define wglGenlockSampleRateI3D _al_wglGenlockSampleRateI3D +#define wglGetGenlockSampleRateI3D _al_wglGetGenlockSampleRateI3D +#define wglGenlockSourceDelayI3D _al_wglGenlockSourceDelayI3D +#define wglGetGenlockSourceDelayI3D _al_wglGetGenlockSourceDelayI3D +#define wglQueryGenlockMaxSourceDelayI3D _al_wglQueryGenlockMaxSourceDelayI3D + +/*WGL_I3D_image_buffer*/ +#define wglCreateImageBufferI3D _al_wglCreateImageBufferI3D +#define wglDestroyImageBufferI3D _al_wglDestroyImageBufferI3D +#define wglAssociateImageBufferEventsI3D _al_wglAssociateImageBufferEventsI3D +#define wglReleaseImageBufferEventsI3D _al_wglReleaseImageBufferEventsI3D + +/*WGL_I3D_swap_frame_lock*/ +#define wglEnableFrameLockI3D _al_wglEnableFrameLockI3D +#define wglDisableFrameLockI3D _al_wglDisableFrameLockI3D +#define wglIsEnabledFrameLockI3D _al_wglIsEnabledFrameLockI3D +#define wglQueryFrameLockMasterI3D _al_wglQueryFrameLockMasterI3D + +/*WGL_I3D_swap_frame_usage*/ +#define wglGetFrameUsageI3D _al_wglGetFrameUsageI3D +#define wglBeginFrameTrackingI3D _al_wglBeginFrameTrackingI3D +#define wglEndFrameTrackingI3D _al_wglEndFrameTrackingI3D +#define wglQueryFrameTrackingI3D _al_wglQueryFrameTrackingI3D + +/*glAddSwapHintRectWIN*/ +#define wglAddSwapHintRectWIN _al_wglAddSwapHintRectWIN + +/*WGL_NV_present_video*/ +#define wglEnumerateVideoDevicesNV _al_wglEnumerateVideoDevicesNV +#define wglBindVideoDeviceNV _al_wglBindVideoDeviceNV +#define wglQueryCurrentContextNV _al_wglQueryCurrentContextNV + +/*WGL_NV_video_out*/ +#define wglGetVideoDeviceNV _al_wglGetVideoDeviceNV +#define wglReleaseVideoDeviceNV _al_wglReleaseVideoDeviceNV +#define wglBindVideoImageNV _al_wglBindVideoImageNV +#define wglReleaseVideoImageNV _al_wglReleaseVideoImageNV +#define wglSendPbufferToVideoNV _al_wglSendPbufferToVideoNV +#define wglGetVideoInfoNV _al_wglGetVideoInfoNV + +/*WGL_NV_swap_group*/ +#define wglJoinSwapGroupNV _al_wglJoinSwapGroupNV +#define wglBindSwapBarrierNV _al_wglBindSwapBarrierNV +#define wglQuerySwapGroupNV _al_wglQuerySwapGroupNV +#define wglQueryMaxSwapGroupsNV _al_wglQueryMaxSwapGroupsNV +#define wglQueryFrameCountNV _al_wglQueryFrameCountNV +#define wglResetFrameCountNV _al_wglResetFrameCountNV + +/*WGL_NV_gpu_affinity*/ +#define wglEnumGpusNV _al_wglEnumGpusNV +#define wglEnumGpuDevicesNV _al_wglEnumGpuDevicesNV +#define wglCreateAffinityDCNV _al_wglCreateAffinityDCNV +#define wglEnumGpusFromAffinityDCNV _al_wglEnumGpusFromAffinityDCNV +#define wglDeleteDCNV _al_wglDeleteDCNV + +/*WGL_AMD_gpu_association*/ +#define wglGetGPUIDsAMD _al_wglGetGPUIDsAMD +#define wglGetGPUInfoAMD _al_wglGetGPUInfoAMD +#define wglGetContextGPUIDAMD _al_wglGetContextGPUIDAMD +#define wglCreateAssociatedContextAMD _al_wglCreateAssociatedContextAMD +#define wglCreateAssociatedContextAttribsAMD _al_wglCreateAssociatedContextAttribsAMD +#define wglDeleteAssociatedContextAMD _al_wglDeleteAssociatedContextAMD +#define wglMakeAssociatedContextCurrentAMD _al_wglMakeAssociatedContextCurrentAMD +#define wglGetCurrentAssociatedContextAMD _al_wglGetCurrentAssociatedContextAMD +#define wglBlitContextFramebufferAMD _al_wglBlitContextFramebufferAMD + +/*WGL_NV_video_capture*/ +#define wglBindVideoCaptureDeviceNV _al_wglBindVideoCaptureDeviceNV +#define wglEnumerateVideoCaptureDevicesNV _al_wglEnumerateVideoCaptureDevicesNV +#define wglLockVideoCaptureDeviceNV _al_wglLockVideoCaptureDeviceNV +#define wglQueryVideoCaptureDeviceNV _al_wglQueryVideoCaptureDeviceNV +#define wglReleaseVideoCaptureDeviceNV _al_wglReleaseVideoCaptureDeviceNV + +/*WGL_NV_copy_image*/ +#define wglCopyImageSubDataNV _al_wglCopyImageSubDataNV diff --git a/common/allegro/include/allegro5/opengl/GLext/wgl_ext_api.h b/common/allegro/include/allegro5/opengl/GLext/wgl_ext_api.h new file mode 100644 index 00000000..40aa9642 --- /dev/null +++ b/common/allegro/include/allegro5/opengl/GLext/wgl_ext_api.h @@ -0,0 +1,167 @@ +/* WGL_ARB_buffer_region */ +AGL_API(HANDLE, CreateBufferRegionARB, (HDC, int, UINT)) +AGL_API(VOID, DeleteBufferRegionARB, (HANDLE)) +AGL_API(BOOL, SaveBufferRegionARB, (HANDLE, int, int, int, int)) +AGL_API(BOOL, RestoreBufferRegionARB, (HANDLE, int, int, int, int, int, int)) + +/* WGL_ARB_extensions_string */ +AGL_API(const char *, GetExtensionsStringARB, (HDC)) + +/* WGL_ARB_pixel_format */ +AGL_API(BOOL, GetPixelFormatAttribivARB, (HDC, int, int, UINT, const int *, int *)) +AGL_API(BOOL, GetPixelFormatAttribfvARB, (HDC, int, int, UINT, const int *, FLOAT *)) +AGL_API(BOOL, ChoosePixelFormatARB, (HDC, const int *, const FLOAT *, UINT, int *, UINT *)) + +/* WGL_ARB_make_current_read */ +AGL_API(BOOL, MakeContextCurrentARB, (HDC, HDC, HGLRC)) +AGL_API(HDC, GetCurrentReadDCARB, (void)) + +/* WGL_ARB_pbuffer */ +AGL_API(HPBUFFERARB, CreatePbufferARB, (HDC, int, int, int, const int *)) +AGL_API(HDC, GetPbufferDCARB, (HPBUFFERARB)) +AGL_API(int, ReleasePbufferDCARB, (HPBUFFERARB, HDC)) +AGL_API(BOOL, DestroyPbufferARB, (HPBUFFERARB)) +AGL_API(BOOL, QueryPbufferARB, (HPBUFFERARB, int, int *)) + +/* WGL_ARB_render_texture */ +AGL_API(BOOL, BindTexImageARB, (HPBUFFERARB, int)) +AGL_API(BOOL, ReleaseTexImageARB, (HPBUFFERARB, int)) +AGL_API(BOOL, SetPbufferAttribARB, (HPBUFFERARB, const int *)) + +/* WGL_ARB_create_context */ +AGL_API(HGLRC, CreateContextAttribsARB, (HDC, HGLRC, const int *)) + +/* WGL_EXT_display_color_table */ +AGL_API(GLboolean, CreateDisplayColorTableEXT, (GLushort)) +AGL_API(GLboolean, LoadDisplayColorTableEXT, (const GLushort *, GLuint)) +AGL_API(GLboolean, BindDisplayColorTableEXT, (GLushort)) +AGL_API(VOID, DestroyDisplayColorTableEXT, (GLushort)) + +/* WGL_EXT_extensions_string */ +AGL_API(const char *, GetExtensionsStringEXT, (void)) + +/* WGL_EXT_make_current_read */ +AGL_API(BOOL, MakeContextCurrentEXT, (HDC, HDC, HGLRC)) +AGL_API(HDC, GetCurrentReadDCEXT, (void)) + +/* WGL_EXT_pbuffer */ +AGL_API(HPBUFFEREXT, CreatePbufferEXT, (HDC, int, int, int, const int *)) +AGL_API(HDC, GetPbufferDCEXT, (HPBUFFEREXT)) +AGL_API(int, ReleasePbufferDCEXT, (HPBUFFEREXT, HDC)) +AGL_API(BOOL, DestroyPbufferEXT, (HPBUFFEREXT)) +AGL_API(BOOL, QueryPbufferEXT, (HPBUFFEREXT, int, int *)) + +/* WGL_EXT_pixel_format */ +AGL_API(BOOL, GetPixelFormatAttribivEXT, (HDC, int, int, UINT, int *, int *)) +AGL_API(BOOL, GetPixelFormatAttribfvEXT, (HDC, int, int, UINT, int *, FLOAT *)) +AGL_API(BOOL, ChoosePixelFormatEXT, (HDC, const int *, const FLOAT *, UINT, int *, UINT *)) + +/* WGL_EXT_swap_control */ +AGL_API(BOOL, SwapIntervalEXT, (int)) +AGL_API(int, GetSwapIntervalEXT, (void)) + +/* WGL_NV_vertex_array_range */ +AGL_API(void*, AllocateMemoryNV, (GLsizei, GLfloat, GLfloat, GLfloat)) +AGL_API(void, FreeMemoryNV, (void *)) + +/* WGL_OML_sync_control */ +AGL_API(BOOL, GetSyncValuesOML, (HDC, INT64 *, INT64 *, INT64 *)) +AGL_API(BOOL, GetMscRateOML, (HDC, INT32 *, INT32 *)) +AGL_API(INT64, SwapBuffersMscOML, (HDC, INT64, INT64, INT64)) +AGL_API(INT64, SwapLayerBuffersMscOML, (HDC, int, INT64, INT64, INT64)) +AGL_API(BOOL, WaitForMscOML, (HDC, INT64, INT64, INT64, INT64 *, INT64 *, INT64 *)) +AGL_API(BOOL, WaitForSbcOML, (HDC, INT64, INT64 *, INT64 *, INT64 *)) + +/* WGL_I3D_digital_video_control */ +AGL_API(BOOL, GetDigitalVideoParametersI3D, (HDC, int, int *)) +AGL_API(BOOL, SetDigitalVideoParametersI3D, (HDC, int, const int *)) + +/* WGL_I3D_gamma */ +AGL_API(BOOL, GetGammaTableParametersI3D, (HDC, int, int *)) +AGL_API(BOOL, SetGammaTableParametersI3D, (HDC, int, const int *)) +AGL_API(BOOL, GetGammaTableI3D, (HDC, int, USHORT *, USHORT *, USHORT *)) +AGL_API(BOOL, SetGammaTableI3D, (HDC, int, const USHORT *, const USHORT *, const USHORT *)) + +/* WGL_I3D_genlock */ +AGL_API(BOOL, EnableGenlockI3D, (HDC)) +AGL_API(BOOL, DisableGenlockI3D, (HDC)) +AGL_API(BOOL, IsEnabledGenlockI3D, (HDC, BOOL *)) +AGL_API(BOOL, GenlockSourceI3D, (HDC, UINT)) +AGL_API(BOOL, GetGenlockSourceI3D, (HDC, UINT *)) +AGL_API(BOOL, GenlockSourceEdgeI3D, (HDC, UINT)) +AGL_API(BOOL, GetGenlockSourceEdgeI3D, (HDC, UINT *)) +AGL_API(BOOL, GenlockSampleRateI3D, (HDC, UINT)) +AGL_API(BOOL, GetGenlockSampleRateI3D, (HDC, UINT *)) +AGL_API(BOOL, GenlockSourceDelayI3D, (HDC, UINT)) +AGL_API(BOOL, GetGenlockSourceDelayI3D, (HDC, UINT *)) +AGL_API(BOOL, QueryGenlockMaxSourceDelayI3D, (HDC, UINT *, UINT *)) + +/* WGL_I3D_image_buffer */ +AGL_API(LPVOID, CreateImageBufferI3D, (HDC, DWORD, UINT)) +AGL_API(BOOL, DestroyImageBufferI3D, (HDC, LPVOID)) +AGL_API(BOOL, AssociateImageBufferEventsI3D, (HDC, const HANDLE *, const LPVOID *, const DWORD *, UINT)) +AGL_API(BOOL, ReleaseImageBufferEventsI3D, (HDC, const LPVOID *, UINT)) + +/* WGL_I3D_swap_frame_lock */ +AGL_API(BOOL, EnableFrameLockI3D, (void)) +AGL_API(BOOL, DisableFrameLockI3D, (void)) +AGL_API(BOOL, IsEnabledFrameLockI3D, (BOOL *)) +AGL_API(BOOL, QueryFrameLockMasterI3D, (BOOL *)) + +/* WGL_I3D_swap_frame_usage */ +AGL_API(BOOL, GetFrameUsageI3D, (float *)) +AGL_API(BOOL, BeginFrameTrackingI3D, (void)) +AGL_API(BOOL, EndFrameTrackingI3D, (void)) +AGL_API(BOOL, QueryFrameTrackingI3D, (DWORD *, DWORD *, float *)) + +/* glAddSwapHintRectWIN */ +AGL_API(void, AddSwapHintRectWIN, (int, int, int, int)) + +/* WGL_NV_present_video */ +AGL_API(int, EnumerateVideoDevicesNV, (HDC, HVIDEOOUTPUTDEVICENV *)) +AGL_API(BOOL, BindVideoDeviceNV, (HDC, unsigned int, HVIDEOOUTPUTDEVICENV, const int *)) +AGL_API(BOOL, QueryCurrentContextNV, (int, int *)) + +/* WGL_NV_video_out */ +AGL_API(BOOL, GetVideoDeviceNV, (HDC, int, HPVIDEODEV *)) +AGL_API(BOOL, ReleaseVideoDeviceNV, (HPVIDEODEV)) +AGL_API(BOOL, BindVideoImageNV, (HPVIDEODEV, HPBUFFERARB, int)) +AGL_API(BOOL, ReleaseVideoImageNV, (HPBUFFERARB, int)) +AGL_API(BOOL, SendPbufferToVideoNV, (HPBUFFERARB, int, unsigned long *, BOOL)) +AGL_API(BOOL, GetVideoInfoNV, (HPVIDEODEV, unsigned long *, unsigned long *)) + +/* WGL_NV_swap_group */ +AGL_API(BOOL, JoinSwapGroupNV, (HDC hDC, GLuint group)) +AGL_API(BOOL, BindSwapBarrierNV, (GLuint group, GLuint barrier)) +AGL_API(BOOL, QuerySwapGroupNV, (HDC hDC, GLuint *group, GLuint *barrier)) +AGL_API(BOOL, QueryMaxSwapGroupsNV, (HDC hDC, GLuint *maxGroups, GLuint *maxBarriers)) +AGL_API(BOOL, QueryFrameCountNV, (HDC hDC, GLuint *count)) +AGL_API(BOOL, ResetFrameCountNV, (HDC hDC)) + +/* WGL_NV_gpu_affinity */ +AGL_API(BOOL, EnumGpusNV, (UINT, HGPUNV *)) +AGL_API(BOOL, EnumGpuDevicesNV, (HGPUNV, UINT, PGPU_DEVICE)) +AGL_API(HDC, CreateAffinityDCNV, (const HGPUNV *)) +AGL_API(BOOL, EnumGpusFromAffinityDCNV, (HDC, UINT, HGPUNV *)) +AGL_API(BOOL, DeleteDCNV, (HDC)) + +/* WGL_AMD_gpu_association */ +AGL_API(UINT, GetGPUIDsAMD, (UINT, UINT *)) +AGL_API(INT, GetGPUInfoAMD, (UINT, int, GLenum, UINT, void *)) +AGL_API(UINT, GetContextGPUIDAMD, (HGLRC)) +AGL_API(HGLRC, CreateAssociatedContextAMD, (UINT)) +AGL_API(HGLRC, CreateAssociatedContextAttribsAMD, (UINT, HGLRC, const int *)) +AGL_API(BOOL, DeleteAssociatedContextAMD, (HGLRC)) +AGL_API(BOOL, MakeAssociatedContextCurrentAMD, (HGLRC)) +AGL_API(HGLRC, GetCurrentAssociatedContextAMD, (void)) +AGL_API(VOID, BlitContextFramebufferAMD, (HGLRC, GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLint, GLbitfield, GLenum)) + +/* WGL_NV_video_capture */ +AGL_API(BOOL, BindVideoCaptureDeviceNV, (UINT uVideoSlot, HVIDEOINPUTDEVICENV hDevice)) +AGL_API(UINT, EnumerateVideoCaptureDevicesNV, (HDC hDc, HVIDEOINPUTDEVICENV *phDeviceList)) +AGL_API(BOOL, LockVideoCaptureDeviceNV, (HDC hDc, HVIDEOINPUTDEVICENV hDevice)) +AGL_API(BOOL, QueryVideoCaptureDeviceNV, (HDC hDc, HVIDEOINPUTDEVICENV hDevice, int iAttribute, int *piValue)) +AGL_API(BOOL, ReleaseVideoCaptureDeviceNV, (HDC hDc, HVIDEOINPUTDEVICENV hDevice)) + +/* WGL_NV_copy_image */ +AGL_API(BOOL, CopyImageSubDataNV, (HGLRC hSrcRC, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, HGLRC hDstRC, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei width, GLsizei height, GLsizei depth)) diff --git a/common/allegro/include/allegro5/opengl/GLext/wgl_ext_defs.h b/common/allegro/include/allegro5/opengl/GLext/wgl_ext_defs.h new file mode 100644 index 00000000..aed3eac5 --- /dev/null +++ b/common/allegro/include/allegro5/opengl/GLext/wgl_ext_defs.h @@ -0,0 +1,386 @@ +#ifndef WGL_ARB_buffer_region +#define WGL_ARB_buffer_region +#define WGL_FRONT_COLOR_BUFFER_BIT_ARB 0x00000001 +#define WGL_BACK_COLOR_BUFFER_BIT_ARB 0x00000002 +#define WGL_DEPTH_BUFFER_BIT_ARB 0x00000004 +#define WGL_STENCIL_BUFFER_BIT_ARB 0x00000008 +#endif + +#ifndef WGL_ARB_multisample +#define WGL_ARB_multisample +#define WGL_SAMPLE_BUFFERS_ARB 0x2041 +#define WGL_SAMPLES_ARB 0x2042 +#endif + +#ifndef WGL_ARB_pixel_format +#define WGL_ARB_pixel_format +#define WGL_NUMBER_PIXEL_FORMATS_ARB 0x2000 +#define WGL_DRAW_TO_WINDOW_ARB 0x2001 +#define WGL_DRAW_TO_BITMAP_ARB 0x2002 +#define WGL_ACCELERATION_ARB 0x2003 +#define WGL_NEED_PALETTE_ARB 0x2004 +#define WGL_NEED_SYSTEM_PALETTE_ARB 0x2005 +#define WGL_SWAP_LAYER_BUFFERS_ARB 0x2006 +#define WGL_SWAP_METHOD_ARB 0x2007 +#define WGL_NUMBER_OVERLAYS_ARB 0x2008 +#define WGL_NUMBER_UNDERLAYS_ARB 0x2009 +#define WGL_TRANSPARENT_ARB 0x200A +#define WGL_TRANSPARENT_RED_VALUE_ARB 0x2037 +#define WGL_TRANSPARENT_GREEN_VALUE_ARB 0x2038 +#define WGL_TRANSPARENT_BLUE_VALUE_ARB 0x2039 +#define WGL_TRANSPARENT_ALPHA_VALUE_ARB 0x203A +#define WGL_TRANSPARENT_INDEX_VALUE_ARB 0x203B +#define WGL_SHARE_DEPTH_ARB 0x200C +#define WGL_SHARE_STENCIL_ARB 0x200D +#define WGL_SHARE_ACCUM_ARB 0x200E +#define WGL_SUPPORT_GDI_ARB 0x200F +#define WGL_SUPPORT_OPENGL_ARB 0x2010 +#define WGL_DOUBLE_BUFFER_ARB 0x2011 +#define WGL_STEREO_ARB 0x2012 +#define WGL_PIXEL_TYPE_ARB 0x2013 +#define WGL_COLOR_BITS_ARB 0x2014 +#define WGL_RED_BITS_ARB 0x2015 +#define WGL_RED_SHIFT_ARB 0x2016 +#define WGL_GREEN_BITS_ARB 0x2017 +#define WGL_GREEN_SHIFT_ARB 0x2018 +#define WGL_BLUE_BITS_ARB 0x2019 +#define WGL_BLUE_SHIFT_ARB 0x201A +#define WGL_ALPHA_BITS_ARB 0x201B +#define WGL_ALPHA_SHIFT_ARB 0x201C +#define WGL_ACCUM_BITS_ARB 0x201D +#define WGL_ACCUM_RED_BITS_ARB 0x201E +#define WGL_ACCUM_GREEN_BITS_ARB 0x201F +#define WGL_ACCUM_BLUE_BITS_ARB 0x2020 +#define WGL_ACCUM_ALPHA_BITS_ARB 0x2021 +#define WGL_DEPTH_BITS_ARB 0x2022 +#define WGL_STENCIL_BITS_ARB 0x2023 +#define WGL_AUX_BUFFERS_ARB 0x2024 +#define WGL_NO_ACCELERATION_ARB 0x2025 +#define WGL_GENERIC_ACCELERATION_ARB 0x2026 +#define WGL_FULL_ACCELERATION_ARB 0x2027 +#define WGL_SWAP_EXCHANGE_ARB 0x2028 +#define WGL_SWAP_COPY_ARB 0x2029 +#define WGL_SWAP_UNDEFINED_ARB 0x202A +#define WGL_TYPE_RGBA_ARB 0x202B +#define WGL_TYPE_COLORINDEX_ARB 0x202C +#endif + +#ifndef WGL_ARB_make_current_read +#define WGL_ARB_make_current_read +#define ERROR_INVALID_PIXEL_TYPE_ARB 0x2043 +#define ERROR_INCOMPATIBLE_DEVICE_CONTEXTS_ARB 0x2054 +#endif + +#ifndef WGL_ARB_pbuffer +#define WGL_ARB_pbuffer +DECLARE_HANDLE(HPBUFFERARB); +#define WGL_DRAW_TO_PBUFFER_ARB 0x202D +#define WGL_MAX_PBUFFER_PIXELS_ARB 0x202E +#define WGL_MAX_PBUFFER_WIDTH_ARB 0x202F +#define WGL_MAX_PBUFFER_HEIGHT_ARB 0x2030 +#define WGL_PBUFFER_LARGEST_ARB 0x2033 +#define WGL_PBUFFER_WIDTH_ARB 0x2034 +#define WGL_PBUFFER_HEIGHT_ARB 0x2035 +#define WGL_PBUFFER_LOST_ARB 0x2036 +#endif + +#ifndef WGL_ARB_render_texture +#define WGL_ARB_render_texture +#define WGL_BIND_TO_TEXTURE_RGB_ARB 0x2070 +#define WGL_BIND_TO_TEXTURE_RGBA_ARB 0x2071 +#define WGL_TEXTURE_FORMAT_ARB 0x2072 +#define WGL_TEXTURE_TARGET_ARB 0x2073 +#define WGL_MIPMAP_TEXTURE_ARB 0x2074 +#define WGL_TEXTURE_RGB_ARB 0x2075 +#define WGL_TEXTURE_RGBA_ARB 0x2076 +#define WGL_NO_TEXTURE_ARB 0x2077 +#define WGL_TEXTURE_CUBE_MAP_ARB 0x2078 +#define WGL_TEXTURE_1D_ARB 0x2079 +#define WGL_TEXTURE_2D_ARB 0x207A +#define WGL_MIPMAP_LEVEL_ARB 0x207B +#define WGL_CUBE_MAP_FACE_ARB 0x207C +#define WGL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB 0x207D +#define WGL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB 0x207E +#define WGL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB 0x207F +#define WGL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB 0x2080 +#define WGL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB 0x2081 +#define WGL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB 0x2082 +#define WGL_FRONT_LEFT_ARB 0x2083 +#define WGL_FRONT_RIGHT_ARB 0x2084 +#define WGL_BACK_LEFT_ARB 0x2085 +#define WGL_BACK_RIGHT_ARB 0x2086 +#define WGL_AUX0_ARB 0x2087 +#define WGL_AUX1_ARB 0x2088 +#define WGL_AUX2_ARB 0x2089 +#define WGL_AUX3_ARB 0x208A +#define WGL_AUX4_ARB 0x208B +#define WGL_AUX5_ARB 0x208C +#define WGL_AUX6_ARB 0x208D +#define WGL_AUX7_ARB 0x208E +#define WGL_AUX8_ARB 0x208F +#define WGL_AUX9_ARB 0x2090 +#endif + + +#ifndef WGL_ARB_pixel_format_float +#define WGL_ARB_pixel_format_float +#define AWGL_ARB_pixel_format_float +#define WGL_TYPE_RGBA_FLOAT_ARB 0x21A0 +#endif + +#ifndef WGL_ARB_create_context +#define WGL_ARB_create_context +#define WGL_CONTEXT_DEBUG_BIT_ARB 0x0001 +#define WGL_CONTEXT_FORWARD_COMPATIBLE_BIT_ARB 0x0002 +#define WGL_CONTEXT_MAJOR_VERSION_ARB 0x2091 +#define WGL_CONTEXT_MINOR_VERSION_ARB 0x2092 +#define WGL_CONTEXT_LAYER_PLANE_ARB 0x2093 +#define WGL_CONTEXT_FLAGS_ARB 0x2094 +#define ERROR_INVALID_VERSION_ARB 0x2095 +#endif + +#ifndef WGL_ARB_create_context_profile +#define WGL_ARB_create_context_profile +#define WGL_CONTEXT_PROFILE_MASK_ARB 0x9126 +#define WGL_CONTEXT_CORE_PROFILE_BIT_ARB 0x00000001 +#define WGL_CONTEXT_COMPATIBILITY_PROFILE_BIT_ARB 0x00000002 +#define ERROR_INVALID_PROFILE_ARB 0x2096 +#endif + +#ifndef WGL_EXT_make_current_read +#define WGL_EXT_make_current_read +#define ERROR_INVALID_PIXEL_TYPE_EXT 0x2043 +#endif + +#ifndef WGL_EXT_pixel_format +#define WGL_EXT_pixel_format +#define WGL_NUMBER_PIXEL_FORMATS_EXT 0x2000 +#define WGL_DRAW_TO_WINDOW_EXT 0x2001 +#define WGL_DRAW_TO_BITMAP_EXT 0x2002 +#define WGL_ACCELERATION_EXT 0x2003 +#define WGL_NEED_PALETTE_EXT 0x2004 +#define WGL_NEED_SYSTEM_PALETTE_EXT 0x2005 +#define WGL_SWAP_LAYER_BUFFERS_EXT 0x2006 +#define WGL_SWAP_METHOD_EXT 0x2007 +#define WGL_NUMBER_OVERLAYS_EXT 0x2008 +#define WGL_NUMBER_UNDERLAYS_EXT 0x2009 +#define WGL_TRANSPARENT_EXT 0x200A +#define WGL_TRANSPARENT_VALUE_EXT 0x200B +#define WGL_SHARE_DEPTH_EXT 0x200C +#define WGL_SHARE_STENCIL_EXT 0x200D +#define WGL_SHARE_ACCUM_EXT 0x200E +#define WGL_SUPPORT_GDI_EXT 0x200F +#define WGL_SUPPORT_OPENGL_EXT 0x2010 +#define WGL_DOUBLE_BUFFER_EXT 0x2011 +#define WGL_STEREO_EXT 0x2012 +#define WGL_PIXEL_TYPE_EXT 0x2013 +#define WGL_COLOR_BITS_EXT 0x2014 +#define WGL_RED_BITS_EXT 0x2015 +#define WGL_RED_SHIFT_EXT 0x2016 +#define WGL_GREEN_BITS_EXT 0x2017 +#define WGL_GREEN_SHIFT_EXT 0x2018 +#define WGL_BLUE_BITS_EXT 0x2019 +#define WGL_BLUE_SHIFT_EXT 0x201A +#define WGL_ALPHA_BITS_EXT 0x201B +#define WGL_ALPHA_SHIFT_EXT 0x201C +#define WGL_ACCUM_BITS_EXT 0x201D +#define WGL_ACCUM_RED_BITS_EXT 0x201E +#define WGL_ACCUM_GREEN_BITS_EXT 0x201F +#define WGL_ACCUM_BLUE_BITS_EXT 0x2020 +#define WGL_ACCUM_ALPHA_BITS_EXT 0x2021 +#define WGL_DEPTH_BITS_EXT 0x2022 +#define WGL_STENCIL_BITS_EXT 0x2023 +#define WGL_AUX_BUFFERS_EXT 0x2024 +#define WGL_NO_ACCELERATION_EXT 0x2025 +#define WGL_GENERIC_ACCELERATION_EXT 0x2026 +#define WGL_FULL_ACCELERATION_EXT 0x2027 +#define WGL_SWAP_EXCHANGE_EXT 0x2028 +#define WGL_SWAP_COPY_EXT 0x2029 +#define WGL_SWAP_UNDEFINED_EXT 0x202A +#define WGL_TYPE_RGBA_EXT 0x202B +#define WGL_TYPE_COLORINDEX_EXT 0x202C +#endif + +#ifndef WGL_EXT_pbuffer +#define WGL_EXT_pbuffer +DECLARE_HANDLE(HPBUFFEREXT); +#define WGL_DRAW_TO_PBUFFER_EXT 0x202D +#define WGL_MAX_PBUFFER_PIXELS_EXT 0x202E +#define WGL_MAX_PBUFFER_WIDTH_EXT 0x202F +#define WGL_MAX_PBUFFER_HEIGHT_EXT 0x2030 +#define WGL_OPTIMAL_PBUFFER_WIDTH_EXT 0x2031 +#define WGL_OPTIMAL_PBUFFER_HEIGHT_EXT 0x2032 +#define WGL_PBUFFER_LARGEST_EXT 0x2033 +#define WGL_PBUFFER_WIDTH_EXT 0x2034 +#define WGL_PBUFFER_HEIGHT_EXT 0x2035 +#endif + +#ifndef WGL_EXT_depth_float +#define WGL_EXT_depth_float +#define WGL_DEPTH_FLOAT_EXT 0x2040 +#endif + +#ifndef WGL_3DFX_multisample +#define WGL_3DFX_multisample +#define WGL_SAMPLE_BUFFERS_3DFX 0x2060 +#define WGL_SAMPLES_3DFX 0x2061 +#endif + +#ifndef WGL_EXT_multisample +#define WGL_EXT_multisample +#define WGL_SAMPLE_BUFFERS_EXT 0x2041 +#define WGL_SAMPLES_EXT 0x2042 +#endif + +#ifndef WGL_I3D_digital_video_control +#define WGL_I3D_digital_video_control +#define WGL_DIGITAL_VIDEO_CURSOR_ALPHA_FRAMEBUFFER_I3D 0x2050 +#define WGL_DIGITAL_VIDEO_CURSOR_ALPHA_VALUE_I3D 0x2051 +#define WGL_DIGITAL_VIDEO_CURSOR_INCLUDED_I3D 0x2052 +#define WGL_DIGITAL_VIDEO_GAMMA_CORRECTED_I3D 0x2053 +#endif + +#ifndef WGL_I3D_gamma +#define WGL_I3D_gamma +#define WGL_GAMMA_TABLE_SIZE_I3D 0x204E +#define WGL_GAMMA_EXCLUDE_DESKTOP_I3D 0x204F +#endif + +#ifndef WGL_I3D_genlock +#define WGL_I3D_genlock +#define WGL_GENLOCK_SOURCE_MULTIVIEW_I3D 0x2044 +#define WGL_GENLOCK_SOURCE_EXTENAL_SYNC_I3D 0x2045 +#define WGL_GENLOCK_SOURCE_EXTENAL_FIELD_I3D 0x2046 +#define WGL_GENLOCK_SOURCE_EXTENAL_TTL_I3D 0x2047 +#define WGL_GENLOCK_SOURCE_DIGITAL_SYNC_I3D 0x2048 +#define WGL_GENLOCK_SOURCE_DIGITAL_FIELD_I3D 0x2049 +#define WGL_GENLOCK_SOURCE_EDGE_FALLING_I3D 0x204A +#define WGL_GENLOCK_SOURCE_EDGE_RISING_I3D 0x204B +#define WGL_GENLOCK_SOURCE_EDGE_BOTH_I3D 0x204C +#endif + +#ifndef WGL_I3D_image_buffer +#define WGL_I3D_image_buffer +#define WGL_IMAGE_BUFFER_MIN_ACCESS_I3D 0x00000001 +#define WGL_IMAGE_BUFFER_LOCK_I3D 0x00000002 +#endif + +#ifndef WGL_NV_render_depth_texture +#define WGL_NV_render_depth_texture +#define WGL_BIND_TO_TEXTURE_DEPTH_NV 0x20A3 +#define WGL_BIND_TO_TEXTURE_RECTANGLE_DEPTH_NV 0x20A4 +#define WGL_DEPTH_TEXTURE_FORMAT_NV 0x20A5 +#define WGL_TEXTURE_DEPTH_COMPONENT_NV 0x20A6 +#define WGL_DEPTH_COMPONENT_NV 0x20A7 +#endif + +#ifndef WGL_NV_render_texture_rectangle +#define WGL_NV_render_texture_rectangle +#define WGL_BIND_TO_TEXTURE_RECTANGLE_RGB_NV 0x20A0 +#define WGL_BIND_TO_TEXTURE_RECTANGLE_RGBA_NV 0x20A1 +#define WGL_TEXTURE_RECTANGLE_NV 0x20A2 +#endif + +#ifndef WGL_NV_float_buffer +#define WGL_NV_float_buffer +#define WGL_FLOAT_COMPONENTS_NV 0x20B0 +#define WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_R_NV 0x20B1 +#define WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_RG_NV 0x20B2 +#define WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_RGB_NV 0x20B3 +#define WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_RGBA_NV 0x20B4 +#define WGL_TEXTURE_FLOAT_R_NV 0x20B5 +#define WGL_TEXTURE_FLOAT_RG_NV 0x20B6 +#define WGL_TEXTURE_FLOAT_RGB_NV 0x20B7 +#define WGL_TEXTURE_FLOAT_RGBA_NV 0x20B8 +#endif + +#ifndef WGL_3DL_stereo_control +#define WGL_3DL_stereo_control +#define WGL_STEREO_EMITTER_ENABLE_3DL 0x2055 +#define WGL_STEREO_EMITTER_DISABLE_3DL 0x2056 +#define WGL_STEREO_POLARITY_NORMAL_3DL 0x2057 +#define WGL_STEREO_POLARITY_INVERT_3DL 0x2058 +#endif + +#ifndef WGL_EXT_framebuffer_sRGB +#define WGL_EXT_framebuffer_sRGB +#define WGL_FRAMEBUFFER_SRGB_CAPABLE_EXT 0x20A9 +#endif + +#ifndef WGL_EXT_pixel_format_packed_float +#define WGL_EXT_pixel_format_packed_float +#define WGL_TYPE_RGBA_UNSIGNED_FLOAT_EXT 0x20A8 +#endif + +#ifndef WGL_WIN_swap_hint +#define WGL_WIN_swap_hint +#endif + +#ifndef WGL_NV_present_video +#define WGL_NV_present_video +DECLARE_HANDLE(HVIDEOOUTPUTDEVICENV); +#define WGL_NUM_VIDEO_SLOTS_NV 0x20F0 +#endif + +#ifndef WGL_NV_video_out +#define WGL_NV_video_out +DECLARE_HANDLE(HPVIDEODEV); +#define WGL_BIND_TO_VIDEO_RGB_NV 0x20C0 +#define WGL_BIND_TO_VIDEO_RGBA_NV 0x20C1 +#define WGL_BIND_TO_VIDEO_RGB_AND_DEPTH_NV 0x20C2 +#define WGL_VIDEO_OUT_COLOR_NV 0x20C3 +#define WGL_VIDEO_OUT_ALPHA_NV 0x20C4 +#define WGL_VIDEO_OUT_DEPTH_NV 0x20C5 +#define WGL_VIDEO_OUT_COLOR_AND_ALPHA_NV 0x20C6 +#define WGL_VIDEO_OUT_COLOR_AND_DEPTH_NV 0x20C7 +#define WGL_VIDEO_OUT_FRAME 0x20C8 +#define WGL_VIDEO_OUT_FIELD_1 0x20C9 +#define WGL_VIDEO_OUT_FIELD_2 0x20CA +#define WGL_VIDEO_OUT_STACKED_FIELDS_1_2 0x20CB +#define WGL_VIDEO_OUT_STACKED_FIELDS_2_1 0x20CC +#endif + +#ifndef WGL_NV_swap_group +#define WGL_NV_swap_group +#endif + +#ifndef WGL_NV_gpu_affinity +#define WGL_NV_gpu_affinity +DECLARE_HANDLE(HPGPUNV); +DECLARE_HANDLE(HGPUNV); + +typedef struct _GPU_DEVICE { + DWORD cb; + CHAR DeviceName[32]; + CHAR DeviceString[128]; + DWORD Flags; + RECT rcVirtualScreen; +} GPU_DEVICE, *PGPU_DEVICE; +#define WGL_ERROR_INCOMPATIBLE_AFFINITY_MASKS_NV 0x20D0 +#define WGL_ERROR_MISSING_AFFINITY_MASK_NV 0x20D1 +#endif + +#ifndef WGL_AMD_gpu_association +#define WGL_AMD_gpu_association +#define WGL_GPU_VENDOR_AMD 0x1F00 +#define WGL_GPU_RENDERER_STRING_AMD 0x1F01 +#define WGL_GPU_OPENGL_VERSION_STRING_AMD 0x1F02 +#define WGL_GPU_FASTEST_TARGET_GPUS_AMD 0x21A2 +#define WGL_GPU_RAM_AMD 0x21A3 +#define WGL_GPU_CLOCK_AMD 0x21A4 +#define WGL_GPU_NUM_PIPES_AMD 0x21A5 +#define WGL_GPU_NUM_SIMD_AMD 0x21A6 +#define WGL_GPU_NUM_RB_AMD 0x21A7 +#define WGL_GPU_NUM_SPI_AMD 0x21A8 +#endif + +#ifndef WGL_NV_video_capture +#define WGL_NV_video_capture +DECLARE_HANDLE(HVIDEOINPUTDEVICENV); +#define WGL_UNIQUE_ID_NV 0x20CE +#define WGL_NUM_VIDEO_CAPTURE_SLOTS_NV 0x20CF +#endif + +#ifndef WGL_NV_copy_image +#define WGL_NV_copy_image +#endif diff --git a/common/allegro/include/allegro5/opengl/GLext/wgl_ext_list.h b/common/allegro/include/allegro5/opengl/GLext/wgl_ext_list.h new file mode 100644 index 00000000..1fd69621 --- /dev/null +++ b/common/allegro/include/allegro5/opengl/GLext/wgl_ext_list.h @@ -0,0 +1,38 @@ +AGL_EXT(ARB_buffer_region, 0) +AGL_EXT(ARB_multisample, 0) +AGL_EXT(ARB_extensions_string, 0) +AGL_EXT(ARB_pixel_format, 0) +AGL_EXT(ARB_make_current_read, 0) +AGL_EXT(ARB_pbuffer, 0) +AGL_EXT(ARB_render_texture, 0) +AGL_EXT(ARB_pixel_format_float, 0) +AGL_EXT(EXT_display_color_table, 0) +AGL_EXT(EXT_extensions_string, 0) +AGL_EXT(EXT_make_current_read, 0) +AGL_EXT(EXT_pixel_format, 0) +AGL_EXT(EXT_pbuffer, 0) +AGL_EXT(EXT_swap_control, 0) +AGL_EXT(EXT_depth_float, 0) +AGL_EXT(EXT_multisample, 0) +AGL_EXT(OML_sync_control, 0) +AGL_EXT(I3D_digital_video_control, 0) +AGL_EXT(I3D_gamma, 0) +AGL_EXT(I3D_genlock, 0) +AGL_EXT(I3D_image_buffer, 0) +AGL_EXT(I3D_swap_frame_lock, 0) +AGL_EXT(I3D_swap_frame_usage, 0) +AGL_EXT(NV_render_depth_texture, 0) +AGL_EXT(NV_render_texture_rectangle, 0) +AGL_EXT(ATI_pixel_format_float, 0) +AGL_EXT(EXT_framebuffer_sRGB, 0) +AGL_EXT(EXT_pixel_format_packed_float,0) +AGL_EXT(WIN_swap_hint, 0) +AGL_EXT(3DL_stereo_control, 0) +AGL_EXT(NV_swap_group, 0) +AGL_EXT(NV_gpu_affinity, 0) +AGL_EXT(NV_video_out, 0) +AGL_EXT(NV_present_video, 0) +AGL_EXT(ARB_create_context, 0) +AGL_EXT(AMD_gpu_association, 0) +AGL_EXT(NV_copy_image, 0) +AGL_EXT(NV_video_capture, 0) diff --git a/common/allegro/include/allegro5/opengl/gl_ext.h b/common/allegro/include/allegro5/opengl/gl_ext.h new file mode 100644 index 00000000..5c137486 --- /dev/null +++ b/common/allegro/include/allegro5/opengl/gl_ext.h @@ -0,0 +1,145 @@ + +#ifndef __al_included_allegro5_gl_ext_h +#define __al_included_allegro5_gl_ext_h + +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_SRC) + +/* + * MSVC declares the following extensions and MinGW doesn't. In order to + * export the same symbols on both platforms we removed the extensions from + * MSVC. + */ +#ifdef ALLEGRO_MSVC + #undef GL_EXT_vertex_array + #undef GL_EXT_paletted_texture + #undef GL_WIN_swap_hint + #undef GL_WIN_draw_range_elements +#endif + +/* GL extension definitions. */ + +/* For example: + * + * #define GL_BGRA 0x80E1 + * + */ + +#if !defined ALLEGRO_CFG_OPENGLES +#include "allegro5/opengl/GLext/gl_ext_defs.h" +#endif +#if defined ALLEGRO_WINDOWS && !defined ALLEGRO_EXCLUDE_WGL +#include "allegro5/opengl/GLext/wgl_ext_defs.h" +#elif defined ALLEGRO_UNIX && !defined ALLEGRO_EXCLUDE_GLX +#include "allegro5/opengl/GLext/glx_ext_defs.h" +#endif + +/* GL extension types */ + +/* For example: + * + * typedef void (APIENTRY * _ALLEGRO_glBlendEquation_t (GLenum); + * + */ + +#ifndef APIENTRY +#define APIENTRY +#define APIENTRY_defined +#endif + +#define AGL_API(type, name, args) typedef type (APIENTRY * _ALLEGRO_gl##name##_t) args; +# include "allegro5/opengl/GLext/gl_ext_api.h" +#undef AGL_API +#ifdef ALLEGRO_WINDOWS +#define AGL_API(type, name, args) typedef type (APIENTRY * _ALLEGRO_wgl##name##_t) args; +# include "allegro5/opengl/GLext/wgl_ext_api.h" +#undef AGL_API +#elif defined ALLEGRO_UNIX +#define AGL_API(type, name, args) typedef type (APIENTRY * _ALLEGRO_glX##name##_t) args; +# include "allegro5/opengl/GLext/glx_ext_api.h" +#undef AGL_API +#endif + +#ifdef APIENTRY_defined +#undef APIENTRY +#undef APIENTRY_defined +#endif + +/* GL extension declarations */ + +/* For example: + * + * #define glBlendEquation _al_glBlendEquation + * extern _ALLEGRO_glBlendEquation_t _al_glBlendEquation; + * + */ + +#define AGL_API(type, name, args) AL_VAR(_ALLEGRO_gl##name##_t, _al_gl##name); +# include "allegro5/opengl/GLext/gl_ext_alias.h" +# include "allegro5/opengl/GLext/gl_ext_api.h" +#undef AGL_API +#ifdef ALLEGRO_WINDOWS +#define AGL_API(type, name, args) AL_VAR(_ALLEGRO_wgl##name##_t, _al_wgl##name); +# include "allegro5/opengl/GLext/wgl_ext_alias.h" +# include "allegro5/opengl/GLext/wgl_ext_api.h" +#undef AGL_API +#elif defined ALLEGRO_UNIX +#define AGL_API(type, name, args) extern _ALLEGRO_glX##name##_t _al_glX##name; +# include "allegro5/opengl/GLext/glx_ext_alias.h" +# include "allegro5/opengl/GLext/glx_ext_api.h" +#undef AGL_API +#endif + +/* A list of all supported extensions. + * + * For example: + * int ALLEGRO_GL_ARB_imaging; + * + */ + +typedef struct ALLEGRO_OGL_EXT_LIST { +# define AGL_EXT(name, ver) int ALLEGRO_GL_##name; +# include "allegro5/opengl/GLext/gl_ext_list.h" +# undef AGL_EXT + +#ifdef ALLEGRO_UNIX +# define AGL_EXT(name, ver) int ALLEGRO_GLX_##name; +# include "allegro5/opengl/GLext/glx_ext_list.h" +# undef AGL_EXT +#elif defined ALLEGRO_WINDOWS +# define AGL_EXT(name, ver) int ALLEGRO_WGL_##name; +# include "allegro5/opengl/GLext/wgl_ext_list.h" +# undef AGL_EXT + +#endif +} ALLEGRO_OGL_EXT_LIST; + + +/* GL extension Structure. Holds the pointers to all the functions + * of all extensions, for a single context. + * + * Example: + * ALLEGRO_BlendEquation_t BlendEquation; + */ +typedef struct ALLEGRO_OGL_EXT_API { +#define AGL_API(type, name, args) _ALLEGRO_gl##name##_t name; +# include "allegro5/opengl/GLext/gl_ext_api.h" +#undef AGL_API +#ifdef ALLEGRO_WINDOWS +#define AGL_API(type, name, args) _ALLEGRO_wgl##name##_t name; +# include "allegro5/opengl/GLext/wgl_ext_api.h" +#undef AGL_API +#elif defined ALLEGRO_UNIX +#define AGL_API(type, name, args) _ALLEGRO_glX##name##_t name; +# include "allegro5/opengl/GLext/glx_ext_api.h" +#undef AGL_API +#endif +} ALLEGRO_OGL_EXT_API; + +#else + +typedef struct ALLEGRO_OGL_EXT_LIST ALLEGRO_OGL_EXT_LIST; + +#endif + +#endif + diff --git a/common/allegro/include/allegro5/path.h b/common/allegro/include/allegro5/path.h new file mode 100644 index 00000000..0eb78c62 --- /dev/null +++ b/common/allegro/include/allegro5/path.h @@ -0,0 +1,57 @@ +#ifndef __al_included_allegro5_path_h +#define __al_included_allegro5_path_h + +#include "allegro5/base.h" +#include "allegro5/utf8.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +#ifdef ALLEGRO_WINDOWS +# define ALLEGRO_NATIVE_PATH_SEP '\\' +# define ALLEGRO_NATIVE_DRIVE_SEP ':' +#else +# define ALLEGRO_NATIVE_PATH_SEP '/' +# define ALLEGRO_NATIVE_DRIVE_SEP '\0' +#endif + +typedef struct ALLEGRO_PATH ALLEGRO_PATH; + +AL_FUNC(ALLEGRO_PATH*, al_create_path, (const char *str)); +AL_FUNC(ALLEGRO_PATH*, al_create_path_for_directory, (const char *str)); +AL_FUNC(ALLEGRO_PATH*, al_clone_path, (const ALLEGRO_PATH *path)); + +AL_FUNC(int, al_get_path_num_components, (const ALLEGRO_PATH *path)); +AL_FUNC(const char*, al_get_path_component, (const ALLEGRO_PATH *path, int i)); +AL_FUNC(void, al_replace_path_component, (ALLEGRO_PATH *path, int i, const char *s)); +AL_FUNC(void, al_remove_path_component, (ALLEGRO_PATH *path, int i)); +AL_FUNC(void, al_insert_path_component, (ALLEGRO_PATH *path, int i, const char *s)); +AL_FUNC(const char*, al_get_path_tail, (const ALLEGRO_PATH *path)); +AL_FUNC(void, al_drop_path_tail, (ALLEGRO_PATH *path)); +AL_FUNC(void, al_append_path_component, (ALLEGRO_PATH *path, const char *s)); +AL_FUNC(bool, al_join_paths, (ALLEGRO_PATH *path, const ALLEGRO_PATH *tail)); +AL_FUNC(bool, al_rebase_path, (const ALLEGRO_PATH *head, ALLEGRO_PATH *tail)); +AL_FUNC(const char*, al_path_cstr, (const ALLEGRO_PATH *path, char delim)); +AL_FUNC(const ALLEGRO_USTR*, al_path_ustr, (const ALLEGRO_PATH *path, char delim)); +AL_FUNC(void, al_destroy_path, (ALLEGRO_PATH *path)); + +AL_FUNC(void, al_set_path_drive, (ALLEGRO_PATH *path, const char *drive)); +AL_FUNC(const char*, al_get_path_drive, (const ALLEGRO_PATH *path)); + +AL_FUNC(void, al_set_path_filename, (ALLEGRO_PATH *path, const char *filename)); +AL_FUNC(const char*, al_get_path_filename, (const ALLEGRO_PATH *path)); + +AL_FUNC(const char*, al_get_path_extension, (const ALLEGRO_PATH *path)); +AL_FUNC(bool, al_set_path_extension, (ALLEGRO_PATH *path, char const *extension)); +AL_FUNC(const char*, al_get_path_basename, (const ALLEGRO_PATH *path)); + +AL_FUNC(bool, al_make_path_canonical, (ALLEGRO_PATH *path)); + + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/platform/alandroid.h b/common/allegro/include/allegro5/platform/alandroid.h new file mode 100644 index 00000000..261cd7df --- /dev/null +++ b/common/allegro/include/allegro5/platform/alandroid.h @@ -0,0 +1,29 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Android-specific header defines. + * + * See readme.txt for copyright information. + */ + + +#ifndef ALLEGRO_ANDROID + #error bad include +#endif + +#include + +#ifdef __cplusplus +extern "C" int main(int argc, char ** argv); +#else +extern int main(int argc, char ** argv); +#endif + +/* Nothing left */ diff --git a/common/allegro/include/allegro5/platform/alandroidcfg.h b/common/allegro/include/allegro5/platform/alandroidcfg.h new file mode 100644 index 00000000..9399c43e --- /dev/null +++ b/common/allegro/include/allegro5/platform/alandroidcfg.h @@ -0,0 +1,25 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Configuration defines for use on Android platforms. + * + * By Thomas Fjellstrom. + * + * See readme.txt for copyright information. + */ + +/* Describe this platform. */ +#define ALLEGRO_PLATFORM_STR "Android" + +#define ALLEGRO_EXTRA_HEADER "allegro5/platform/alandroid.h" +#define ALLEGRO_INTERNAL_HEADER "allegro5/platform/aintandroid.h" +#define ALLEGRO_INTERNAL_THREAD_HEADER "allegro5/platform/aintuthr.h" + +#define ALLEGRO_EXCLUDE_GLX diff --git a/common/allegro/include/allegro5/platform/albcc32.h b/common/allegro/include/allegro5/platform/albcc32.h new file mode 100644 index 00000000..ca6bbc26 --- /dev/null +++ b/common/allegro/include/allegro5/platform/albcc32.h @@ -0,0 +1,97 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Configuration defines for use with Borland C++Builder. + * + * By Greg Hackmann. + * + * See readme.txt for copyright information. + */ + + +/* +#ifdef ALLEGRO_SRC + #error Currently BCC32 cannot build the library +#endif +*/ + + +#include +#include +#include +#include + + +#pragma warn -8004 /* unused assigned value */ +#pragma warn -8008 /* condition always met */ +#pragma warn -8057 /* unused parameter */ +#pragma warn -8066 /* unreachable code */ + + +/* describe this platform */ +#define ALLEGRO_PLATFORM_STR "BCC32" +#define ALLEGRO_WINDOWS +#define ALLEGRO_I386 +#define ALLEGRO_LITTLE_ENDIAN +#define ALLEGRO_GUESS_INTTYPES_OK + /* TODO: check if BCC has inttypes.h and/or stdint.h */ + +#ifdef ALLEGRO_USE_CONSOLE + #define ALLEGRO_NO_MAGIC_MAIN +#endif + + +/* describe how function prototypes look to BCC32 */ +#if (defined ALLEGRO_STATICLINK) + #define _AL_DLL +#elif (defined ALLEGRO_SRC) + #define _AL_DLL __declspec(dllexport) +#else + #define _AL_DLL __declspec(dllimport) +#endif + +#define AL_VAR(type, name) extern _AL_DLL type name +#define AL_ARRAY(type, name) extern _AL_DLL type name[] +#define AL_FUNC(type, name, args) extern _AL_DLL type name args +#define AL_METHOD(type, name, args) type (*name) args +#define AL_FUNCPTR(type, name, args) extern _AL_DLL type (*name) args + + +#define END_OF_INLINE(name) +//#define AL_INLINE(type, name, args, code) extern __inline type name args code END_OF_INLINE(name) + +#define INLINE __inline + +#undef AL_INLINE +#undef AL_INLINE_STATIC + +#define AL_INLINE(type, name, args, code) extern __inline type __cdecl name args code END_OF_INLINE(name) +#define AL_INLINE_STATIC(type, name, args, code) static __inline type name args code END_OF_INLINE(name) + +#define int64_t signed __int64 +#define uint64_t unsigned __int64 + +#define __func__ "FIXME" + +#define _wfindfirst __wfindfirst +#define _wfindnext __wfindnext + +#define WinMain _main + +/* windows specific defines */ +#ifdef NONAMELESSUNION + #undef NONAMELESSUNION +#endif +/* This fixes 99.999999% of Borland C++Builder's problems with structs. */ + +/* arrange for other headers to be included later on */ +#define ALLEGRO_EXTRA_HEADER "allegro5/platform/alwin.h" +#define ALLEGRO_INTERNAL_HEADER "allegro5/platform/aintwin.h" +#define ALLEGRO_INTERNAL_THREAD_HEADER "allegro5/platform/aintwthr.h" diff --git a/common/allegro/include/allegro5/platform/aliphone.h b/common/allegro/include/allegro5/platform/aliphone.h new file mode 100644 index 00000000..228c07ee --- /dev/null +++ b/common/allegro/include/allegro5/platform/aliphone.h @@ -0,0 +1,11 @@ +#ifndef ALLEGRO_IPHONE + #error bad include +#endif + +#ifndef ALLEGRO_LIB_BUILD +#define ALLEGRO_MAGIC_MAIN +#define main _al_mangled_main +#ifdef __cplusplus + extern "C" int _al_mangled_main(int, char **); +#endif +#endif diff --git a/common/allegro/include/allegro5/platform/aliphonecfg.h b/common/allegro/include/allegro5/platform/aliphonecfg.h new file mode 100644 index 00000000..a4739acc --- /dev/null +++ b/common/allegro/include/allegro5/platform/aliphonecfg.h @@ -0,0 +1,33 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Configuration defines for use on iOS. + * + * See readme.txt for copyright information. + */ + + +#include +#include + +/* Describe this platform. */ +#define ALLEGRO_PLATFORM_STR "IPHONE" + +#define ALLEGRO_EXTRA_HEADER "allegro5/platform/aliphone.h" +#define ALLEGRO_INTERNAL_HEADER "allegro5/platform/aintiphone.h" +#define ALLEGRO_INTERNAL_THREAD_HEADER "allegro5/platform/aintuthr.h" + +#define ALLEGRO_EXCLUDE_GLX + +#ifndef AL_INLINE +#define AL_INLINE(type, name, args, code) \ +static __inline__ type name args; \ +static __inline__ type name args code +#endif diff --git a/common/allegro/include/allegro5/platform/allegro_sdl_config.h b/common/allegro/include/allegro5/platform/allegro_sdl_config.h new file mode 100644 index 00000000..79e98d1b --- /dev/null +++ b/common/allegro/include/allegro5/platform/allegro_sdl_config.h @@ -0,0 +1,8 @@ +#define ALLEGRO_PLATFORM_STR "SDL" + +#define ALLEGRO_INTERNAL_HEADER "allegro5/platform/allegro_internal_sdl.h" +#define ALLEGRO_INTERNAL_THREAD_HEADER "allegro5/platform/allegro_sdl_thread.h" + +// FIXME: remove once we don't use Unix specifics anymore +#include +#include diff --git a/common/allegro/include/allegro5/platform/almngw32.h b/common/allegro/include/allegro5/platform/almngw32.h new file mode 100644 index 00000000..cfda24fd --- /dev/null +++ b/common/allegro/include/allegro5/platform/almngw32.h @@ -0,0 +1,84 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Configuration defines for use with Mingw32. + * + * By Michael Rickmann. + * + * Native build version by Henrik Stokseth. + * + * See readme.txt for copyright information. + */ + + +#include +#include +#include +#include + +#include "allegro5/platform/alplatf.h" + + +/* describe this platform */ +#ifdef ALLEGRO_STATICLINK + #define ALLEGRO_PLATFORM_STR "MinGW32.s" +#else + #define ALLEGRO_PLATFORM_STR "MinGW32" +#endif + +#define ALLEGRO_WINDOWS +#define ALLEGRO_I386 +#define ALLEGRO_LITTLE_ENDIAN + +#ifdef ALLEGRO_USE_CONSOLE + #define ALLEGRO_NO_MAGIC_MAIN +#endif + + +/* describe how function prototypes look to MINGW32 */ +#if (defined ALLEGRO_STATICLINK) || (defined ALLEGRO_SRC) + #define _AL_DLL +#else + #define _AL_DLL __declspec(dllimport) +#endif + +#define AL_VAR(type, name) extern _AL_DLL type name +#define AL_ARRAY(type, name) extern _AL_DLL type name[] +#define AL_FUNC(type, name, args) extern type name args +#define AL_METHOD(type, name, args) type (*name) args +#define AL_FUNCPTR(type, name, args) extern _AL_DLL type (*name) args + + +/* windows specific defines */ + +#if (defined ALLEGRO_SRC) +/* pathches to handle DX7 headers on a win9x system */ + +/* should WINNT be defined on win9x systems? */ +#ifdef WINNT + #undef WINNT +#endif + +/* defined in windef.h */ +#ifndef HMONITOR_DECLARED + #define HMONITOR_DECLARED 1 +#endif + +#endif /* ALLEGRO_SRC */ + +/* another instance of missing constants in the mingw32 headers */ +#ifndef ENUM_CURRENT_SETTINGS + #define ENUM_CURRENT_SETTINGS ((DWORD)-1) +#endif + +/* arrange for other headers to be included later on */ +#define ALLEGRO_EXTRA_HEADER "allegro5/platform/alwin.h" +#define ALLEGRO_INTERNAL_HEADER "allegro5/platform/aintwin.h" +#define ALLEGRO_INTERNAL_THREAD_HEADER "allegro5/platform/aintwthr.h" diff --git a/common/allegro/include/allegro5/platform/almsvc.h b/common/allegro/include/allegro5/platform/almsvc.h new file mode 100644 index 00000000..9a3cdf56 --- /dev/null +++ b/common/allegro/include/allegro5/platform/almsvc.h @@ -0,0 +1,105 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Configuration defines for use with MSVC. + * + * By Shawn Hargreaves. + * + * See readme.txt for copyright information. + */ + + +#include +#include +#include +#include + +#include "allegro5/platform/alplatf.h" + +#pragma warning (disable: 4200 4244 4305 4800) + + +/* describe this platform */ +#ifdef ALLEGRO_STATICLINK + #define ALLEGRO_PLATFORM_STR "MSVC.s" +#else + #define ALLEGRO_PLATFORM_STR "MSVC" +#endif + +#define ALLEGRO_WINDOWS +#define ALLEGRO_I386 +#define ALLEGRO_LITTLE_ENDIAN +#define ALLEGRO_GUESS_INTTYPES_OK + +#ifdef ALLEGRO_USE_CONSOLE + #define ALLEGRO_NO_MAGIC_MAIN +#endif + + +/* describe how function prototypes look to MSVC */ +#ifndef ALLEGRO_STATICLINK + #ifdef ALLEGRO_SRC + #define _AL_DLL __declspec(dllexport) + #else + #define _AL_DLL __declspec(dllimport) + #endif +#else + #define _AL_DLL +#endif + +#define AL_VAR(type, name) extern _AL_DLL type name +#define AL_ARRAY(type, name) extern _AL_DLL type name[] +#define AL_FUNC(type, name, args) _AL_DLL type __cdecl name args +#define AL_METHOD(type, name, args) type (__cdecl *name) args +#define AL_FUNCPTR(type, name, args) extern _AL_DLL type (__cdecl *name) args + +#ifdef AL_INLINE + #define END_OF_INLINE(name) void *_force_instantiate_##name = name; +#else + #define END_OF_INLINE(name) +#endif + +#undef AL_INLINE +#undef AL_INLINE_STATIC + +#define AL_INLINE(type, name, args, code) __inline _AL_DLL type __cdecl name args code END_OF_INLINE(name) +#define AL_INLINE_STATIC(type, name, args, code) __inline type __cdecl name args code END_OF_INLINE(name) + +#define INLINE __inline + +/* VC10 is the first version to define int64_t and uint64_t */ +#if _MSC_VER < 1600 +#define int64_t signed __int64 +#define uint64_t unsigned __int64 +#endif + +/* __func__ is C99 */ +#ifndef __func__ + /* MSVC versions before VC7 don't have __FUNCTION__ */ + #if _MSC_VER < 1300 + #define __func__ "???" + #else + #define __func__ __FUNCTION__ + #endif +#endif + + +/* life would be so easy if compilers would all use the same names! */ +#if (!defined S_IRUSR) + #define S_IRUSR S_IREAD + #define S_IWUSR S_IWRITE + #define S_IXUSR S_IEXEC +#endif + + +/* arrange for other headers to be included later on */ +#define ALLEGRO_EXTRA_HEADER "allegro5/platform/alwin.h" +#define ALLEGRO_INTERNAL_HEADER "allegro5/platform/aintwin.h" +#define ALLEGRO_INTERNAL_THREAD_HEADER "allegro5/platform/aintwthr.h" diff --git a/common/allegro/include/allegro5/platform/alosx.h b/common/allegro/include/allegro5/platform/alosx.h new file mode 100644 index 00000000..d9845b92 --- /dev/null +++ b/common/allegro/include/allegro5/platform/alosx.h @@ -0,0 +1,79 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * MacOS X specific header defines. + * + * By Angelo Mottola. + * + * See readme.txt for copyright information. + */ + + +#ifndef __al_included_allegro5_alosx_h +#define __al_included_allegro5_alosx_h + +#ifndef ALLEGRO_MACOSX + #error bad include +#endif + + + +#include +#include +#include +#include +#include +#include +#if defined __OBJC__ && defined ALLEGRO_SRC + #import + #import + #import + #import + #import + #import + #import + #import + #import + #import + #import + #import + #import +#endif + +ALLEGRO_PATH *_al_osx_get_path(int id); + +#ifndef ALLEGRO_LIB_BUILD + #ifndef ALLEGRO_NO_MAGIC_MAIN + #define ALLEGRO_MAGIC_MAIN + #if __GNUC__ >= 4 + #define main __attribute__ ((visibility("default"),used)) _al_mangled_main + #else + #define main _al_mangled_main + #endif + #ifdef __cplusplus + extern "C" int _al_mangled_main(int, char **); + /* We can't provide a prototype for C without restricting + * users into a single function signature for main(). + */ + #endif + #endif +#endif + +/* Keyboard driver */ +#define KEYBOARD_MACOSX AL_ID('O','S','X','K') + +#endif + +/* Local variables: */ +/* mode: objc */ +/* c-basic-offset: 3 */ +/* indent-tabs-mode: nil */ +/* End: */ +/* vim: set sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/platform/alosxcfg.h b/common/allegro/include/allegro5/platform/alosxcfg.h new file mode 100644 index 00000000..830cf116 --- /dev/null +++ b/common/allegro/include/allegro5/platform/alosxcfg.h @@ -0,0 +1,36 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Configuration defines for use with MacOS X. + * + * By Angelo Mottola. + * + * See readme.txt for copyright information. + */ + + +#ifndef __al_included_allegro5_alosxcfg_h +#define __al_included_allegro5_alosxcfg_h + +/* Include configuration information. */ +#include "allegro5/platform/alplatf.h" + +#define ALLEGRO_INTERNAL_THREAD_HEADER "allegro5/platform/aintuthr.h" + +/* Describe this platform */ +#define ALLEGRO_PLATFORM_STR "MacOS X" + + +/* Arrange for other headers to be included later on */ +#define ALLEGRO_EXTRA_HEADER "allegro5/platform/alosx.h" +#define ALLEGRO_INTERNAL_HEADER "allegro5/platform/aintosx.h" + + +#endif diff --git a/common/allegro/include/allegro5/platform/alplatf.h b/common/allegro/include/allegro5/platform/alplatf.h new file mode 100644 index 00000000..21383380 --- /dev/null +++ b/common/allegro/include/allegro5/platform/alplatf.h @@ -0,0 +1,119 @@ +/* alplatf.h is generated from alplatf.h.cmake */ +/* #undef ALLEGRO_MINGW32 */ +/* #undef ALLEGRO_UNIX */ +#define ALLEGRO_MSVC +/* #undef ALLEGRO_MACOSX */ +/* #undef ALLEGRO_BCC32 */ +/* #undef ALLEGRO_IPHONE */ +/* #undef ALLEGRO_ANDROID */ +/* #undef ALLEGRO_RASPBERRYPI */ +/* #undef ALLEGRO_CFG_NO_FPU */ +/* #undef ALLEGRO_CFG_DLL_TLS */ +/* #undef ALLEGRO_CFG_PTHREADS_TLS */ +#define ALLEGRO_CFG_RELEASE_LOGGING + +#define ALLEGRO_CFG_D3D +/* #undef ALLEGRO_CFG_D3D9EX */ +#define ALLEGRO_CFG_D3DX9 +#define ALLEGRO_CFG_XINPUT +#define ALLEGRO_CFG_OPENGL +/* #undef ALLEGRO_CFG_OPENGLES */ +/* #undef ALLEGRO_CFG_OPENGLES2 */ +/* #undef ALLEGRO_CFG_OPENGLES3 */ +#define ALLEGRO_CFG_OPENGL_PROGRAMMABLE_PIPELINE +#define ALLEGRO_CFG_SHADER_GLSL +#define ALLEGRO_CFG_SHADER_HLSL + +/* #undef ALLEGRO_CFG_ANDROID_LEGACY */ + +/*---------------------------------------------------------------------------*/ + +/* Define to 1 if you have the corresponding header file. */ +/* #undef ALLEGRO_HAVE_DIRENT_H */ +#define ALLEGRO_HAVE_INTTYPES_H +/* #undef ALLEGRO_HAVE_LINUX_AWE_VOICE_H */ +/* #undef ALLEGRO_HAVE_LINUX_INPUT_H */ +/* #undef ALLEGRO_HAVE_LINUX_SOUNDCARD_H */ +/* #undef ALLEGRO_HAVE_MACHINE_SOUNDCARD_H */ +/* #undef ALLEGRO_HAVE_SOUNDCARD_H */ +#define ALLEGRO_HAVE_STDBOOL_H +#define ALLEGRO_HAVE_STDINT_H +/* #undef ALLEGRO_HAVE_SV_PROCFS_H */ +/* #undef ALLEGRO_HAVE_SYS_IO_H */ +/* #undef ALLEGRO_HAVE_SYS_SOUNDCARD_H */ +#define ALLEGRO_HAVE_SYS_STAT_H +/* #undef ALLEGRO_HAVE_SYS_TIME_H */ +#define ALLEGRO_HAVE_TIME_H +/* #undef ALLEGRO_HAVE_SYS_UTSNAME_H */ +#define ALLEGRO_HAVE_SYS_TYPES_H +/* #undef ALLEGRO_HAVE_OSATOMIC_H */ +/* #undef ALLEGRO_HAVE_SYS_INOTIFY_H */ +#define ALLEGRO_HAVE_SAL_H + +/* Define to 1 if the corresponding functions are available. */ +/* #undef ALLEGRO_HAVE_GETEXECNAME */ +/* #undef ALLEGRO_HAVE_MKSTEMP */ +/* #undef ALLEGRO_HAVE_MMAP */ +/* #undef ALLEGRO_HAVE_MPROTECT */ +/* #undef ALLEGRO_HAVE_SCHED_YIELD */ +/* #undef ALLEGRO_HAVE_SYSCONF */ +/* #undef ALLEGRO_HAVE_SYSCTL */ + +/* #undef ALLEGRO_HAVE_FSEEKO */ +/* #undef ALLEGRO_HAVE_FTELLO */ +/* #undef ALLEGRO_HAVE_STRERROR_R */ +#define ALLEGRO_HAVE_STRERROR_S +#define ALLEGRO_HAVE_VA_COPY +#define ALLEGRO_HAVE_FTELLI64 +#define ALLEGRO_HAVE_FSEEKI64 + +/* Define to 1 if procfs reveals argc and argv */ +/* #undef ALLEGRO_HAVE_PROCFS_ARGCV */ + +/*---------------------------------------------------------------------------*/ + +/* Define if target machine is little endian. */ +#define ALLEGRO_LITTLE_ENDIAN + +/* Define if target machine is big endian. */ +/* #undef ALLEGRO_BIG_ENDIAN */ + +/* Define if target platform is Darwin. */ +/* #undef ALLEGRO_DARWIN */ + +/*---------------------------------------------------------------------------*/ + +/* Define if you need support for X-Windows. */ +/* #undef ALLEGRO_WITH_XWINDOWS */ + +/* Define if XCursor ARGB extension is available. */ +/* #undef ALLEGRO_XWINDOWS_WITH_XCURSOR */ + +/* Define if XF86VidMode extension is supported. */ +/* #undef ALLEGRO_XWINDOWS_WITH_XF86VIDMODE */ + +/* Define if Xinerama extension is supported. */ +/* #undef ALLEGRO_XWINDOWS_WITH_XINERAMA */ + +/* Define if XRandR extension is supported. */ +/* #undef ALLEGRO_XWINDOWS_WITH_XRANDR */ + +/* Define if XIM extension is supported. */ +/* #undef ALLEGRO_XWINDOWS_WITH_XIM */ + +/* Define if XInput 2.2 X11 extension is supported. */ +/* #undef ALLEGRO_XWINDOWS_WITH_XINPUT2 */ + +/* Define if Xpm is found. Useful on Ubuntu Unity to set icon. */ +/* #undef ALLEGRO_XWINDOWS_WITH_XPM */ + +/*---------------------------------------------------------------------------*/ + +/* Define if target platform is linux. */ +/* #undef ALLEGRO_LINUX */ + +/* Define if we are building with SDL backend. */ +/* #undef ALLEGRO_SDL */ + +/*---------------------------------------------------------------------------*/ +/* vi: set ft=c ts=3 sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/platform/alraspberrypi.h b/common/allegro/include/allegro5/platform/alraspberrypi.h new file mode 100644 index 00000000..629a02ff --- /dev/null +++ b/common/allegro/include/allegro5/platform/alraspberrypi.h @@ -0,0 +1,25 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Raspberry Pi-specific header defines. + * + * See readme.txt for copyright information. + */ + + +#ifndef ALLEGRO_RASPBERRYPI + #error bad include +#endif + +#ifdef ALLEGRO_LIB_BUILD +#include "allegro5/platform/aintuthr.h" +#endif + +/* Nothing left */ diff --git a/common/allegro/include/allegro5/platform/alraspberrypicfg.h b/common/allegro/include/allegro5/platform/alraspberrypicfg.h new file mode 100644 index 00000000..17941ca7 --- /dev/null +++ b/common/allegro/include/allegro5/platform/alraspberrypicfg.h @@ -0,0 +1,29 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Configuration defines for use on Raspberry Pi platforms. + * + * By Trent Gamblin. + * + * See readme.txt for copyright information. + */ + +#include +#include +#include + +/* Describe this platform. */ +#define ALLEGRO_PLATFORM_STR "RaspberryPi" + +#define ALLEGRO_EXTRA_HEADER "allegro5/platform/alraspberrypi.h" +#define ALLEGRO_INTERNAL_HEADER "allegro5/platform/aintraspberrypi.h" +#define ALLEGRO_INTERNAL_THREAD_HEADER "allegro5/platform/aintuthr.h" + +#define ALLEGRO_EXCLUDE_GLX diff --git a/common/allegro/include/allegro5/platform/alucfg.h b/common/allegro/include/allegro5/platform/alucfg.h new file mode 100644 index 00000000..b9947c88 --- /dev/null +++ b/common/allegro/include/allegro5/platform/alucfg.h @@ -0,0 +1,40 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Configuration defines for use on Unix platforms. + * + * By Michael Bukin. + * + * See readme.txt for copyright information. + */ + + +#include +#include + +/* Describe this platform. */ +#define ALLEGRO_PLATFORM_STR "Unix" + +#define ALLEGRO_EXTRA_HEADER "allegro5/platform/alunix.h" + +#ifdef _this_is_a_hack_to_fool_scons +#include "alunix.h" +#endif + +#define ALLEGRO_INTERNAL_HEADER "allegro5/platform/aintunix.h" +#define ALLEGRO_INTERNAL_THREAD_HEADER "allegro5/platform/aintuthr.h" + +/* Include configuration information. */ +#include "allegro5/platform/alplatf.h" + +/* Enable OpenGL if GLX is available. */ +#ifdef ALLEGRO_GLX +#define ALLEGRO_CFG_OPENGL +#endif diff --git a/common/allegro/include/allegro5/platform/alunix.h b/common/allegro/include/allegro5/platform/alunix.h new file mode 100644 index 00000000..ae1b858a --- /dev/null +++ b/common/allegro/include/allegro5/platform/alunix.h @@ -0,0 +1,23 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Unix-specific header defines. + * + * See readme.txt for copyright information. + */ + + +#ifndef ALLEGRO_UNIX + #error bad include +#endif + + +/* Nothing left */ + diff --git a/common/allegro/include/allegro5/platform/alwatcom.h b/common/allegro/include/allegro5/platform/alwatcom.h new file mode 100644 index 00000000..f2d07714 --- /dev/null +++ b/common/allegro/include/allegro5/platform/alwatcom.h @@ -0,0 +1,181 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Configuration defines for use with Watcom. + * + * By Shawn Hargreaves. + * + * See readme.txt for copyright information. + */ + + +#ifndef __SW_3S + #error Allegro only supports stack based calling convention +#endif + +#ifndef __SW_S + #error Stack overflow checking must be disabled +#endif + +#include +#include +#include +#include +#include +#include + + +#pragma disable_message (120 201 202) + + +/* these are available in OpenWatcom 1.3 (12.3) */ +#if __WATCOMC__ >= 1230 + #define ALLEGRO_HAVE_INTTYPES_H 1 + #define ALLEGRO_HAVE_STDINT_H 1 +#else + #define ALLEGRO_GUESS_INTTYPES_OK +#endif + + +/* describe this platform */ +#define ALLEGRO_PLATFORM_STR "Watcom" +#define ALLEGRO_DOS +#define ALLEGRO_I386 +#define ALLEGRO_LITTLE_ENDIAN + +#ifdef ALLEGRO_GUESS_INTTYPES_OK + #define int64_t signed long long + #define uint64_t unsigned long long +#endif + + +/* emulate some important djgpp routines */ +#define inportb(port) inp(port) +#define inportw(port) inpw(port) +#define outportb(port, val) outp(port, val) +#define outportw(port, val) outpw(port, val) + +#define ffblk find_t +#define ff_name name +#define ff_attrib attrib +#define ff_fsize size +#define ff_ftime wr_time +#define ff_fdate wr_date + +#define findfirst(name, dta, attrib) _dos_findfirst(name, attrib, dta) +#define findnext(dta) _dos_findnext(dta) + +#define random() rand() +#define srandom(n) srand(n) + +#define _dos_ds _default_ds() + +#define dosmemget(offset, length, buffer) memcpy(buffer, (void *)(offset), length) +#define dosmemput(buffer, length, offset) memcpy((void *)(offset), buffer, length) + +#define __djgpp_nearptr_enable() 1 +#define __djgpp_nearptr_disable() + +#define __djgpp_base_address 0 +#define __djgpp_conventional_base 0 + +#define _crt0_startup_flags 1 +#define _CRT0_FLAG_NEARPTR 1 + + +#ifdef __cplusplus +extern "C" { +#endif + +typedef union __dpmi_regs +{ + struct { + unsigned long edi, esi, ebp, res, ebx, edx, ecx, eax; + } d; + struct { + unsigned short di, di_hi, si, si_hi, bp, bp_hi, res, res_hi; + unsigned short bx, bx_hi, dx, dx_hi, cx, cx_hi, ax, ax_hi; + unsigned short flags, es, ds, fs, gs, ip, cs, sp, ss; + } x; + struct { + unsigned char edi[4], esi[4], ebp[4], res[4]; + unsigned char bl, bh, ebx_b2, ebx_b3, dl, dh, edx_b2, edx_b3; + unsigned char cl, ch, ecx_b2, ecx_b3, al, ah, eax_b2, eax_b3; + } h; +} __dpmi_regs; + + +typedef struct __dpmi_meminfo +{ + unsigned long handle; + unsigned long size; + unsigned long address; +} __dpmi_meminfo; + + +typedef struct __dpmi_free_mem_info +{ + unsigned long largest_available_free_block_in_bytes; + unsigned long maximum_unlocked_page_allocation_in_pages; + unsigned long maximum_locked_page_allocation_in_pages; + unsigned long linear_address_space_size_in_pages; + unsigned long total_number_of_unlocked_pages; + unsigned long total_number_of_free_pages; + unsigned long total_number_of_physical_pages; + unsigned long free_linear_address_space_in_pages; + unsigned long size_of_paging_file_partition_in_pages; + unsigned long reserved[3]; +} __dpmi_free_mem_info; + + +extern unsigned long __tb; + + +int __dpmi_int(int vector, __dpmi_regs *regs); +int __dpmi_allocate_dos_memory(int paragraphs, int *ret); +int __dpmi_free_dos_memory(int selector); +int __dpmi_physical_address_mapping(__dpmi_meminfo *info); +int __dpmi_free_physical_address_mapping(__dpmi_meminfo *info); +int __dpmi_lock_linear_region(__dpmi_meminfo *info); +int __dpmi_unlock_linear_region(__dpmi_meminfo *info); +int __dpmi_allocate_ldt_descriptors(int count); +int __dpmi_free_ldt_descriptor(int descriptor); +int __dpmi_get_segment_base_address(int selector, unsigned long *addr); +int __dpmi_set_segment_base_address(int selector, unsigned long address); +int __dpmi_set_segment_limit(int selector, unsigned long limit); +int __dpmi_get_free_memory_information(__dpmi_free_mem_info *info); +int __dpmi_simulate_real_mode_interrupt(int vector, __dpmi_regs *regs); +int __dpmi_simulate_real_mode_procedure_retf(__dpmi_regs *regs); +int _go32_dpmi_lock_data(void *lockaddr, unsigned long locksize); +int _go32_dpmi_lock_code(void *lockaddr, unsigned long locksize); + +long _allocate_real_mode_callback(void (*handler)(__dpmi_regs *r), __dpmi_regs *regs); + + +/* memory locking macros */ +void _unlock_dpmi_data(void *addr, int size); + +#ifdef __cplusplus +} +#endif + + +#define END_OF_FUNCTION(x) void x##_end(void) { } +#define END_OF_STATIC_FUNCTION(x) static void x##_end(void) { } +#define LOCK_DATA(d, s) _go32_dpmi_lock_data(d, s) +#define LOCK_CODE(c, s) _go32_dpmi_lock_code(c, s) +#define UNLOCK_DATA(d,s) _unlock_dpmi_data(d, s) +#define LOCK_VARIABLE(x) LOCK_DATA((void *)&x, sizeof(x)) +#define LOCK_FUNCTION(x) LOCK_CODE((void *)FP_OFF(x), (long)FP_OFF(x##_end) - (long)FP_OFF(x)) + + +/* arrange for other headers to be included later on */ +#define ALLEGRO_EXTRA_HEADER "allegro5/platform/aldos.h" +#define ALLEGRO_INTERNAL_HEADER "allegro5/platform/aintdos.h" diff --git a/common/allegro/include/allegro5/platform/alwin.h b/common/allegro/include/allegro5/platform/alwin.h new file mode 100644 index 00000000..eab4b10f --- /dev/null +++ b/common/allegro/include/allegro5/platform/alwin.h @@ -0,0 +1,148 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Windows-specific header defines. + * + * By Shawn Hargreaves. + * + * See readme.txt for copyright information. + */ + + +#ifndef ALLEGRO_WINDOWS + #error bad include +#endif + +/*******************************************/ +/********** magic main emulation ***********/ +/*******************************************/ +#ifdef __cplusplus +extern "C" { +#endif + +AL_FUNC(int, _WinMain, (void *_main, void *hInst, void *hPrev, char *Cmd, int nShow)); + +#ifdef __cplusplus +} +#endif + + +/* The following is due to torhu from A.cc (see + * http://www.allegro.cc/forums/thread/596872/756993#target) + */ +#ifndef ALLEGRO_NO_MAGIC_MAIN + #if defined _MSC_VER && !defined ALLEGRO_LIB_BUILD + #pragma comment(linker,"/ENTRY:mainCRTStartup") + #endif +#endif + + +/*******************************************/ +/************ joystick drivers *************/ +/*******************************************/ +#define AL_JOY_TYPE_DIRECTX AL_ID('D','X',' ',' ') + +#ifdef __cplusplus +extern "C" { +#endif + +AL_VAR(struct ALLEGRO_JOYSTICK_DRIVER, _al_joydrv_directx); + +#ifdef __cplusplus +} +#endif + +#define _AL_JOYSTICK_DRIVER_DIRECTX \ + { AL_JOY_TYPE_DIRECTX, &_al_joydrv_directx, true }, + +#define AL_JOY_TYPE_XINPUT AL_ID('X','I',' ',' ') + +#ifdef __cplusplus +extern "C" { +#endif + +AL_VAR(struct ALLEGRO_JOYSTICK_DRIVER, _al_joydrv_xinput); + +#ifdef __cplusplus +} +#endif + +#define _AL_JOYSTICK_DRIVER_XINPUT \ + { AL_JOY_TYPE_XINPUT, &_al_joydrv_xinput, true }, + +#define AL_JOY_TYPE_WINDOWS_ALL AL_ID('X','D',' ',' ') + +#ifdef __cplusplus +extern "C" { +#endif + +AL_VAR(struct ALLEGRO_JOYSTICK_DRIVER, _al_joydrv_windows_all); + +#ifdef __cplusplus +} +#endif + +#define _AL_JOYSTICK_DRIVER_WINDOWS_ALL \ + { AL_JOY_TYPE_WINDOWS_ALL, &_al_joydrv_windows_all, true }, + + + +/*******************************************/ +/************ haptic drivers *************/ +/*******************************************/ + +#define AL_HAPTIC_TYPE_DIRECTX AL_ID('D','X','F','F') + +#ifdef __cplusplus +extern "C" { +#endif + +AL_VAR(struct ALLEGRO_HAPTIC_DRIVER, _al_hapdrv_directx); + +#ifdef __cplusplus +} +#endif + +#define _AL_HAPTIC_DRIVER_DIRECTX \ + { AL_HAPTIC_TYPE_DIRECTX, &_al_hapdrv_directx, true }, + + +#define AL_HAPTIC_TYPE_XINPUT AL_ID('X','I','F','F') + +#ifdef __cplusplus +extern "C" { +#endif + +AL_VAR(struct ALLEGRO_HAPTIC_DRIVER, _al_hapdrv_xinput); + +#ifdef __cplusplus +} +#endif + +#define _AL_HAPTIC_DRIVER_XINPUT \ + { AL_HAPTIC_TYPE_XINPUT, &_al_hapdrv_xinput, true }, + + +#define AL_HAPTIC_TYPE_WINDOWS_ALL AL_ID('X','D','F','F') + +#ifdef __cplusplus +extern "C" { +#endif + +AL_VAR(struct ALLEGRO_HAPTIC_DRIVER, _al_hapdrv_windows_all); + +#ifdef __cplusplus +} +#endif + +#define _AL_HAPTIC_DRIVER_WINDOWS_ALL \ + { AL_HAPTIC_TYPE_WINDOWS_ALL, &_al_hapdrv_windows_all, true }, + + diff --git a/common/allegro/include/allegro5/platform/astdbool.h b/common/allegro/include/allegro5/platform/astdbool.h new file mode 100644 index 00000000..591f4769 --- /dev/null +++ b/common/allegro/include/allegro5/platform/astdbool.h @@ -0,0 +1,35 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * A header file to get C99's stdbool.h. + * + * By Peter Wang. + * + * See readme.txt for copyright information. + */ + +#ifndef __al_included_allegro5_astdbool_h +#define __al_included_allegro5_astdbool_h + +#ifndef __cplusplus +# ifdef ALLEGRO_HAVE_STDBOOL_H +# include +# else +# ifndef ALLEGRO_HAVE__BOOL + typedef unsigned char _Bool; +# endif +# define bool _Bool +# define false 0 +# define true 1 +# define __bool_true_false_are_defined 1 +# endif +#endif + +#endif diff --git a/common/allegro/include/allegro5/platform/astdint.h b/common/allegro/include/allegro5/platform/astdint.h new file mode 100644 index 00000000..6db81de3 --- /dev/null +++ b/common/allegro/include/allegro5/platform/astdint.h @@ -0,0 +1,75 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * A header file to get definitions of uint*_t and int*_t. + * + * By Peter Wang. + * + * See readme.txt for copyright information. + */ + +#ifndef __al_included_allegro5_astdint_h +#define __al_included_allegro5_astdint_h + +/* Please only include this file from include/allegro5/internal/alconfig.h + * and don't add more than inttypes.h/stdint.h emulation here. Thanks. + */ + + + +#if defined ALLEGRO_HAVE_INTTYPES_H + #include +#elif defined ALLEGRO_HAVE_STDINT_H + #include +#elif defined ALLEGRO_I386 && defined ALLEGRO_LITTLE_ENDIAN + #ifndef ALLEGRO_GUESS_INTTYPES_OK + #warning Guessing the definitions of fixed-width integer types. + #endif + #define int8_t signed char + #define uint8_t unsigned char + #define int16_t signed short + #define uint16_t unsigned short + #define int32_t signed int + #define uint32_t unsigned int + + #ifdef ALLEGRO_WINDOWS + + #ifndef _INTPTR_T_DEFINED + #ifdef _WIN64 + #define intptr_t __int64 + #else + #define intptr_t int + #endif + #define _INTPTR_T_DEFINED + #endif + + #ifndef _UINTPTR_T_DEFINED + #ifdef _WIN64 + #define uintptr_t unsigned __int64 + #else + #define uintptr_t unsigned int + #endif + #define _UINTPTR_T_DEFINED + #endif + + #else + + #define intptr_t int32_t + #define uintptr_t uint32_t + + #endif + +#else + #error I dunno how to get the definitions of fixed-width integer types on your platform. Please report this to your friendly Allegro developer. +#endif + + + +#endif diff --git a/common/allegro/include/allegro5/render_state.h b/common/allegro/include/allegro5/render_state.h new file mode 100644 index 00000000..99c07648 --- /dev/null +++ b/common/allegro/include/allegro5/render_state.h @@ -0,0 +1,55 @@ +#ifndef __al_included_allegro5_render_state_h +#define __al_included_allegro5_render_state_h + +#include "allegro5/base.h" + +#ifdef __cplusplus + extern "C" { +#endif + +/* Enum: ALLEGRO_RENDER_STATE + */ +typedef enum ALLEGRO_RENDER_STATE { + /* ALLEGRO_ALPHA_TEST was the name of a rare bitmap flag only used on the + * Wiz port. Reuse the name but retain the same value. + */ + ALLEGRO_ALPHA_TEST = 0x0010, + ALLEGRO_WRITE_MASK, + ALLEGRO_DEPTH_TEST, + ALLEGRO_DEPTH_FUNCTION, + ALLEGRO_ALPHA_FUNCTION, + ALLEGRO_ALPHA_TEST_VALUE +} ALLEGRO_RENDER_STATE; + +/* Enum: ALLEGRO_RENDER_FUNCTION + */ +typedef enum ALLEGRO_RENDER_FUNCTION { + ALLEGRO_RENDER_NEVER, + ALLEGRO_RENDER_ALWAYS, + ALLEGRO_RENDER_LESS, + ALLEGRO_RENDER_EQUAL, + ALLEGRO_RENDER_LESS_EQUAL, + ALLEGRO_RENDER_GREATER, + ALLEGRO_RENDER_NOT_EQUAL, + ALLEGRO_RENDER_GREATER_EQUAL +} ALLEGRO_RENDER_FUNCTION; + +/* Enum: ALLEGRO_WRITE_MASK_FLAGS + */ +typedef enum ALLEGRO_WRITE_MASK_FLAGS { + ALLEGRO_MASK_RED = 1 << 0, + ALLEGRO_MASK_GREEN = 1 << 1, + ALLEGRO_MASK_BLUE = 1 << 2, + ALLEGRO_MASK_ALPHA = 1 << 3, + ALLEGRO_MASK_DEPTH = 1 << 4, + ALLEGRO_MASK_RGB = (ALLEGRO_MASK_RED | ALLEGRO_MASK_GREEN | ALLEGRO_MASK_BLUE), + ALLEGRO_MASK_RGBA = (ALLEGRO_MASK_RGB | ALLEGRO_MASK_ALPHA) +} ALLEGRO_WRITE_MASK_FLAGS; + +AL_FUNC(void, al_set_render_state, (ALLEGRO_RENDER_STATE state, int value)); + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/shader.h b/common/allegro/include/allegro5/shader.h new file mode 100644 index 00000000..97183be6 --- /dev/null +++ b/common/allegro/include/allegro5/shader.h @@ -0,0 +1,78 @@ +#ifndef __al_included_allegro5_shader_h +#define __al_included_allegro5_shader_h + +#include "allegro5/base.h" +#include "allegro5/transformations.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +/* Type: ALLEGRO_SHADER + */ +typedef struct ALLEGRO_SHADER ALLEGRO_SHADER; + +enum ALLEGRO_SHADER_TYPE { + ALLEGRO_VERTEX_SHADER = 1, + ALLEGRO_PIXEL_SHADER = 2 +}; + +/* Enum: ALLEGRO_SHADER_TYPE + */ +typedef enum ALLEGRO_SHADER_TYPE ALLEGRO_SHADER_TYPE; + +enum ALLEGRO_SHADER_PLATFORM { + ALLEGRO_SHADER_AUTO = 0, + ALLEGRO_SHADER_GLSL = 1, + ALLEGRO_SHADER_HLSL = 2 +}; + +/* Enum: ALLEGRO_SHADER_PLATFORM + */ +typedef enum ALLEGRO_SHADER_PLATFORM ALLEGRO_SHADER_PLATFORM; + +/* Shader variable names */ +#define ALLEGRO_SHADER_VAR_COLOR "al_color" +#define ALLEGRO_SHADER_VAR_POS "al_pos" +#define ALLEGRO_SHADER_VAR_PROJVIEW_MATRIX "al_projview_matrix" +#define ALLEGRO_SHADER_VAR_TEX "al_tex" +#define ALLEGRO_SHADER_VAR_TEXCOORD "al_texcoord" +#define ALLEGRO_SHADER_VAR_TEX_MATRIX "al_tex_matrix" +#define ALLEGRO_SHADER_VAR_USER_ATTR "al_user_attr_" +#define ALLEGRO_SHADER_VAR_USE_TEX "al_use_tex" +#define ALLEGRO_SHADER_VAR_USE_TEX_MATRIX "al_use_tex_matrix" + +AL_FUNC(ALLEGRO_SHADER *, al_create_shader, (ALLEGRO_SHADER_PLATFORM platform)); +AL_FUNC(bool, al_attach_shader_source, (ALLEGRO_SHADER *shader, + ALLEGRO_SHADER_TYPE type, const char *source)); +AL_FUNC(bool, al_attach_shader_source_file, (ALLEGRO_SHADER *shader, + ALLEGRO_SHADER_TYPE type, const char *filename)); +AL_FUNC(bool, al_build_shader, (ALLEGRO_SHADER *shader)); +AL_FUNC(const char *, al_get_shader_log, (ALLEGRO_SHADER *shader)); +AL_FUNC(ALLEGRO_SHADER_PLATFORM, al_get_shader_platform, (ALLEGRO_SHADER *shader)); +AL_FUNC(bool, al_use_shader, (ALLEGRO_SHADER *shader)); +AL_FUNC(void, al_destroy_shader, (ALLEGRO_SHADER *shader)); + +AL_FUNC(bool, al_set_shader_sampler, (const char *name, ALLEGRO_BITMAP *bitmap, + int unit)); +AL_FUNC(bool, al_set_shader_matrix, (const char *name, + const ALLEGRO_TRANSFORM *matrix)); +AL_FUNC(bool, al_set_shader_int, (const char *name, int i)); +AL_FUNC(bool, al_set_shader_float, (const char *name, float f)); +AL_FUNC(bool, al_set_shader_int_vector, (const char *name, int num_components, + const int *i, int num_elems)); +AL_FUNC(bool, al_set_shader_float_vector, (const char *name, int num_components, + const float *f, int num_elems)); +AL_FUNC(bool, al_set_shader_bool, (const char *name, bool b)); + +AL_FUNC(char const *, al_get_default_shader_source, (ALLEGRO_SHADER_PLATFORM platform, + ALLEGRO_SHADER_TYPE type)); + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/system.h b/common/allegro/include/allegro5/system.h new file mode 100644 index 00000000..da525ca9 --- /dev/null +++ b/common/allegro/include/allegro5/system.h @@ -0,0 +1,50 @@ +#ifndef __al_included_allegro5_system_h +#define __al_included_allegro5_system_h + +#include "allegro5/config.h" +#include "allegro5/path.h" + +#ifdef __cplusplus + extern "C" { +#endif + +typedef struct ALLEGRO_SYSTEM ALLEGRO_SYSTEM; + +/* Function: al_init + */ +#define al_init() (al_install_system(ALLEGRO_VERSION_INT, atexit)) + +AL_FUNC(bool, al_install_system, (int version, int (*atexit_ptr)(void (*)(void)))); +AL_FUNC(void, al_uninstall_system, (void)); +AL_FUNC(bool, al_is_system_installed, (void)); +AL_FUNC(ALLEGRO_SYSTEM *, al_get_system_driver, (void)); +AL_FUNC(ALLEGRO_CONFIG *, al_get_system_config, (void)); + +enum { + ALLEGRO_RESOURCES_PATH = 0, + ALLEGRO_TEMP_PATH, + ALLEGRO_USER_DATA_PATH, + ALLEGRO_USER_HOME_PATH, + ALLEGRO_USER_SETTINGS_PATH, + ALLEGRO_USER_DOCUMENTS_PATH, + ALLEGRO_EXENAME_PATH, + ALLEGRO_LAST_PATH /* must be last */ +}; + +AL_FUNC(ALLEGRO_PATH *, al_get_standard_path, (int id)); +AL_FUNC(void, al_set_exe_name, (char const *path)); + +AL_FUNC(void, al_set_org_name, (const char *org_name)); +AL_FUNC(void, al_set_app_name, (const char *app_name)); +AL_FUNC(const char *, al_get_org_name, (void)); +AL_FUNC(const char *, al_get_app_name, (void)); + +AL_FUNC(bool, al_inhibit_screensaver, (bool inhibit)); + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/threads.h b/common/allegro/include/allegro5/threads.h new file mode 100644 index 00000000..c0d127fa --- /dev/null +++ b/common/allegro/include/allegro5/threads.h @@ -0,0 +1,67 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Thread routines. + * + * See readme.txt for copyright information. + */ + +#ifndef __al_included_allegro5_threads_h +#define __al_included_allegro5_threads_h + +#include "allegro5/altime.h" + +#ifdef __cplusplus + extern "C" { +#endif + +/* Type: ALLEGRO_THREAD + */ +typedef struct ALLEGRO_THREAD ALLEGRO_THREAD; + +/* Type: ALLEGRO_MUTEX + */ +typedef struct ALLEGRO_MUTEX ALLEGRO_MUTEX; + +/* Type: ALLEGRO_COND + */ +typedef struct ALLEGRO_COND ALLEGRO_COND; + + +AL_FUNC(ALLEGRO_THREAD *, al_create_thread, + (void *(*proc)(ALLEGRO_THREAD *thread, void *arg), void *arg)); +AL_FUNC(void, al_start_thread, (ALLEGRO_THREAD *outer)); +AL_FUNC(void, al_join_thread, (ALLEGRO_THREAD *outer, void **ret_value)); +AL_FUNC(void, al_set_thread_should_stop, (ALLEGRO_THREAD *outer)); +AL_FUNC(bool, al_get_thread_should_stop, (ALLEGRO_THREAD *outer)); +AL_FUNC(void, al_destroy_thread, (ALLEGRO_THREAD *thread)); +AL_FUNC(void, al_run_detached_thread, (void *(*proc)(void *arg), void *arg)); + +AL_FUNC(ALLEGRO_MUTEX *, al_create_mutex, (void)); +AL_FUNC(ALLEGRO_MUTEX *, al_create_mutex_recursive, (void)); +AL_FUNC(void, al_lock_mutex, (ALLEGRO_MUTEX *mutex)); +AL_FUNC(void, al_unlock_mutex, (ALLEGRO_MUTEX *mutex)); +AL_FUNC(void, al_destroy_mutex, (ALLEGRO_MUTEX *mutex)); + +AL_FUNC(ALLEGRO_COND *, al_create_cond, (void)); +AL_FUNC(void, al_destroy_cond, (ALLEGRO_COND *cond)); +AL_FUNC(void, al_wait_cond, (ALLEGRO_COND *cond, ALLEGRO_MUTEX *mutex)); +AL_FUNC(int, al_wait_cond_until, (ALLEGRO_COND *cond, ALLEGRO_MUTEX *mutex, + const ALLEGRO_TIMEOUT *timeout)); +AL_FUNC(void, al_broadcast_cond, (ALLEGRO_COND *cond)); +AL_FUNC(void, al_signal_cond, (ALLEGRO_COND *cond)); + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set sts=3 sw=3 et: */ diff --git a/common/allegro/include/allegro5/timer.h b/common/allegro/include/allegro5/timer.h new file mode 100644 index 00000000..1d6bffdd --- /dev/null +++ b/common/allegro/include/allegro5/timer.h @@ -0,0 +1,67 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Timer routines. + * + * See readme.txt for copyright information. + */ + +#ifndef __al_included_allegro5_timer_h +#define __al_included_allegro5_timer_h + +#include "allegro5/base.h" +#include "allegro5/events.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +/* Function: ALLEGRO_USECS_TO_SECS + */ +#define ALLEGRO_USECS_TO_SECS(x) ((x) / 1000000.0) + +/* Function: ALLEGRO_MSECS_TO_SECS + */ +#define ALLEGRO_MSECS_TO_SECS(x) ((x) / 1000.0) + +/* Function: ALLEGRO_BPS_TO_SECS + */ +#define ALLEGRO_BPS_TO_SECS(x) (1.0 / (x)) + +/* Function: ALLEGRO_BPM_TO_SECS + */ +#define ALLEGRO_BPM_TO_SECS(x) (60.0 / (x)) + + +/* Type: ALLEGRO_TIMER + */ +typedef struct ALLEGRO_TIMER ALLEGRO_TIMER; + + +AL_FUNC(ALLEGRO_TIMER*, al_create_timer, (double speed_secs)); +AL_FUNC(void, al_destroy_timer, (ALLEGRO_TIMER *timer)); +AL_FUNC(void, al_start_timer, (ALLEGRO_TIMER *timer)); +AL_FUNC(void, al_stop_timer, (ALLEGRO_TIMER *timer)); +AL_FUNC(void, al_resume_timer, (ALLEGRO_TIMER *timer)); +AL_FUNC(bool, al_get_timer_started, (const ALLEGRO_TIMER *timer)); +AL_FUNC(double, al_get_timer_speed, (const ALLEGRO_TIMER *timer)); +AL_FUNC(void, al_set_timer_speed, (ALLEGRO_TIMER *timer, double speed_secs)); +AL_FUNC(int64_t, al_get_timer_count, (const ALLEGRO_TIMER *timer)); +AL_FUNC(void, al_set_timer_count, (ALLEGRO_TIMER *timer, int64_t count)); +AL_FUNC(void, al_add_timer_count, (ALLEGRO_TIMER *timer, int64_t diff)); +AL_FUNC(ALLEGRO_EVENT_SOURCE *, al_get_timer_event_source, (ALLEGRO_TIMER *timer)); + + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/tls.h b/common/allegro/include/allegro5/tls.h new file mode 100644 index 00000000..949b18a7 --- /dev/null +++ b/common/allegro/include/allegro5/tls.h @@ -0,0 +1,66 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Thread local storage routines. + * + * See readme.txt for copyright information. + */ + +#ifndef __al_included_allegro5_tls_h +#define __al_included_allegro5_tls_h + +#include "allegro5/base.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +/* Enum: ALLEGRO_STATE_FLAGS + */ +typedef enum ALLEGRO_STATE_FLAGS +{ + ALLEGRO_STATE_NEW_DISPLAY_PARAMETERS = 0x0001, + ALLEGRO_STATE_NEW_BITMAP_PARAMETERS = 0x0002, + ALLEGRO_STATE_DISPLAY = 0x0004, + ALLEGRO_STATE_TARGET_BITMAP = 0x0008, + ALLEGRO_STATE_BLENDER = 0x0010, + ALLEGRO_STATE_NEW_FILE_INTERFACE = 0x0020, + ALLEGRO_STATE_TRANSFORM = 0x0040, + ALLEGRO_STATE_PROJECTION_TRANSFORM = 0x0100, + + ALLEGRO_STATE_BITMAP = ALLEGRO_STATE_TARGET_BITMAP +\ + ALLEGRO_STATE_NEW_BITMAP_PARAMETERS, + + ALLEGRO_STATE_ALL = 0xffff + +} ALLEGRO_STATE_FLAGS; + + +/* Type: ALLEGRO_STATE + */ +typedef struct ALLEGRO_STATE ALLEGRO_STATE; + +struct ALLEGRO_STATE +{ + /* Internally, a thread_local_state structure is placed here. */ + char _tls[1024]; +}; + + +AL_FUNC(void, al_store_state, (ALLEGRO_STATE *state, int flags)); +AL_FUNC(void, al_restore_state, (ALLEGRO_STATE const *state)); + + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/touch_input.h b/common/allegro/include/allegro5/touch_input.h new file mode 100644 index 00000000..cd2f3bce --- /dev/null +++ b/common/allegro/include/allegro5/touch_input.h @@ -0,0 +1,98 @@ +/* ______ ___ ___ + * /\ _ \ /\_ \ /\_ \ + * \ \ \L\ \\//\ \ \//\ \ __ __ _ __ ___ + * \ \ __ \ \ \ \ \ \ \ /'__`\ /'_ `\/\`'__\/ __`\ + * \ \ \/\ \ \_\ \_ \_\ \_/\ __//\ \L\ \ \ \//\ \L\ \ + * \ \_\ \_\/\____\/\____\ \____\ \____ \ \_\\ \____/ + * \/_/\/_/\/____/\/____/\/____/\/___L\ \/_/ \/___/ + * /\____/ + * \_/__/ + * + * Touch input routines. + * + * See readme.txt for copyright information. + */ + +#ifndef __al_included_allegro5_touch_input_h +#define __al_included_allegro5_touch_input_h + +#include "allegro5/base.h" +#include "allegro5/events.h" + +#ifdef __cplusplus + extern "C" { +#endif + + +/* Enum: ALLEGRO_TOUCH_INPUT_MAX_TOUCH_COUNT + */ +#define ALLEGRO_TOUCH_INPUT_MAX_TOUCH_COUNT 16 + + +/* Type: ALLEGRO_TOUCH_INPUT + */ +typedef struct ALLEGRO_TOUCH_INPUT ALLEGRO_TOUCH_INPUT; + + +/* Type: ALLEGRO_TOUCH_INPUT_STATE + */ +typedef struct ALLEGRO_TOUCH_INPUT_STATE ALLEGRO_TOUCH_INPUT_STATE; + + +/* Type: ALLEGRO_TOUCH_STATE + */ +typedef struct ALLEGRO_TOUCH_STATE ALLEGRO_TOUCH_STATE; + + +struct ALLEGRO_TOUCH_STATE +{ + /* (id) An identifier of touch. If touch is valid this number is positive. + * (x, y) Touch position on the screen in 1:1 resolution. + * (dx, dy) Relative touch position. + * (primary) True, if touch is a primary one (usually first one). + * (display) Display at which the touch belong. + */ + int id; + float x, y; + float dx, dy; + bool primary; + struct ALLEGRO_DISPLAY *display; +}; + +struct ALLEGRO_TOUCH_INPUT_STATE +{ + ALLEGRO_TOUCH_STATE touches[ALLEGRO_TOUCH_INPUT_MAX_TOUCH_COUNT]; +}; + + +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_SRC) +/* Enum: ALLEGRO_MOUSE_EMULATION_MODE + */ +typedef enum ALLEGRO_MOUSE_EMULATION_MODE +{ + ALLEGRO_MOUSE_EMULATION_NONE, + ALLEGRO_MOUSE_EMULATION_TRANSPARENT, + ALLEGRO_MOUSE_EMULATION_INCLUSIVE, + ALLEGRO_MOUSE_EMULATION_EXCLUSIVE, + ALLEGRO_MOUSE_EMULATION_5_0_x +} ALLEGRO_MOUSE_EMULATION_MODE; +#endif + + +AL_FUNC(bool, al_is_touch_input_installed, (void)); +AL_FUNC(bool, al_install_touch_input, (void)); +AL_FUNC(void, al_uninstall_touch_input, (void)); +AL_FUNC(void, al_get_touch_input_state, (ALLEGRO_TOUCH_INPUT_STATE *ret_state)); +AL_FUNC(ALLEGRO_EVENT_SOURCE *, al_get_touch_input_event_source, (void)); + +#if defined(ALLEGRO_UNSTABLE) || defined(ALLEGRO_INTERNAL_UNSTABLE) || defined(ALLEGRO_SRC) +AL_FUNC(void, al_set_mouse_emulation_mode, (int mode)); +AL_FUNC(int, al_get_mouse_emulation_mode, (void)); +AL_FUNC(ALLEGRO_EVENT_SOURCE *, al_get_touch_input_mouse_emulation_event_source, (void)); +#endif + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/transformations.h b/common/allegro/include/allegro5/transformations.h new file mode 100644 index 00000000..84368e7a --- /dev/null +++ b/common/allegro/include/allegro5/transformations.h @@ -0,0 +1,52 @@ +#ifndef __al_included_allegro5_transformations_h +#define __al_included_allegro5_transformations_h + +#include "allegro5/display.h" + +#ifdef __cplusplus + extern "C" { +#endif + +/* Type: ALLEGRO_TRANSFORM + */ +typedef struct ALLEGRO_TRANSFORM ALLEGRO_TRANSFORM; + +struct ALLEGRO_TRANSFORM { + float m[4][4]; +}; + +/* Transformations*/ +AL_FUNC(void, al_use_transform, (const ALLEGRO_TRANSFORM* trans)); +AL_FUNC(void, al_use_projection_transform, (const ALLEGRO_TRANSFORM* trans)); +AL_FUNC(void, al_copy_transform, (ALLEGRO_TRANSFORM* dest, const ALLEGRO_TRANSFORM* src)); +AL_FUNC(void, al_identity_transform, (ALLEGRO_TRANSFORM* trans)); +AL_FUNC(void, al_build_transform, (ALLEGRO_TRANSFORM* trans, float x, float y, float sx, float sy, float theta)); +AL_FUNC(void, al_build_camera_transform, (ALLEGRO_TRANSFORM *trans, + float position_x, float position_y, float position_z, + float look_x, float look_y, float look_z, + float up_x, float up_y, float up_z)); +AL_FUNC(void, al_translate_transform, (ALLEGRO_TRANSFORM* trans, float x, float y)); +AL_FUNC(void, al_translate_transform_3d, (ALLEGRO_TRANSFORM *trans, float x, float y, float z)); +AL_FUNC(void, al_rotate_transform, (ALLEGRO_TRANSFORM* trans, float theta)); +AL_FUNC(void, al_rotate_transform_3d, (ALLEGRO_TRANSFORM *trans, float x, float y, float z, float angle)); +AL_FUNC(void, al_scale_transform, (ALLEGRO_TRANSFORM* trans, float sx, float sy)); +AL_FUNC(void, al_scale_transform_3d, (ALLEGRO_TRANSFORM *trans, float sx, float sy, float sz)); +AL_FUNC(void, al_transform_coordinates, (const ALLEGRO_TRANSFORM* trans, float* x, float* y)); +AL_FUNC(void, al_transform_coordinates_3d, (const ALLEGRO_TRANSFORM *trans, + float *x, float *y, float *z)); +AL_FUNC(void, al_compose_transform, (ALLEGRO_TRANSFORM* trans, const ALLEGRO_TRANSFORM* other)); +AL_FUNC(const ALLEGRO_TRANSFORM*, al_get_current_transform, (void)); +AL_FUNC(const ALLEGRO_TRANSFORM*, al_get_current_inverse_transform, (void)); +AL_FUNC(const ALLEGRO_TRANSFORM *, al_get_current_projection_transform, (void)); +AL_FUNC(void, al_invert_transform, (ALLEGRO_TRANSFORM *trans)); +AL_FUNC(int, al_check_inverse, (const ALLEGRO_TRANSFORM *trans, float tol)); +AL_FUNC(void, al_orthographic_transform, (ALLEGRO_TRANSFORM *trans, float left, float top, float n, float right, float bottom, float f)); +AL_FUNC(void, al_perspective_transform, (ALLEGRO_TRANSFORM *trans, float left, float top, float n, float right, float bottom, float f)); +AL_FUNC(void, al_horizontal_shear_transform, (ALLEGRO_TRANSFORM *trans, float theta)); +AL_FUNC(void, al_vertical_shear_transform, (ALLEGRO_TRANSFORM *trans, float theta)); + +#ifdef __cplusplus + } +#endif + +#endif diff --git a/common/allegro/include/allegro5/utf8.h b/common/allegro/include/allegro5/utf8.h new file mode 100644 index 00000000..f0459dac --- /dev/null +++ b/common/allegro/include/allegro5/utf8.h @@ -0,0 +1,150 @@ +#ifndef __al_included_allegro5_utf8_h +#define __al_included_allegro5_utf8_h + +#include "allegro5/base.h" + +#ifdef __cplusplus + extern "C" { +#endif + +/* Type: ALLEGRO_USTR + */ +typedef struct _al_tagbstring ALLEGRO_USTR; + +/* Type: ALLEGRO_USTR_INFO + */ +typedef struct _al_tagbstring ALLEGRO_USTR_INFO; + +#ifndef __al_tagbstring_defined +#define __al_tagbstring_defined +struct _al_tagbstring { + int mlen; + int slen; + unsigned char * data; +}; +#endif + +/* Creating strings */ +AL_FUNC(ALLEGRO_USTR *, al_ustr_new, (const char *s)); +AL_FUNC(ALLEGRO_USTR *, al_ustr_new_from_buffer, (const char *s, size_t size)); +AL_PRINTFUNC(ALLEGRO_USTR *, al_ustr_newf, (const char *fmt, ...), 1, 2); +AL_FUNC(void, al_ustr_free, (ALLEGRO_USTR *us)); +AL_FUNC(const char *, al_cstr, (const ALLEGRO_USTR *us)); +AL_FUNC(void, al_ustr_to_buffer, (const ALLEGRO_USTR *us, char *buffer, int size)); +AL_FUNC(char *, al_cstr_dup, (const ALLEGRO_USTR *us)); +AL_FUNC(ALLEGRO_USTR *, al_ustr_dup, (const ALLEGRO_USTR *us)); +AL_FUNC(ALLEGRO_USTR *, al_ustr_dup_substr, (const ALLEGRO_USTR *us, + int start_pos, int end_pos)); + +/* Predefined string */ +AL_FUNC(const ALLEGRO_USTR *, al_ustr_empty_string, (void)); + +/* Reference strings */ +AL_FUNC(const ALLEGRO_USTR *, al_ref_cstr, (ALLEGRO_USTR_INFO *info, const char *s)); +AL_FUNC(const ALLEGRO_USTR *, al_ref_buffer, (ALLEGRO_USTR_INFO *info, const char *s, + size_t size)); +AL_FUNC(const ALLEGRO_USTR *, al_ref_ustr, (ALLEGRO_USTR_INFO *info, + const ALLEGRO_USTR *us, int start_pos, int end_pos)); + +/* Sizes and offsets */ +AL_FUNC(size_t, al_ustr_size, (const ALLEGRO_USTR *us)); +AL_FUNC(size_t, al_ustr_length, (const ALLEGRO_USTR *us)); +AL_FUNC(int, al_ustr_offset, (const ALLEGRO_USTR *us, int index)); +AL_FUNC(bool, al_ustr_next, (const ALLEGRO_USTR *us, int *pos)); +AL_FUNC(bool, al_ustr_prev, (const ALLEGRO_USTR *us, int *pos)); + +/* Get codepoints */ +AL_FUNC(int32_t, al_ustr_get, (const ALLEGRO_USTR *us, int pos)); +AL_FUNC(int32_t, al_ustr_get_next, (const ALLEGRO_USTR *us, int *pos)); +AL_FUNC(int32_t, al_ustr_prev_get, (const ALLEGRO_USTR *us, int *pos)); + +/* Insert */ +AL_FUNC(bool, al_ustr_insert, (ALLEGRO_USTR *us1, int pos, + const ALLEGRO_USTR *us2)); +AL_FUNC(bool, al_ustr_insert_cstr, (ALLEGRO_USTR *us, int pos, + const char *us2)); +AL_FUNC(size_t, al_ustr_insert_chr, (ALLEGRO_USTR *us, int pos, int32_t c)); + +/* Append */ +AL_FUNC(bool, al_ustr_append, (ALLEGRO_USTR *us1, const ALLEGRO_USTR *us2)); +AL_FUNC(bool, al_ustr_append_cstr, (ALLEGRO_USTR *us, const char *s)); +AL_FUNC(size_t, al_ustr_append_chr, (ALLEGRO_USTR *us, int32_t c)); +AL_PRINTFUNC(bool, al_ustr_appendf, (ALLEGRO_USTR *us, const char *fmt, ...), + 2, 3); +AL_FUNC(bool, al_ustr_vappendf, (ALLEGRO_USTR *us, const char *fmt, + va_list ap)); + +/* Remove */ +AL_FUNC(bool, al_ustr_remove_chr, (ALLEGRO_USTR *us, int pos)); +AL_FUNC(bool, al_ustr_remove_range, (ALLEGRO_USTR *us, int start_pos, + int end_pos)); +AL_FUNC(bool, al_ustr_truncate, (ALLEGRO_USTR *us, int start_pos)); +AL_FUNC(bool, al_ustr_ltrim_ws, (ALLEGRO_USTR *us)); +AL_FUNC(bool, al_ustr_rtrim_ws, (ALLEGRO_USTR *us)); +AL_FUNC(bool, al_ustr_trim_ws, (ALLEGRO_USTR *us)); + +/* Assign */ +AL_FUNC(bool, al_ustr_assign, (ALLEGRO_USTR *us1, const ALLEGRO_USTR *us2)); +AL_FUNC(bool, al_ustr_assign_substr, (ALLEGRO_USTR *us1, const ALLEGRO_USTR *us2, + int start_pos, int end_pos)); +AL_FUNC(bool, al_ustr_assign_cstr, (ALLEGRO_USTR *us1, const char *s)); + +/* Replace */ +AL_FUNC(size_t, al_ustr_set_chr, (ALLEGRO_USTR *us, int pos, int32_t c)); +AL_FUNC(bool, al_ustr_replace_range, (ALLEGRO_USTR *us1, int start_pos1, + int end_pos1, const ALLEGRO_USTR *us2)); + +/* Searching */ +AL_FUNC(int, al_ustr_find_chr, (const ALLEGRO_USTR *us, int start_pos, + int32_t c)); +AL_FUNC(int, al_ustr_rfind_chr, (const ALLEGRO_USTR *us, int start_pos, + int32_t c)); +AL_FUNC(int, al_ustr_find_set, (const ALLEGRO_USTR *us, int start_pos, + const ALLEGRO_USTR *accept)); +AL_FUNC(int, al_ustr_find_set_cstr, (const ALLEGRO_USTR *us, int start_pos, + const char *accept)); +AL_FUNC(int, al_ustr_find_cset, (const ALLEGRO_USTR *us, int start_pos, + const ALLEGRO_USTR *reject)); +AL_FUNC(int, al_ustr_find_cset_cstr, (const ALLEGRO_USTR *us, int start_pos, + const char *reject)); +AL_FUNC(int, al_ustr_find_str, (const ALLEGRO_USTR *haystack, int start_pos, + const ALLEGRO_USTR *needle)); +AL_FUNC(int, al_ustr_find_cstr, (const ALLEGRO_USTR *haystack, int start_pos, + const char *needle)); +AL_FUNC(int, al_ustr_rfind_str, (const ALLEGRO_USTR *haystack, int start_pos, + const ALLEGRO_USTR *needle)); +AL_FUNC(int, al_ustr_rfind_cstr, (const ALLEGRO_USTR *haystack, int start_pos, + const char *needle)); +AL_FUNC(bool, al_ustr_find_replace, (ALLEGRO_USTR *us, int start_pos, + const ALLEGRO_USTR *find, const ALLEGRO_USTR *replace)); +AL_FUNC(bool, al_ustr_find_replace_cstr, (ALLEGRO_USTR *us, int start_pos, + const char *find, const char *replace)); + +/* Compare */ +AL_FUNC(bool, al_ustr_equal, (const ALLEGRO_USTR *us1, const ALLEGRO_USTR *us2)); +AL_FUNC(int, al_ustr_compare, (const ALLEGRO_USTR *u, const ALLEGRO_USTR *v)); +AL_FUNC(int, al_ustr_ncompare, (const ALLEGRO_USTR *us1, const ALLEGRO_USTR *us2, + int n)); +AL_FUNC(bool, al_ustr_has_prefix,(const ALLEGRO_USTR *u, const ALLEGRO_USTR *v)); +AL_FUNC(bool, al_ustr_has_prefix_cstr, (const ALLEGRO_USTR *u, const char *s)); +AL_FUNC(bool, al_ustr_has_suffix,(const ALLEGRO_USTR *u, const ALLEGRO_USTR *v)); +AL_FUNC(bool, al_ustr_has_suffix_cstr,(const ALLEGRO_USTR *us1, const char *s)); + +/* Low level UTF-8 functions */ +AL_FUNC(size_t, al_utf8_width, (int32_t c)); +AL_FUNC(size_t, al_utf8_encode, (char s[], int32_t c)); + +/* UTF-16 */ +AL_FUNC(ALLEGRO_USTR *, al_ustr_new_from_utf16, (uint16_t const *s)); +AL_FUNC(size_t, al_ustr_size_utf16, (const ALLEGRO_USTR *us)); +AL_FUNC(size_t, al_ustr_encode_utf16, (const ALLEGRO_USTR *us, uint16_t *s, size_t n)); +AL_FUNC(size_t, al_utf16_width, (int c)); +AL_FUNC(size_t, al_utf16_encode, (uint16_t s[], int32_t c)); + +#ifdef __cplusplus + } +#endif + +#endif + +/* vim: set sts=3 sw=3 et: */ diff --git a/common/assets/Mayor_Quimby.png b/common/assets/Mayor_Quimby.png new file mode 100644 index 00000000..dc96c61e Binary files /dev/null and b/common/assets/Mayor_Quimby.png differ diff --git a/common/assets/Sounds/Funk.wav b/common/assets/Sounds/Funk.wav new file mode 100644 index 00000000..6b6724f0 Binary files /dev/null and b/common/assets/Sounds/Funk.wav differ diff --git a/common/assets/Sounds/Laser.wav b/common/assets/Sounds/Laser.wav new file mode 100644 index 00000000..c5170362 Binary files /dev/null and b/common/assets/Sounds/Laser.wav differ diff --git a/common/assets/Sounds/minetrap/BEATHIGH.WAV b/common/assets/Sounds/minetrap/BEATHIGH.WAV new file mode 100644 index 00000000..67c81717 Binary files /dev/null and b/common/assets/Sounds/minetrap/BEATHIGH.WAV differ diff --git a/common/assets/Sounds/minetrap/BLIP.WAV b/common/assets/Sounds/minetrap/BLIP.WAV new file mode 100644 index 00000000..df4de287 Binary files /dev/null and b/common/assets/Sounds/minetrap/BLIP.WAV differ diff --git a/common/assets/Sounds/minetrap/BONOBJ3.WAV b/common/assets/Sounds/minetrap/BONOBJ3.WAV new file mode 100644 index 00000000..67515bcf Binary files /dev/null and b/common/assets/Sounds/minetrap/BONOBJ3.WAV differ diff --git a/common/assets/Sounds/minetrap/BUMP1.WAV b/common/assets/Sounds/minetrap/BUMP1.WAV new file mode 100644 index 00000000..eca6adc7 Binary files /dev/null and b/common/assets/Sounds/minetrap/BUMP1.WAV differ diff --git a/common/assets/Sounds/minetrap/BUMP2.WAV b/common/assets/Sounds/minetrap/BUMP2.WAV new file mode 100644 index 00000000..ff561950 Binary files /dev/null and b/common/assets/Sounds/minetrap/BUMP2.WAV differ diff --git a/common/assets/Sounds/minetrap/BUMP3.WAV b/common/assets/Sounds/minetrap/BUMP3.WAV new file mode 100644 index 00000000..c84f2994 Binary files /dev/null and b/common/assets/Sounds/minetrap/BUMP3.WAV differ diff --git a/common/assets/Sounds/minetrap/DBSPLAT.WAV b/common/assets/Sounds/minetrap/DBSPLAT.WAV new file mode 100644 index 00000000..f0fb261d Binary files /dev/null and b/common/assets/Sounds/minetrap/DBSPLAT.WAV differ diff --git a/common/assets/Sounds/minetrap/DISKS.WAV b/common/assets/Sounds/minetrap/DISKS.WAV new file mode 100644 index 00000000..4d316c03 Binary files /dev/null and b/common/assets/Sounds/minetrap/DISKS.WAV differ diff --git a/common/assets/Sounds/minetrap/ELEC2.WAV b/common/assets/Sounds/minetrap/ELEC2.WAV new file mode 100644 index 00000000..5bcede01 Binary files /dev/null and b/common/assets/Sounds/minetrap/ELEC2.WAV differ diff --git a/common/assets/Sounds/minetrap/EXP-L.WAV b/common/assets/Sounds/minetrap/EXP-L.WAV new file mode 100644 index 00000000..6ac04b01 Binary files /dev/null and b/common/assets/Sounds/minetrap/EXP-L.WAV differ diff --git a/common/assets/Sounds/minetrap/EXP-M.WAV b/common/assets/Sounds/minetrap/EXP-M.WAV new file mode 100644 index 00000000..aac091fe Binary files /dev/null and b/common/assets/Sounds/minetrap/EXP-M.WAV differ diff --git a/common/assets/Sounds/minetrap/EXP-S.WAV b/common/assets/Sounds/minetrap/EXP-S.WAV new file mode 100644 index 00000000..a0de9903 Binary files /dev/null and b/common/assets/Sounds/minetrap/EXP-S.WAV differ diff --git a/common/assets/Sounds/minetrap/EXP17B.WAV b/common/assets/Sounds/minetrap/EXP17B.WAV new file mode 100644 index 00000000..dd30c865 Binary files /dev/null and b/common/assets/Sounds/minetrap/EXP17B.WAV differ diff --git a/common/assets/Sounds/minetrap/EXPLO1.WAV b/common/assets/Sounds/minetrap/EXPLO1.WAV new file mode 100644 index 00000000..f422c801 Binary files /dev/null and b/common/assets/Sounds/minetrap/EXPLO1.WAV differ diff --git a/common/assets/Sounds/minetrap/FAN.WAV b/common/assets/Sounds/minetrap/FAN.WAV new file mode 100644 index 00000000..a28ea4ce Binary files /dev/null and b/common/assets/Sounds/minetrap/FAN.WAV differ diff --git a/common/assets/Sounds/minetrap/FANFARE.WAV b/common/assets/Sounds/minetrap/FANFARE.WAV new file mode 100644 index 00000000..a8a914fa Binary files /dev/null and b/common/assets/Sounds/minetrap/FANFARE.WAV differ diff --git a/common/assets/Sounds/minetrap/FILL2.WAV b/common/assets/Sounds/minetrap/FILL2.WAV new file mode 100644 index 00000000..c86d3200 Binary files /dev/null and b/common/assets/Sounds/minetrap/FILL2.WAV differ diff --git a/common/assets/Sounds/minetrap/FIR-L.WAV b/common/assets/Sounds/minetrap/FIR-L.WAV new file mode 100644 index 00000000..951bfea0 Binary files /dev/null and b/common/assets/Sounds/minetrap/FIR-L.WAV differ diff --git a/common/assets/Sounds/minetrap/FIR-S.WAV b/common/assets/Sounds/minetrap/FIR-S.WAV new file mode 100644 index 00000000..68325361 Binary files /dev/null and b/common/assets/Sounds/minetrap/FIR-S.WAV differ diff --git a/common/assets/Sounds/minetrap/GAG3.WAV b/common/assets/Sounds/minetrap/GAG3.WAV new file mode 100644 index 00000000..a213ef2c Binary files /dev/null and b/common/assets/Sounds/minetrap/GAG3.WAV differ diff --git a/common/assets/Sounds/minetrap/GUARDS.WAV b/common/assets/Sounds/minetrap/GUARDS.WAV new file mode 100644 index 00000000..83abddfd Binary files /dev/null and b/common/assets/Sounds/minetrap/GUARDS.WAV differ diff --git a/common/assets/Sounds/minetrap/KILLED.WAV b/common/assets/Sounds/minetrap/KILLED.WAV new file mode 100644 index 00000000..073f8cfb Binary files /dev/null and b/common/assets/Sounds/minetrap/KILLED.WAV differ diff --git a/common/assets/Sounds/minetrap/LADDER.WAV b/common/assets/Sounds/minetrap/LADDER.WAV new file mode 100644 index 00000000..da3623f8 Binary files /dev/null and b/common/assets/Sounds/minetrap/LADDER.WAV differ diff --git a/common/assets/Sounds/minetrap/LANDED.WAV b/common/assets/Sounds/minetrap/LANDED.WAV new file mode 100644 index 00000000..6ac04b01 Binary files /dev/null and b/common/assets/Sounds/minetrap/LANDED.WAV differ diff --git a/common/assets/Sounds/minetrap/MAKEHIGH.WAV b/common/assets/Sounds/minetrap/MAKEHIGH.WAV new file mode 100644 index 00000000..c60f1a11 Binary files /dev/null and b/common/assets/Sounds/minetrap/MAKEHIGH.WAV differ diff --git a/common/assets/Sounds/minetrap/NEGFAN.WAV b/common/assets/Sounds/minetrap/NEGFAN.WAV new file mode 100644 index 00000000..d9fa4625 Binary files /dev/null and b/common/assets/Sounds/minetrap/NEGFAN.WAV differ diff --git a/common/assets/Sounds/minetrap/NEWHI.WAV b/common/assets/Sounds/minetrap/NEWHI.WAV new file mode 100644 index 00000000..214f0138 Binary files /dev/null and b/common/assets/Sounds/minetrap/NEWHI.WAV differ diff --git a/common/assets/Sounds/minetrap/NEWPLAY.WAV b/common/assets/Sounds/minetrap/NEWPLAY.WAV new file mode 100644 index 00000000..c60f1a11 Binary files /dev/null and b/common/assets/Sounds/minetrap/NEWPLAY.WAV differ diff --git a/common/assets/Sounds/minetrap/NONOISE.WAV b/common/assets/Sounds/minetrap/NONOISE.WAV new file mode 100644 index 00000000..d3fdc8ba Binary files /dev/null and b/common/assets/Sounds/minetrap/NONOISE.WAV differ diff --git a/common/assets/Sounds/minetrap/PADDLE.WAV b/common/assets/Sounds/minetrap/PADDLE.WAV new file mode 100644 index 00000000..feaeda3f Binary files /dev/null and b/common/assets/Sounds/minetrap/PADDLE.WAV differ diff --git a/common/assets/Sounds/minetrap/POWERPK.WAV b/common/assets/Sounds/minetrap/POWERPK.WAV new file mode 100644 index 00000000..0d6501d0 Binary files /dev/null and b/common/assets/Sounds/minetrap/POWERPK.WAV differ diff --git a/common/assets/Sounds/minetrap/PROP1.WAV b/common/assets/Sounds/minetrap/PROP1.WAV new file mode 100644 index 00000000..f2999f5d Binary files /dev/null and b/common/assets/Sounds/minetrap/PROP1.WAV differ diff --git a/common/assets/Sounds/minetrap/PROPGN.WAV b/common/assets/Sounds/minetrap/PROPGN.WAV new file mode 100644 index 00000000..e1feab68 Binary files /dev/null and b/common/assets/Sounds/minetrap/PROPGN.WAV differ diff --git a/common/assets/Sounds/minetrap/SHOVEL.WAV b/common/assets/Sounds/minetrap/SHOVEL.WAV new file mode 100644 index 00000000..7ace88bc Binary files /dev/null and b/common/assets/Sounds/minetrap/SHOVEL.WAV differ diff --git a/common/assets/Sounds/minetrap/SIREN.WAV b/common/assets/Sounds/minetrap/SIREN.WAV new file mode 100644 index 00000000..69f89263 Binary files /dev/null and b/common/assets/Sounds/minetrap/SIREN.WAV differ diff --git a/common/assets/Sounds/minetrap/SPLAT.WAV b/common/assets/Sounds/minetrap/SPLAT.WAV new file mode 100644 index 00000000..3531c063 Binary files /dev/null and b/common/assets/Sounds/minetrap/SPLAT.WAV differ diff --git a/common/assets/Sounds/minetrap/STEPLFT.WAV b/common/assets/Sounds/minetrap/STEPLFT.WAV new file mode 100644 index 00000000..a4e4e3f0 Binary files /dev/null and b/common/assets/Sounds/minetrap/STEPLFT.WAV differ diff --git a/common/assets/Sounds/minetrap/STEPRHT.WAV b/common/assets/Sounds/minetrap/STEPRHT.WAV new file mode 100644 index 00000000..af084597 Binary files /dev/null and b/common/assets/Sounds/minetrap/STEPRHT.WAV differ diff --git a/common/assets/Sounds/minetrap/TIMEUP.WAV b/common/assets/Sounds/minetrap/TIMEUP.WAV new file mode 100644 index 00000000..48d30f3a Binary files /dev/null and b/common/assets/Sounds/minetrap/TIMEUP.WAV differ diff --git a/common/assets/Sounds/quest.wav b/common/assets/Sounds/quest.wav new file mode 100644 index 00000000..15078005 Binary files /dev/null and b/common/assets/Sounds/quest.wav differ diff --git a/common/assets/Woods.png b/common/assets/Woods.png new file mode 100644 index 00000000..8cf6c786 Binary files /dev/null and b/common/assets/Woods.png differ diff --git a/common/assets/axamer-lizum.png b/common/assets/axamer-lizum.png new file mode 100644 index 00000000..47a000bb Binary files /dev/null and b/common/assets/axamer-lizum.png differ diff --git a/common/assets/clapping.wav b/common/assets/clapping.wav new file mode 100644 index 00000000..84c2031f Binary files /dev/null and b/common/assets/clapping.wav differ diff --git a/common/assets/cour.ttf b/common/assets/cour.ttf new file mode 100644 index 00000000..2c99e08c Binary files /dev/null and b/common/assets/cour.ttf differ diff --git a/common/assets/dean_sprites.png b/common/assets/dean_sprites.png new file mode 100644 index 00000000..45850b65 Binary files /dev/null and b/common/assets/dean_sprites.png differ diff --git a/common/assets/glowing-balls.png b/common/assets/glowing-balls.png new file mode 100644 index 00000000..1dcf352d Binary files /dev/null and b/common/assets/glowing-balls.png differ diff --git a/common/assets/imp.png b/common/assets/imp.png new file mode 100644 index 00000000..4dbbfa79 Binary files /dev/null and b/common/assets/imp.png differ diff --git a/common/assets/smurf_sprites.png b/common/assets/smurf_sprites.png new file mode 100644 index 00000000..ba64e4c7 Binary files /dev/null and b/common/assets/smurf_sprites.png differ diff --git a/common/assets/smurf_sprites_numbered.png b/common/assets/smurf_sprites_numbered.png new file mode 100644 index 00000000..353d6f89 Binary files /dev/null and b/common/assets/smurf_sprites_numbered.png differ diff --git a/common/assets/sprites.png b/common/assets/sprites.png new file mode 100644 index 00000000..f1fe1d97 Binary files /dev/null and b/common/assets/sprites.png differ diff --git a/common/assets/steps.png b/common/assets/steps.png new file mode 100644 index 00000000..3f93af58 Binary files /dev/null and b/common/assets/steps.png differ diff --git a/common/lawson/Event System/AnimationManager.h b/common/lawson/Event System/AnimationManager.h new file mode 100644 index 00000000..2f934a91 --- /dev/null +++ b/common/lawson/Event System/AnimationManager.h @@ -0,0 +1,21 @@ +#pragma once + +class Animation +{ +private: + float mTimingInfo; + AnimationPrototype* mPrototype; +}; + +class AnimationManager +{ +public: + Animation getAnimation(string key); + + void loadAnimation(GraphicsBuffer, sprite sheet info, string key); + + init, cleanup + +private: + map mMap; +}; diff --git a/common/lawson/Event System/Event.cpp b/common/lawson/Event System/Event.cpp new file mode 100644 index 00000000..b6316149 --- /dev/null +++ b/common/lawson/Event System/Event.cpp @@ -0,0 +1,11 @@ +#include "Event.h" + +Event::Event(EventType type) +:mType(type) +{ +} + +Event::~Event() +{ +} + diff --git a/common/lawson/Event System/Event.h b/common/lawson/Event System/Event.h new file mode 100644 index 00000000..03ba5683 --- /dev/null +++ b/common/lawson/Event System/Event.h @@ -0,0 +1,27 @@ +#pragma once + +#include +#include + +using namespace std; + +enum EventType +{ + INVALID_EVENT_TYPE = -1, + MOVE_EVENT, + MESSAGE_EVENT, + NUM_EVENT_TYPES +}; + +class Event:public Trackable +{ +public: + Event( EventType type ); + virtual ~Event(); + + EventType getType() const { return mType; }; + +private: + EventType mType; + +}; \ No newline at end of file diff --git a/common/lawson/Event System/EventListener.cpp b/common/lawson/Event System/EventListener.cpp new file mode 100644 index 00000000..e5c058e7 --- /dev/null +++ b/common/lawson/Event System/EventListener.cpp @@ -0,0 +1,11 @@ +#include "EventListener.h" +#include "EventSystem.h" + +EventListener::EventListener() +{ +} + +EventListener::~EventListener() +{ + EventSystem::getInstance()->removeListenerFromAllEvents( this ); +} diff --git a/common/lawson/Event System/EventListener.h b/common/lawson/Event System/EventListener.h new file mode 100644 index 00000000..21eb7383 --- /dev/null +++ b/common/lawson/Event System/EventListener.h @@ -0,0 +1,17 @@ +#pragma once + +#include + +class Event; +class EventSystem; + +class EventListener:public Trackable +{ +public: + EventListener(); + virtual ~EventListener(); + + virtual void handleEvent( const Event& theEvent ) = 0; + +private: +}; \ No newline at end of file diff --git a/common/lawson/Event System/EventSystem.cpp b/common/lawson/Event System/EventSystem.cpp new file mode 100644 index 00000000..0f22f773 --- /dev/null +++ b/common/lawson/Event System/EventSystem.cpp @@ -0,0 +1,123 @@ +#include "EventSystem.h" +#include "Event.h" +#include "EventListener.h" +#include + +EventSystem* EventSystem::mspInstance = nullptr; + +EventSystem::EventSystem() +{ +} + +EventSystem::~EventSystem() +{ + cleanup(); +} + +void EventSystem::addListener(EventType type, EventListener* pListener) +{ + if (mIsInitted) + { + mListenerMap.insert(pair< EventType, EventListener* >(type, pListener)); + } +} + +void EventSystem::removeListener(EventType type, EventListener *pListener) +{ + if (mIsInitted) + { + pair::iterator, multimap::iterator> ret; + + ret = mListenerMap.equal_range(type); + multimap::iterator iter; + + for (iter = ret.first; iter != ret.second; ++iter) + { + if (iter->second == pListener) + { + mListenerMap.erase(iter); + break;//to prevent using invalidated iterator + } + } + } +} + +void EventSystem::removeListenerFromAllEvents( EventListener* pListener ) +{ + if (mIsInitted) + { + multimap::iterator iter; + + bool allTheWayThrough = false; + + while (!allTheWayThrough) + { + allTheWayThrough = true; + for (iter = mListenerMap.begin(); iter != mListenerMap.end(); ++iter) + { + if (iter->second == pListener) + { + mListenerMap.erase(iter); + allTheWayThrough = false; //didn't make it the whole way through + break;//to prevent using invalidated iterator + } + } + } + } +} + +EventSystem* EventSystem::getInstance() +{ + assert(mspInstance); + return mspInstance; +} + +void EventSystem::initInstance() +{ + assert(!mspInstance); + mspInstance = new EventSystem; +} + +void EventSystem::cleanupInstance() +{ + delete mspInstance; + mspInstance = nullptr; +} + +void EventSystem::init() +{ + if (mIsInitted) + { + cleanup(); + } + mIsInitted = true; +} + +void EventSystem::cleanup() +{ + mListenerMap.clear(); + mIsInitted = false; +} + +void EventSystem::fireEvent( const Event& theEvent ) +{ + if (mIsInitted) + { + dispatchAllEvents(theEvent); + } +} + +void EventSystem::dispatchAllEvents( const Event& theEvent ) +{ + if (mIsInitted) + { + pair::iterator, multimap::iterator> ret; + ret = mListenerMap.equal_range(theEvent.getType()); + + multimap::iterator iter; + for (iter = ret.first; iter != ret.second; ++iter) + { + iter->second->handleEvent(theEvent); + } + } +} \ No newline at end of file diff --git a/common/lawson/Event System/EventSystem.h b/common/lawson/Event System/EventSystem.h new file mode 100644 index 00000000..7782d2ee --- /dev/null +++ b/common/lawson/Event System/EventSystem.h @@ -0,0 +1,39 @@ +#pragma once + +#include +#include + +class Event; +class EventListener; +enum EventType; + +using namespace std; + +class EventSystem:public Trackable +{ +public: + static EventSystem* getInstance(); + static void initInstance(); + static void cleanupInstance(); + + void init(); + void cleanup(); + + void fireEvent( const Event& theEvent ); + void addListener( EventType type, EventListener* pListener ); + void removeListener( EventType type, EventListener* pListener ); + void removeListenerFromAllEvents( EventListener* pListener ); + +private: + static EventSystem* mspInstance; + multimap< EventType, EventListener* > mListenerMap; + bool mIsInitted = false; + + void dispatchAllEvents( const Event& theEvent ); + + EventSystem(); + ~EventSystem(); + + +}; + diff --git a/common/lawson/Event System/EventSystem.sln b/common/lawson/Event System/EventSystem.sln new file mode 100644 index 00000000..1d18177c --- /dev/null +++ b/common/lawson/Event System/EventSystem.sln @@ -0,0 +1,25 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 15 +VisualStudioVersion = 15.0.27130.2027 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "EventSystem", "EventSystem.vcxproj", "{4B602022-E8DA-41DB-B4B6-A43B8DB5041D}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Win32 = Debug|Win32 + Release|Win32 = Release|Win32 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {4B602022-E8DA-41DB-B4B6-A43B8DB5041D}.Debug|Win32.ActiveCfg = Debug|Win32 + {4B602022-E8DA-41DB-B4B6-A43B8DB5041D}.Debug|Win32.Build.0 = Debug|Win32 + {4B602022-E8DA-41DB-B4B6-A43B8DB5041D}.Release|Win32.ActiveCfg = Release|Win32 + {4B602022-E8DA-41DB-B4B6-A43B8DB5041D}.Release|Win32.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {87B9D9D5-ECBE-4F19-BB0D-903949EA5AFE} + EndGlobalSection +EndGlobal diff --git a/common/lawson/Event System/EventSystem.vcxproj b/common/lawson/Event System/EventSystem.vcxproj new file mode 100644 index 00000000..e6320b4d --- /dev/null +++ b/common/lawson/Event System/EventSystem.vcxproj @@ -0,0 +1,93 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + + {4B602022-E8DA-41DB-B4B6-A43B8DB5041D} + EventSystem + 10.0 + + + + Application + true + v142 + MultiByte + + + Application + false + v142 + true + MultiByte + + + + + + + + + + + + + + + Level3 + Disabled + true + ../../DeanLib/include + + + true + ../../DeanLib/lib + DeanLibDebug.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) + + + + + Level3 + MaxSpeed + true + true + true + + + true + true + true + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/common/lawson/Event System/ExampleListener.cpp b/common/lawson/Event System/ExampleListener.cpp new file mode 100644 index 00000000..fbd7875d --- /dev/null +++ b/common/lawson/Event System/ExampleListener.cpp @@ -0,0 +1,33 @@ +#include "ExampleListener.h" +#include "EventSystem.h" +#include "Event.h" +#include "MoveEvent.h" +#include "StringEvent.h" + +ExampleListener::ExampleListener() +{ + EventSystem* pEventSystem = EventSystem::getInstance(); + pEventSystem->addListener( MOVE_EVENT, this ); + pEventSystem->addListener(MESSAGE_EVENT, this); +} + +ExampleListener::~ExampleListener() +{ +} + +void ExampleListener::handleEvent(const Event &theEvent) +{ + cout << endl << "ExampleListener" << endl; + + if( theEvent.getType() == MOVE_EVENT ) + { + const MoveEvent& moveEvent = static_cast(theEvent); + cout << endl << "\tMove to: " << moveEvent.getLocation().getX() + << "," << moveEvent.getLocation().getY() << endl; + } + else if( theEvent.getType() == MESSAGE_EVENT) + { + const StringEvent& stringEvent = static_cast(theEvent); + cout << endl << "\tMessage: " << stringEvent.getString() << endl; + } +} \ No newline at end of file diff --git a/common/lawson/Event System/ExampleListener.h b/common/lawson/Event System/ExampleListener.h new file mode 100644 index 00000000..3caabdad --- /dev/null +++ b/common/lawson/Event System/ExampleListener.h @@ -0,0 +1,17 @@ +#pragma once + +#include +#include "EventListener.h" + +class EventSystem; + +class ExampleListener : public EventListener +{ +public: + ExampleListener(); + ~ExampleListener(); + + void handleEvent( const Event& theEvent ); + +private: +}; \ No newline at end of file diff --git a/common/lawson/Event System/GameEvent.h b/common/lawson/Event System/GameEvent.h new file mode 100644 index 00000000..6f70f09b --- /dev/null +++ b/common/lawson/Event System/GameEvent.h @@ -0,0 +1 @@ +#pragma once diff --git a/common/lawson/Event System/KillEvent.h b/common/lawson/Event System/KillEvent.h new file mode 100644 index 00000000..f57989ff --- /dev/null +++ b/common/lawson/Event System/KillEvent.h @@ -0,0 +1,12 @@ +#pragma once + +#include "Event.h" +#include "GameEvent.h" + +class KillEvent : public Event +{ +public: + KillEvent() :Event((EventType)KILL) {}; + ~KillEvent() {}; +private: +}; \ No newline at end of file diff --git a/common/lawson/Event System/MoveEvent.cpp b/common/lawson/Event System/MoveEvent.cpp new file mode 100644 index 00000000..32deb3d8 --- /dev/null +++ b/common/lawson/Event System/MoveEvent.cpp @@ -0,0 +1,11 @@ +#include "MoveEvent.h" + +MoveEvent::MoveEvent(const Vector2D& loc) +:Event( MOVE_EVENT ) +,mLoc(loc) +{ +} + +MoveEvent::~MoveEvent() +{ +} diff --git a/common/lawson/Event System/MoveEvent.h b/common/lawson/Event System/MoveEvent.h new file mode 100644 index 00000000..aa95a7ca --- /dev/null +++ b/common/lawson/Event System/MoveEvent.h @@ -0,0 +1,16 @@ +#pragma once + +#include +#include "Event.h" + +class MoveEvent : public Event +{ +public: + MoveEvent( const Vector2D& loc ); + ~MoveEvent(); + + Vector2D getLocation() const { return mLoc; }; + +private: + Vector2D mLoc; +}; \ No newline at end of file diff --git a/common/lawson/Event System/SoundSystem.cpp b/common/lawson/Event System/SoundSystem.cpp new file mode 100644 index 00000000..f8864964 --- /dev/null +++ b/common/lawson/Event System/SoundSystem.cpp @@ -0,0 +1,18 @@ +#include "SoundSystem.h" +#include "EventSystem.h" +#include "Event.h" + +SoundSystem::SoundSystem() +{ + EventSystem::getInstance()->addListener(MESSAGE_EVENT, this); +} + +void SoundSystem::handleEvent(const Event& theEvent) +{ + cout << endl << "SoundSystem" << endl; + + if (theEvent.getType() == MESSAGE_EVENT) + { + cout << endl << "Ding" << endl; + } +} diff --git a/common/lawson/Event System/SoundSystem.h b/common/lawson/Event System/SoundSystem.h new file mode 100644 index 00000000..0627e7f8 --- /dev/null +++ b/common/lawson/Event System/SoundSystem.h @@ -0,0 +1,17 @@ +#pragma once + +#include "EventSystem.h" +#include "EventListener.h" + +class SoundSystem : public EventListener +{ +public: + SoundSystem(); + ~SoundSystem() {}; + +private: + virtual void handleEvent(const Event& theEvent); + +}; + + diff --git a/common/lawson/Event System/StringEvent.cpp b/common/lawson/Event System/StringEvent.cpp new file mode 100644 index 00000000..c60d08d7 --- /dev/null +++ b/common/lawson/Event System/StringEvent.cpp @@ -0,0 +1,11 @@ +#include "StringEvent.h" + +StringEvent::StringEvent(const string& theString) + :Event( MESSAGE_EVENT ) +,mString(theString) +{ +} + +StringEvent::~StringEvent() +{ +} diff --git a/common/lawson/Event System/StringEvent.h b/common/lawson/Event System/StringEvent.h new file mode 100644 index 00000000..c5e5e8b3 --- /dev/null +++ b/common/lawson/Event System/StringEvent.h @@ -0,0 +1,18 @@ +#pragma once + +#include +#include "Event.h" + +using namespace std; + +class StringEvent : public Event +{ +public: + StringEvent( const string& theString ); + ~StringEvent(); + + inline string getString() const { return mString; }; + +private: + string mString; +}; \ No newline at end of file diff --git a/common/lawson/Event System/main.cpp b/common/lawson/Event System/main.cpp new file mode 100644 index 00000000..467f0219 --- /dev/null +++ b/common/lawson/Event System/main.cpp @@ -0,0 +1,49 @@ + +#include +#include + +#include +#include + +#include +#include +#include + +#include "EventSystem.h" +#include "ExampleListener.h" +#include "MoveEvent.h" +#include "StringEvent.h" +#include "SoundSystem.h" + +int main() +{ + EventSystem::initInstance(); + EventSystem* pEventSystem = EventSystem::getInstance(); + + pEventSystem->init(); + + ExampleListener* pListener = new ExampleListener; + SoundSystem* pSoundSystem = new SoundSystem; + + + //fire some events + pEventSystem->fireEvent( MoveEvent( Vector2D( 1.0f, 2.0f ) ) ); + + pEventSystem->fireEvent( StringEvent( "Initialization complete" ) ); + + pEventSystem->fireEvent( StringEvent( "Text1" ) ); + + + delete pListener;//make sure you delete listeners before the event system they use + + pEventSystem->fireEvent(StringEvent("Text\n")); + + delete pSoundSystem; + + EventSystem::cleanupInstance(); + MemoryTracker::getInstance()->reportAllocations(std::cout); + + system("pause"); + + return 0; +} \ No newline at end of file diff --git a/common/lawson/Manager and Singleton examples/Game.cpp b/common/lawson/Manager and Singleton examples/Game.cpp new file mode 100644 index 00000000..934bf064 --- /dev/null +++ b/common/lawson/Manager and Singleton examples/Game.cpp @@ -0,0 +1,3 @@ +#include "Game.h" + +Game * Game::mpGameInstance = nullptr; \ No newline at end of file diff --git a/common/lawson/Manager and Singleton examples/Game.h b/common/lawson/Manager and Singleton examples/Game.h new file mode 100644 index 00000000..9d5b97ae --- /dev/null +++ b/common/lawson/Manager and Singleton examples/Game.h @@ -0,0 +1,16 @@ +#pragma once + +#include + +class Game +{ +public: + static Game* getInstance(){ assert(mpGameInstance != nullptr); return mpGameInstance; }; + static void initInstance(){ mpGameInstance = new Game; }; + static void cleanupInstance(){ delete mpGameInstance; }; +private: + Game(); + + static Game* mpGameInstance; + +}; \ No newline at end of file diff --git a/common/lawson/Manager and Singleton examples/Singleton.cpp b/common/lawson/Manager and Singleton examples/Singleton.cpp new file mode 100644 index 00000000..8a3e12dc --- /dev/null +++ b/common/lawson/Manager and Singleton examples/Singleton.cpp @@ -0,0 +1,25 @@ +#include "Singleton.h" +#include + +Singleton* Singleton::mpsInstance = NULL; + +Singleton* Singleton::getInstance() +{ + if (mpsInstance == NULL) + mpsInstance = new Singleton; + return mpsInstance; +} + +/*void Singleton::cleanup() +{ + delete mpsInstance; + mpsInstance = NULL; +}; + +void Singleton::init() +{ + if (mpsInstance == NULL) + { + mpsInstance = new Singleton; + } +}*/ \ No newline at end of file diff --git a/common/lawson/Manager and Singleton examples/Singleton.h b/common/lawson/Manager and Singleton examples/Singleton.h new file mode 100644 index 00000000..d390f024 --- /dev/null +++ b/common/lawson/Manager and Singleton examples/Singleton.h @@ -0,0 +1,21 @@ +#include +#include + +class Singleton:public Trackable +{ +private: + static Singleton* mpsInstance; + Singleton(){ mAString = "Hi"; mAnInt = 12; }; + ~Singleton(){}; + + int mAnInt; + std::string mAString; + +public: + static Singleton* getInstance(); + //static void init(); + //static void cleanup(); + + int getInt(){ return mAnInt; }; + const std::string& getString(){ return mAString; }; +}; \ No newline at end of file diff --git a/common/lawson/Manager and Singleton examples/Widget.cpp b/common/lawson/Manager and Singleton examples/Widget.cpp new file mode 100644 index 00000000..b5892c00 --- /dev/null +++ b/common/lawson/Manager and Singleton examples/Widget.cpp @@ -0,0 +1 @@ +#include "Widget.h" \ No newline at end of file diff --git a/common/lawson/Manager and Singleton examples/Widget.h b/common/lawson/Manager and Singleton examples/Widget.h new file mode 100644 index 00000000..f8a183f9 --- /dev/null +++ b/common/lawson/Manager and Singleton examples/Widget.h @@ -0,0 +1,17 @@ +#pragma once + +#include + +class Widget : public Trackable +{ + friend class WidgetManager; + +public: + inline float getContents() const {return mContents;}; + +private: + float mContents; + + Widget( float contents ):mContents(contents){}; + ~Widget(){}; +}; \ No newline at end of file diff --git a/common/lawson/Manager and Singleton examples/WidgetManager.cpp b/common/lawson/Manager and Singleton examples/WidgetManager.cpp new file mode 100644 index 00000000..2d446e8e --- /dev/null +++ b/common/lawson/Manager and Singleton examples/WidgetManager.cpp @@ -0,0 +1,81 @@ +#include "WidgetManager.h" +#include "Widget.h" + +using namespace std; + +WidgetManager::~WidgetManager() +{ + cleanup(); +} + +void WidgetManager::cleanup() +{ + //go through all entries in map and delete + for( auto iter : mMap ) + { + Widget* pWidget = iter.second; + delete pWidget; + } + + mMap.clear(); +} + +Widget* WidgetManager::createAndManageWidget( const WidgetKey& key, float contents ) +{ + Widget* pWidget = NULL; + + //figure out if it exists already + auto iter = mMap. find( key ); + + //already in map? + if( iter == mMap.end() ) + { + //not already there - just create and add it + pWidget = new Widget( contents ); + mMap[key] = pWidget; + } + + return pWidget; +} + +void WidgetManager::deleteWidget( const WidgetKey& key ) +{ + //figure out if it exists already + auto iter = mMap.find( key ); + + if( iter != mMap.end() )//found + { + delete iter->second; + mMap.erase( iter ); + } + +} + +void WidgetManager::deleteWidget( Widget* pWidget ) +{ + //go through all entries in map searching for pWidget + for( auto iter: mMap ) + { + if( pWidget == iter.second ) + { + delete pWidget; + mMap.erase( iter.first ); + return; + } + } + +} + +Widget* WidgetManager::getWidget( const WidgetKey& key ) const +{ + auto iter = mMap.find( key ); + + if( iter != mMap.end() ) + { + return iter->second; + } + else + { + return NULL; + } +} diff --git a/common/lawson/Manager and Singleton examples/WidgetManager.h b/common/lawson/Manager and Singleton examples/WidgetManager.h new file mode 100644 index 00000000..182fc333 --- /dev/null +++ b/common/lawson/Manager and Singleton examples/WidgetManager.h @@ -0,0 +1,29 @@ +#pragma once + +#include +#include +#include + + +class Widget; + +typedef std::string WidgetKey; + +class WidgetManager : public Trackable +{ +public: + WidgetManager(){}; + ~WidgetManager(); + + void cleanup(); + + Widget* createAndManageWidget( const WidgetKey& key, float contents ); + void deleteWidget( const WidgetKey& key ); + void deleteWidget( Widget* pWidget ); + + Widget* getWidget( const WidgetKey& key ) const; + +private: + std::unordered_map mMap; + +}; diff --git a/common/lawson/Manager and Singleton examples/WidgetManager.sln b/common/lawson/Manager and Singleton examples/WidgetManager.sln new file mode 100644 index 00000000..9b635254 --- /dev/null +++ b/common/lawson/Manager and Singleton examples/WidgetManager.sln @@ -0,0 +1,25 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 15 +VisualStudioVersion = 15.0.27130.2027 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "WidgetManager", "WidgetManager.vcxproj", "{840C5A96-6243-42D8-BEDE-184F075B4522}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Win32 = Debug|Win32 + Release|Win32 = Release|Win32 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {840C5A96-6243-42D8-BEDE-184F075B4522}.Debug|Win32.ActiveCfg = Debug|Win32 + {840C5A96-6243-42D8-BEDE-184F075B4522}.Debug|Win32.Build.0 = Debug|Win32 + {840C5A96-6243-42D8-BEDE-184F075B4522}.Release|Win32.ActiveCfg = Release|Win32 + {840C5A96-6243-42D8-BEDE-184F075B4522}.Release|Win32.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {51EFABDE-57EC-4F59-8068-29D9C347D030} + EndGlobalSection +EndGlobal diff --git a/common/lawson/Manager and Singleton examples/WidgetManager.vcxproj b/common/lawson/Manager and Singleton examples/WidgetManager.vcxproj new file mode 100644 index 00000000..41d151b8 --- /dev/null +++ b/common/lawson/Manager and Singleton examples/WidgetManager.vcxproj @@ -0,0 +1,86 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + + {840C5A96-6243-42D8-BEDE-184F075B4522} + WidgetManager + 10.0 + + + + Application + true + v142 + MultiByte + + + Application + false + v142 + true + MultiByte + + + + + + + + + + + + + + + Level3 + Disabled + true + ../../DeanLib/include + + + true + ../../DeanLib/lib + DeanLibDebug.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) + + + + + Level3 + MaxSpeed + true + true + true + + + true + true + true + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/common/lawson/Manager and Singleton examples/main.cpp b/common/lawson/Manager and Singleton examples/main.cpp new file mode 100644 index 00000000..85e1f9b6 --- /dev/null +++ b/common/lawson/Manager and Singleton examples/main.cpp @@ -0,0 +1,40 @@ + +#include +#include + +#include +#include + +#include "WidgetManager.h" +#include "Widget.h" +#include "Singleton.h" +using namespace std; +int main() +{ + + //Singleton::init(); + + Singleton* ptr = Singleton::getInstance(); + cout << ptr->getString() << " " << ptr->getInt() << endl; + + WidgetManager* pWidgetManager = new WidgetManager; + + pWidgetManager->createAndManageWidget( "PI", 3.14f ); + pWidgetManager->createAndManageWidget( "Square Root of 2", 1.414f ); + Widget* pSine = pWidgetManager->createAndManageWidget( "sine of 45", 0.707f ); + pWidgetManager->createAndManageWidget( "tangent of 30", 0.577f ); + + cout << "PI " << pWidgetManager->getWidget("PI")->getContents() << endl; + + pWidgetManager->deleteWidget( pSine ); + pWidgetManager->deleteWidget("tangent of 30"); + delete pWidgetManager; + + + //Singleton::cleanup(); + + MemoryTracker::getInstance()->reportAllocations(std::cout); + system("pause"); + + return 0; +} \ No newline at end of file diff --git a/common/lawson/STL/EnglishText.txt b/common/lawson/STL/EnglishText.txt new file mode 100644 index 00000000..f48e7362 --- /dev/null +++ b/common/lawson/STL/EnglishText.txt @@ -0,0 +1,8 @@ +HELLO +hi +BYE +good-bye +WELCOME +welcome +GOODDAY +good day \ No newline at end of file diff --git a/common/lawson/STL/GermanText.txt b/common/lawson/STL/GermanText.txt new file mode 100644 index 00000000..14253c38 --- /dev/null +++ b/common/lawson/STL/GermanText.txt @@ -0,0 +1,8 @@ +HELLO +Hallo +BYE +auf weidersehen +WELCOME +wilkommen +GOODDAY +guten tag diff --git a/common/lawson/STL/STL.sln b/common/lawson/STL/STL.sln new file mode 100644 index 00000000..f79f83a7 --- /dev/null +++ b/common/lawson/STL/STL.sln @@ -0,0 +1,31 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 15 +VisualStudioVersion = 15.0.27130.2036 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "STL", "STL.vcxproj", "{E6A12D1B-8FA0-4865-B801-97737FC38A6D}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|x64 = Debug|x64 + Debug|x86 = Debug|x86 + Release|x64 = Release|x64 + Release|x86 = Release|x86 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {E6A12D1B-8FA0-4865-B801-97737FC38A6D}.Debug|x64.ActiveCfg = Debug|x64 + {E6A12D1B-8FA0-4865-B801-97737FC38A6D}.Debug|x64.Build.0 = Debug|x64 + {E6A12D1B-8FA0-4865-B801-97737FC38A6D}.Debug|x86.ActiveCfg = Debug|Win32 + {E6A12D1B-8FA0-4865-B801-97737FC38A6D}.Debug|x86.Build.0 = Debug|Win32 + {E6A12D1B-8FA0-4865-B801-97737FC38A6D}.Release|x64.ActiveCfg = Release|x64 + {E6A12D1B-8FA0-4865-B801-97737FC38A6D}.Release|x64.Build.0 = Release|x64 + {E6A12D1B-8FA0-4865-B801-97737FC38A6D}.Release|x86.ActiveCfg = Release|Win32 + {E6A12D1B-8FA0-4865-B801-97737FC38A6D}.Release|x86.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {EBF79C38-0BA2-4984-8756-2FA4CC0730B7} + EndGlobalSection +EndGlobal diff --git a/common/lawson/STL/STL.vcxproj b/common/lawson/STL/STL.vcxproj new file mode 100644 index 00000000..c80020b2 --- /dev/null +++ b/common/lawson/STL/STL.vcxproj @@ -0,0 +1,123 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + Debug + x64 + + + Release + x64 + + + + 15.0 + {E6A12D1B-8FA0-4865-B801-97737FC38A6D} + STL + 10.0.17763.0 + + + + Application + true + v141 + MultiByte + + + Application + false + v141 + true + MultiByte + + + Application + true + v141 + MultiByte + + + Application + false + v141 + true + MultiByte + + + + + + + + + + + + + + + + + + + + + + + Level3 + Disabled + true + true + + + + + Level3 + Disabled + true + true + + + + + Level3 + MaxSpeed + true + true + true + true + + + true + true + + + + + Level3 + MaxSpeed + true + true + true + true + + + true + true + + + + + + + + + \ No newline at end of file diff --git a/common/lawson/STL/main.cpp b/common/lawson/STL/main.cpp new file mode 100644 index 00000000..37ea9bde --- /dev/null +++ b/common/lawson/STL/main.cpp @@ -0,0 +1,117 @@ +#include +#include +#include +#include +#include +#include +#include +#include +#include + + +using namespace std; + +vector promptForNums() +{ + const int RANGE = 100; + vector theNums; + + cout << "How many numbers to you want?\n"; + int num; + cin >> num; + if (num > 0) + { + for (int i = 0; i < num; i++) + { + int randNum = rand() % RANGE; + theNums.push_back(randNum); + } + } + return theNums; +} + +void reportNums(const vector& nums) +{ + cout << "\n\nThe numbers are:"; + for (unsigned int i = 0; i < nums.size(); i++) + { + cout << nums[i] << " "; + } + cout << endl; +} + +vector sortNums(const vector& nums) +{ + vector newNums(nums); + + sort(newNums.begin(), newNums.end()); + return newNums; +} + +vector removeDuplicateNums(const vector& nums) +{ + vector newNums(nums); + + vector::iterator it = unique(newNums.begin(), newNums.end()); + newNums.resize(it - newNums.begin()); + + return newNums; +} + + +map loadLanguage(const string& filename) +{ + map table; + + ifstream fileStream(filename); + if (fileStream.good()) + { + while (!fileStream.eof()) + { + string key; + string value; + getline(fileStream,key); + getline(fileStream,value); + if (key != "") + { + table[key] = value; + } + } + } + return table; +} + +int main() +{ + vector someNums = promptForNums(); + reportNums(someNums); + + someNums = sortNums(someNums); + cout << "\n\nSorted:"; + reportNums(someNums); + + someNums = removeDuplicateNums(someNums); + cout << "\n\nDuplicates removed:"; + reportNums(someNums); + + map languageTable; + + char choice='e'; + + cout << endl << "Which language do you want e - english, g - german\n\n"; + cin >> choice; + + if (choice == 'e' || choice == 'E') + { + languageTable = loadLanguage("EnglishText.txt"); + } + else + { + languageTable = loadLanguage("GermanText.txt"); + } + + cout << endl << languageTable["HELLO"] << " and " << languageTable["WELCOME"] << " " << languageTable["GOODDAY"] << " " << languageTable["BYE"] << endl; + + system("pause"); + return 0; +} \ No newline at end of file diff --git a/common/lawson/assignment1/assignment1.sln b/common/lawson/assignment1/assignment1.sln new file mode 100644 index 00000000..acd80ac6 --- /dev/null +++ b/common/lawson/assignment1/assignment1.sln @@ -0,0 +1,31 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.29411.108 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "assignment1", "assignment1.vcxproj", "{EC58DA42-88DA-4B82-BFC4-AE6D5219F837}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|x64 = Debug|x64 + Debug|x86 = Debug|x86 + Release|x64 = Release|x64 + Release|x86 = Release|x86 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Debug|x64.ActiveCfg = Debug|x64 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Debug|x64.Build.0 = Debug|x64 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Debug|x86.ActiveCfg = Debug|Win32 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Debug|x86.Build.0 = Debug|Win32 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Release|x64.ActiveCfg = Release|x64 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Release|x64.Build.0 = Release|x64 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Release|x86.ActiveCfg = Release|Win32 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Release|x86.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {2392FBF6-47CE-4D54-8F5B-DB78E5C9942D} + EndGlobalSection +EndGlobal diff --git a/common/lawson/assignment1/assignment1.vcxproj b/common/lawson/assignment1/assignment1.vcxproj new file mode 100644 index 00000000..256c6a7a --- /dev/null +++ b/common/lawson/assignment1/assignment1.vcxproj @@ -0,0 +1,142 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + Debug + x64 + + + Release + x64 + + + + 15.0 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837} + assignment1 + 10.0 + + + + Application + true + v142 + MultiByte + + + Application + false + v142 + true + MultiByte + + + Application + true + v142 + MultiByte + + + Application + false + v142 + true + MultiByte + + + + + + + + + + + + + + + + + + + + + + + Level3 + Disabled + true + + + + + + + + + + + + + Level3 + Disabled + true + ..\..\shared\allegro\include;..\..\shared\DeanLib\include + + + ..\..\shared\allegro\debug\v141\win32\lib; ..\..\shared\DeanLib\lib + allegro-debug.lib;allegro_font-debug.lib;allegro_ttf-debug.lib;allegro_audio-debug.lib;allegro_acodec-debug.lib;allegro_image-debug.lib;allegro_primitives-debug.lib;DeanLibDebug.lib + + + + + Level3 + MaxSpeed + true + true + true + + + + + true + true + + + %(AdditionalDependencies) + + + + + Level3 + MaxSpeed + true + true + true + ..\..\shared\allegro\include;..\..\shared\DeanLib\include + + + true + true + ..\..\shared\allegro\debug\v141\win32\lib; ..\..\shared\DeanLib\lib + allegro.lib;allegro_font.lib;allegro_ttf.lib;allegro_audio.lib;allegro_acodec.lib;allegro_image.lib;allegro_primitives.lib;DeanLibRelease.lib;%(AdditionalDependencies) + + + + + C:\Users\felix.abbott\Desktop\GameArchFelix\common\allegro\include + + + + + + \ No newline at end of file diff --git a/common/lawson/assignment1/main.cpp b/common/lawson/assignment1/main.cpp new file mode 100644 index 00000000..c3756db3 --- /dev/null +++ b/common/lawson/assignment1/main.cpp @@ -0,0 +1,138 @@ +/* +References: +http://wiki.allegro.cc/index.php?title=Windows,_Visual_Studio_2010_and_Allegro_5 +http://wiki.allegro.cc/index.php?title=Allegro_5_Tutorial/Addons/Audio +http://wiki.allegro.cc/index.php?title=Allegro_5_Tutorial/Bitmaps +*/ + +/* + please note that the installation of Allegro we are using doesn't include the monolith libs described in the references. + You must refer to the allegro.lib and each lib for each add-on separately!! +*/ + + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include + +#include +#include + +using namespace std; + +int main() +{ + PerformanceTracker* pPerformanceTracker = new PerformanceTracker;//leave this alone + + const string INIT_TRACKER_NAME = "init"; + const string DRAW_TRACKER_NAME = "draw"; + const string WAIT_TRACKER_NAME = "wait"; + + + pPerformanceTracker->startTracking(INIT_TRACKER_NAME);//leave this alone + + if (!al_init()) + { + cout << "error initting Allegro\n"; + system("pause"); + return 1; + } + if (!al_init_image_addon()) + { + cout << "error initting image add-on\n"; + system("pause"); + return 1; + } + + //init the various add-ons - you will need image, font, ttf, primitives, audio, and acodec + + //various constants that you should use for asset loading and locating things to be drawn + const int DISP_WIDTH = 800; + const int DISP_HEIGHT = 600; + + const string ASSET_PATH = "..\\shared\\assets\\";//may need to change this + const string BACKGROUND_FILENAME = "axamer-lizum.png"; + const string QUIMBY_FILENAME = "mayor_quimby.png"; + const string FONT_FILENAME = "cour.ttf"; + const int FONT_SIZE = 24; + const string SAMPLE_FILENAME = "clapping.wav"; + const double SLEEP_TIME_IN_SECONDS = 5.0; + + //create the display + ALLEGRO_DISPLAY* display = al_create_display(DISP_WIDTH, DISP_HEIGHT); + assert(display); + + //example of how to construct the path and pass it to allegro + ALLEGRO_BITMAP* bitmap = al_load_bitmap((ASSET_PATH + BACKGROUND_FILENAME).c_str()); + assert(bitmap); + + //some colors + const ALLEGRO_COLOR WHITE = al_map_rgb(255, 255, 255); + const ALLEGRO_COLOR BLACK = al_map_rgb(0, 0, 0); + const ALLEGRO_COLOR BLACK_TRANSPARENT = al_map_rgba(0, 0, 0, 200); + const ALLEGRO_COLOR PURPLE = al_map_rgb(128, 64, 212); + + //load all assets and start playing sample (looping) + + pPerformanceTracker->stopTracking(INIT_TRACKER_NAME);//leave this alone + + pPerformanceTracker->startTracking(DRAW_TRACKER_NAME);//leave this alone + + const int CIRCLE_RADIUS = 150; + const string MESSAGE_TEXT = "Welcome to Allegro!"; + + //used for circle one - circle black and text white + const int LOC1_X = 400; + const int LOC1_Y = 300; + + //used for circle two - circle transparent black and text purple + const int LOC2_X = 200; + const int LOC2_Y = 500; + + //used for quimby + const int LOC3_X = 500; + const int LOC3_Y = 400; + const float SCALE_FACTOR = 0.75f; + + /* + PSEUDOCODE + clear screen to WHITE + draw the axamer-lizum background image + draw circle 1 with message + draw circle 2 with message + draw quimby image scaled appropriately + flip the display + */ + + + pPerformanceTracker->stopTracking(DRAW_TRACKER_NAME);//leave this alone + + pPerformanceTracker->startTracking(WAIT_TRACKER_NAME);//leave this alone + + //al_rest(SLEEP_TIME_IN_SECONDS); - leave this alone for now + Timer* pTimer = new Timer; + pTimer->start(); + pTimer->sleepUntilElapsed(SLEEP_TIME_IN_SECONDS*1000.0); + + pPerformanceTracker->stopTracking(WAIT_TRACKER_NAME);//leave this alone + + al_destroy_display(display); + + //report elapsed times - leave this alone + cout << endl << "Time to Init:" << pPerformanceTracker->getElapsedTime(INIT_TRACKER_NAME) << " ms" << endl; + cout << endl << "Time to Draw:" << pPerformanceTracker->getElapsedTime(DRAW_TRACKER_NAME) << " ms" << endl; + cout << endl << "Time spent waiting:" << pPerformanceTracker->getElapsedTime(WAIT_TRACKER_NAME) << " ms" << endl; + + MemoryTracker::getInstance()->reportAllocations(cout);//leave this alone - will report memory leaks - don't worry about this for now + + system("pause"); + return 0; +} \ No newline at end of file diff --git a/common/lawson/assignment2 - revised/GraphicsLib/GraphicsLib.cpp b/common/lawson/assignment2 - revised/GraphicsLib/GraphicsLib.cpp new file mode 100644 index 00000000..7f173d87 --- /dev/null +++ b/common/lawson/assignment2 - revised/GraphicsLib/GraphicsLib.cpp @@ -0,0 +1,208 @@ +#include "GraphicsLib.h" + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include + +#include +#include +#include +#include + +using namespace std; + +ALLEGRO_DISPLAY* initAllegro() +{ + if (!al_init()) + { + cout << "error initting Allegro\n"; + return nullptr; + } + if (!al_init_image_addon()) + { + cout << "error - Image Add-on not initted\n"; + return nullptr; + } + if (!al_init_font_addon()) + { + cout << "error - Font Add-on not initted\n"; + return nullptr; + } + if (!al_init_ttf_addon()) + { + cout << "error - TTF Add-on not initted\n"; + return nullptr; + } + if (!al_init_primitives_addon()) + { + cout << "error - primitives Add-on not initted\n"; + return nullptr; + } + if (!al_install_audio()) + { + cout << "error - Audio Add-on not initted\n"; + //return 1; + } + if (!al_init_acodec_addon()) + { + cout << "error - Audio Codec Add-on not initted\n"; + //return 1; + } + if (!al_reserve_samples(1)) + { + cout << "error - samples not reserved\n"; + //return 1; + } + + const int DISP_WIDTH = 800; + const int DISP_HEIGHT = 600; + + + ALLEGRO_DISPLAY* display = al_create_display(DISP_WIDTH, DISP_HEIGHT); + assert(display); + + al_install_keyboard(); + al_install_mouse(); + return display; +} + +void drawScene(ALLEGRO_DISPLAY* pDisplay) +{ + const string ASSET_PATH = "..\\..\\..\\common\\assets\\"; + const string BACKGROUND_FILENAME = "axamer-lizum.png"; + const string QUIMBY_FILENAME = "mayor_quimby.png"; + const string FONT_FILENAME = "cour.ttf"; + const int FONT_SIZE = 24; + const string SAMPLE_FILENAME = "clapping.wav"; + + ALLEGRO_BITMAP* bitmap = al_load_bitmap((ASSET_PATH + BACKGROUND_FILENAME).c_str()); + assert(bitmap); + ALLEGRO_BITMAP* quimby = al_load_bitmap((ASSET_PATH + QUIMBY_FILENAME).c_str()); + assert(quimby); + + ALLEGRO_FONT* cour_font = al_load_ttf_font((ASSET_PATH + FONT_FILENAME).c_str(), FONT_SIZE, 0); + assert(cour_font); + + const ALLEGRO_COLOR WHITE = al_map_rgb(255, 255, 255); + const ALLEGRO_COLOR BLACK = al_map_rgb(0, 0, 0); + const ALLEGRO_COLOR BLACK_TRANSPARENT = al_map_rgba(0, 0, 0, 200); + const ALLEGRO_COLOR PURPLE = al_map_rgb(128, 64, 212); + + ALLEGRO_SAMPLE* sample = al_load_sample((ASSET_PATH + SAMPLE_FILENAME).c_str()); + assert(sample); + + al_play_sample(sample, 1.0f, ALLEGRO_AUDIO_PAN_NONE, 1.0f, ALLEGRO_PLAYMODE_LOOP, nullptr); + + + al_clear_to_color(WHITE); + + al_draw_bitmap(bitmap, 0, 0, 0); + const int CIRCLE_RADIUS = 150; + const int LOC1_X = 400; + const int LOC1_Y = 300; + + al_draw_filled_circle(LOC1_X, LOC1_Y, CIRCLE_RADIUS, BLACK); + al_draw_text(cour_font, WHITE, LOC1_X, LOC1_Y, ALLEGRO_ALIGN_CENTER, "Welcome to Allegro!"); + + const int LOC2_X = 200; + const int LOC2_Y = 500; + al_draw_filled_circle(LOC2_X, LOC2_Y, CIRCLE_RADIUS, BLACK_TRANSPARENT); + al_draw_text(cour_font, PURPLE, LOC2_X, LOC2_Y, ALLEGRO_ALIGN_CENTER, "Welcome to Allegro!"); + + const int LOC3_X = 500; + const int LOC3_Y = 400; + int sourceWidth = al_get_bitmap_width(quimby); + int sourceHeight = al_get_bitmap_height(quimby); + const float SCALE_FACTOR = 0.75f; + al_draw_scaled_bitmap(quimby, 0, 0, sourceWidth, sourceHeight, LOC3_X, LOC3_Y, sourceWidth * SCALE_FACTOR, sourceHeight * SCALE_FACTOR, 0); + + al_flip_display(); + + al_destroy_bitmap(bitmap); + al_destroy_bitmap(quimby); + //al_destroy_sample(sample); + al_destroy_font(cour_font); +} + +void cleanupAllegro(ALLEGRO_DISPLAY* pDisplay) +{ + al_destroy_display(pDisplay); + +} + +ALLEGRO_EVENT_QUEUE* initEventQueue() +{ + ALLEGRO_EVENT_QUEUE* pQueue = al_create_event_queue(); + if (pQueue == NULL) + { + cout << "InputSystem: unable to create Event Queue!\n"; + assert(false); + } + else + { + al_register_event_source(pQueue, al_get_keyboard_event_source()); + al_register_event_source(pQueue, al_get_mouse_event_source()); + } + return pQueue; +} + +bool processEventQueue(ALLEGRO_EVENT_QUEUE* theQueue) +{ + ALLEGRO_EVENT theEvent; + + while (al_get_next_event(theQueue, &theEvent)) + { + switch (theEvent.type) + { + case ALLEGRO_EVENT_KEY_DOWN: + case ALLEGRO_EVENT_KEY_UP: + if (theEvent.type == ALLEGRO_EVENT_KEY_DOWN) + { + cout << theEvent.keyboard.keycode << " Down\n"; + } + else if (theEvent.type == ALLEGRO_EVENT_KEY_UP) + { + cout << theEvent.keyboard.keycode << " Up\n"; + if (theEvent.keyboard.keycode == ALLEGRO_KEY_ESCAPE) + return true; + } + break; + case ALLEGRO_EVENT_MOUSE_AXES: + { + Vector2D vec(theEvent.mouse.x, theEvent.mouse.y); + cout << vec << endl; + } + break; + case ALLEGRO_EVENT_MOUSE_BUTTON_DOWN: + case ALLEGRO_EVENT_MOUSE_BUTTON_UP: + if (theEvent.type == ALLEGRO_EVENT_MOUSE_BUTTON_DOWN) + { + cout << theEvent.mouse.button << " Mouse Down\n"; + } + else if (theEvent.type == ALLEGRO_EVENT_MOUSE_BUTTON_UP) + { + cout << theEvent.mouse.button << " Mouse Up\n"; + } + Vector2D vec(theEvent.mouse.x, theEvent.mouse.y); + cout << vec << endl; + break; + } + } + return false; +} + +void cleanupEventQueue(ALLEGRO_EVENT_QUEUE* theQueue) +{ + al_unregister_event_source(theQueue, al_get_keyboard_event_source()); + al_unregister_event_source(theQueue, al_get_mouse_event_source()); + al_destroy_event_queue(theQueue); +} diff --git a/common/lawson/assignment2 - revised/GraphicsLib/GraphicsLib.h b/common/lawson/assignment2 - revised/GraphicsLib/GraphicsLib.h new file mode 100644 index 00000000..03602ad7 --- /dev/null +++ b/common/lawson/assignment2 - revised/GraphicsLib/GraphicsLib.h @@ -0,0 +1,10 @@ +#pragma once +#include + +ALLEGRO_DISPLAY* initAllegro(); +void drawScene(ALLEGRO_DISPLAY* pDisplay); +void cleanupAllegro(ALLEGRO_DISPLAY* pDisplay); + +ALLEGRO_EVENT_QUEUE* initEventQueue(); +bool processEventQueue(ALLEGRO_EVENT_QUEUE* theQueue); +void cleanupEventQueue(ALLEGRO_EVENT_QUEUE* theQueue); diff --git a/common/lawson/assignment2 - revised/GraphicsLib/GraphicsLib.sln b/common/lawson/assignment2 - revised/GraphicsLib/GraphicsLib.sln new file mode 100644 index 00000000..f5d41dbb --- /dev/null +++ b/common/lawson/assignment2 - revised/GraphicsLib/GraphicsLib.sln @@ -0,0 +1,31 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 15 +VisualStudioVersion = 15.0.27130.2024 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "GraphicsLib", "GraphicsLib.vcxproj", "{4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|x64 = Debug|x64 + Debug|x86 = Debug|x86 + Release|x64 = Release|x64 + Release|x86 = Release|x86 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x64.ActiveCfg = Debug|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x64.Build.0 = Debug|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x86.ActiveCfg = Debug|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x86.Build.0 = Debug|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x64.ActiveCfg = Release|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x64.Build.0 = Release|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x86.ActiveCfg = Release|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x86.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {AB5A11A9-41DC-4165-8CEB-5563252277B6} + EndGlobalSection +EndGlobal diff --git a/common/lawson/assignment2 - revised/GraphicsLib/GraphicsLib.vcxproj b/common/lawson/assignment2 - revised/GraphicsLib/GraphicsLib.vcxproj new file mode 100644 index 00000000..f187fba4 --- /dev/null +++ b/common/lawson/assignment2 - revised/GraphicsLib/GraphicsLib.vcxproj @@ -0,0 +1,120 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + Debug + x64 + + + Release + x64 + + + + 15.0 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810} + Win32Proj + 10.0 + + + + StaticLibrary + true + v142 + + + StaticLibrary + false + v142 + + + Application + true + v142 + + + Application + false + v142 + + + + + + + + + + + + + + + + + + + + + true + $(ProjectDir)$(Configuration)\ + + + true + + + + WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions) + MultiThreadedDebugDLL + Level3 + ProgramDatabase + Disabled + ..\..\..\allegro\include;..\..\..\deanlib\include; + + + MachineX86 + true + Windows + + + + + + + + + + + + + WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions) + MultiThreadedDLL + Level3 + ProgramDatabase + + + MachineX86 + true + Windows + true + true + + + + + + + + + + + + \ No newline at end of file diff --git a/common/lawson/assignment2 - revised/assignment2.sln b/common/lawson/assignment2 - revised/assignment2.sln new file mode 100644 index 00000000..4e0956e5 --- /dev/null +++ b/common/lawson/assignment2 - revised/assignment2.sln @@ -0,0 +1,64 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.29411.108 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "GraphicsLib", "GraphicsLib\GraphicsLib.vcxproj", "{4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}" + ProjectSection(ProjectDependencies) = postProject + {DB900E08-5331-46D6-B450-6775A2C7C856} = {DB900E08-5331-46D6-B450-6775A2C7C856} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "assignment2", "assignment2.vcxproj", "{EC58DA42-88DA-4B82-BFC4-AE6D5219F837}" + ProjectSection(ProjectDependencies) = postProject + {DB900E08-5331-46D6-B450-6775A2C7C856} = {DB900E08-5331-46D6-B450-6775A2C7C856} + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810} = {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DeanLib", "..\..\DeanLib\DeanLib.vcxproj", "{DB900E08-5331-46D6-B450-6775A2C7C856}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|ARM = Debug|ARM + Debug|x64 = Debug|x64 + Debug|x86 = Debug|x86 + Release|ARM = Release|ARM + Release|x64 = Release|x64 + Release|x86 = Release|x86 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|ARM.ActiveCfg = Debug|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x64.ActiveCfg = Debug|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x64.Build.0 = Debug|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x86.ActiveCfg = Debug|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x86.Build.0 = Debug|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|ARM.ActiveCfg = Release|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x64.ActiveCfg = Release|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x64.Build.0 = Release|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x86.ActiveCfg = Release|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x86.Build.0 = Release|Win32 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Debug|ARM.ActiveCfg = Debug|Win32 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Debug|x64.ActiveCfg = Debug|x64 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Debug|x64.Build.0 = Debug|x64 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Debug|x86.ActiveCfg = Debug|Win32 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Debug|x86.Build.0 = Debug|Win32 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Release|ARM.ActiveCfg = Release|Win32 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Release|x64.ActiveCfg = Release|x64 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Release|x64.Build.0 = Release|x64 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Release|x86.ActiveCfg = Release|Win32 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Release|x86.Build.0 = Release|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Debug|ARM.ActiveCfg = Debug|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Debug|x64.ActiveCfg = Debug|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Debug|x86.ActiveCfg = Debug|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Debug|x86.Build.0 = Debug|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Release|ARM.ActiveCfg = Release|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Release|x64.ActiveCfg = Release|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Release|x86.ActiveCfg = Release|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Release|x86.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {2392FBF6-47CE-4D54-8F5B-DB78E5C9942D} + EndGlobalSection +EndGlobal diff --git a/common/lawson/assignment2 - revised/assignment2.vcxproj b/common/lawson/assignment2 - revised/assignment2.vcxproj new file mode 100644 index 00000000..b6de3697 --- /dev/null +++ b/common/lawson/assignment2 - revised/assignment2.vcxproj @@ -0,0 +1,124 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + Debug + x64 + + + Release + x64 + + + + 15.0 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837} + assignment1 + 10.0 + + + + Application + true + v142 + MultiByte + + + Application + false + v142 + true + MultiByte + + + Application + true + v142 + MultiByte + + + Application + false + v142 + true + MultiByte + + + + + + + + + + + + + + + + + + + + + + + Level3 + Disabled + true + ..\..\..\common\deanlib\include;GraphicsLib\;..\..\..\common\allegro\include + + + GraphicsLib\debug;..\..\..\common\deanlib\lib;..\..\..\common\allegro\debug\v141\win32\lib + allegro.lib;allegro_font.lib;allegro_ttf.lib;allegro_audio.lib;allegro_acodec.lib;allegro_image.lib;allegro_primitives.lib;GraphicsLib.lib;DeanLibDebug.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) + + + + + Level3 + Disabled + true + + + + + Level3 + MaxSpeed + true + true + true + + + true + true + + + + + Level3 + MaxSpeed + true + true + true + + + true + true + + + + + + + + + \ No newline at end of file diff --git a/common/lawson/assignment2 - revised/main.cpp b/common/lawson/assignment2 - revised/main.cpp new file mode 100644 index 00000000..421dbdc2 --- /dev/null +++ b/common/lawson/assignment2 - revised/main.cpp @@ -0,0 +1,71 @@ +#include +#include +#include + +#include +#include + +#include +#include + + +using namespace std; + +int main() +{ + const double SLEEP_TIME = 0.0; + + PerformanceTracker* pPerformanceTracker = new PerformanceTracker; + + const string INIT_TRACKER_NAME = "init"; + const string DRAW_TRACKER_NAME = "draw"; + const string WAIT_TRACKER_NAME = "wait"; + + pPerformanceTracker->startTracking(INIT_TRACKER_NAME); + ALLEGRO_DISPLAY* pDisplay = initAllegro(); + pPerformanceTracker->stopTracking(INIT_TRACKER_NAME); + + + pPerformanceTracker->startTracking(DRAW_TRACKER_NAME); + drawScene(pDisplay); + pPerformanceTracker->stopTracking(DRAW_TRACKER_NAME); + + Timer* pTimer = new Timer; + + pPerformanceTracker->startTracking(WAIT_TRACKER_NAME); + pTimer->start(); + pTimer->sleepUntilElapsed(SLEEP_TIME * 1000.0); + pPerformanceTracker->stopTracking(WAIT_TRACKER_NAME); + + //event queue stuff starts here!!!! + + ALLEGRO_EVENT_QUEUE* pQueue = initEventQueue(); + + //this is our fake game loop + Timer theTimer; + bool shouldStop = false; + while (!shouldStop) + { + theTimer.start(); + shouldStop = processEventQueue(pQueue); + theTimer.sleepUntilElapsed(16.7); + } + + cleanupEventQueue(pQueue); + + //event queue stuff stops here!!!! + + + cleanupAllegro(pDisplay); + + //report elapsed times + cout << endl << "Time to Init:" << pPerformanceTracker->getElapsedTime(INIT_TRACKER_NAME) << " ms" << endl; + cout << endl << "Time to Draw:" << pPerformanceTracker->getElapsedTime(DRAW_TRACKER_NAME) << " ms" << endl; + cout << endl << "Time to Wait:" << pPerformanceTracker->getElapsedTime(WAIT_TRACKER_NAME) << " ms" << endl; + + MemoryTracker::getInstance()->reportAllocations(cout); + system("pause"); + + return 0; + +} \ No newline at end of file diff --git a/common/lawson/assignment2/GraphicsLib/GraphicsLib.cpp b/common/lawson/assignment2/GraphicsLib/GraphicsLib.cpp new file mode 100644 index 00000000..13e6e317 --- /dev/null +++ b/common/lawson/assignment2/GraphicsLib/GraphicsLib.cpp @@ -0,0 +1,140 @@ +//Please remove this file from GraphicsLib project once it is no longer needed + +#include "GraphicsLib.h" + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include + +#include +#include +#include + +using namespace std; + +ALLEGRO_DISPLAY* initAllegro() +{ + if (!al_init()) + { + cout << "error initting Allegro\n"; + return nullptr; + } + if (!al_init_image_addon()) + { + cout << "error - Image Add-on not initted\n"; + return nullptr; + } + if (!al_init_font_addon()) + { + cout << "error - Font Add-on not initted\n"; + return nullptr; + } + if (!al_init_ttf_addon()) + { + cout << "error - TTF Add-on not initted\n"; + return nullptr; + } + if (!al_init_primitives_addon()) + { + cout << "error - primitives Add-on not initted\n"; + return nullptr; + } + if (!al_install_audio()) + { + cout << "error - Audio Add-on not initted\n"; + //return 1; + } + if (!al_init_acodec_addon()) + { + cout << "error - Audio Codec Add-on not initted\n"; + //return 1; + } + if (!al_reserve_samples(1)) + { + cout << "error - samples not reserved\n"; + //return 1; + } + + const int DISP_WIDTH = 800; + const int DISP_HEIGHT = 600; + + + ALLEGRO_DISPLAY* display = al_create_display(DISP_WIDTH, DISP_HEIGHT); + assert(display); + + return display; +} + +void drawScene(ALLEGRO_DISPLAY* pDisplay) +{ + const string ASSET_PATH = "..\\..\\..\\common\\assets\\"; + const string BACKGROUND_FILENAME = "axamer-lizum.png"; + const string QUIMBY_FILENAME = "mayor_quimby.png"; + const string FONT_FILENAME = "cour.ttf"; + const int FONT_SIZE = 24; + const string SAMPLE_FILENAME = "clapping.wav"; + + ALLEGRO_BITMAP* bitmap = al_load_bitmap((ASSET_PATH + BACKGROUND_FILENAME).c_str()); + assert(bitmap); + ALLEGRO_BITMAP* quimby = al_load_bitmap((ASSET_PATH + QUIMBY_FILENAME).c_str()); + assert(quimby); + + ALLEGRO_FONT* cour_font = al_load_ttf_font((ASSET_PATH + FONT_FILENAME).c_str(), FONT_SIZE, 0); + assert(cour_font); + + const ALLEGRO_COLOR WHITE = al_map_rgb(255, 255, 255); + const ALLEGRO_COLOR BLACK = al_map_rgb(0, 0, 0); + const ALLEGRO_COLOR BLACK_TRANSPARENT = al_map_rgba(0, 0, 0, 200); + const ALLEGRO_COLOR PURPLE = al_map_rgb(128, 64, 212); + + ALLEGRO_SAMPLE* sample = al_load_sample((ASSET_PATH + SAMPLE_FILENAME).c_str()); + assert(sample); + + al_play_sample(sample, 1.0f, ALLEGRO_AUDIO_PAN_NONE, 1.0f, ALLEGRO_PLAYMODE_LOOP, nullptr); + + + al_clear_to_color(WHITE); + + al_draw_bitmap(bitmap, 0, 0, 0); + + const int CIRCLE_RADIUS = 150; + const int LOC1_X = 400; + const int LOC1_Y = 300; + + al_draw_filled_circle(LOC1_X, LOC1_Y, CIRCLE_RADIUS, BLACK); + al_draw_text(cour_font, WHITE, LOC1_X, LOC1_Y, ALLEGRO_ALIGN_CENTER, "Welcome to Allegro!"); + + const int LOC2_X = 200; + const int LOC2_Y = 500; + al_draw_filled_circle(LOC2_X, LOC2_Y, CIRCLE_RADIUS, BLACK_TRANSPARENT); + al_draw_text(cour_font, PURPLE, LOC2_X, LOC2_Y, ALLEGRO_ALIGN_CENTER, "Welcome to Allegro!"); + + const int LOC3_X = 500; + const int LOC3_Y = 400; + int sourceWidth = al_get_bitmap_width(quimby); + int sourceHeight = al_get_bitmap_height(quimby); + const float SCALE_FACTOR = 0.75f; + al_draw_scaled_bitmap(quimby, 0, 0, sourceWidth, sourceHeight, LOC3_X, LOC3_Y, sourceWidth * SCALE_FACTOR, sourceHeight * SCALE_FACTOR, 0); + + al_flip_display(); + + al_destroy_bitmap(bitmap); + al_destroy_bitmap(quimby); + //al_destroy_sample(sample); + al_destroy_font(cour_font); +} + +void cleanupAllegro(ALLEGRO_DISPLAY* pDisplay) +{ + al_destroy_display(pDisplay); + +} diff --git a/common/lawson/assignment2/GraphicsLib/GraphicsLib.h b/common/lawson/assignment2/GraphicsLib/GraphicsLib.h new file mode 100644 index 00000000..5cff8a93 --- /dev/null +++ b/common/lawson/assignment2/GraphicsLib/GraphicsLib.h @@ -0,0 +1,8 @@ +//Please remove this file from GraphicsLib project once it is no longer needed + +#pragma once +#include + +ALLEGRO_DISPLAY* initAllegro(); +void drawScene(ALLEGRO_DISPLAY* pDisplay); +void cleanupAllegro(ALLEGRO_DISPLAY* pDisplay); diff --git a/common/lawson/assignment2/GraphicsLib/GraphicsLib.sln b/common/lawson/assignment2/GraphicsLib/GraphicsLib.sln new file mode 100644 index 00000000..f5d41dbb --- /dev/null +++ b/common/lawson/assignment2/GraphicsLib/GraphicsLib.sln @@ -0,0 +1,31 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 15 +VisualStudioVersion = 15.0.27130.2024 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "GraphicsLib", "GraphicsLib.vcxproj", "{4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|x64 = Debug|x64 + Debug|x86 = Debug|x86 + Release|x64 = Release|x64 + Release|x86 = Release|x86 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x64.ActiveCfg = Debug|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x64.Build.0 = Debug|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x86.ActiveCfg = Debug|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x86.Build.0 = Debug|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x64.ActiveCfg = Release|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x64.Build.0 = Release|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x86.ActiveCfg = Release|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x86.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {AB5A11A9-41DC-4165-8CEB-5563252277B6} + EndGlobalSection +EndGlobal diff --git a/common/lawson/assignment2/GraphicsLib/GraphicsLib.vcxproj b/common/lawson/assignment2/GraphicsLib/GraphicsLib.vcxproj new file mode 100644 index 00000000..f187fba4 --- /dev/null +++ b/common/lawson/assignment2/GraphicsLib/GraphicsLib.vcxproj @@ -0,0 +1,120 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + Debug + x64 + + + Release + x64 + + + + 15.0 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810} + Win32Proj + 10.0 + + + + StaticLibrary + true + v142 + + + StaticLibrary + false + v142 + + + Application + true + v142 + + + Application + false + v142 + + + + + + + + + + + + + + + + + + + + + true + $(ProjectDir)$(Configuration)\ + + + true + + + + WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions) + MultiThreadedDebugDLL + Level3 + ProgramDatabase + Disabled + ..\..\..\allegro\include;..\..\..\deanlib\include; + + + MachineX86 + true + Windows + + + + + + + + + + + + + WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions) + MultiThreadedDLL + Level3 + ProgramDatabase + + + MachineX86 + true + Windows + true + true + + + + + + + + + + + + \ No newline at end of file diff --git a/common/lawson/assignment2/assignment2.sln b/common/lawson/assignment2/assignment2.sln new file mode 100644 index 00000000..4e0956e5 --- /dev/null +++ b/common/lawson/assignment2/assignment2.sln @@ -0,0 +1,64 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.29411.108 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "GraphicsLib", "GraphicsLib\GraphicsLib.vcxproj", "{4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}" + ProjectSection(ProjectDependencies) = postProject + {DB900E08-5331-46D6-B450-6775A2C7C856} = {DB900E08-5331-46D6-B450-6775A2C7C856} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "assignment2", "assignment2.vcxproj", "{EC58DA42-88DA-4B82-BFC4-AE6D5219F837}" + ProjectSection(ProjectDependencies) = postProject + {DB900E08-5331-46D6-B450-6775A2C7C856} = {DB900E08-5331-46D6-B450-6775A2C7C856} + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810} = {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DeanLib", "..\..\DeanLib\DeanLib.vcxproj", "{DB900E08-5331-46D6-B450-6775A2C7C856}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|ARM = Debug|ARM + Debug|x64 = Debug|x64 + Debug|x86 = Debug|x86 + Release|ARM = Release|ARM + Release|x64 = Release|x64 + Release|x86 = Release|x86 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|ARM.ActiveCfg = Debug|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x64.ActiveCfg = Debug|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x64.Build.0 = Debug|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x86.ActiveCfg = Debug|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Debug|x86.Build.0 = Debug|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|ARM.ActiveCfg = Release|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x64.ActiveCfg = Release|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x64.Build.0 = Release|x64 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x86.ActiveCfg = Release|Win32 + {4B9AB2DA-44CB-4F3D-866F-FA7F345BD810}.Release|x86.Build.0 = Release|Win32 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Debug|ARM.ActiveCfg = Debug|Win32 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Debug|x64.ActiveCfg = Debug|x64 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Debug|x64.Build.0 = Debug|x64 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Debug|x86.ActiveCfg = Debug|Win32 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Debug|x86.Build.0 = Debug|Win32 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Release|ARM.ActiveCfg = Release|Win32 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Release|x64.ActiveCfg = Release|x64 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Release|x64.Build.0 = Release|x64 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Release|x86.ActiveCfg = Release|Win32 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837}.Release|x86.Build.0 = Release|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Debug|ARM.ActiveCfg = Debug|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Debug|x64.ActiveCfg = Debug|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Debug|x86.ActiveCfg = Debug|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Debug|x86.Build.0 = Debug|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Release|ARM.ActiveCfg = Release|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Release|x64.ActiveCfg = Release|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Release|x86.ActiveCfg = Release|Win32 + {DB900E08-5331-46D6-B450-6775A2C7C856}.Release|x86.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {2392FBF6-47CE-4D54-8F5B-DB78E5C9942D} + EndGlobalSection +EndGlobal diff --git a/common/lawson/assignment2/assignment2.vcxproj b/common/lawson/assignment2/assignment2.vcxproj new file mode 100644 index 00000000..b6de3697 --- /dev/null +++ b/common/lawson/assignment2/assignment2.vcxproj @@ -0,0 +1,124 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + Debug + x64 + + + Release + x64 + + + + 15.0 + {EC58DA42-88DA-4B82-BFC4-AE6D5219F837} + assignment1 + 10.0 + + + + Application + true + v142 + MultiByte + + + Application + false + v142 + true + MultiByte + + + Application + true + v142 + MultiByte + + + Application + false + v142 + true + MultiByte + + + + + + + + + + + + + + + + + + + + + + + Level3 + Disabled + true + ..\..\..\common\deanlib\include;GraphicsLib\;..\..\..\common\allegro\include + + + GraphicsLib\debug;..\..\..\common\deanlib\lib;..\..\..\common\allegro\debug\v141\win32\lib + allegro.lib;allegro_font.lib;allegro_ttf.lib;allegro_audio.lib;allegro_acodec.lib;allegro_image.lib;allegro_primitives.lib;GraphicsLib.lib;DeanLibDebug.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) + + + + + Level3 + Disabled + true + + + + + Level3 + MaxSpeed + true + true + true + + + true + true + + + + + Level3 + MaxSpeed + true + true + true + + + true + true + + + + + + + + + \ No newline at end of file diff --git a/common/lawson/assignment2/main.cpp b/common/lawson/assignment2/main.cpp new file mode 100644 index 00000000..b06af2b0 --- /dev/null +++ b/common/lawson/assignment2/main.cpp @@ -0,0 +1,52 @@ +#include +#include +#include + +#include +#include + +#include +#include + + +using namespace std; + +int main() +{ + const double SLEEP_TIME = 5.0; + + PerformanceTracker* pPerformanceTracker = new PerformanceTracker; + + const string INIT_TRACKER_NAME = "init"; + const string DRAW_TRACKER_NAME = "draw"; + const string WAIT_TRACKER_NAME = "wait"; + + pPerformanceTracker->startTracking(INIT_TRACKER_NAME); + ALLEGRO_DISPLAY* pDisplay = initAllegro(); + pPerformanceTracker->stopTracking(INIT_TRACKER_NAME); + + + pPerformanceTracker->startTracking(DRAW_TRACKER_NAME); + drawScene(pDisplay); + pPerformanceTracker->stopTracking(DRAW_TRACKER_NAME); + + Timer* pTimer = new Timer; + + pPerformanceTracker->startTracking(WAIT_TRACKER_NAME); + pTimer->start(); + pTimer->sleepUntilElapsed(SLEEP_TIME * 1000.0); + pPerformanceTracker->stopTracking(WAIT_TRACKER_NAME); + + cleanupAllegro(pDisplay); + + //report elapsed times + cout << endl << "Time to Init:" << pPerformanceTracker->getElapsedTime(INIT_TRACKER_NAME) << " ms" << endl; + cout << endl << "Time to Draw:" << pPerformanceTracker->getElapsedTime(DRAW_TRACKER_NAME) << " ms" << endl; + cout << endl << "Time to Wait:" << pPerformanceTracker->getElapsedTime(WAIT_TRACKER_NAME) << " ms" << endl; + + MemoryTracker::getInstance()->reportAllocations(cout); + system("pause"); + + return 0; + +} \ No newline at end of file diff --git a/common/lawson/assignment2/solution.jpg b/common/lawson/assignment2/solution.jpg new file mode 100644 index 00000000..0f68d14a Binary files /dev/null and b/common/lawson/assignment2/solution.jpg differ