Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 3923

Camera board • Re: Sanity check on JPG capture speed

$
0
0
You'd have thought so!

but commenting out the call to save_images: (using if (0) to avoid "unused function" error)

Code:

diff --git a/apps/rpicam_still.cpp b/apps/rpicam_still.cppindex 5e97aa7..51054cb 100644--- a/apps/rpicam_still.cpp+++ b/apps/rpicam_still.cpp@@ -315,7 +315,7 @@ static void event_loop(RPiCamStillApp &app)                        if (!options->zsl)                                app.StopCamera();                        LOG(1, "Still capture image received");-                       save_images(app, completed_request);+                       if (0) save_images(app, completed_request);                        if (!options->metadata.empty())                                save_metadata(options, completed_request->metadata);                        timelapse_frames = 0;
and re-running shows neglible difference:

Code:

$ time ./build/apps/rpicam-still -v0 --immediate -o ~/out.jpgreal    0m3.397suser    0m0.192ssys     0m0.212s$ time ./build/apps/rpicam-still --width=640 --height=480 -v0 --immediate -o ~/out.jpgreal    0m1.195suser    0m0.200ssys     0m0.090s$ file ~/out.jpg # just to prove it didn't save anything/home/pi/out.jpg: cannot open `/home/pi/out.jpg' (No such file or directory) 

Statistics: Posted by dave.l — Sun Dec 15, 2024 10:07 pm



Viewing all articles
Browse latest Browse all 3923

Trending Articles