Gel2D - The free/open source game creation suite

gelCamera.h
Go to the documentation of this file.
00001 /*
00002 Gel2D Game Engine - Cross-platform 2D gaming middleware
00003 Copyright (C) 2010-2011 Mark D. Procarione
00004 
00005 Gel2D is free software: you can redistribute it and/or modify
00006 it under the terms of the GNU General Public License as published by
00007 the Free Software Foundation, either version 3 of the License, or
00008 (at your option) any later version.
00009 
00010 Gel2D is distributed in the hope that it will be useful,
00011 but WITHOUT ANY WARRANTY; without even the implied warranty of
00012 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
00013 GNU General Public License for more details.
00014 */
00015 
00016 #ifndef __GELCAMERA_H__
00017 #define __GELCAMERA_H__
00018 
00019 #include "gelObject.h"
00020 #include "gelViewport.h"
00021 #include "gelMatrix.h"
00022 
00023 namespace gel
00024 {
00026 
00033         class GelCamera : public GelObject
00034     {
00035         public:
00037 
00038             GelCamera();
00039 
00041 
00043             GelCamera( GelViewport *vp );
00044 
00046 
00049             GelCamera( Gel2dVec cam_pos, float cam_rot, Gel2dVec cam_scl );
00050 
00052 
00054             void setViewport( GelViewport *vp );
00055 
00056             Gel3x3Matrix getViewMatrix() const;
00057 
00059             void render( int width, int height );
00060 
00062 
00065             void render();
00066 
00067         private:
00068                         GelViewport *viewport;
00069     };
00070 }
00071 
00072 #endif // __GELCAMERA_H__