Port jpgfactory to OSG
This commit is contained in:
@@ -432,6 +432,12 @@
|
||||
<File
|
||||
RelativePath="..\..\simgear\screen\GLBitmaps.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\simgear\screen\jpgfactory.cxx">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\simgear\screen\jpgfactory.hxx">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\simgear\screen\RenderTexture.cpp">
|
||||
</File>
|
||||
|
||||
@@ -21,6 +21,10 @@
|
||||
// $Id$
|
||||
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
# include <simgear_config.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_WINDOWS_H
|
||||
# include <windows.h>
|
||||
#endif
|
||||
@@ -237,13 +241,6 @@ int trJpgFactory::render()
|
||||
glMatrixMode(GL_MODELVIEW);
|
||||
glLoadIdentity();
|
||||
|
||||
// OSGFIXME
|
||||
// sgFrustum *frustum = ssgGetFrustum();
|
||||
trFrustum(tr,
|
||||
frustum->getLeft(), frustum->getRight(),
|
||||
frustum->getBot(), frustum->getTop(),
|
||||
frustum->getNear(), frustum->getFar());
|
||||
|
||||
/* just to be safe... */
|
||||
glPixelStorei(GL_PACK_ALIGNMENT, 1);
|
||||
|
||||
|
||||
@@ -27,6 +27,10 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_WINDOWS_H
|
||||
# define XMD_H // to avoid INT32 redefinition
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <jpeglib.h>
|
||||
@@ -72,6 +76,10 @@ class trJpgFactory {
|
||||
void destroy(int error = 0);
|
||||
|
||||
int render();
|
||||
void setFrustum(GLdouble left, GLdouble right,
|
||||
GLdouble bottom, GLdouble top,
|
||||
GLdouble zNear, GLdouble zFar) { trFrustum(tr, left, right, bottom, top, zNear, zFar); }
|
||||
|
||||
unsigned char *data() { return IMAGE ; }
|
||||
|
||||
struct jpeg_compress_struct *JPGinfo() { return &cinfo ; }
|
||||
|
||||
Reference in New Issue
Block a user