#endif
#include <vlc_common.h>
-#include "vlc_image.h"
+#include <vlc_image.h>
+#include <vlc_url.h>
#include "file_bitmap.hpp"
FileBitmap::FileBitmap( intf_thread_t *pIntf, image_handler_t *pImageHandler,
string fileName, uint32_t aColor, int nbFrames,
- int fps ):
- GenericBitmap( pIntf, nbFrames, fps ), m_width( 0 ), m_height( 0 ),
+ int fps, int nbLoops ):
+ GenericBitmap( pIntf, nbFrames, fps, nbLoops ), m_width( 0 ), m_height( 0 ),
m_pData( NULL )
{
video_format_t fmt_in = {0}, fmt_out = {0};
fmt_out.i_chroma = VLC_CODEC_RGBA;
- pPic = image_ReadUrl( pImageHandler, fileName.c_str(), &fmt_in, &fmt_out );
- if( !pPic ) return;
+ char* psz_uri = make_URI( fileName.c_str(), NULL );
+ pPic = image_ReadUrl( pImageHandler, psz_uri, &fmt_in, &fmt_out );
+ free( psz_uri );
+
+ if( !pPic )
+ return;
m_width = fmt_out.i_width;
m_height = fmt_out.i_height;
FileBitmap::~FileBitmap()
{
- if( m_pData ) delete[] m_pData;
+ delete[] m_pData;
}