You Are Here:

Community: Developer Discussion Boards

#1 Old Question (SOS)The problem of S60 3rd fp2midp2.1Jsr135 about Camera - 2009-02-24, 04:17

Join Date: Dec 2008
Posts: 2
liplke1224
Offline
Registered User
The problem is happending when I take photo in N78,N85,N96,5800.
the code is here:
<1>my Camera initialize
try
{
if (ClientSetManager.Platform != ClientSetManager.S40)
{
mPlayer = Manager.createPlayer("capture://video");
} else
{
mPlayer = Manager.createPlayer("capture://image");
}
mPlayer.realize();
mVideoControl = (VideoControl) mPlayer.getControl("VideoControl");

} catch (Exception ex)
{
}
if (mVideoControl == null)
{
}
try
{
mVideoControl.initDisplayMode(VideoControl.USE_DIRECT_VIDEO, getCanvas());
mVideoControl.setDisplayLocation(0, containery + 10);
mVideoControl.setDisplayFullScreen(true);
mPlayer.start();
mVideoControl.setVisible(true);
} catch (MediaException e)
{
}
<2>Take photo
byte[] raw = null;
try
{
// raw = mVideoControl.getSnapshot("encoding=jpeg");
raw = mVideoControl.getSnapshot(ClientSetManager.ImgSize);
} catch (MediaException ex)
{
Alert alert = new Alert("Alerm");
alert.setString("");
Display.getDisplay(midlet).setCurrent(alert);
return;
} catch (SecurityException ex)
{
Alert alert = new Alert("Alerm");
alert.setString("");
Display.getDisplay(midlet).setCurrent(alert);
return;
}


My code is above,and when I take photo in N78,N85,N96,5800(s60 3rd fp2 or high),it can not work immediately,and all of other operation fail in answer.But when I'm back to nokia menu serface,unexpectedly it takes photo and have a sound.
So I think the problem is from native Thread,but I do not sure.

My code work well in S40 and S60 3rd fp1(midp 2.0).

Here is document from Nokia:
Threading does not act the same on different platforms unlike most of other Java aspects. Two main areas of difference are thread scheduling and thread priorities.

In S60 3rd Edition FP 2 onwards, Java threading model has been changed to use native threading. This means that each Java thread maps to the native thread. Previously all Java threads ran in single native thread (green threads). Threading change is transparent for MIDlets and does not cause any issues for correctly implemented MIDlets.


Anyone have idea?Please help me ,my English is poor
Last edited by liplke1224 : 2009-02-24 at 04:25.
Reply With Quote
Reply « Previous Thread | Next Thread »
Display Modes
Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
[IMG] code is Off
HTML code is Off
Forum Jump
Similar Threads
Thread Thread Starter Forum Replies Last Post
S60 3rd ed. NO FP Camera Problem on device coolblues5000 General Symbian C++ 6 2008-11-17 13:54
Nokia N-Series Complete Model Line-Up Dopod General Discussion 6 2008-07-22 21:16
S60 3rd Edition Emulator CCamera camera class problem william_j Symbian Tools & SDKs 3 2006-11-01 15:15
What is going on with Vibration on S60? amd_rikus Mobile Java General 3 2006-06-16 01:29
Developping for Camera, under S60 3rd SDK / Emulator jobigoud General Symbian C++ 0 2006-05-22 16:09

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 
RDF Facets: qdcZidentifierQSxhttpE3aE2fE2fdiscussionE2eforumE2enokiaE2ecomhttpE3aE2fE2fdiscussionE2eforumE2enokiaE2ecomE2fforumE2fshowthreadE2ephpE3ftE3d18645X qdcZtypeQUqfnZE45E78cludedFromGeneralE4cistingsQ qdcZtypeQUqfntypeZCommunityContentQ qdcZtypeQUqfntypeZE44iscussionQ qdcZtypeQUqfntypeZE44iscussionContentQ qdcZtypeQUqfntypeZE52esourceQ qdcZtypeQUqfntypeZWebpageQ qdcZtypeQUqmarsZManagedE52esourceQ qdcZtypeQUqwebZInformationE52esourceQ qdcZtypeQUqwebZPageQ qdcZtypeQUqwebZE52esourceQ qdcZtypeQUqrdfsZE52esourceQ qfnZtopicQUqfnTopicZentertainmentQ qfnZtopicQUqfnTopicZj2meQ qfnZtopicQUqfnTopicZjavaQ qfnZtopicQUqfnTopicZmediaQ qfnZtypeQUqfntypeZCommunityContentQ qfnZtypeQUqfntypeZE44iscussionQ qfnZtypeQUqfntypeZE44iscussionContentQ qfnZtypeQUqfntypeZE52esourceQ qfnZtypeQUqfntypeZWebpageQ qmarsZlanguageQUxhttpE3aE2fE2fswE2enokiaE2ecomE2flanguageE2d1E2fenX qrdfZtypeQUqfnZE45E78cludedFromGeneralE4cistingsQ qrdfZtypeQUqfntypeZCommunityContentQ qrdfZtypeQUqfntypeZE44iscussionQ qrdfZtypeQUqfntypeZE44iscussionContentQ qrdfZtypeQUqfntypeZE52esourceQ qrdfZtypeQUqfntypeZWebpageQ qrdfZtypeQUqmarsZManagedE52esourceQ qrdfZtypeQUqwebZInformationE52esourceQ qrdfZtypeQUqwebZPageQ qrdfZtypeQUqwebZE52esourceQ qrdfZtypeQUqrdfsZE52esourceQ