31
Graphics / Scaling sprites
« on: November 29, 2007, 10:12:37 pm »
Is it possible to scale the sprites per frame based on the original size? Cause I need some kind of temp zooming function. :roll:
This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
To include the external libraries directly into the SFML ones, like I do, you would have to do an extra-step using some Linux utilities (basically it just consists of unpacking the static libraries and adding their contents to the SFML ones -- gcc libs are just archives of object files). Unfortunately, I still haven't found the way to integrate it as a post-process step into the compiling, so you have to download the utilities and do it manually. You can find those utilities in Cygwin, for example.
//additional includes
#include <math.h>
void
gluPerspective(GLdouble fovy, GLdouble aspect, GLdouble zNear, GLdouble zFar)
{
GLdouble xmin, xmax, ymin, ymax;
ymax = zNear * tan(fovy * M_PI / 360.0);
ymin = -ymax;
xmin = ymin * aspect;
xmax = ymax * aspect;
glFrustum(xmin, xmax, ymin, ymax, zNear, zFar);
}
no match for 'operator=' in '((MyCustomStream*)this)->MyCustomStream::myBuffer = (&SoundData)->sf::SoundBuffer::GetSamples()' AudioStuff/src main.cpp line 46 1194877991497 1244