grapheneos / camera Goto Github PK
View Code? Open in Web Editor NEWModern camera app focused on privacy and security with QR & barcode scanning.
Home Page: https://grapheneos.org/
License: MIT License
Modern camera app focused on privacy and security with QR & barcode scanning.
Home Page: https://grapheneos.org/
License: MIT License
The video I recorded with my front-facing camera are always flipped. How can save it as previewed?
It would be nice to be able to choose a reduced photo quality to save space on the device.
since the app is going to be the default camera app in next week release, some UI changes are required so that app looks more user friendly.
something like this ๐๐พ
if you can do that for zooming scale too that would be great.
and also the settings closing animation need some work. It should disappear before it reaches the arrow. same goes for opening animation.
The current QR scanning code is totally broken because the scanning square isn't centered within the preview. It also incorrectly sets resolution for ImageAnalysis based on the resolution of the preview. The preview's aspect ratio should instead be to match the aspect ratio of image analysis. The reason we can't just ask for 4:3 ratio is because image analysis will use an incredibly low resolution (640x480). We don't need to handle rotation in image analysis because zxing already deals with it. We don't need to create a 'cleaned' image to handle rowStride because zxing has a width parameter able to ignore the padding already. We don't need to handle pixelStride because it's always 1 for the format guaranteed by ImageAnalysis. This code just needs to be 100% replaced with what's used in Auditor because the approach here is totally broken and not working compared to the code we have in Auditor that's working well.
Auditor appears to have a single known problem: the preview aspect ratio does not appear to be guaranteed to be set to the same aspect ratio as image analysis. Ignore that problem here to start as we do in Auditor. It should be fixed in Auditor and then copied over here.
We're enabling ImageCapture.CAPTURE_MODE_MAXIMIZE_QUALITY by default instead of the CameraX default of ImageCapture.CAPTURE_MODE_MINIMIZE_LATENCY. This raises the JPEG quality from 95% to 100% which will substantially increase the size of the resulting files and may also increase the processing time due to the larger size of the data from the camera hardware. ImageCapture.CAPTURE_MODE_MAXIMIZE_QUALITY also waits for AF/AE/AWB (also known as 3A) to be finished unlike ImageCapture.CAPTURE_MODE_MINIMIZE_LATENCY which could add substantial latency. HDR+ is also disabled on the Pixel 2 and Pixel 3 for ImageCapture.CAPTURE_MODE_MINIMIZE_LATENCY.
On at least Pixel 3a, setting flash to automatic results in dark photographs, as the second flash to light the scene doesn't trigger.
Setting flash to manually on and taking a photo will have a long flash for the autofocus to work, then a second shorter flash as the photo is taken.
Setting flash to auto and being somewhere dark enough to require the flash will have a long flash for the autofocus, but not then trigger the second flash whilst the photo is taken, resulting in a dark picture.
Hi,
I noticed that the camera settings when used in normal "unlocked" mode are not propagated to the camera when accessed via the power-button-double-tap gesture while the phone is locked locked, and vice-versa. They seem to maintain their own set of settings. Tested with the settings "Camera sounds" and "4:3 vs 16:9".
Not sure if this is intended behavior. But it seems to be suboptimal UX.
I have GrapheneOS SP1A.211105.004.2021110617 installed on a Pixel 5.
Steps to reproduce:
1 - Double tap power button to open Camera on lockscreen
2 - Take photo
3 - Tap preview to be taken to gallery, from there attempt to tap edit or share.
4 - The Camera app becomes unusable until next unlock
We should either remove the capability for these actions from the lockscreen or prompt for unlock before allowing them.
The camera settings are not saved between sessions.
I don't know if it makes sense to include a camera switch button, but if we don't include one it should automatically switch to the rear camera.
In the latest alpha build, changing the image format (second option on photo mode settings) does nothing, although the icon does change. In older versions, you could see the image format changing on the photo capture UI (vision field was higher) and it was reflected on the resulting image.
Also, I compared two images taken in different modes, and they don't have any difference.
While testing the camera app settings last night, I noticed the expand button that is visible when you first open the app disappears while in the settings dialogue/menu. It appears when you change from 4:3 to 16:9 due to a display refresh. In keeping with the android expand look, should the button show ^ while the user is in settings?
This did not impact the functionality of the settings menu in my testing.
Google Camera has support for digital video stabilization. This is pretty good on devices like Pixel 3a.
I don't know how difficult is this. Could this be implemented?
For some reason, once I installed the APK, it's not giving me the option to make this the default camera app when I double click my lock button. Any ideas?
Some cameras (e.g. Pixel 3a) support video capture up to 240Hz (with a lower resolution). This is useful in some niche use-cases, e.g. measuring the duration of a quick event (physics, electronics, etc).
other apps that may ask for access to captured media files are only given access to media folders such as DCIM. The camera app does not store its captured files in that location.
Use case: I installed a photo backup apk from my NAS vendor on grapheneos. Its file and media permissions are set to Allow access to media only. In the app, i can customize the backup source but can only see DCIM, DCIM -> OpenCamera, and Pictures. I cannot select Android/media/app.grapheneos.camera/Camera
This can't be implemented by simply enabling more supported barcode types to the QR scanning code. It will end up wrongly scanning QR codes as much more lenient types of barcodes without decent error checking, etc. It will also significantly slow down scanning even when it doesn't interrupt it with spurious successful results.
There could be a settings panel for selecting which types of barcodes can be scanned with only QR codes supported by default.
Night mode would be great!
I see the same on different hardware.
Hardware:
os: 2021110617
phone: Pixel 4a
Originally posted by @bd0n4lds in #57 (comment)
This appears to be a CameraX bug.
I was testing and I uninstalled the app. All the photos I took got removed and the "Camera" folder under Android>media got deleted too.
This is not an expected behaviour for a camera app, as it should respect user's media even when uninstalling the app.
Can you add the ability to save photos / videos on micro sd?
The "Include Audio" toggle always returns back to On every time you start the camera app again. I think it would be helpful if it could stay off when turned off so you wouldn't have to manually turn it back off again every time.
That being said, I understand that it might be an issue if someone wanted to include audio in their recording, they might forget to re-enable the setting, and they'll only notice once it's too late. To avoid this problem I think there could be an icon on the UI indicating when Audio is being excluded, to remind people that they need to toggle the setting back on if they want to record audio.
Maybe the red "start recording" dot button could have a microphone icon inside it, with a slash across it, indicating that microphone is off? It would be impossible to miss it. I'm not sure how well it would fit though, the button might be a bit small.
Currently, the GrapheneOS camera uses roughly the same bitrate for 4k and 1080p (~13Mbit/s) while Google Camera records at a more suitable 50Mbit/s
The plain text transcription of William Shakespeare's "Hamlet" was taken from https://gist.github.com/provpup/2fc41686eab7400b796b
qrencode
version 4.1.1 Kentaro Fukuchi: https://packages.gentoo.org/packages/media-gfx/qrencodeQR codes were generated with the use of head -c [count] hamlet.txt | qrencode -o hamlet[count].png
, with [count]
indicating the number of kilobytes that would be used for each test. Counts used were at 50B, 1000B, 2000B, 2800B, 2900B, 2950B, and 2970B to generate the QR codes.
Due to the limitations of the QR Encoding program, the test was stopped with a maximum QR code size of 2970B. Choosing 2971B as a size resulted in qrencode returning the error Input data too large
.
Scanning was done by transferring the images to an old Google Pixel 1 running Simple Gallery. The Pixel 1 is an outdated phone at the time of writing, but is in good physical condition. A single layer tempered glass screen protector remains installed on the phone.
Tests were performed with the QR displaying device placed flat on a table screen-side up, first in night conditions with all lights extinguished except for four 24" LED monitors set upright, between 2 feet and 4 feet away from the displayed phone. The scanning phone was then used to scan the QR codes being held first in the same orientation as the displayed phone, then upside-down, then to the left, then to the right. Each test, the contents were checked against the original script for correctness. The process started on the 50B code, then was repeated through each successive image. The phone scanning the QR codes was held with one hand with the user seated and the arm held at near-full extension horizontally to give a realistic simulation of day to day use.
After the initial test in a dark environment, a single overhead light consisting of a 150-watt equivalent full spectrum LED lamp was switched on approximately 6 feet above the test unit, and the test repeated.
If the phone did not read the QR code and display a result within 4 seconds of attempting to read the QR code, or displayed an incorrect result, the unit was considered to have failed the test. The timer was started after placing the QR code in the highlighted box shown by the camera app, and the edges of the QR code roughly aligned to the horizontal and vertical sections of the box.
All tests passed successfully.
The new QR Scanning code utility on GrapheneOS Camera works at scanning black and white QR codes against a gray background in both night and daytime conditions with the phone held in any reasonable orientation. The QR Code Scanning functionality in GrapheneOS Camera performs fully as it is intended to perform.
Its Happening Only if i use 16:9!
Works Fine in 4:3!
4K video recording shows so much glitch! ... And if i try to see 4k recorded videos it's laggy!.
Version running (2)
Device Running (OG Pixel XL)
Don't Know if it will get fixed! For OG pixel!... At least showing this issue to you guys!
(Sorry for my bad English).
We don't really know what this will do across devices and it likely shouldn't be the default. It's going to turn on post-processing people may not want, and it's not necessarily going to be a high quality implementation.
Pictures are currently saved with filenames of the format IMG_%Y%m%d_%H%i%s.jpg
(e.g. IMG_20211114_191156.jpg
). Please add an configuration option to allow specifying custom filename formats. I personally prefer the format %Y%m%d_%H%i%s.jpg
(e.g. 20211114_191156.jpg
). Thank you.
If there end up being video extensions, they can be fit into the video mode as settings. Most of the CameraX extension modes are only going to be for images.
User should be able to choose
When using the newly released camera app, I've noticed that navigation tabs ("QR SCAN", "CAMERA", "VIDEO") never seem to align properly and tend to float off center. Most of the time, when switching mode, tabs align in the center and then move abruptly, to the wrong place.
It is a very minor bug. I also would like to say, that this is a really welcome update, that has finally made the native Graphene OS camera usable. Thank you!
Hardware:
os: 2021110617
phone: Pixel 5
Pixel 5a, GrapheneOS, Android 12, build 2021102613
Downloaded APK from GitHub that posted 2 hours ago. Clicked to open apk, when installation was finished, I tapped open. The Camera app opened, I was able to see new options and navigate app. I closed the app. Now the app will not open. Icon appears in the middle of the screen and never opens the app fully. I have restarted the phone. No Joy.
Glad to attach info that can help debug.
Would you consider adding this feature?
"Save pictures with the same orientation seen in the viewer."
This depends on implementing #20 as a baseline. It's possible that the CTS requires some minor integration so that it can press the button to take pictures, etc. We'll need to figure out what's required. It's going to be mandatory to build this app into the OS as the camera app and run the relevant parts of the CTS (camera tests, media tests, content tests, etc.) and compare the results with AOSP Camera to make sure the app isn't a regression.
I don't think zxing supports this so we'll need to flip the data ourselves after the initial attempt fails and try again. It will slow down the analysis pipeline quite a bit since we'll be doing 2x failed scans for each frame instead of one.
The location tag for a photo with "location" toggled on is never saved on the photo metadata.
I am using Pixel 3a updated to the latest Camera app alpha release. Maybe this is a known issue, or it is not already implemented.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.