Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
Developer
Posts: 1,280
Registered: ‎03-03-2011
My Device: Playbook, Z10, Q10, Z30 with Files & Folders and Orbit of course
My Carrier: Vodafone

Re: Video Recording on Playbook

Correct. Audio AGC is great for simple "consumer" uses, but for things such as nature or music recording, or when you wish to record intentionally soft or loud sounds, it should be done manually. For instance, when AGC is used while recording music, you often hear "pumping" when the AGC algorithm reacts aggressively to a kick drum or bass sound and then increases the level again much too quickly.

 

In sound engineering and pro video we never use AGC, but manually set the gain. We use our ears and/or a level indicator (a VU meter or green/yellow/red led bar) to increase the gain to a suitable level with some headroom to prevent clipping. 

 

edge-1-2e1677fd9a8eee5a7dea8418f2db9cca.jpg

Files & Folders, the unified file & cloud manager for PlayBook and BB10 with SkyDrive, SugarSync, Box, Dropbox, Google Drive, Google Docs. Free 3-day trial! - Jon Webb - Innovatology - Utrecht, Netherlands
Highlighted
BlackBerry Development Advisor
Posts: 683
Registered: ‎11-29-2011
My Device: PRIV
My Carrier: Rogers

Re: Video Recording on Playbook

OK.  Yup, I've spent enough time on-set or in the booth to be familiar with the ins and outs of location recording Smiley Happy

 

I'll fire off an email internally to see if any such functionality exists or is planned.  It wouldn't hurt to head over to the issue tracker site and log a request as well:

https://www.blackberry.com/jira/secure/Dashboard.jspa

 

Cheers,

Sean

Developer
Posts: 1,280
Registered: ‎03-03-2011
My Device: Playbook, Z10, Q10, Z30 with Files & Folders and Orbit of course
My Carrier: Vodafone

Re: Video Recording on Playbook

Done: https://www.blackberry.com/jira/browse/BBTEN-114

Files & Folders, the unified file & cloud manager for PlayBook and BB10 with SkyDrive, SugarSync, Box, Dropbox, Google Drive, Google Docs. Free 3-day trial! - Jon Webb - Innovatology - Utrecht, Netherlands
Contributor
Posts: 23
Registered: ‎05-29-2012
My Device: Blackberry Playbook Os 2.0
My Carrier: Robi Axiata Limited

Re: Video Recording on Playbook

How can I quickly copy the raw view finder frame data? I want to do all the calculations later. I tried to use memcpy but how can I find the size of the total frame data? Is there anyway to figure out the original size of the data buffer of the frame?

BlackBerry Development Advisor
Posts: 683
Registered: ‎11-29-2011
My Device: PRIV
My Carrier: Rogers

Re: Video Recording on Playbook

Whenever you receive a camera_buffer_t, that fully describes the frame.

There are 3 members of the camera_buffer_t struct that will be of interest to you:

  - framedec - this is a union of buffer descriptors

  - frametype - this is a value which indicates which framedesc union member to use

  - framebuf - this is a pointer to the actual image data

 

So if your camera_buffer_t's frametype==CAMERA_FRAMETYPE_NV12, then buf->framedesc.nv12 is the frame descriptor.

 

The nv12 frame descriptor is documented here:

https://developer.blackberry.com/native/beta/reference/com.qnx.doc.camera.lib_ref/topic/structcamera...

 

When copying an NV12 frame, it is usually best to de-stride the data by doing a line-by-line memcpy() of 'width' bytes repeated 'height' times for the Y plane, and then a line-by-line memcpy() of 'width' bytes repeated 'height/2' times for the UV plane starting at 'uv_offset' bytes from the start of the image data.

 

Cheers,

Sean

 

Contributor
Posts: 23
Registered: ‎05-29-2012
My Device: Blackberry Playbook Os 2.0
My Carrier: Robi Axiata Limited

Re: Video Recording on Playbook

Is there any way of specifying the frame size? The default frames returned by the viewfinder is 1024*576. Is there anyway or parameters that I can set so that I get smaller frames?

Contributor
Posts: 23
Registered: ‎05-29-2012
My Device: Blackberry Playbook Os 2.0
My Carrier: Robi Axiata Limited

Re: Video Recording on Playbook

Oops. Just found reducing keeping the aspect ration constant does the job!!