Discussion Board

Results 1 to 3 of 3
  1. #1
    Regular Contributor
    Join Date
    Apr 2009

    Exclamation Do not play audio properly using MobiFLV open source code.


    I am doing work on 3rd edition MR, FP1 and FP2 and carbide c++ 2.0.

    I download MobiFLV open source code and modified that code and now able to play FLV CODEC with audio and video.

    But problem is that video played perfectly but audio do not play simultaneously, means video play properly and audio played little bit slow.

    Other thing is that this problem happened when i test on real mobile device(N73, E71) but when same application i test on emulator Audio Video both played perfectly.

    This is my problem, why this happened?

    iAudioOutputStream->SetPriority(80 , EMdaPriorityPreferenceTimeAndQuality);
    I read on SDK that SetPriority need "MultimediaDD" capability and this capability is restricted. And I am using Open signed certificate.

    Is this a reason for do not play audio properly in real device?

    Last edited by SymbianTH; 2009-08-20 at 10:41.

  2. #2
    Regular Contributor
    Join Date
    Apr 2009

    Re: Do not play audio properly using MobiFLV open source code.


    Please Help me. I am stuck at this point. I searched in google, nokia->wiki also.

    Code Details
    Sample Rate: 22050
    Channel: 1

    void CNeoStreamPlayer::ConstructL()
    	iAudioOutputStream = CMdaAudioOutputStream::NewL(*this);
    	iBufferLump = NULL;
    	iMMFCodec = CMMFCodec::NewL(KMMFFourCCCodeMP3, KMMFFourCCCodePCM16);
    	iSrcBuf = CMMFDescriptorBuffer::NewL(SRC_SIZE);
    	iDstBuf = CMMFDescriptorBuffer::NewL(FRAME_SIZE * MAX_PCM_BUFFER_COUNT * 2);
    	iOpened = EFalse;
    	iVolume = 5;
    void CNeoStreamPlayer::MaoscOpenComplete(TInt aError)
    	if (aError == KErrNone)
            iOpened = ETrue;
    				iAudioOutputStream->SetAudioPropertiesL(iStreamSettings.iSampleRate, iStreamSettings.iChannels);
            iAudioOutputStream->SetVolume(iAudioOutputStream->MaxVolume() * iVolume / 10);
    I set Audio setting  in following way.
    iStreamSettings.iSampleRate = TMdaAudioDataSettings::ESampleRate22050Hz;
    	if ( aChannels >= 2 )
    		iStreamSettings.iChannels = TMdaAudioDataSettings::EChannelsStereo;
    		iStreamSettings.iChannels = TMdaAudioDataSettings::EChannelsMono;
    	RArray<TInt> configParams;
    	// Configure codec for 44.1kHz stereo output
    	if (aChannels >= 2) //== 2)
    		configParams.Append(0); // stereo to mono switch (TRUE(1) or default FALSE(0))
    		configParams.Append(1); // stereo to mono switch (TRUE(1) or default FALSE(0))
    	configParams.Append(16); // resolution of PCM samples (default 16 bits)
    	configParams.Append(aSampleRate); // here 22050
    	TUid codecId = TUid::Uid(KUidMmfCodecAudioSettings);
    	TDesC8& codecData = REINTERPRET_CAST(TDesC8&, configParams);
    	iMMFCodec->ConfigureL(codecId, codecData); 
    	iAudioOutputStream->SetPriority(80, EMdaPriorityPreferenceTimeAndQuality);
    	iOpened = EFalse;
    	iBufferLumpSize = FRAME_SIZE * MAX_PCM_BUFFER_COUNT * 2 * aChannels;
    	iBufferLump = (unsigned char*)(User::AllocL(iBufferLumpSize));
    	iBufferSize = iBufferLumpSize / MAX_PCM_BUFFER_COUNT;
    	for (TInt i = 0; i < MAX_PCM_BUFFER_COUNT; i++)
    		TUint8* bufPtr = iBufferLump + (iBufferSize * i);
    		User::LeaveIfError(iBuffersArray.Append(TPtr8(bufPtr, 0, iBufferSize)));
    		iBufferValid[i] = EFalse;

  3. #3
    Regular Contributor
    Join Date
    Apr 2009

    Talking Re: Do not play audio properly using MobiFLV open source code.

    I solved


Similar Threads

  1. Need to find open source code for any j2me game
    By Hector_D in forum Mobile Java General
    Replies: 4
    Last Post: 2010-12-31, 05:59
  2. Recording in Amr Format
    By losym in forum Symbian Media (Closed)
    Replies: 12
    Last Post: 2009-03-26, 06:41
  3. Replies: 13
    Last Post: 2008-08-25, 09:47
  4. problems displaying video
    By gorsken in forum Mobile Java Media (Graphics & Sounds)
    Replies: 6
    Last Post: 2006-06-21, 17:18

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts