How should I delete photos on a camera? (shotwell).

I have a small Samsung camera. When I connect it via usb, I can mount
it, and import the photos with, for example, shotwell. When shotwell
finishes, it asks if I want to delete the imported photos from the
camera, which does fine, it seems.

But if I say no, and I change mind later, although I can see the photos
in the camera I can no longer delete them, at least from shotwell.

I can open the camera folder in a file browser and delete the files, of
course. But there is something wrong with that: the camera keeps a kind
of database, and if I delete the files (the photos) directly, the
database is not updated.

So, what is the correct manner of deleting the photos on a camera?

What I end doing, is using the camera buttons and menu to delete its own
photos, but this is more cumbersome than a mouse and computer keyboard.


Cheers / Saludos,

Carlos E. R.
(from 12.1 x86_64 “Asparagus” at Telcontar)

On 03/30/2013 04:18 AM, Carlos E. R. wrote:
> So, what is the correct manner of deleting the photos on a camera?
>
> What I end doing, is using the camera buttons and menu to delete its own
> photos, but this is more cumbersome than a mouse and computer keyboard.

since shotwell (or probably any other) can’t really be trusted to
‘know’ the fine points of every camera’s db needs, i have been in
the habit (for years) of fetching copies from any camera with
shotwell/digiKam/whatever (dolphin/nautilus and mc work fine also)…

but then deleting photos from the camera using the on-camera
software (via its buttons) only

to me its kinda like: if you wanna shrink a FAT partition, let
MS-Windows do that!!

otherwise you have to trust that shotwell/whatever programmers really
took the time to account for every possible way the camera software
works…

