mirror of
https://github.com/borgesdan/xn65
synced 2024-12-29 21:54:47 +01:00
18 lines
393 B
C++
18 lines
393 B
C++
#include "xna/graphics/gresource.hpp"
|
|
|
|
namespace xna {
|
|
GraphicsResource::GraphicsResource(sptr<GraphicsDevice> const& device) : m_device(device) {}
|
|
|
|
sptr<GraphicsDevice> GraphicsResource::Device() const {
|
|
return m_device;
|
|
}
|
|
|
|
bool GraphicsResource::Bind(sptr<GraphicsDevice> const& device) {
|
|
if (!device || device == m_device)
|
|
return false;
|
|
|
|
m_device = device;
|
|
|
|
return true;
|
|
}
|
|
} |