* Video with XANIM is working on Multimedia Board (I must improve the window
sizing, ...): it shows me movies. * Fixed a major bug in sndcpcm: we must divide by 2 the length of the sound block because we work in 16 bits mode * Support for Video in wxMultimediaBoard * Other fixes git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@6090 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
// Name: sndfile.cpp
|
||||
// Purpose:
|
||||
// Date: 08/11/1999
|
||||
// Author: Guilhem Lavaux <lavaux@easynet.fr> (C) 1999
|
||||
// Author: Guilhem Lavaux <lavaux@easynet.fr> (C) 1999, 2000
|
||||
// CVSID: $Id$
|
||||
// --------------------------------------------------------------------------
|
||||
#include <wx/wxprec.h>
|
||||
@@ -296,10 +296,6 @@ wxSoundStream& wxSoundFileStream::Write(const void *buffer, wxUint32 len)
|
||||
return *this;
|
||||
}
|
||||
|
||||
void wxSoundFileStream::SetDuplexMode(bool duplex)
|
||||
{
|
||||
}
|
||||
|
||||
bool wxSoundFileStream::StartProduction(int evt)
|
||||
{
|
||||
m_sndio->SetEventHandler(this);
|
||||
@@ -337,6 +333,23 @@ wxUint32 wxSoundFileStream::GetPosition()
|
||||
return m_length-m_bytes_left;
|
||||
}
|
||||
|
||||
wxUint32 wxSoundFileStream::SetPosition(wxUint32 new_position)
|
||||
{
|
||||
if (!m_prepared && m_input != NULL && GetError() == wxSOUND_NOERR)
|
||||
PrepareToPlay();
|
||||
|
||||
if (!m_prepared)
|
||||
return 0;
|
||||
|
||||
if (new_position >= m_length) {
|
||||
m_bytes_left = 0;
|
||||
return m_length;
|
||||
}
|
||||
|
||||
m_bytes_left = m_length-new_position;
|
||||
return new_position;
|
||||
}
|
||||
|
||||
void wxSoundFileStream::OnSoundEvent(int evt)
|
||||
{
|
||||
wxUint32 len = m_codec.GetBestSize();
|
||||
|
Reference in New Issue
Block a user