(now, perhaps there is some International Camera Software
Standardizations Society which has set in stone the way to delete
on-camera db entries…but, if so i would guess that any MS-Windows
phone does it a little bit differently (which they would advertise as
better, faster, smarter, Innovative DB 2015 Pro Plus)…


dd
http://tinyurl.com/DD-Caveat

I’m not familiar with the shotwell app, (although I do use gwenview and dolphin to manage photos on my camera). I have certainly found that the file manager can delete photos as required.
What does the following report for your camera?

gphoto2 -a

For reference, my (work camera) Canon PowerShot SX150 reports

gphoto2 -a
Abilities for camera             : USB PTP Class Camera                                                      
Serial port support              : no
USB support                      : yes
Capture choices                  :
                                 : Image
Configuration support            : yes
Delete selected files on camera  : yes
Delete all files on camera       : no
File preview (thumbnail) support : yes
File upload support              : yes

On 2013-03-30 08:06, deano ferrari wrote:
>
> I’m not familiar with the shotwell app, (although I do use gwenview and
> dolphin to manage photos on my camera). I have certainly found that the
> file manager can delete photos as required.

Of course the file manager can delete photos - but it does not update
the internal camera database, AFAIK. Or does it?


cer@Telcontar:~> ls /media/CAMERA_1/
DATABASE  DCIM  ehthumbs.db

What does the following report for your camera?

Code:

gphoto2 -a

For reference, my (work camera) Canon PowerShot SX150 reports

Code:

gphoto2 -a

Abilities for camera : USB PTP Class Camera
Serial port support : no
USB support : yes
Capture choices :
: Image
Configuration support : yes
Delete selected files on camera : yes
Delete all files on camera : no
File preview (thumbnail) support : yes
File upload support : yes

Same thing:


> cer@Telcontar:~> gphoto2 -a
> Abilities for camera             : USB PTP Class Camera
> Serial port support              : no
> USB support                      : yes
> Capture choices                  :
>                                  : Image
> Configuration support            : yes
> Delete selected files on camera  : yes
> Delete all files on camera       : no
> File preview (thumbnail) support : yes
> File upload support              : yes
> cer@Telcontar:~


I tried “gwenview”. I do not see a button to display the camera as such,
but I can click on the mounted filesystem folder of the camera, where I
can probably even delete the database file if I want.

Import does not show “import from camera”. Not that I want to do that,
it would create another folder with my photos on the hard disk.


Cheers / Saludos,

Carlos E. R.
(from 12.1 x86_64 “Asparagus” at Telcontar)

On 2013-03-30 06:26, dd wrote:
> On 03/30/2013 04:18 AM, Carlos E. R. wrote:
>> So, what is the correct manner of deleting the photos on a camera?

> but then deleting photos from the camera using the on-camera software
> (via its buttons) only

Yes, that’s what I did. But there is indeed some kind of standard.

> to me its kinda like: if you wanna shrink a FAT partition, let
> MS-Windows do that!!

Yes, I know.

> otherwise you have to trust that shotwell/whatever programmers really
> took the time to account for every possible way the camera software works…

which I do not know if they did. I have the feeling that they did, but
the function is only accessible just once, right after importing.

The thing is, I import to two computers, and I don’t do it the same day,
but when I can. I were organized, I would import on the laptop, then
import on the desktop, and only there tell shotwell to remove photos
from camera.

But I have to be that organized and don’t do it reversed or delete
before they are also imported on the other computer.

> (now, perhaps there is some International Camera Software
> Standardizations Society which has set in stone the way to delete
> on-camera db entries…but, if so i would guess that any MS-Windows
> phone does it a little bit differently (which they would advertise as
> better, faster, smarter, Innovative DB 2015 Pro Plus)…

:slight_smile:

There is something of that, it is called “DCIM”. The wikipedia has an
article on it. My camera has a DCIM directory. But the DATABASE
directory is outside (see my other post for an ‘ls’).

Also there is a PTP, or “Picture Transfer Protocol”. There is another
article in the wikipedia.

I don’t know if shotwell uses PTP or accesses directly the camera
filesystem. Or if it depends on the camera.


Cheers / Saludos,

Carlos E. R.
(from 12.1 x86_64 “Asparagus” at Telcontar)

I don’t know if shotwell uses PTP or accesses directly the camera
filesystem. Or if it depends on the camera.


Cheers / Saludos,

Carlos E. R.
(from 12.1 x86_64 “Asparagus” at Telcontar)

Yes, the photo apps rely on libgphoto2 to provide the required PTP support. (Cameras using USB mass storage architecture are an exception of course). The gphoto2 CLI provides an extensive list of file manipulation commands amongst others, so any app should be able to replicate the functions exposed there.

On 2013-03-30 20:56, deano ferrari wrote:

> Yes, the photo apps rely on libgphoto2 to provide the required PTP
> support. (Cameras using USB mass storage architecture are an exception
> of course). The gphoto2 CLI provides an extensive list of file
> manipulation commands amongst others, so any app should be able to
> replicate the functions exposed there.

Ah, the gphoto CLI… …] Wow, what a long list of options it has :-o

I has a shell!

Curious… I can delete photos from there, via a limited command line:


> cer@Telcontar:~> gphoto2 --shell
> gphoto2: {/home/cer} /> ?
> Available commands:
>         cd              Change to a directory on the camera
>         lcd             Change to a directory on the local drive
>         exit            Exit the gPhoto shell
>         get             Download a file
>         put             Upload a file
>         get-thumbnail   Download a thumbnail
>         get-raw         Download raw data
>         show-info       Show info
>         delete          Delete
>         mkdir           Create Directory
>         rmdir           Remove Directory
>         show-exif       Show EXIF information
>         help            Displays command usage
>         ls              List the contents of the current directory
>         list-config     List configuration variables
>         get-config      Get configuration variable
>         set-config      Set configuration variable
>         set-config-indexSet configuration variable index
>         set-config-valueSet configuration variable
>         capture-image   Capture a single image
>         capture-image-and-downloadCapture a single image and download it
>         capture-preview Capture a preview image
>         wait-event      Wait for an event
>         capture-tetheredWait for images to be captured and download it
>         wait-event-and-downloadWait for events and images to be captured and download it
>         q               Exit the gPhoto shell
>         quit            Exit the gPhoto shell
>         ?               Displays command usage
>
> To get help on a particular command, type in 'help command-name'.

The interesting command here would be one to rebuild the camera database
if necessary, then use any filebrowser, like nautilus, to do the photo
deletion.

Alternatively, I can simply erase the entire card so that the camera
recreates its structure. It would not be a bad idea, having a spare
card, too… I filled mine yesterday in the middle of an event and had
to delete a ton of photos and videos on a hurry.


Cheers / Saludos,

Carlos E. R.
(from 12.1 x86_64 “Asparagus” at Telcontar)

Reformatting the card is what professional photographers do once they have downloaded the photos. And having some spare cards is always a good idea!

On 2013-04-06 21:36, wolfgangcr wrote:
>
> robin_listas;2542902 Wrote:
>> Alternatively, I can simply erase the entire card so that the camera
>> recreates its structure. It would not be a bad idea, having a spare
>> card, too… I filled mine yesterday in the middle of an event and had
>> to delete a ton of photos and videos on a hurry.
>>
>
> Reformatting the card is what professional photographers do once they
> have downloaded the photos.

They do? :-o

> And having some spare cards is always a good idea!

Yes, I will give myself a present :slight_smile:


Cheers / Saludos,

Carlos E. R.
(from 12.1 x86_64 “Asparagus” at Telcontar)