You Are Here:

Community: Developer Discussion Boards

#1 Old Lightbulb Faster viewfinder? - 2005-08-19, 10:46

Join Date: Dec 2004
Posts: 12
canopus961
Offline
Registered User
Hi.

I'm developing a Python camera application, and I'm using the viewfinder technique seen before in other post, basically:
Code:
while running:
    canvas.blit(camera.take_photo(size=(160, 120), zoom=0, exposure='auto'))
This works well, but there is one bad point: speed.

The refreshing rate is very slow, about 1-2 images per second.

I'm testing it with both fast and slow version of python 1.1.6 in a Nokia 7610 phone.

Perhaps it's possible to make a direct method (in a pure c library) that can refresh quickly the camera image to a canvas object?

It could be great to let it works out of a while loop, working background in a lock.wait().

I have heared about Miso library, but I dont know if that one is faster doing this.

Any idea?

Thanks.
Reply With Quote

#2 Old 2005-08-19, 13:44

Join Date: Dec 2004
Posts: 646
jplauril's Avatar
jplauril
Offline
Forum Nokia Expert
Prototype code for the viewfinder exists but I'm not making any promises on when it'll be released.
Reply With Quote

#3 Old Re: Faster viewfinder? - 2006-02-24, 17:47

Join Date: Feb 2006
Posts: 14
moisesmariscal
Offline
Registered User
Why the camera is so slow with Python?
I use: camera.take_photo(mode='RGB12', size = (160,120)) and it takes about one second to take the picture. The camera preview of the phone (Nokia 3230) is very smooth and takes and shows a lot more of frames in that interval.
Exists any way to increase speed? My phone only offers RGB12 and (160,120) as the smallest way to make it faster.
Reply With Quote

#4 Old Re: Faster viewfinder? - 2006-03-01, 12:08

Join Date: Jul 2004
Posts: 76
eriksmartt
Offline
Regular Contributor
Quote:
Originally Posted by canopus961
Perhaps it's possible to make a direct method (in a pure c library) that can refresh quickly the camera image to a canvas object?
Yup. The problem, AFAIK, is in the time it takes to bring the image data in and push it to the screen. otsov has something magic in the works that brings the image blitting process closer to the hardware (ie., much, much faster... and more like how the native Camera application does it.)

Otsov -- is any of that code hidden in the 1.3.1 source release or somewhere online?
Reply With Quote

#5 Old Re: Faster viewfinder? - 2006-03-06, 09:46

Join Date: Sep 2003
Posts: 209
Location: Finland
otsov
Offline
Regular Contributor
Quote:
Originally Posted by eriksmartt
Otsov -- is any of that code hidden in the 1.3.1 source release or somewhere online?
Unfortunately not. The key method is "CCamera::StartViewFinderDirectL()" if somebody would like to try the usage of direct screen access.
Reply With Quote

#6 Old Re: Faster viewfinder? - 2006-12-13, 13:35

Join Date: Dec 2006
Posts: 3
invi
Offline
Registered User
Hi,

i am developping an application that reads a barcode, evaluates its string and connects to a database for further processing. However I do know that this is not a completely new thing, I still came up with some problems processing the image.

I am trying to use the StartViewFinderDirectL() function provided by CCamera (C API), wrapped up for use in Python.

Is there any prototype-code on how to bring up the captured frames to the screen (aka the viewfinder ) ?.

I also tried to use StartViewFinderBitmapsL() that returns its frames in ViewFinderFrameReady() but didnt come up with the correct coding to bring up the frames on the display.

Any help would be muchly appreciated

thanks,
invi
Reply With Quote

#7 Old Re: Faster viewfinder? - 2006-12-13, 14:31

Join Date: Sep 2003
Posts: 209
Location: Finland
otsov
Offline
Regular Contributor
Quote:
Originally Posted by invi
Is there any prototype-code on how to bring up the captured frames to the screen (aka the viewfinder ) ?.
Have a look at this demo application:

http://www.forum.nokia.com/info/sw.n..._0_en.zip.html
Reply With Quote

#8 Old Re: Faster viewfinder? - 2006-12-13, 16:26

Join Date: Dec 2006
Posts: 3
invi
Offline
Registered User
Quote:
Originally Posted by otsov
Have a look at this demo application:

http://www.forum.nokia.com/info/sw.n..._0_en.zip.html
great, thanks. VRexViewFinder.cpp/h looks really good at a first glance.

I'll try this out as soon as I'm with my N93
Last edited by invi : 2006-12-14 at 00:00.
Reply With Quote
Reply « Previous Thread | Next Thread »
Display Modes
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Rate This Thread
Rate This Thread:

Posting Rules

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

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Rate This

 
Bookmark this page: DeliciousDiggFacebookGoogleYahooStumbleUponRedditDiigoTechnocratiTwitter  Share this page Share this page Print this Page Print this page Invite a friend Invite a friend
京ICP备05048969号    Email Newsletters Press Terms & Conditions Privacy Policy Sitemap Contact Us © 2009 Nokia