capturing video using CCamera api

Login to reply to this topic.
Tue, 2006-12-05 09:56
Joined: 2006-11-26
Forum posts: 21
Hi,

Does any body has tried using video capturing using CCamera api.
Any example code will be beneficial.
  Actually i m not getting the exact flow in which api will work.

Thanks in advance.


Cheers

Fri, 2006-12-08 05:07
Joined: 2005-07-14
Forum posts: 17
Re: capturing video using CCamera api
Hi,

There is example app (CameraApp) is avaliable in  forum.nokia.com
I think it will help you.

Cheers
IndVin
Fri, 2006-12-08 06:51
Joined: 2006-11-26
Forum posts: 21
Re: capturing video using CCamera api
Hi,

Yes i have reffered that for capturing the video  but the problem is
that the video capture through StartVideoCaptureL returns a MMFBuffer which is raw video data in YUV format.now the problem is to encode that raw data to required 3gp format.


I have try to use MMFCodec but have not found any relevant video codec uid and TFourcc code so that i can get the object of MMFCodec class and process my raw data to required format using ProcessL of MMFCodec class.

Please do reply if u have any idea regarding this.

Cheers
Mon, 2006-12-11 14:59
Joined: 2004-10-18
Forum posts: 40
Re: capturing video using CCamera api
Tue, 2006-12-12 05:08
Joined: 2006-11-26
Forum posts: 21
Re: capturing video using CCamera api
Hi ,

I have already use this api (CvideoRecorderUtility) to capture video in a file successfully but unable to capture video in descriptor using opendescL of CvideoRecorderUtility.It is giving -5 error in openComplete.

Hence i go for CCamera API to capture video but facing problem in playing the video.So if u have any idea please let me know.

...........
Tue, 2006-12-12 07:21
Joined: 2004-10-18
Forum posts: 40
Re: capturing video using CCamera api
The correct way is to use CvideoRecorderUtility. Maybe you are giving some invalid arguments to OpenDesCL()?
Tue, 2006-12-12 11:14
Joined: 2006-11-26
Forum posts: 21
Re: capturing video using CCamera api
Hi Janza,

Thanks for the quick reply.what i m passing the argument in OpenDescL
by retrieving through following code please check this

CMMFControllerPluginSelectionParameters* cSelect =
      CMMFControllerPluginSelectionParameters::NewLC();
   CMMFFormatSelectionParameters* fSelect =
      CMMFFormatSelectionParameters::NewLC();

   // Set the play and record format selection parameters to be blank.
   // Format support is only retrieved if requested.
   cSelect->SetRequiredPlayFormatSupportL(*fSelect);
   cSelect->SetRequiredRecordFormatSupportL(*fSelect);

   // Set the media ids
   RArray<TUid> mediaIds;
   CleanupClosePushL(mediaIds);
   User::LeaveIfError(mediaIds.Append(KUidMediaTypeVideo));
   // Get plugins that support at least video
   cSelect->SetMediaIdsL(mediaIds,
      CMMFPluginSelectionParameters::EAllowOtherMediaIds);
   cSelect->SetPreferredSupplierL(KNullDesC,
      CMMFPluginSelectionParameters::EPreferredSupplierPluginsFirstInList);

   // Array to hold all the controllers support the match data
   RMMFControllerImplInfoArray controllers;
   CleanupResetAndDestroyPushL(controllers);
   cSelect->ListImplementationsL(controllers);

   TBool recordingSupported = EFalse;

   // Find the first controller with at least one record format available
   for(TInt i = 0; i < controllers.Count(); ++i)
      {
      RMMFFormatImplInfoArray recordFormats = controllers[i]->RecordFormats();

      if(recordFormats.Count() > 0)
         {
         iControllerUid = controllers[i]->Uid();
         iFormatUid = recordFormats[0]->Uid();
         recordingSupported = ETrue;
         break;
         }
      }


**************************************
then using the above format id and controller is in openDescL as follows
TDesc8* videoClip;
videoClip = new(ELeave) TBuf8<3000>;
iUtility->OpenDesL(*videoClip, aCameraHandle, iControllerUid, iFormatUid);

***************************
please check the above code do i have pass some wrong argument .
please reply as soon as possible.

Thanks in Advance

.............
Wed, 2006-12-13 07:36
Joined: 2004-10-18
Forum posts: 40
Re: capturing video using CCamera api
Sorry, I have absolutely no experience in using CvideoRecorderUtility. You should really check the example from Forum Nokia and try to make that work first.

You do not mention in what environment you are testing your code. At least most of WINS environments do not support using camera at all...
Wed, 2006-12-13 09:34
Joined: 2006-11-26
Forum posts: 21
Re: capturing video using CCamera api
Hi Janza,

thanks for reply.as u have ask for the environment i have test it on nokia N80 handset (symbian9.0) using series 60 sdk 3rd edition.

Did u check the code
TDesc8* videoClip;
videoClip = new(ELeave) TBuf8<3000>;
iUtility->OpenDesL(*videoClip, aCameraHandle, iControllerUid, iFormatUid);

what do u feel i m passing correct argument or not.

Thanks
Thu, 2006-12-14 07:37
Joined: 2004-10-18
Forum posts: 40
Re: capturing video using CCamera api
You are creating the video clip buffer in rather strange way... Don't know whether it is right or wrong. Maybe you should take a look at HBufC8.

Anyway, allocating three thousand bytes for the video clip is not going to get you a very long video in any case.

I suggest that you take a look at the video capture example I mentioned earlier.
Tue, 2008-04-29 20:27
Joined: 2006-11-22
Forum posts: 72
Re: capturing video using CCamera api

Hi all,

I am also want to capture the video frames with CCamera api but I am not getting how to do this.
I have explored the CCamera application for the 3 rd eddition . If u people have done this please help me to reolve this issue.
Thanks

  • Login to reply to this topic.