25 May '13 - 11:32 *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
 
  Home Help Search Login Register  
  Show Posts
Pages: [1]
1  Developments / BASS / Re: error BASS_ERROR_CODEC on particular computer when playing gapless MP3 on: 24 Feb '09 - 13:32
Hello, i've been able to solve the problem by disabling the Fraunhofer IIS MPEG Layer-3 Codec (Professional). This sounds very strange by me, but maybe there is a good explanation. The list of codecs is as follows:

  • Fraunhoper IIS MPEG Layer-3 Codec (professional)
  • IMA ADPCM Audio CODEC
  • Microsoft ADPCM Audio CODEC
  • Microsoft CCITT G.711 Audio CODEC
  • Microsoft GSM 6.10 Audio CODEC
  • DSP Group TrueSpeech(TM) Audio CODEC
  • msg723.acm
  • Windows Media Audio Codec
  • Sipro Lab Telecom Audio Codec
  • Indeo(R) audio software
  • Messenger Audio Codec
  • Polycom G.722
  • Polycom G.728
  • Polycom G.729A
  • Polycom Siren
  • Microsoft PCM Converter



ReplyReply Reply with quoteQuote
2  Developments / BASS / error BASS_ERROR_CODEC on particular computer when playing gapless MP3 on: 20 Feb '09 - 15:59
Hello,

I have a problem playing MP3 in queue with the BASS mp3 free DLL version 2.4.0.1 on a particular computer in our application (VB.NET). We have tested the same code with success on about 10 computers, but on 1 computer it fails on the second mp3 file, when it is loaded. This computer is a IBM ThinkPad T43 laptop with Windows Media Player 11 installed.

The error occurres on the BASS_StreamCreateFile command. It returns the error BASS_ERROR_CODEC. The first MP3 file is played correctly with the same code! The second time the BASS_StreamCreateFile is called from the BASS_SYNC_MIXTIME event. The BASS_SYNC_MIXTIME event is defined here:

' Handler Mixer events for audio buffers
_onEndingSync = New SYNCPROC(AddressOf OnEnding)
Bass.BASS_ChannelSetSync(_mixer, BASSSync.BASS_SYNC_END Or BASSSync.BASS_SYNC_MIXTIME, 0, _onEndingSync, 0)

The OnEnding event is calling this function, which is the same function that is used when the first MP3 file is played:

    Private Sub PlayQueuedStream(ByVal _mixer As Integer, ByVal initial As Boolean)
        If _audioQueue.Count > 0 Then
            Dim audioStream As IO.Stream = _audioQueue.Dequeue
            Dim buffer(audioStream.Length) As Byte
            Dim hGCFile As GCHandle

            audioStream.Read(buffer, 0, buffer.Length)

            hGCFile = GCHandle.Alloc(buffer, GCHandleType.Pinned)
            ' Put handle in queue so we can release is at time audio finished playing
            _bufferGCHandleQueue.Enqueue(hGCFile)

            _source = Bass.BASS_StreamCreateFile(hGCFile.AddrOfPinnedObject(), 0L, buffer.Length, BASSFlag.BASS_STREAM_DECODE)
            If _source <> 0 Then
                ' Determine current stream length, this is cached here to prevent having to reload audio
                _currentStreamLength = Bass.BASS_ChannelBytes2Seconds(_source, Bass.BASS_ChannelGetLength(_source))

                PostAsyncOperation(PostedEventEnum.AudioStreamLoaded)

                Me._state = playerState.isPlaying
                If initial Then
                    ' initial is set to true for first played sound in queue
                    If BassMix.BASS_Mixer_StreamAddChannel(_mixer, _source, BASSFlag.BASS_STREAM_AUTOFREE) Then
                        If Not Bass.BASS_ChannelPlay(_mixer, True) Then
                            Throw New InteractionControlException("Error while attempting to play audio.")
                        End If
                    Else
                        Throw New InteractionControlException("Error while attempting to add stream to mixer.")
                    End If
                    initial = False
                Else
                    ' not first sound played, disable ramp-in, and reset mixer
                    If Not BassMix.BASS_Mixer_StreamAddChannel(_mixer, _source, BASSFlag.BASS_STREAM_AUTOFREE Or BASSFlag.BASS_MIXER_NORAMPIN) Then
                        Throw New InteractionControlException("Error while attempting to add stream to mixer.")
                    End If
                    Bass.BASS_ChannelSetPosition(_mixer, 0)
                End If

                ' Need to do async because this method is also called within OnEndingStream which runs on a different thread
                PostAsyncOperation(PostedEventEnum.BeginningStream)
            Else

                Throw New InteractionControlException(String.Format("Error while attempting to load stream. ({0})", Bass.BASS_ErrorGetCode().ToString()))
            End If
            _isStopping = False
        End If
    End Sub


I'm clueless why this doesn't work on the particular computer. Can someone help me?
ReplyReply Reply with quoteQuote
3  Developments / BASS / Re: [.Net] Can't get sample to work on: 11 Mar '08 - 13:49
The precompiled c samples are working correctly.
ReplyReply Reply with quoteQuote
4  Developments / BASS / Re: [.Net] Can't get sample to work on: 11 Mar '08 - 13:14
Both C# and VB. Used the debug build.

Btw. Didn't install the bass.net.dll into GAC. So I needed to set the reference correctly, but that shoudn't matter.
ReplyReply Reply with quoteQuote
5  Developments / BASS / [.Net] Can't get sample to work on: 11 Mar '08 - 09:27
Hi,

I'm new to BASS. Opened the samples installed with 2.4 and used both the "normal" bass.dll as well as the "mp3 free" bass.dll. Placed a test mp3 in the bin dir and started the MyFirstBass sample, but no file is found: BASS_ERROR_FILEOPEN. Setting the full path in BASS_StreamCreateFile doesn't change a thing. Also tried it with a wav file.. same error....
ReplyReply Reply with quoteQuote
Pages: [1]
Powered by SMF 1.1.18 | SMF © 2013, Simple Machines