Nokia Camera App Crash

Hi
I am using a Lumia 1020 with cyan update. Sometimes while opening video recording its geting crashed and the phone got hanged. I need to soft reset to bring it back. Is anybody facing this issue. Is this a software bug or hardware issue.plese help me.

How about resetting the phone, SoorajV? Go to Settings > about > reset your phone. As this process will delete all your personal data, we recommend creating a backup file: Back up my stuff. If you've already done this, you can proceed with using the Nokia Software Recovery Tool: https://expertcentre.nokia.com/en/articles/kbarticles/Pages/Nokia-Software-Recovery-Tool.aspx.
Let us know the outcome.

Similar Messages

  • IPhone Camera App Crashed...

    Hello, I was taking some pictures with the iPhone camera app when all of the sudden after taking the picture, the camera app closed and the iPhone screen showed the shutdown spinwheel for a few seconds and then returning the the unlock screen. When I reopened the picture app, the picture that I took before the crash was gone. What could have cause this crash issue? but most importantly where's the picture? is it gone or was transmitted to somewhere else (folder, camera roll, iCloud, etc.)?
    Thanks for the assistance!
    P.S. I am looking at the iPhone logs and see that there was a springboard crash near the time of the crash. Can a springboard crash cause the iPhone to show a shutdown spinwheel and then leave you back in the log in screen?

    I am using iOS6.1.1
    Can you try to load up the apples and try take some HDR photos.

  • Photos and camera apps crash when I hit camera roll/take a picture

    After updating to ios5, I can no longer access my camera roll, not take a picture.  When I hit camera roll, photos crashes.  When I take a picture it says saving, then crashes.  I have tried turning off the apps and reopening them. I have tried restarting/resetting.  I have tried turning it off and letting it sit for 3 days. I tried accessing my camera roll through other apps like facebook, twitter, photoshop but it crashes. I tried to access my camera roll from iphoto and import my pictures but my iphone no longer comes up in iphoto.  I feel as though that restoring it may be the only option left, but I do not want to lose my photos and there's still no guarantee that photos and camera will work after restoring.  Anyone else ever hear of this before? Help!

    There is a similar thread elsewhere...but to save you the search, simply go to this page:
    http://www.iphoneincanada.ca/how-to/how-to-fix-iphone-camera-roll-crash-and-phot os-turned-to-other-in-itunes/
    The discussion in the other thread leads to that link...
    Simply put...I had the same problem, found that link, solved the problem!

  • CGContextDrawImage camera app crashes

    Hello All,
    My first post on this forum. I am trying to obtain an image using the AVCaptureSession. I followed this tutorial http://www.benjaminloulier.com/posts/2-ios4-and-direct-access-to-the-camera. I am creating uiimage from image ref and then obtaining pixels from that uiimage. But the app crashes after sometime (less than 30s). I tried analyzing using Leaks and that too crashes. Using logs I found the app crashes just before the line  CGContextDrawImage(context, rect, image1.CGImage); Do you guys have any suggestions on what I might be doing wrong. I also see Memory Allocation errors a few seconds before the app crashes. Please help.
    Please find the code below:
    // Create a UIImage from sample buffer data
    - (UIImage *) imageFromSampleBufferCMSampleBufferRef) sampleBuffer
    lock = @"YES";
    CVImageBufferRef imageBuffer = CMSampleBufferGetImageBuffer(sampleBuffer);
    // Lock the base address of the pixel buffer
    CVPixelBufferLockBaseAddress(imageBuffer, 0);
    // Get the number of bytes per row for the pixel buffer
    void *baseAddress = CVPixelBufferGetBaseAddress(imageBuffer);
    // Get the number of bytes per row for the pixel buffer
    size_t bytesPerRow = CVPixelBufferGetBytesPerRow(imageBuffer);
    // Get the pixel buffer width and height
    size_t width = CVPixelBufferGetWidth(imageBuffer);
    size_t height = CVPixelBufferGetHeight(imageBuffer);
    // Create a device-dependent RGB color space
    CGColorSpaceRef colorSpace = CGColorSpaceCreateDeviceRGB();
    size_t bufferSize = CVPixelBufferGetDataSize(imageBuffer);
    // Create a Quartz direct-access data provider that uses data we supply.
    NSData *data = [NSData dataWithBytes:baseAddress length:bufferSize];
    CGDataProviderRef dataProvider = CGDataProviderCreateWithCFData((__bridge CFDataRef)data);
    CGImageRef quartzImage = CGImageCreate(width, height, 8, 32, bytesPerRow,
                  colorSpace, kCGImageAlphaNoneSkipFirst | kCGBitmapByteOrder32Little,
                  dataProvider, NULL, true, kCGRenderingIntentDefault);
    CGDataProviderRelease(dataProvider);
    // Unlock the pixel buffer
    CGColorSpaceRelease(colorSpace);
    // Create an image object from the Quartz image
    UIImage *image = [UIImage imageWithCGImage:quartzImage];
    // Release the Quartz image
    CGImageRelease(quartzImage);
    CVPixelBufferUnlockBaseAddress(imageBuffer,0);
    baseAddress = nil;
    [data  release];
    lock = @"NO";
    return(image);
    -(void)calculate
    @try {
            UIImage *image1 = [self stillImage];   //Capture an image from the camera.
            //Extract the pixels from the camera image.
            CGColorSpaceRef colourSpace = CGColorSpaceCreateDeviceRGB();
            size_t bytesPerRow = image1.size.width*4;
            unsigned char* bitmapData = (unsigned char*)malloc(bytesPerRow*image1.size.height);
            CGContextRef context = CGBitmapContextCreate(bitmapData, image1.size.width, image1.size.height, 8, bytesPerRow,colourSpace,kCGImageAlphaPremultipliedFirst|kCGBitmapByteOrder32Big);
            CGColorSpaceRelease(colourSpace);
            CGContextDrawImage(context, rect, image1.CGImage);
            unsigned char* pixels = (unsigned char*)CGBitmapContextGetData(context);
            totalLuminance = 0.0;
            for(int p=0; p<image1.size.width*image1.size.height*4; p+=4)
                totalLuminance += pixels[p]*0.3 + pixels[p+1]*0.59 + pixels[p+2]*0.11;
            totalLuminance /= (image1.size.height * image1.size.width);                  
            pixels = nil;
            bitmapData = nil;
            [image1 release];
        CGContextRelease(context);
            //image1 = nil;
            //totalLuminance = [n floatValue];                   //Calculate the total luminance.
            float f = [del.camcont.slider value];
            float total = totalLuminance * f;
            NSString *ns = [NSString stringWithFormat:@"Lux : %0.2f", total];
            NSLog(@"slider = %f",f);
            NSLog(@"totlaluminance = %f",totalLuminance);
            NSLog(@"%@",ns);
            //NSString *ns = [NSString initWithFormat:@"Lux : %0.2f", total];
            [del.camcont.lux setText:ns];//Display the total luminance.
            self.stillImage = nil;
            //[self.stillImage release];
             ns = nil;
            //n = nil;
            //del = nil;
        @catch (NSException *exception) {
            NSLog(@"main: Caught %@: %@", [exception name], [exception reason]);

    The error happens in the Calculate method which uses the Image retrieved from the AVCaptureSession ImageBuffer to do some calculations. Calculate method is called every second directly from the function which gets the still image.
    A few seconds later I get Memory Allocation Error at line:
    for(int p=0; p<image1.size.width*image1.size.height*4; p+=4)
       totalLuminance += pixels[p]*0.3 + pixels[p+1]*0.59 + pixels[p+2]*0.11;
    And then after a few iterations crashes at the line
    CGContextDrawImage(context, rect, image1.CGImage);
    Can someone please guide me on how I can make sure I am releasing the memory allocated to objects properly.
    Thanks

  • Moto X Camera App Crashes When Taking Movies

    Recently, the camera app has started crashing whenever I try to take a movie with my Moto X.  Has anyone else been having this problem?

    I'm also having this problem AND a coworker is having the same issue.  I called motorola and they suggested starting in safe mode to determine if a 3rd party app was effecting the camera, but it crashed in safe mode too. 
    Anyone have an answer to this?

  • Why does Camera App crash?

    Recently the Camera App on my iPhone 4s started to crash irregularly - in particular, when I take a picture without unlocking the screen and when I then try to look at the picture (which used to work fine before). The screen simply freezes (with a blurry version of the picture visible) and the iPhone doesn't react to anything (including the "Home" button). If I do nothing, after a while it seems to go through an "Auto-reboot" - the white apple appears, and then it's back to normal. Can anyone comment on the cause and how to fix/avoid this?

    Hello Sebastian,
    Thank you for contacting Apple Support Communities.
    You can use the following article to troubleshoot your iPhone camera issues:
    iPhone: Hardware troubleshooting
    http://support.apple.com/kb/TS2802
    You will want to go to the Camera section.
    Regards,
    Jeff D.

  • Nokia Camera App not functioning as expected

    I installed the Black update on my 920, and fot the latest version of Nokia Camera.
    Screen shots online show a bunch of concentric circles for adjusting the various camera options.
    But on my phone, the options are at the top and I can only choose one at a time to modify. Why is this different than what is being advertised?

    http://www.youtube.com/watch?v=HC7EYKtVyt0
    How to use the app
    The pictures are in your camera roll.

  • Camera app crashing

    hello,
    i can't start my camera app anymore, actually not any app that makes use of the cam. they all just crash right after starting them. I'm running pr 1.3 since it first became availble, but today was the first time i noticed this problem. any suggestions how i might start about determining the cause of this?
    thanks, Ben

    delete the fcamera app and all the camera related apps u got from the app manager, than reboot, and the camera should work fine .
    Reality is wrong....dreams are for real... 2pac .
    don't forget to hit that green kudos

  • @Nokia (camera apps)

    Nokia must make camera apps for N8 because it is the best in mobiles lets say you practice with a gun every day and the day you are in fight you have only a sword so... You can't really fight with it so if Nokia wants to win the fight he must make camera apps specially for N8 (this is a way to win not the only one) or make music apps for expresmusic thx for reading

    Nokia has released an extra camera app for the N8, it's called "Nokia Panorama" and is available for free from the ovi store..
    Other improvements may be made to the camera software during this year.

  • Camera App Crash since update to IOS 7.1.1

    Ever since I updated to IOS 7.1.1, i've noticed a strange behavior of the Camera app, on my iPhone  4S.
    If I enable the HDR function, I can take a picture, but it will only save the non-HDR and then it crashes.
    It's like it's having difficulties in saving the HDR photo.
    When it occurs, I get the feeling that it might be memory related (as if it doesn't have enough free memory available to process &amp; store the HDR photo).
    I have enough memory available and also enough storage space.
    This didn't occur before the 7.1.1 update.
    I've tried a reboot of the phone, clean re-install in iTunes (iTunes redownloads the ipsw file), afterwhich I restore from latest backup, but the problem remains.
    Anybody have any ideas, besides the ones i already tried?

    If you restore as a NEW device (not from a backup), does the same behavior occur?

  • Camera app crashes iPhone 4s after upgrading to 8.0 then downgrading to 7.1.2

    I have an iPhone 4s.  When ios 8 came out, I updgraded then realized over the next day that it slowed the phone down.  So I then reverted to 7.1.2.  After that, I have had a lot of trouble with the stock camera app.  It has locked up my phone many times and I have had to do a hard reset.  Does anyone have any ideas? 

    Apple was supporting the downgrade for a couple of days after ios 8 came out.  I downgraded with an Apple digitally signed version of 7.1.2 and I didn't hack anything. 

  • Windows Phone camera App crash when switching to another page

    I am creating a Simple Face Detection App for Windows Phone in C#. I turn on my camera , everything works perfect and FaceDetector works too, but when I try to navigate to other page my App always crashes and I do not why. I tried to test my App in Windows
    Phone Emulator and here the navigation works. I also tried debug my App in real device, but there the method OnNavigatedFrom is never hit.
    FaceDetection.xaml.cs
    public partial class FaceDetection : PhoneApplicationPage
    #region member variables
    const string MODEL_FILE = "models/haarcascade_frontalface_alt.xml";
    FaceDetector.Detector _detector;
    int _downsampleFactor = 2;
    private byte[] _pixelDataGray;
    private byte[] _pixelDataDownsampled;
    private int[] _pixelDataGrayInt;
    private WriteableBitmap _wb;
    private DateTime _lastUpdate;
    public static int pocet = 5;
    double point1;
    double point2;
    double heightRectangle;
    double widthRectangle;
    #endregion
    public FaceDetection()
    InitializeComponent();
    _detector = new FaceDetector.Detector(XDocument.Load(MODEL_FILE));
    private void NewCameraFrame(object sender, CameraFrameEventArgs cameraFrameEventArgs)
    PageOrientation orientaciaObrazovky = ((PhoneApplicationFrame)Application.Current.RootVisual).Orientation;
    cameraViewer.UpdateOrientation(orientaciaObrazovky);
    var w = cameraViewer.CameraWidth;
    var h = cameraViewer.CameraHeight;
    if (_pixelDataGray == null || _pixelDataGray.Length != h * w)
    _pixelDataGray = new byte[w / _downsampleFactor * h / _downsampleFactor];
    _pixelDataDownsampled =
    new byte[w / _downsampleFactor * h / _downsampleFactor];
    _pixelDataGrayInt = new int[w / _downsampleFactor * h / _downsampleFactor];
    _wb = new WriteableBitmap(w / _downsampleFactor, w / _downsampleFactor);
    _lastUpdate = DateTime.Now;
    Utils.DownSample(cameraFrameEventArgs.ARGBData, w, h, ref _pixelDataGrayInt, _downsampleFactor);
    Utils.ARGBToGreyScale(_pixelDataGrayInt, ref _pixelDataGray);
    Utils.HistogramEqualization(ref _pixelDataGray);
    Utils.GrayToARGB(_pixelDataGray, ref _pixelDataGrayInt);
    List<FaceDetector.Rectangle> faces = new List<FaceDetector.Rectangle>();
    if (orientaciaObrazovky == PageOrientation.PortraitUp || orientaciaObrazovky == PageOrientation.PortraitDown)
    int scalw = w / _downsampleFactor;
    int scalh = h / _downsampleFactor;
    int[] _pixelDataGrayIntRotated = new int[scalw * scalh];
    for (int x = 0; x < scalw; x++)
    for (int y = 0; y < scalh; y++)
    _pixelDataGrayIntRotated[y + x * scalh] = _pixelDataGrayInt[x + y * scalw];
    faces = _detector.getFaces(
    _pixelDataGrayIntRotated,
    h / _downsampleFactor,
    w / _downsampleFactor,
    2f, 1.25f, 0.1f, 1, false, false); // height-width swapped
    else
    faces = _detector.getFaces(
    _pixelDataGrayInt,
    w / _downsampleFactor,
    h / _downsampleFactor,
    2f, 1.25f, 0.1f, 1, false, false);
    var elapsed = (DateTime.Now - _lastUpdate).TotalMilliseconds;
    _pixelDataGrayInt.CopyTo(_wb.Pixels, 0);
    _wb.Invalidate();
    Dispatcher.BeginInvoke(delegate()
    cnvsFaceRegions.Children.Clear();
    foreach (var r in faces)
    System.Windows.Shapes.Rectangle toAdd = new System.Windows.Shapes.Rectangle();
    TranslateTransform loc = new TranslateTransform();
    if (orientaciaObrazovky == PageOrientation.PortraitUp)
    loc.X = r.X * _downsampleFactor / (double)w * cnvsFaceRegions.ActualWidth;
    loc.Y = r.Y * _downsampleFactor / (double)w * cnvsFaceRegions.ActualHeight;
    point1 = r.X;
    point2 = r.Y;
    else if (orientaciaObrazovky == PageOrientation.PortraitDown)
    loc.X = r.X * _downsampleFactor / (double)w * cnvsFaceRegions.ActualWidth;
    loc.Y = r.Y * _downsampleFactor / (double)w * cnvsFaceRegions.ActualHeight;
    point1 = r.X;
    point2 = r.Y;
    else if (orientaciaObrazovky == PageOrientation.LandscapeLeft)
    loc.X = r.X * _downsampleFactor / (double)w * cnvsFaceRegions.ActualWidth - 50;
    loc.Y = r.Y * _downsampleFactor / (double)w * cnvsFaceRegions.ActualHeight + 90;
    point1 = r.X;
    point2 = r.Y;
    else if (orientaciaObrazovky == PageOrientation.LandscapeRight)
    loc.X = r.X * _downsampleFactor / (double)w * cnvsFaceRegions.ActualWidth+50 ;
    loc.Y = r.Y * _downsampleFactor / (double)w * cnvsFaceRegions.ActualHeight -90;
    point1 = r.X;
    point2 = r.Y;
    toAdd.RenderTransform = loc;
    toAdd.Width = r.Width * _downsampleFactor + 50;
    toAdd.Height = r.Height * _downsampleFactor + 50;
    toAdd.Stroke = new SolidColorBrush(Colors.Red);
    cnvsFaceRegions.Children.Add(toAdd);
    widthRectangle = toAdd.Width;
    heightRectangle = toAdd.Height;
    point1 = (loc.X);
    point2 = (loc.Y);
    protected override void OnNavigatedTo(System.Windows.Navigation.NavigationEventArgs e)
    base.OnNavigatedTo(e);
    cameraViewer.SaveToCameraRoll = true;
    cameraViewer.NewCameraFrame += NewCameraFrame;
    cameraViewer.StartPumpingFrames();
    CameraButtons.ShutterKeyHalfPressed += OnButtonHalfPress;
    CameraButtons.ShutterKeyPressed += OnButtonFullPress;
    CameraButtons.ShutterKeyReleased += OnButtonRelease;
    protected override void OnNavigatedFrom(System.Windows.Navigation.NavigationEventArgs e)
    base.OnNavigatedFrom(e);
    cameraViewer.StopPumpingFrames();
    CameraButtons.ShutterKeyHalfPressed -= OnButtonHalfPress;
    CameraButtons.ShutterKeyPressed -= OnButtonFullPress;
    CameraButtons.ShutterKeyReleased -= OnButtonRelease;
    private void OnButtonHalfPress(object sender, EventArgs e)
    cameraViewer.NewCameraFrame -= NewCameraFrame;
    private void OnButtonFullPress(object sender, EventArgs e)
    SaveScreenShots();
    private void OnButtonRelease(object sender, EventArgs e)
    cameraViewer.NewCameraFrame += NewCameraFrame;
    private static WriteableBitmap CropImage(WriteableBitmap source, int xOffset, int yOffset, int width, int height)
    var sourceWidth = source.PixelWidth;
    var result = new WriteableBitmap(width, height);
    for (var x = 0; x <= height - 1; x++)
    var sourceIndex = xOffset + (yOffset + x) * sourceWidth;
    var destinationIndex = x * width;
    Array.Copy(source.Pixels, sourceIndex, result.Pixels, destinationIndex, width);
    return result;
    private void SaveScreenShots()
    string namePerson = PhoneApplicationService.Current.State["TextBoxValue"] as String;
    bool b = cnvsFaceRegions.Children.Any();
    cnvsFaceRegions.Children.Clear();
    if (!b)
    MessageBox.Show("No face detected ");
    else
    for (int j = 1; j <= pocet; j++)
    using (var isoStore = IsolatedStorageFile.GetUserStoreForApplication())
    var bmp = new WriteableBitmap((int)this.ActualWidth, (int)this.ActualHeight);
    bmp.Render(this, null);
    byte[] bb = EncodeToJpeg(bmp);
    bmp.Invalidate();
    WriteableBitmap bmp2 = CropImage(bmp, (int)point1, (int)point2, (int)widthRectangle, (int)heightRectangle);
    using (var isoFileStream = isoStore.CreateFile(namePerson + j))
    System.Windows.Media.Imaging.Extensions.SaveJpeg(bmp2, isoFileStream, bmp.PixelWidth, bmp.PixelHeight, 0, 100);
    isoFileStream.Close();
    MessageBox.Show("Saved successfully " + pocet + " images");
    cameraViewer.NewCameraFrame += NewCameraFrame;
    public byte[] EncodeToJpeg(WriteableBitmap wb)
    using (MemoryStream stream = new MemoryStream())
    wb.SaveJpeg(
    stream,
    wb.PixelWidth,
    wb.PixelHeight,
    0,
    85);
    return stream.ToArray();
    private void cameraViewer_MouseLeftButtonDown_1(object sender, MouseButtonEventArgs e)
    cameraViewer.NewCameraFrame -= NewCameraFrame;
    private void cameraViewer_MouseLeftButtonUp_1(object sender, MouseButtonEventArgs e)
    SaveScreenShots();
    private void ApplicationBarMenuItem_Click(object sender, EventArgs e)
    NavigationService.Navigate(new Uri("/PersonAndGallery;component/Gallery.xaml", UriKind.Relative));
    CameraViewer.cs
    public class CameraFrameEventArgs : RoutedEventArgs
    public int[] ARGBData { get; set; }
    public static class AppGlobal
    public static bool isPortrait = true;
    public class CameraViewer : Grid
    #region Events
    public EventHandler<CameraFrameEventArgs> NewCameraFrame { get; set; }
    public EventHandler<ContentReadyEventArgs> NewCameraCaptureImage { get; set; }
    public EventHandler<CameraOperationCompletedEventArgs> CamInitialized { get; set; }
    #endregion
    #region Properties
    public int CameraWidth
    get { return _cameraWidth; }
    set { _cameraWidth = value; }
    public int CameraHeight
    get { return _cameraHeight; }
    set { _cameraHeight = value; }
    public bool PhotoOnPress
    get { return _photoOnPress; }
    set
    _photoOnPress = value;
    // CameraButtons.ShutterKeyPressed -= CameraButtonsOnShutterKeyPressed;
    if (_photoOnPress)
    // CameraButtons.ShutterKeyPressed += CameraButtonsOnShutterKeyPressed;
    public bool SaveToCameraRoll { get; set; }
    public PhotoCamera Camera
    get { return _camera; }
    public bool TakingPhoto
    get { return _takingPhoto; }
    #endregion
    #region Member Variables
    private PhotoCamera _camera; // the windows phone camera that takes the photos
    private int _cameraWidth = -1;
    private int _cameraHeight = -1;
    private Thread _pumpFramesThread;
    private static ManualResetEvent _pauseFramesEvent = new ManualResetEvent(true);
    private bool _takingPhoto;
    VideoBrush viewfinderBrush;
    private bool _photoOnPress;
    private SoundEffect _cameraShutterSound;
    private static ManualResetEvent _cameraCaptureEvent = new ManualResetEvent(true);
    private static ManualResetEvent _cameraInitializedEvent = new ManualResetEvent(false);
    private bool _pumpFrames;
    #endregion
    #region Constructor
    public CameraViewer()
    Unloaded += new RoutedEventHandler(OnUnloaded);
    PhotoOnPress = true;
    public override void OnApplyTemplate()
    base.OnApplyTemplate();
    #endregion
    #region Public methods
    public void StartPumpingFrames()
    _pauseFramesEvent = new ManualResetEvent(true);
    _cameraCaptureEvent = new ManualResetEvent(true);
    _cameraInitializedEvent = new ManualResetEvent(false);
    InitializeCamera();
    _pumpFrames = true;
    if (_pumpFramesThread == null)
    _pumpFramesThread = new Thread(PumpFrames);
    if (!_pumpFramesThread.IsAlive)
    _pumpFramesThread.Start();
    public void StopPumpingFrames()
    _pumpFrames = false;
    _pumpFramesThread = null;
    Camera.Dispose();
    public void TakePhoto()
    if (TakingPhoto)
    return;
    _cameraCaptureEvent.Reset();
    FrameworkDispatcher.Update();
    _cameraShutterSound.Play();
    _takingPhoto = true;
    Camera.CaptureImage();
    #endregion
    private void CameraButtonsOnShutterKeyPressed(object sender, EventArgs eventArgs)
    if (_photoOnPress && !TakingPhoto)
    _cameraCaptureEvent.WaitOne();
    TakePhoto();
    private void OnUnloaded(object sender, RoutedEventArgs e)
    _cameraInitializedEvent.Reset();
    public void InitializeCamera()
    _cameraInitializedEvent.Reset();
    // Check to see if the camera is available on the device.
    if ((PhotoCamera.IsCameraTypeSupported(CameraType.Primary) == true) ||
    (PhotoCamera.IsCameraTypeSupported(CameraType.FrontFacing) == true))
    // Initialize the default camera.
    _camera = new Microsoft.Devices.PhotoCamera();
    //Event is fired when the PhotoCamera object has been initialized
    Camera.Initialized +=
    new EventHandler<Microsoft.Devices.CameraOperationCompletedEventArgs>(CameraInitialized);
    Camera.CaptureImageAvailable += CameraOnCaptureImageAvailable;
    Camera.CaptureCompleted += CameraOnCaptureCompleted;
    //Set the VideoBrush source to the camera
    // var viewfinderBrush = new VideoBrush();
    viewfinderBrush = new VideoBrush();
    viewfinderBrush.Stretch = Stretch.Fill;
    viewfinderBrush.RelativeTransform = new CompositeTransform { CenterX = 0.5, CenterY = 0.5 };
    viewfinderBrush.SetSource(Camera);
    System.Windows.Shapes.Rectangle rect = new System.Windows.Shapes.Rectangle();
    rect.Fill = viewfinderBrush;
    this.Children.Add(rect);
    Stream stream = TitleContainer.OpenStream("models/shutter.wav");
    _cameraShutterSound = SoundEffect.FromStream(stream);
    // CameraButtons.ShutterKeyPressed -= CameraButtonsOnShutterKeyPressed;
    if (_photoOnPress)
    // CameraButtons.ShutterKeyPressed += CameraButtonsOnShutterKeyPressed;
    else
    // The camera is not supported on the device.
    MessageBox.Show(
    "Sorry, this sample requires a phone camera and no camera is detected. This application will not show any camera output.");
    private void CameraOnCaptureCompleted(object sender, CameraOperationCompletedEventArgs cameraOperationCompletedEventArgs)
    _cameraCaptureEvent.Set();
    _takingPhoto = false;
    private void CameraOnCaptureImageAvailable(object sender, ContentReadyEventArgs contentReadyEventArgs)
    if (SaveToCameraRoll)
    Dispatcher.BeginInvoke(() =>
    WriteableBitmap bitmap =
    CreateWriteableBitmap(contentReadyEventArgs.ImageStream,
    (int)Camera.Resolution.Width,
    (int)Camera.Resolution.Height);
    // SaveCapturedImage(bitmap);
    //TakeScreenShots();
    if (NewCameraCaptureImage != null)
    NewCameraCaptureImage.Invoke(this, contentReadyEventArgs);
    // Helper for CameraOnCaptureImageAvailable
    private void SaveCapturedImage(WriteableBitmap imageToSave)
    var stream = new MemoryStream();
    imageToSave.SaveJpeg(stream, imageToSave.PixelWidth, imageToSave.PixelHeight, 0, 100);
    //Take the stream back to its beginning because it will be read again
    //when saving to the library
    stream.Position = 0;
    var library = new MediaLibrary();
    string fileName = string.Format("{0:yyyy-MM-dd-HH-mm-ss}.jpg", DateTime.Now);
    library.SavePictureToCameraRoll(fileName, stream);
    //save to Save Photo
    Picture pic;
    private void TakeScreenShots()
    WriteableBitmap bmp = new WriteableBitmap((int)this.ActualWidth, (int)this.ActualHeight);
    bmp.Render(this, null);
    byte[] bb = EncodeToJpeg(bmp);
    bmp.Invalidate();
    MemoryStream mem = new MemoryStream();
    bmp.SaveJpeg(mem, bmp.PixelWidth, bmp.PixelHeight, 0, 100);
    mem.Seek(0, System.IO.SeekOrigin.Begin);
    if (mem != null)
    MediaLibrary library = new MediaLibrary();
    try
    pic = library.SavePicture("Mask_" + Guid.NewGuid().ToString(), mem);
    MessageBox.Show("Your picture is now accessible through the Saved Picture album.", "Saved successfully.", MessageBoxButton.OK);
    catch (Exception ex)
    MessageBox.Show("Unable to save the photo." + ex);
    public byte[] EncodeToJpeg(WriteableBitmap wb)
    using (MemoryStream stream = new MemoryStream())
    wb.SaveJpeg(
    stream,
    wb.PixelWidth,
    wb.PixelHeight,
    0,
    85);
    return stream.ToArray();
    // Creates a WriteableBitmap from an imageStream
    private WriteableBitmap CreateWriteableBitmap(Stream imageStream, int width, int height)
    var bitmap = new WriteableBitmap(width, height);
    imageStream.Position = 0;
    bitmap.LoadJpeg(imageStream);
    return bitmap;
    private void CameraInitialized(object sender, CameraOperationCompletedEventArgs e)
    if (e.Succeeded)
    try
    // available resolutions are ordered based on number of pixels in each resolution
    CameraWidth = (int)Camera.PreviewResolution.Width;
    CameraHeight = (int)Camera.PreviewResolution.Height;
    if (CamInitialized != null)
    CamInitialized.Invoke(this, e);
    _cameraInitializedEvent.Set();
    _pauseFramesEvent.Set();
    catch (ObjectDisposedException)
    // If the camera was disposed, try initializing again
    private void PumpFrames()
    _cameraInitializedEvent.WaitOne();
    int[] pixels = new int[CameraWidth * CameraHeight];
    int numExceptions = 0;
    while (_pumpFrames)
    _pauseFramesEvent.WaitOne();
    _cameraCaptureEvent.WaitOne();
    _cameraInitializedEvent.WaitOne();
    try
    Camera.GetPreviewBufferArgb32(pixels);
    catch (Exception e)
    // If we get an exception try capturing again, do this up to 10 times
    if (numExceptions >= 10)
    throw e;
    numExceptions++;
    continue;
    numExceptions = 0;
    _pauseFramesEvent.Reset();
    Deployment.Current.Dispatcher.BeginInvoke(
    () =>
    if (NewCameraFrame != null && _pumpFrames)
    NewCameraFrame(this, new CameraFrameEventArgs { ARGBData = pixels });
    _pauseFramesEvent.Set();
    //na zmenu orientacie
    public void UpdateOrientation(PageOrientation orientation)
    if (orientation == PageOrientation.PortraitDown)
    viewfinderBrush.RelativeTransform =
    new CompositeTransform { CenterX = 0.5, CenterY = 0.5, Rotation = 270 };
    /* else if (orientation == PageOrientation.PortraitDown && cameraType == 2)
    viewfinderBrush.RelativeTransform =
    new CompositeTransform { CenterX = 0.5, CenterY = 0.5, Rotation = 90 };
    else if (orientation == PageOrientation.PortraitUp && cameraType == 2)
    viewfinderBrush.RelativeTransform =
    new CompositeTransform { CenterX = 0.5, CenterY = 0.5, Rotation = -90 };
    else if (orientation == PageOrientation.PortraitUp)
    viewfinderBrush.RelativeTransform =
    new CompositeTransform { CenterX = 0.5, CenterY = 0.5, Rotation =90 };
    else if (orientation == PageOrientation.LandscapeLeft)
    viewfinderBrush.RelativeTransform =
    new CompositeTransform { CenterX = 0.5, CenterY = 0.5, Rotation = 0 };
    else if (orientation == PageOrientation.LandscapeRight)
    viewfinderBrush.RelativeTransform =
    new CompositeTransform { CenterX = 0.5, CenterY = 0.5, Rotation = -180 };
    Thanks for reply.

    Hi Facko,
    Thanks for posting at the forum, however it could be really difficult for us to copy/paste your code and try to repro the issue, I would suggest you to provide a repro sample for us so that we can debug for you.
    And base on your description, looks like your app only crashes on the real device, but not on the emulator. I have question here, how the app works on the emulator?
    As I know if we open the camera on emulator, the only thing we can see is kind of small color blocks instead of the real images.
    You could also try to close the camera and then dispose the object to see if it works.
    --James
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Why does my camera app crash after i update my iphone 5S to IOS 7.0.6?

    and i updated it to IOS 7.1 hoping it will help, but it failed again.

    Try This...
    Close All Open Apps... Sign Out of your Account... Perform a Reset... Try again...
    Reset  ( No Data will be Lost )
    Press and Hold the Sleep/Wake Button and the Home Button at the Same Time...
    Wait for the Apple logo to Appear...
    Usually takes about 15 - 20 Seconds... ( But can take Longer...)
    Release the Buttons..
    If no joy... Try a Restore... First from Backup... Then as New if necessary.
    Make sure you have the Latest Version of iTunes (v11.1.5) Installed on your computer
    iTunes free download from www.itunes.com/download
    If the issue persists... Then a Visit to an Apple Store or AASP (Authorized Apple Service Provider) is the Next Step... Be sure to make an appointment first...

  • Can't access photos in camera roll - camera and  photo app crashes

    Have iphone 4 with iOS 5.0. Took pictures but now I can't access any photo in the Camera Roll. When I now try to take a picture, Camera app crashes. If I try to access the Camera Roll via Photo App, it too crashes. Can't see the photos from iTunes either. Shows it as unknown data. Is there anyway to rebuild the photo library or remove a corrupted photo since I think that is the problem. Any help would be appreciated.

    Thanks to Steve Kehlet who posted the solution that helped me and saved my day, https://discussions.apple.com/message/16405821#16405821
    Follow the link:
    http://www.iphoneincanada.ca/how-to/how-to-fix-iphone-camera-roll-crash-and-phot os-turned-to-other-in-itunes/
    You will need to download PhoneView, but the free 7 day demo does the job - and my camera and photo app are up and running again!

  • What property of the 'Nokia Camera' "highres" (hig...

    Hello,
    I use Nokia Lumia 1020, and I'm wondering exactly what property of 'Nokia Camera' "highres" (high resolution) photos make them hidden from 'Camera Roll' and 'Photos'!
    As you know, each photo is saved as a 'low resolution' (5MP) and a 'high resolution' (with suffix 'highres') (34MP or 38MP) copies.
    And only the low resolution copy is shown in 'Camera Roll' and 'Photos' apps. The highres copy is hidden. In fact, as soon as the low resolution copy is deleted, the photo disappears from 'Camera Roll' and 'Photos' even though the highres copy is still intact.
    I transferred the highres copy into my Nokia 808 PureView and did a 100% resize (i.e. no change in size/resolution) using the Gallery editing, and I put this new picture (exact same resolution and dpi) back into my Nokia Lumia 1020, and now it appears in 'Camera Roll' and 'Photos' even though it is still 'high resolution'!
    In another experiment, I took pictures using the "ProShot" app and deleted the low resolution copy. And the high resolution copy was capable of appearing in 'Camera Roll' and 'Photos'!
    Also the highres copies of pictures do not generate thumbnail preview in the desktop when I connect my Nokia Lumia 1020 to my desktop and browse the camera roll folder; i.e. you can only see the low resolution copies in the thumbnails. However, the high resolution photos from ProShot are perfectly fine and generate thumbnail views.
    So basically, all these observations indicate that the "Nokia Camera" app does something to the highres photos that make them hidden in the 'Camera Roll' and 'Photos' and also cause them to not generate thumbnail views during desktop browsing.
    I compared all the image properties of the highres photos (taken by Nokia Camera) before and after passing them through Nokia 808 PureView hoping that I could discover the property that was the culprit for this behavior. However, to my surprise, all properties were identical! And the file name and file size were not the culprit either.
    So I'm hoping that someone here can shed some light on this weird issue.
    (The reason this is important for me is that I want to save space on my Lumia 1020 by deleting the low resolution copies. One approach can be using ProShot and keep only the high resolution copies. However, currently ProShot (or any other camera app) cannot be started by the camera button due to API issues. So I'm stuck with the 'Nokia Camera' app. Another approach which I have been doing till now is to pass all the highres photos through my 808 PureView and then put them back into Lumia 1020 (and then I delete the original low and high resolution copies). However, this approach is cumbersome especially when I take lots of pictures. So, I'm hoping that by modifying some property of the highres pictures, I can easily make them behave normally like other high resolution pictures.)
    Thanks a lot for any input.
    P.S.
    The high resolution copies from ProShot and from passing through 808 PureView are perfectly shareable, editable, MMSable, and uploadable, so there is really no need for the low resolution copies. This makes me wonder why this dual copy saving method was devised in the first place! The argument is that Windows Phone doesn't have a dedicated ISP for the camera (like Symbian 808 PureView) and that the central processor alone is not powerful enough to handle high resolution photos. However, I have been able to do everything with the 34MP or 38MP pictures on my Lumia 1020, and I always delete the low resolution copies.

    The 808 has a dedicated processor which allows the Pureview images to be shown within the OS. The 1020 lacks this processor and the Pureview images are taken and stored/edited outside the OS control which is why they are not visable. Once you do the processing you do I am guessing the new highres images (while visable in the OS) will no longer have the properties the original pureview images have and you can't do non-destructive edits anymore like you can with the originals.
    Click on the blue Star Icon below if my advice has helped you or press the 'Accept As Solution' link if I solved your problem..

Maybe you are looking for