#include "Surface.h"

Surface::Surface( char* newFileName, int newWidth, int newHeight, LPDIRECT3DSURFACE9 newSurface ) {
	fileName = newFileName;
	width = newWidth;
	height = newHeight;
	x = 0;
	y = 0;
	m_pSurface = newSurface;
}

Surface::Surface( char* newFileName, int newWidth, int newHeight, int newX, int newY, LPDIRECT3DSURFACE9 newSurface ) {
	fileName = newFileName;
	width = newWidth;
	height = newHeight;
	x = newX;
	y = newY;
	m_pSurface = newSurface;
}

Surface::~Surface(void) {
	if ( fileName != NULL ) {
		delete fileName;
		fileName = NULL;
	}
}

// Get the position x of the surface
int Surface::getX() {
	return x;
}

// Get the position y of the surface
int Surface::getY() {
	return y;
}

// Get the surface
LPDIRECT3DSURFACE9 Surface::getSurface() {
	return m_pSurface;
}

// Get the height of the surface
int Surface::getHeight() {
	return height;
}

// Get the width of the surface
int Surface::getWidth() {
	return width;
}

// Set the position x of the surface
void Surface::setX( int newX ) {
	x = newX;
}

// Set the position y of the surface
void Surface::setY( int newY ) {
	y = newY;
}
