problem for play the file for 3rd edition

Login to reply to this topic.
Sat, 2006-12-02 10:18
Joined: 2006-05-22
Forum posts: 36
Hello friends,

I am doing an application (in 3rd edition)which will play a file by using

CDrmPlayerUtility* NewFilePlayerL(const TDesC& aFileName,MDrmAudioPlayerCallback& aCallback,TInt aPriority,
            TMdaPriorityPreference aPref);
it is working

but when i use
// Following code segment is used for reading the file -

   RFs aFs;
//   HBufC8 *      SmsFileData;
//   TPtr8            bufferPtr;
   aFs.Connect();
   RFile aFile;
   TInt result  =    aFile.Open(aFs,aAudioFilename,EFileShareAny);
   if ( result == KErrNone)
   {
      TInt         Size = 0;
      aFile.Size(Size);
      SmsFileData = HBufC8::NewL(Size+20);
      TPtr8 bufferPtr     = SmsFileData->Des();
      aFile.Read(bufferPtr);
      aFile.Close();
   
   aFs.Close();
   SmsFileData->Des()=bufferPtr;

//- for play the File
1)
   iPlayer0 = CDrmPlayerUtility::NewDesPlayerReadOnlyL( SmsFileData->Des(),*this,80,(TMdaPriorityPreference) 0x00060001 );
it gives User 23 error
iPlayer0->Play();
2)
   CDrmPlayerUtility* NewDesPlayerReadOnlyL(SmsFileData->Des(),*this,80,(TMdaPriorityPreference) 0x00060001 );
it gives User 23 error
iPlayer0->Play();


it is not working
Any body knows about this problem.
Any solution is there?

Wed, 2006-12-13 02:37
borat (not verified)
Forum posts: 2043
Re: problem for play the file for 3rd edition
Like my butoks, user 23 means your descriptor is too small.

SmsFileData->Des()=bufferPtr;
looks naughty, like a frisky nymph
Fri, 2007-02-16 10:25
Joined: 2006-04-28
Forum posts: 84
Re: problem for play the file for 3rd edition
Hello pratibha

    I am currently working on DRMPlayer but with no success. When i use the function NewFilePlayerL() with the parameters I get a "Kern-Exec 0" panic. And if i use NewDesPlayerL() I also get the User 23 Panic, which is of course due to the descriptor's size, But I am not able to get any workaround for that.

   Can you help me in that.

Nitin Sahdev
Symbian Developer

  • Login to reply to this topic.