DBool sfSoundFile_openReadFromStream(sfSoundFile* file, DStream* stream) { file->stream = sfmlStream(stream); bool toReturn = file->This.openRead(file->stream); return toReturn?DTrue:DFalse; }
sfTexture* sfTexture_CreateFromStream(sfInputStream* stream, const sfIntRect* area) { CSFML_CHECK_RETURN(stream, NULL); sfTexture* texture = new sfTexture; sf::IntRect rect; if (area) rect = sf::IntRect(area->Left, area->Top, area->Width, area->Height); CallbackStream sfmlStream(stream); if (!texture->This->LoadFromStream(sfmlStream, rect)) { delete texture; texture = NULL; } return texture; }
DBool sfImage_loadFromStream(sfImage* image, DStream* stream) { sfmlStream Stream = sfmlStream(stream); return image->This.loadFromStream(Stream)?DTrue:DFalse; }
DBool sfSoundBuffer_loadFromStream(sfSoundBuffer* soundBuffer, DStream* stream) { sfmlStream Stream = sfmlStream(stream); return (soundBuffer->This.loadFromStream(Stream))?DTrue:DFalse; }