Question [CLOSED] Any good-working GCam-Mods for the 12 and/or the 12X - Xiaomi 12

Are there already good-working GCam-Mods for the 12 and/or the 12X (which i have)?
Are there already configs for this phone?
I tried LMC8.4_R9 from hasli.
Works so fare (all cams of the phone, all functions of GCam). But the pictures are a bit too dark, a bit too colorless. I think with adjustement to the sensor(s), the results would be great.
Any recommendations?

Hi, anyone has any config for these GCams and can share it? Can't find anything on telegram groups for our device

maex-la said:
Are there already good-working GCam-Mods for the 12 and/or the 12X (which i have)?
Are there already configs for this phone?
I tried LMC8.4_R9 from hasli.
Works so fare (all cams of the phone, all functions of GCam). But the pictures are a bit too dark, a bit too colorless. I think with adjustement to the sensor(s), the results would be great.
Any recommendations?
Click to expand...
Click to collapse
Hello, you have good config for 12x with beautiful color?

You have good config for 12x?

this is xiaomi 12 or 12pro?

Thread closed since the topic already exists here.

Related

Camera - Manual Focus

Hello devs!
I wonder if anyone is interested in/capable of implementing a manual focus feature in android, at least for G1. Hardware-wise, I think it is probably feasible since (the great dev) DZO has already done it for the Kaiser (and I have seen it in action)!
CLARIFICATION EDIT: by Manual Focus I mean controlling the focal length, not just triggering the autofocus. For example, on the Kaiser, dzo has mapped the up/down side-wheel to focus-farther/focus-nearer!
See here the source code commit.
It would be great if the implementation introduced a relevant Java-level API, or extent the current Camera API.
My idea is to use this feature to fix-focus the camera, just a few centimeters away and make barcode scanning faster, not relying so much on auto-focusing. But I'm sure that there are plenty more useful stuff that can be done with manual focus (e.g. inspiring/artistic photo captures).
I'm rather new in android-dev and not experienced enough (yet) to work on the below-Java space, that's why I'm kindly asking for someone else to have a look at it
any thoughts?
have fun,
hypest
This is a great idea. Hope to see someone working on it.
This would be awesome! Espcially for photographers like muah
lapalways05 said:
This would be awesome! Espcially for photographers like muah
Click to expand...
Click to collapse
Photographers use shoddy-quality 3MPx cameras? Is your dSLR in the shop or something?
MattKilla said:
Photographers use shoddy-quality 3MPx cameras? Is your dSLR in the shop or something?
Click to expand...
Click to collapse
No, but it's not in my pocket most or all of the time, either. In a pinch, between 3Mpixel and 0Mpixel, the photographer will usually choose the former.
marxmarv said:
No, but it's not in my pocket most or all of the time, either. In a pinch, between 3Mpixel and 0Mpixel, the photographer will usually choose the former.
Click to expand...
Click to collapse
Yeah exactly. I love my dSLR to death, but I can't always have that beast with me. My phone is ALWAYS with me. I would a lot rather take a quick shot with it than no shot at all.
To the OP. Look in the android source repo at the camera code. Or is the G1 camera drivers in the closed source area? I know the actual camera driver is (thats why 2.X didnt have a camera at first) but is the AF code there too?
As the phone has auto focus i see no reason why manual focus couldn't be coded in.
In fact, i'm surprised no one has done it yet. I remember it being done on my old LG Viewty (that had a fantastic camera) and my SE k750i and was great for the really close up shots that the auto focus can't normally achieve.
Ok I looked at the code. Here is the camera code for the MSM7xxx chips:
http://android.git.kernel.org/?p=pl...=libcamera/QualcommCameraHardware.cpp;hb=HEAD
http://android.git.kernel.org/?p=pl...;f=libcamera/QualcommCameraHardware.h;hb=HEAD
http://android.git.kernel.org/?p=pl...a=blob_plain;f=libcamera/camera_ifc.h;hb=HEAD
If you look at the first one, it does all its autofocus calls thru libqcamera. That is one of the proprietary HTC/Qualcomm drivers. Here is the code:
Code:
status_t QualcommCameraHardware::autoFocus(autofocus_callback af_cb,
void *user)
{
LOGV("Starting auto focus.");
Mutex::Autolock l(&mLock);
Mutex::Autolock lock(&mStateLock);
if (mCameraState != QCS_PREVIEW_IN_PROGRESS) {
LOGE("Invalid camera state %s: expecting QCS_PREVIEW_IN_PROGRESS,"
" cannot start autofocus!",
getCameraStateStr(mCameraState));
return INVALID_OPERATION;
}
if (mAutoFocusCallback != NULL) {
LOGV("Auto focus is already in progress");
return mAutoFocusCallback == af_cb ? NO_ERROR : INVALID_OPERATION;
}
mAutoFocusCallback = af_cb;
mAutoFocusCallbackCookie = user;
LINK_camera_start_focus(CAMERA_AUTO_FOCUS, camera_cb, this);
return NO_ERROR;
}
First off you can see its calling the QualcommCameraHardware library which is libqcamera and then the method autoFocus. I think this is a dead end.
However, for 2.X we reverse engineered the drivers since we didn't have them available. They are open source. We may be able to look at them and get how they use the AF code.
Geniusdog254, thanx for sharing your thoughts, info and findings.
I'm assuming here: if the AF is done in software, even in proprietry drivers, it may indeed be possible to use it by RE it. Best case scenario would be to find functions lingering in there, waiting to be called
I'm wondering though, if the IOCTL's dzo is using are directly triggering hardware "switches", or are they handled in the drivers...
Could you please also share links to the open sourced 2.x driver?
Geniusdog254 said:
First off you can see its calling the QualcommCameraHardware library which is libqcamera and then the method autoFocus. I think this is a dead end.
Click to expand...
Click to collapse
Maybe not. I vaguely remember that the HTC camera app from CM 4.0 or 4.1 would allow you to switch between autofocus and infinity focus. Maybe that's a start?
I found these symbols in the libqcamera.so on my CM g1 (and highlighted some interesting ones):
Code:
af_algo_config
af_algo_execution
af_algo_preview
af_check_aec_settled_cnt
[SIZE="5"][B]af_do_move_lens[/B][/SIZE]
af_done
af_do_process_exhaustive_search
af_do_process_hill_climbing
[SIZE="5"][B]af_do_reset_lens[/B][/SIZE]
af_do_safe_move
af_init_process_exhaustive_search
af_init_process_hill_climbing
af_is_active
[SIZE="5"][B]af_move_lens_to[/B][/SIZE]
af_process_focus_sensor
af_process_lens_move_done
af_process_start_focus
af_process_stats
af_read_process_type
af_read_sharpness
af_start_stats
af_stop_focus
seems to me that maybe there are suitable means for manipulating the lens/focus.
I've attached the whole readelf dump...
I'd love to see this implimented
I think that if with proprietary drivers we can't manually move the hardware, perhaps we can indirectly trick it into focusing closer, thinking that it's "autofocusing" on a close object. Either one of these methods is a bit of a longshot with a proprietary driver, but they are both worth exploring. I'd LOVE to see some control over the focus of the camera, and if we can't do it with the AOSP code, let's look at Hero.... it offers significantly more focus control, with touch-to-focus. I haven't even glanced at the code there, though, so I have no idea. I'm just throwing thoughts at the wall in hopes that one of them will stick.
Here is the code for the opensource, reverse engineered driver for eclair. Have it at, I may look & post my findings:
http://gitorious.org/eclair-camera-drivers
EDIT: Well of course I'm looking at it lol, I can't resist.
Look on line 345 of this page (they're numbered): http://gitorious.org/eclair-camera-...are_msm7k/blobs/master/libcamera/camera_ifc.h
CAMERA_PARM_FOCUS_STEP is defined. It sounds like a way to step the focus forward/backward but I don't know which way.
Also, there is a LOT of interesting things in here, including some that our hardware doesn't support, so take it with a grain of salt (it has flash & all kinds of stuff, pretty much a generic Qualcomm camera driver). Anyways, here are some of the interesting ones;
CAMERA_PARM_ISO, (duh)
CAMERA_PARM_APERTURE, (maybe change aperture speed for better shots?)
CAMERA_PARM_SHUTTER_SPEED, (better response time?)
CAMERA_PARM_HISTOGRAM, (not useful for me, but neat)
CAMERA_PARM_FPS_LIST, (this one is defined under a video section, maybe change frame rate??)
Neat huh?
Anyway, the really cool part is line 405-409:
typedef enum
{
CAMERA_AUTO_FOCUS,
CAMERA_MANUAL_FOCUS
} camera_focus_e_type;
Now I can't tell you what all this means, but I can read & tell you that that does say manual focus where it defines the options for focus type
Also, ISO options are; MAX, HIGH, DEBLUR, 100, 200, 400, 800. There are also some WB settings that we don't have available, here is the full list; AUTO, CUSTOM, INCANDESCENT, FLUORESCENT, DAYLIGHT, CLOUDY_DAYLIGHT, TWILIGHT, SHADE, MAX_PLUS_1. Most of those are available in the 1.5 HTC based camera apps, but twilight & shade aren't.
Actually speaking of the HTC camera, it does almost EVERYTHING mentioned in this code. It misses a few of them, as I said, but it has debanding, WB, brightness. It is just missing the ISO (different from brightness, I promise).
This is about all I know, that its REALLY interesting to look through, and that we should make a camera app that can use all this
Also, just to say in my last post, I DO know what all of those camera terms mean, I'm a photo buff, I just put them in terms that apply to the G1
Bump. Isn't there any other interest in this? I don't have the experience nor the time to do this, but I REALLY want it. I already looked at the code & did a writeup. Surely someone can do it...
Geniusdog254 said:
Bump. Isn't there any other interest in this? I don't have the experience nor the time to do this, but I REALLY want it. I already looked at the code & did a writeup. Surely someone can do it...
Click to expand...
Click to collapse
Hey Geniusdog254,
thanx for sharing your findings! I guess is just a matter of (spare) time. I'm personally (but slowly) trying to get into kernel building (and low-level dev in general) so to try these myself...
An already experienced and interested fellow dev would certainly help if he/she came forward
I am very interested in this as well. Has any progress been made?
lapalways05 said:
This would be awesome! Espcially for photographers like muah
Click to expand...
Click to collapse
If you are a photographer and rely on a phone camera something tells me oyu dont get much work.
My only advice at this point is to change the title of the thread to [Think Tank] camera manual focus... you'll get more devs to glance at it.

Manual camera settings with third-party aaps

I'm contemplating the purchase of a Pixel 4a. While I'm aware Google's machine-learning auto-everything camera is widely regarded as wonderful, there are situations in which I want to take fully manual pictures with no, or minimal automatic postprocessing. I should probably get a real camera, but I don't always do what I should.
I'd like to know if the following items work, particularly with the opencamera.org app, but perhaps with others as well:
RAW capture
Manual focus
White balance to arbitrary CCT rather than a small number of presets
Manual exposure (what's the longest and shortest available?)
Manual ISO (what's the lowest and highest?)
zak.wilson said:
I'm contemplating the purchase of a Pixel 4a. While I'm aware Google's machine-learning auto-everything camera is widely regarded as wonderful, there are situations in which I want to take fully manual pictures with no, or minimal automatic postprocessing. I should probably get a real camera, but I don't always do what I should.
I'd like to know if the following items work, particularly with the opencamera.org app, but perhaps with others as well:
RAW capture
Manual focus
White balance to arbitrary CCT rather than a small number of presets
Manual exposure (what's the longest and shortest available?)
Manual ISO (what's the lowest and highest?)
Click to expand...
Click to collapse
Have look here:
https://forum.xda-developers.com/apps/google-camera-mods/gcam-google-pixel-1-2-3-t3875663
mzsquared said:
Have look here:
https://forum.xda-developers.com/apps/google-camera-mods/gcam-google-pixel-1-2-3-t3875663
Click to expand...
Click to collapse
That's an enhanced version of the factory camera app, which looks useful. It's not what I'm asking about.
What I'm asking about is camera2 API apps like pl.vipek.camera2 ("Manual Camera") and net.sourceforge.opencamera ("Open Camera"). The latter is free and open source if anybody with a Pixel 4A would care to try it out and report on functionality.
I bought a Pixel 4a. Running the factory ROM updated to Android 11, I have answers. It all works:
RAW capture: yes
Manual focus: yes
White balance: lowest 1000K, highest 15000K
Manual exposure: shortest 1/73470s, longest 10.2s
Manual ISO: lowest 55, highest 7111

Support for dual-frequency GNSS?

The phone is supposed to support dual-frequency GNSS.
Can someone use GPSTest (https://play.google.com/store/apps/details?id=com.android.gpstest&hl=en&gl=US)
and show a screenshot that demonstrates that the phone can pick up both frequencies?
Attached screenshot, you can see L5 and E5a in use there.
Looks like the screenshot got lost in the mail ;-) But yet I can confirm that dual-frequency is supported.
B2a too
Dual-frequency GNSS works. Positioning in general seems to be quite fast and accurate outdoors, also in forests.
Unfortunately it does not record carrier phase data with GPSTest or other apps (only outputs zeroes), so post-processing (PPK or others) are not usable. Does anybody know whether a custom rom can help with that?
I've seen it couldn't output "Navigation Messages", is that what's missing ? The Mi 8 could do that though I think. Is it really worth doing post-processing with an Android phone though where you're going to be limited by the poor antenna ? What post-processing tools do you use ?
You're probably right about the antenna. I wanted to see how far you can get with this phone. For some of my applications it could be useful to have sub-meter or at least the best accuracy available.
I wanted to use https://jason.rokubun.cat/#!/
Thanks for the link, they do indeed mention Android Smartphones under https://jason.docs.rokubun.cat/examples/ and give instructions on how to log data with GNSS Logger (GNS Logger v3 keeps crashing on me, does it work for you ?). They don't mention Navigation Messages that the Mi 10 '(and all 765G devices) is not capable of but "measurements" should be ok. Did you activate the "Full GNSS measurements" in the Developer Options ?
PS - I tried to create an account on Jason but I'm not getting the confirmation email. I tried "forgot password" and got an email but it won't reset. Looks like the site might have a few issues !
GNSS Logger always crashed on my phone, too. I have successfully used "GNSS/IMU Logger" as well as "GPSTest" instead (I prefer the former but since the last MIUI update (12.1.3) it has some bugs). I have enabled "Full GNSS measurements" in the developer settings.
The site worked just fine for me. At first files from the GPSTest app were not readable by the engine but the developers changed this immediately. They have also been very fast and helpful with my problems so far so maybe try contacting them via mail.
Good to hear, so what phone were you using when you got your data processed by Jason ? I received the email so I'll give it a try with both GPSTest and GNSS Logger v2 with my Mi 10 Lite just in case.
EDIT : so the GPSTest recording was...empty so same problem as you it seems (or I did something wrong while recording) but the GNSS Logger file is 1.8MB and is currently processing but stuck on "Looking for closest CORS station" so I'm not sure what's going on.
Ah sorry, my message was unclear. I have produced valid rinex and raw log files with the Xiaomi Mi 10 Lite but the fields with the carrier phase data were empty. Jason then still processes the files but the output data are not helpful, with positions way worse than what a standard gpx recorder delivers.
Jason usually didn't take long with my files.
Gotcha, I opened the log with excel and the CarrierPhase fields are indeed empty. Is that why we get the " Could not set-up parameters for PPP processing: Cannot perform PPP on Rinex because SP3 orbits for 2021-01-21 16:00:17.429569 could not be found " message in Jason ? That sounds more like a CORS station problem but anyway it won't help with our problem.
The result was indeed poor, worse than what I was seeing on GPSTest actually but I think GPSTest shows the "Android Position", i.e. fused GPS/WiFI/4G
By the way, which rom are you using?
I don't use 4G or Wifi for positioning.
Stock ROM with Miui 11.0.4.0
I'll try turning off data to see what that does to the position. It might be using the accelerometers too to keep it steady.
About the empty CarrierPhase data fields I wonder if the data isn't being made available differently after reading the paper made available here : https://www.researchgate.net/public...g_Xiaomi_Mi_8_Dual-Frequency_Raw_Measurements
Where it says : " Not all available public methods in these two classes are actually in use or of interest for satellite-based positioning. In fact, some variables (e.g., ‘CarrierPhase’) have been deprecated starting from API version 28 [11]"
EDIT : ok, what we need is the "AccumulatedDeltaRangeMeters" and it is indeed shown as 0.0 on the Mi 10 Lite
Looking for some Mi 8 logs now, I'm pretty sure I've seen some somewhere !
See here for example:
https://www.kaggle.com/google/android-smartphones-high-accuracy-datasets
From the "awesome GNSS" list. You can also find a list of device capabilities there:
https://docs.google.com/spreadsheets/d/1jXtRCoEnnFNWj6_oFlVWflsf-b0jkfZpyhN-BXsv7uo/edit#gid=0
The Mi 10 Lite 5G is supposed to support carrier phase data /accumulatedDelta. It just seems like they are not calculated.
I'm sure you know the GPSTest group:
https://groups.google.com/g/gpstest_android
I'll leave the link for other interested people.
Yes I'm there too ;-) I just mentioned the GeolocPVT app, I managed to build it starting from the .aab, what a hassle ! Unfortunately it can't get a fix with the Mi 10, maybe because of the lacking ADR data ?
Talking of which I ran GNSS Logger v2 on a lowly Redmi 9 and...it logs ADR data ! I'll see if I can post-process some data with Jason.
Thanks for the links for the logs, the video presentation was interesting too. Do you know what the "Ground Truth Data" is ? A geodetic receiver getting RTK corrections maybe ?
I wonder if the Mi10 will ever get proper ADR data...have you had other Android phones that provide that data ?
Sorry, no. I didn't check with the Realme X2 Pro and now no longer have it.

Camera2API Support

Hello,
does this phone support the Camera2API module? I frequently use OpenCamera and FilmicPro on my Honor 10 so I was wondering if I can do the same with Honor 20. If possible, could someone send screenshots from the 'Camera2 API Probe' and 'Filmic Pro Evaluator' apps?
Thank you.
Ok, so I got ahold of this phone and I tested out what it can and can't do regarding these functions. The result are are not terrible but not great either.
Camera2API
Here is the full report from the Camera2 API Probe. It's hard to read compared to the Android app, but here is my summary: It supports resolutions up to 48MP. It supports manual exposure (ISO/shutter). White balance too. The biggest caveat: no RAW support. You can't shoot in RAW with 3rd party applications like OpenCamera. Manual exposure works, you can also use the wide angle camera with manual exposure controls.
FilmicPro / OpenCamera
Here are the screenshots from the FilmicPro Evaluator app for all of the cameras available. In this case most of the features are supported. The EIS works only up to [email protected] though. You can't shoot 120fps videos with third party applications. The biggest caveat - no Cinematography Kit (aka LOG profile) support. I'm guessing this is related to the RAW format compatibility but I don't actually know. Same goes for OpenCamera, the color profile setting isn't available for video mode. Also, the EIS doesn't seem to work on OpenCamera for some reason.
(here starts the rant)
Honestly it's not bad (better than the P30 for example) but I don't understand why they disabled the RAW shooting option. I don't actually understand why they would limit the API at all for a phone at this price range. Especially when my Honor 10 (which was relased 1 year earlier) has this option. My guess is that it messes with their ****ty marketing gimmicks like 'Ultra-sharp 48mp mode' etc. This phone is good, but Huawei always makes a lot of specific enhancements with their software, and thus the options for customisation are limited. It's not a bad thing for "regular" customers that don't care about features like this, but I think they should allow the enthusiast to do their thing if they want to. It's going downhill since they stopped giving out bootloader unlock codes. While Huawei makes good phones, I feel like they are going more the closed-up iPhone way, and unfortunately this isn't something that suits me. I'll probably look somewhere else for my next phone - something like OnePlus (if the situation doesn't change).
If you have any other questions about the camera, or phone in general, feel free to ask.

Question Gcam for the S23/23+?

Hi all.
I've been doing a lot of reading about the Gcam port for Samsung devices and to be honest, I got lost. With all the Gcam variants, Telegram channels, XML configs... I coulnd't figure out which one is the latest version that is considered the best, out of the LMC or BMG apk's and which is the latest config that won't cause "force close" on all the camera mods for the S23.
It felt like I'm chasing my own tail...
Is there anyone here who knows which is the most suitable and latest verion APK with the correct config that gets all the camera modes working? By camera modes, I mean slow-mo, hi-res, etc.
Thank you!

Categories

Resources