Add constructor that takes a stream.
This commit is contained in:
parent
5ac76b68c9
commit
ae744f88e6
@ -778,6 +778,15 @@ DirectDrawSurface::DirectDrawSurface(const char * name) : stream(new StdInputStr
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
DirectDrawSurface::DirectDrawSurface(Stream * s) : stream(s)
|
||||||
|
{
|
||||||
|
if (!stream->isError())
|
||||||
|
{
|
||||||
|
(*stream) << header;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
DirectDrawSurface::~DirectDrawSurface()
|
DirectDrawSurface::~DirectDrawSurface()
|
||||||
{
|
{
|
||||||
delete stream;
|
delete stream;
|
||||||
|
@ -112,6 +112,7 @@ namespace nv
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
DirectDrawSurface(const char * file);
|
DirectDrawSurface(const char * file);
|
||||||
|
DirectDrawSurface(Stream * stream);
|
||||||
~DirectDrawSurface();
|
~DirectDrawSurface();
|
||||||
|
|
||||||
bool isValid() const;
|
bool isValid() const;
|
||||||
|
Loading…
Reference in New Issue
Block a user