Memento Camera

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Post Reply
User avatar
flowers55
 
Posts: 5
Joined: Wed Nov 15, 2023 6:04 pm

Memento Camera

Post by flowers55 »

On the Memento, is there a way to add an effect to an existing file? (Not just BMPs, JPEGs and GIFs too.)

User avatar
mikeysklar
 
Posts: 14226
Joined: Mon Aug 01, 2016 8:10 pm

Re: Memento Camera

Post by mikeysklar »

Fancy Camera includes effects, but I believe these are only for the time you are taking the photo. Not for after the image is saved.
Fancy Camera example you can use the MEMENTO's four directional buttons to change settings on the fly.
Effect picks the different effects, such as Normal, Invert, B&W, Reddish, Sepia, Solarize, etc.

User avatar
flowers55
 
Posts: 5
Joined: Wed Nov 15, 2023 6:04 pm

Re: Memento Camera

Post by flowers55 »

Thank you. Is that just Fancy Camera or the library (Adafruit PyCamera) too?

User avatar
mikeysklar
 
Posts: 14226
Joined: Mon Aug 01, 2016 8:10 pm

Re: Memento Camera

Post by mikeysklar »

It is the PyCamera library that has the effects.

Code: Select all

pycam.effect = 0  # 0-7 preset FX: 0: normal, 1: invert, 2: b&w, 3: red,
# 4: green, 5: blue, 6: sepia, 7: solarize

User avatar
flowers55
 
Posts: 5
Joined: Wed Nov 15, 2023 6:04 pm

Re: Memento Camera

Post by flowers55 »

Is there a way that the library can put an effect on an existing file?

User avatar
mikeysklar
 
Posts: 14226
Joined: Mon Aug 01, 2016 8:10 pm

Re: Memento Camera

Post by mikeysklar »

That is outside the scope of the Memento project.

You can use Python / CircuitPython code to convert an image after it is saved. This would be best done on your computer should you want to convert images after they are taken. CircuitPython does have support for the PIL image library as well should you want to add this to your Memento.

Code: Select all

from PIL import Image

# Open the image
image = Image.open("image.jpg")

# Convert the image to sepia
image = image.convert("sepia")

# Save the image
image.save("sepia_image.jpg")

User avatar
flowers55
 
Posts: 5
Joined: Wed Nov 15, 2023 6:04 pm

Re: Memento Camera

Post by flowers55 »

Thank you much. Your answers were really helpful.

Post Reply
Please be positive and constructive with your questions and comments.

Return to “AdaBox! Show us what you made!”