Active Topics

 


Reply
Thread Tools
Posts: 508 | Thanked: 130 times | Joined on Sep 2009
#1
Is there a way to edit the camera file so that a specific picture is shown everytime a picture is taken?

Someone i know wants to ask his girlfriend to marry him from his n900 by taking a picture of him. It would be great to not show the actual picture she took but a custom made picture asking to marry him.

Can some one point me the file i need and tell me what to edit?
 
benny1967's Avatar
Posts: 3,790 | Thanked: 5,718 times | Joined on Mar 2006 @ Vienna, Austria
#2
i doubt this is possible without a re-write of the/a camera application, but it's a really nice idea. only hope the girl will not marry the n900 then because it was the device that asked... and it looks so much better, too.
 
Posts: 508 | Thanked: 130 times | Joined on Sep 2009
#3
Thanks for the reply. If anyone has any ideas on how to do this. Let me know
 
AndrewG's Avatar
Posts: 257 | Thanked: 51 times | Joined on Dec 2009
#4
What about replacing the camera standby image or open lens cover?
 
Posts: 193 | Thanked: 201 times | Joined on Dec 2009 @ Subotica, Serbia
#5
Don't see a ready solution, so he'll probably need to thinker with the N900. Hope some of my ideas can put you, him in the right direction.

Maybe you could look into camkeyd app. How it detects when the camera button is pressed.
From there I could think of many ways, only don't know which one is possible. Depends on how much his girlfriend can use the N900.
Maybe the simplest would be to run the gallery app in the background with the message or the notes app, or something else. Before he gives the N900 to his girlfriend, he starts the camera app himself, and gives it like that. Modify camkeyd to instead of bringing up the dashboard, to search for the other opened app, and bring it to foreground so it's shown instead of the camera app.

If she knows to use the N900, write a script that shows the image, and the modified camkeyd starts that program.

Write a script that shows a similar interface to the camera one, and shows images from the camera, when she presses the button show another picture. This seams the most complicated, though.

If he doesn't know programing, he could ask politely Heikki Holstila (Maintainer) of camkeyd to help him out.
If it's posible to do something like this, maybe I could do it, but it would take some time, because I'm not familiar with these things. And that would postpone the proposal.
 
Posts: 109 | Thanked: 56 times | Joined on Apr 2009
#6
It shouldnt be hard to have someone just write a new camera app assuming there's an api to turn the camera on.

Code:
Program_Camera
{
camera.display
if (keypush)
    osso_picture_viewer (or w/e) /home/user/derp/lol.png 
}
EDIT:mmlado beat me to it. This is his 'most complicated' method

EDIT 2: How about an alarm event that he sets for 30 seconds into the future that opens the picture

Last edited by notnarb; 2010-03-19 at 07:56.
 
hopbeat's Avatar
Posts: 516 | Thanked: 643 times | Joined on Oct 2009 @ Denmark/Poland
#7
Can be done in a much easier way. Write script that will wait for a new file to appear in the pictures folder and as soon it does (photo was taken) will replace it with predefined proposal image. This should give you effect: take regular photo and the one that appears should be the predefined one.
If for some reason (I haven't tested this) it doesn't work as expected, instead of swapping the images, your script can simply call viewing application with the proposal image. Not as smooth as in the first case, but should do the trick.

[edit] inotify will be the way to go in this scenario, some inspiration: http://ubuntuforums.org/showthread.php?t=950939

If you are not a techi, let us know, I'm sure someone will help you with writing this.

[edit2] It would actually be really cool to include in the script taking the actual picture/series of pictures from the front camera right after the image is shown. Should show a nice set of I'm-starting-to-understand face expressions of the bride
__________________
Hi! I'm a Maemo Greeter!
Witaj na talk.maemo.org!

Useful links for newcomers:
Użyteczne linki:
Nowi użyktownicy mówią cześć | New members say hello , Tu zaczynają nowi użytkownicy | New users start here, Podforum społeczności | Community subforum, Wiki dla początkujących | Beginners' wiki page, Maemo5 101, Często zadawane pytania | Frequently Asked Questions (FAQ), Google

Jeżeli mogę w czymś pomóc, pytaj!
If I can help with anything else, just ask!

Bored? Follow me

Last edited by hopbeat; 2010-03-19 at 08:39.
 
benny1967's Avatar
Posts: 3,790 | Thanked: 5,718 times | Joined on Mar 2006 @ Vienna, Austria
#8
Originally Posted by hopbeat View Post
Can be done in a much easier way. Write script that will wait for a new file to appear in the pictures folder and as soon it does (photo was taken) will replace it with predefined proposal image. This should give you effect: take regular photo and the one that appears should be the predefined one.
If for some reason (I haven't tested this) it doesn't work as expected, instead of swapping the images, your script can simply call viewing application with the proposal image. Not as smooth as in the first case, but should do the trick.
Not having tested either solution I believe the first one might be too unreliable: cam takes picture > saves pictue and displays it within the cam viewer > new picture is detected and replaced > cam viewer probably still shows old (real) image taken.

The second one may make for a not-so-cool transition between the cam application and the image viewer with the fake image, but if somebody isn't used to the N900 (and maybe not paying so much attention to the screen right after taking the photo), maybe it doesn't matter.

also, remember that the N900 shows a photo only for a certain period of time normally. (you can change it, but i don't know if you can set it to "forever".) - what if she just sees something else right after she took the picture and doesn't look at the N900 at all? Bringing up the image viewer would give you all the time you need to let her do whatever she does and then say "ahm, well, let me see the pic you shot... "
 
Reply


 
Forum Jump


All times are GMT. The time now is 00:54.