yashsingh1/xdaforums huggingface dataset:
[ZenFone 2 Themes and Apps] dreckneck:
[MENTION=6268214]SpiderPack[/MENTION]

I started analyzing your logcat and the code from LineageOS. I've found some interesting things:

LineageOS uses a wrapper around the vendor (asus) camera blobs. This could be a source of problems.

LineageOS knows the camera parameters used by Asus, however, the burst parameters aren't included on the list, hmmmm...

The latest LineageOS 14.1 nightly is using the camera blobs from Lollipop. I know the camera implementation from Intel has a (really stupid, actually) bug that crashes the rear camera when getting raw pics (the front camera works, though). Marshmallow blob's fixes this bug, but I could find a workaround.

For some reason, there's no mention of atom_take_picture in your logcat; this could mean that the picture is not even being taken at first place (I compared to mine logcat where I get a lot of atom_take_picture calls during burst capture).

Could you please tell me what PixelMaster features are currently working on LineageOS?
[ZenFone 2 Themes and Apps] SpiderPack:
Still using Lollipop blobs?! This is odd, because one must update to Marshmallow first in order to install LineageOS 14.1.

Off the top of my head:

- Burst doesn't work (takes only the first shot);

- Super resolution takes "a shot", but it's all green artifacts;

- Manual mode, with focus set manually -> green artifacts in low light conditions;

- and a well known one: if optimizations are not set to "off", there will be green artifacts in the picture.

Let me know if more logs are needed (even with your app). Also, tell me if I can filter more the logs.
[ZenFone 2 Themes and Apps] dreckneck:
A logcat using my app would be useful too :)
[ZenFone 2 Themes and Apps] SpiderPack:
Procedure:

Reboot;

Open RawDumper App;

Select Info;

Shutter button;

Flash button (which causes app crash);

logcat:

https://paste.ee/p/0U7Vw
[ZenFone 2 Themes and Apps] dreckneck:
I have found this line on your logcat (exactly when the crash is happening):

06-06 23:52:02.594 5550 5550 F DEBUG : #05 pc 000e8086 /system/lib/hw/camera.vendor.mofd_v1.so (_ZN7android34getGFXHALPixelFormatFromV4L2FormatEi+198)

This means the camera is crashing when calling the function getGFXHALPixelFormatFromV4L2Format (source code here). The function aborts the entire camera subsystem if the picture format is unsupported. This happens when taking a raw picture using the rear camera, because the Toshiba sensor uses the V4L2_PIX_FMT_SGRBG10 format which is not listed in the function implementation. Unfortunately, this is the bug found in the lollipop camera blobs I was talking about :/

Try restarting the app twice without clicking on anything (capture button, flash button...). Then, check if there's any file inside the /sdcard/DCIM/RawDumper folder, because some pictures could be restored.
[ZenFone 2 Themes and Apps] SpiderPack:
Yeah, something appeared: !qpicfake.jpg (0 bytes)

So... No hopes for LineageOS?
[ZenFone 2 Themes and Apps] dreckneck:
Well, that was unexpected, since there's no code that generates "!qpicfake.jpg" inside my app........ There's also a hidden folder called .partial inside RawDumper's folder, you could check if there's something with the extension i3av4 inside that too. If there's no file inside RawDumper, .partial or even /data/misc/media, there's currently no way to get raw pics on LineageOS :/ (at least for the rear camera)
[ZenFone 2 Themes and Apps] SpiderPack:
”.partial/” is empty

And no ”/data/misc/media”

Could be my file explorer... Do you recommend any?

I can even hear it:

"Hello darkness, my old friend..." lol
[ZenFone 2 Themes and Apps] foober:
With new version i can install app. But when start, check root and got freeze. This happen on latest slim rom with magisk. Later i add logcat.

Wysłane z mojego ASUS_Z00A przy użyciu Tapatalka
[ZenFone 2 Themes and Apps] dreckneck:
That means there's currently no way of enabling raw capture on roms using Lollipop camera blobs :(

But maybe I could help getting the Marshmallow blobs work on LineageOS hmmm
[ZenFone 2 Themes and Apps] dreckneck:
Apparently it's freezing on roms that are using lollipop's camera blobs :/
[ZenFone 2 Themes and Apps] foober:
Its possibly to change to mm camera blobs?

Wysłane z mojego ASUS_Z00A przy użyciu Tapatalka
[ZenFone 2 Themes and Apps] SpiderPack:
I would gladly be a tester for you! :good:
[ZenFone 2 Themes and Apps] diogotux:
Man, this is awesome! I totally love this phone, the only thing that I missed is the ability to take RAW pictures.

I've installed it on my ZF2 running Android M and it worked like a charm!

Congrats on the GREAT work!
[ZenFone 2 Themes and Apps] Felipe2077:
Normally don't comment, but this is super interesting to hear about, especially on a two year old phone! Thanks dev! :D
[ZenFone 2 Themes and Apps] diogotux:
Same here! Actually I just created a user to thank the author.
[ZenFone 2 Themes and Apps] chiudikas:
This program is such a joy :)

If only I could pick a focus point, it would be perfect!

I will buy if you ever release it to Play store.

[IMG="Amazing cats shot with Zenfone 2"]https://image.prntscr.com/image/Dci1p337RwudzqKTOOKGOA.jpg[/IMG]
[ZenFone 2 Themes and Apps] a22069367:
It just works like a magic! Due to this feature, zenfone 2 can still use ten years longer!
[ZenFone 2 Themes and Apps] SpiderPack:
Those who were able to use the app, checkout the new update!

Please share your thoughts!
[ZenFone 2 Themes and Apps] andrea.giommi:
551ml last cleanstock root with magisk

Inviato dal mio ASUS_Z00A utilizzando Tapatalk
[ZenFone 2 Themes and Apps] dreckneck:
I knew this was going to happen to someone...

Well, I updated (again) the apk and (temporarily) disabled this alert.

I added a internal logging feature, so I can track bugs faster.

Could you please try the new 1.2.2 version, take a picture and send to me the file RawDumperLog.txt inside the RawDumper directory?
[ZenFone 2 Themes and Apps] dreckneck:
Hi,

I'm planning to make the app compatible with your device

could you please try to install the app again and send me a logcat (you can use the SysLog app) when you try to take a picture?

And also send me the file RawDumperLog.txt inside the DCIM/RawDumper directory?
[ZenFone 2 Themes and Apps] andrea.giommi:
Same error
[ZenFone 2 Themes and Apps] dreckneck:
I tested more and fixed some more bugs today and released the 1.2.3 version, tell me if it's working now :)
[ZenFone 2 Themes and Apps] jags3g:
Works very well, you made my day by releasing this RAW image capture app. :) :good:

---------- Post added at 10:38 PM ---------- Previous post was at 10:32 PM ----------

Me too!
[ZenFone 2 Themes and Apps] SpiderPack:
[MENTION=7094526]dreckneck[/MENTION] the only thing holding me back is the fact Asus' Stock ROM UI is SOOO ungly!

Please let me know with you believe any custom ROM has the camera blobs necessary. And once again, keep the great work! I've even shared this thread's link in a reddit post r/zenfone2. :D
[ZenFone 2 Themes and Apps] dreckneck:
Thank you!

Since I posted this app I have received such a great feedback, so I'm feeling really motivated to keep working on it :D

I'll try to find a custom ROM that uses the MM camera blobs.

Anyway, in the next few days I'm planning to enable raw capture on the front camera (and it works on the lollipop blobs, so you can test it!).

Some interesting spoilers: from what I've tested, manual ISO, shutter speed and white balance works also on the front camera (!!!)

In the Marshmallow update, Asus was quite nice and even included long exposure (up to 2s) in the driver of the front camera sensor. This feature is completely inaccessible, however.

Stay tuned!
[ZenFone 2 Themes and Apps] andrea.giommi:
now working! only a problem: the files are like hidden, snapseed doesen't open the files. with file manager i can see them hidden
[ZenFone 2 Themes and Apps] dreckneck:
This is an annoying bug in Snapseed, actually.... You need to open the RawDumper folder in a file manager app (like the stock Asus's file manager) and select the share option, so you can share it to Snapseed and it'll be opened.
[ZenFone 2 Themes and Apps] keshav_c17:
Please make it compatible for LineageOS 14.1 . I feel camera performance is degraded after updating to LineageOS from stock. I guess this could be the saviour for LineageOS users.

Right now app gets installed but as i open it camera gets freezes whereas i can still toggle the on-screen buttons of the app. And when i click capture button just circle keeps on rotating forever.

This could be the next big thing for ZenFone 2 community.

Thank you.
[ZenFone 2 Themes and Apps] basdriver62:
Why wouldn't you just use Open Camera? ? I guess I just don't understand the point of this mod... ?
[ZenFone 2 Themes and Apps] chiudikas:
Open Camera can't take RAW photos, what's the point of this post? :)
[ZenFone 2 Themes and Apps] SleepingAran:
This does not work on non-Stock custom ROM am I right?
[ZenFone 2 Themes and Apps] blazzer12:
Awesome work! :good:

I have got a question: There are camera apps that can make use of the Camera API2 and shoot raw pictures. With this development will they do the same with ZF2?
[ZenFone 2 Themes and Apps] blazzer12:
It will not work on stock rom. It will work on custom rom.

EDIT: I regret the misinformation.

PLEASE READ THIS FOR THE CORRECT ANSWER: https://xdaforums.com/showpost.php?p=72855237&postcount=65
[ZenFone 2 Themes and Apps] SleepingAran:
That's weird. I have MoKee ROM and the camera don't function at all.
[ZenFone 2 Themes and Apps] SpiderPack:
[MENTION=4989081]SleepingAran[/MENTION], [MENTION=4691033]blazzer12[/MENTION] messed up trying to explain.

As said in the first post:

"It works on 184 and latest 223 update of Marshmallow stock rom (wont work on Lollipop stock roms)"

"It's currently not working on roms using camera blobs from Lollipop's era"

You can include to the last one ALL CUSTOM ROMS (as observed by OP, custom ROMs, like lineageOs, are using camera blobs from Lollipop).

Maybe in a future update, users with custom roms will be able to shoot RAW from FRONT CAMERA (and as it is, front camera only). Due to the fact Lollipop blobs for front face camera doesn't have the so called "bug".
[ZenFone 2 Themes and Apps] SleepingAran:
Ok. Thanks for the clarification!
[ZenFone 2 Themes and Apps] marcossanches:
Thanks for the app, the pixelmaster just go to ISO 800 and shutter time 16s, but it takes up photos on much greater values, everything worked, you could just add another path to the photos so we can set the path manually (lightroom does not recognized the default path, so I have to move the photos and then work on them), I know you still have a lot to do, but the only important thing missing is the manual focus, it sucks when you leave the phone frozen within 20+s to discover later that the focus was wrong, so I have to set the focus on high ISO so I can see the image focused, then set ISO to 50 and high exposure on shutter speed to get a crisp low noise image. I'm using stock 6.0.1 .223 and I don't saw any black borders from the lens, also, I'm confused, is the menu supposed to show something more than the "i" icon with the "about" or are you still developing the options?
[ZenFone 2 Themes and Apps] sbetatester:
[MENTION=7094526]dreckneck[/MENTION] wouldn't it be awesome to create a telegram group for discussing bugs?

Why telegram because it keeps your number private.

Anyways, thanks for the great mod but i'm unable to install it. I cant press the install button, i can only cancel it

Device : Asus Zenfone 2 ZE551ML

OS : Lineage OS 29th June Build

Rooted using magisk beta 13.0
[ZenFone 2 Themes and Apps] SpiderPack:
Dude, disable the night mode thing you're using.

ANY overlay app (i.e.: one which casts a dark screen above Android screen) will unitilize the install button. You're welcome.

Btw, I'm against telegram or wherevergram group. :)
[ZenFone 2 Themes and Apps] sbetatester:
Oops, i was unaware of the same. It did work in the morning and i was like wtf. But its quite strange as installation of other apps have no issues with the overlay.

About the other thing, it would be easier and faster to communicate from an IM instead of forum based comments.

Thanks anyway
[ZenFone 2 Themes and Apps] dreckneck:
Unfortunately, no.

The raw capture and manual shooting features are all implemented using Camera API1 on the Zen2.

Implementing the whole Camera API2 on any phone is a GIGANTIC amount of work and you need to know a LOT about the internals of the device; currently, only OEMs could do this kind of work :(
[ZenFone 2 Themes and Apps] dreckneck:
Thank you for your feedback!

The ability to change the path manually seems a good idea for a future release (I'm also planning to enable manual focus).

YEAH, I hate when this happens, too :b

You won't see them because the app is already applying some sort of lens correction :D

Yes, I'm still developing the options.

I'm currently working on making the UI more fluid (by accessing the camera and processing the pictures on the background), but this is WAAAY harder to do than I previously thought. That also will bring a better and more organized code, so in the future it will be easier to add new features and fix bugs :)
[ZenFone 2 Themes and Apps] dreckneck:
[MENTION=5365160]sbetatester[/MENTION]

I'm really not sure about creating an IM group :S
[ZenFone 2 Themes and Apps] SpiderPack:
[MENTION=7094526]dreckneck[/MENTION]

I saw you've updated it. My feedback:

- I can toggle between rear and front cameras :D

- When I take a picture with the front face it shows momentarily a greenish screen and says that picture was taken (and saved).

- Although no file seems to be generated. I can't find anything in DCIM/RawDumper besides log.txt and .partial/ (empty)

Log.txt
[ZenFone 2 Themes and Apps] dreckneck:
The greenish screen probably means that the raw picture was taken, YAY! However, I'm not sure why the file is not in the RawDumper directory hmm
[ZenFone 2 Themes and Apps] jags3g:
The file gets created for me, no issues
[ZenFone 2 Themes and Apps] neosinan:
Is It possible that you could do no root version of this app with ADB permission ?
[ZenFone 2 Themes and Apps] SpiderPack:
Are you using LineageOS 14.1 too?
[ZenFone 2 Themes and Apps] jags3g:
No I am currently on CleanStock
[ZenFone 2 Themes and Apps] jamulia91:
i get green screen after take picture, but notify dng sucessful.. in DCIM/RawDumper no photo file..

z008 Cusrom R-R 5.8.3..
[ZenFone 2 Themes and Apps] dreckneck:
[MENTION=6268214]SpiderPack[/MENTION] [MENTION=7629662]jamulia91[/MENTION]

I've flashed the latest LineageOS to see what's going on Lollipop Camera blobs.

First of all: the app has to know three, f*cking THREE different ways of grabbing raw pictures on the Zen2! The software it's literally becoming more and more complex. Asus really changed A LOT of things under the hood, especially in the Marshmallow update, when they even included support for long exposure and that needed a lot of changes in the camera drivers.

Second: the picture is not being saved because, in the Lollipop blobs, the raw i3av4 files should be saved on /data/ directory (and not on /data/misc/media/ directory as happens on MM blobs). However, due to a permission failure on the Media Server side, the raw files are never saved anywhere.

But there is a workaround: the app can grab the raw picture from the raw PictureCallback (source: https://goo.gl/STUhZ5).

So this is going to be the next feature I'll be working on :)

PS: apparently on qualcomm's processors, getting raw pictures is SO MUCH easier xP
[ZenFone 2 Themes and Apps] SpiderPack:
Wow, you really went for it! :D

I saw the amount of coding you have done so far... You're a beast! Hahaha

Let me know if I can provide anything to help you. Cheers, man. ****ing cheers!
[ZenFone 2 Themes and Apps] neosinan:
Thank you for this app, I just rooted my device just to use your app. You did something Asus haven't done So I really thank to you. Keep up the good work.
[ZenFone 2 Themes and Apps] badboy21102000:
nice job, keep going

https://xdaforums.com/zenfone2/orig...4-1-weekly-t3545692/post73129293#post73129293
[ZenFone 2 Themes and Apps] badboy21102000:
main camera has been stuck when i start app, but all button work, when i choise to call camera, it work good. i use lineage os
[ZenFone 2 Themes and Apps] dreckneck:
[MENTION=4952610]badboy21102000[/MENTION] [MENTION=6268214]SpiderPack[/MENTION]

Hi, I have some news!

1) I've managed to patch the Lollipop camera blobs, fixing the bug that prevents getting raw pictures on the rear camera. I haven't tested that much, but apparently it's working.

2) I got a Zenfone 5 from a friend for replacing its power button, and apparently it also has raw capability. I'm planning to add the Zen5 to the compatibility list.

3) The app itself it getting more and more complex, so the development is probably going to taking more time, unfortunately.

4) The next app version will always try to load the Intel Camera Extensions Library directly from the device, if available. I've tested and it's currently working on stock Zen2 and stock Zen5, even though their libraries are sightly different.
[ZenFone 2 Themes and Apps] badboy21102000:
good job
[ZenFone 2 Themes and Apps] badboy21102000:
i think if you add some feature like hdr, manual turn on/off 1 or 2 led light at the same time to get more bright + manual White balance to get better color , it will amazing
[ZenFone 2 Themes and Apps] neosinan:
Does #4 mean it's gonna work on Custom ROMs without problem?
[ZenFone 2 Themes and Apps] dreckneck:
I've had some issues when I was testing the app in Lineage OS and I needed to change the app architecture a bit. But I should work flawlessly in the next version :)
[ZenFone 2 Themes and Apps] themonyo666:
thanks for updates it works now
[ZenFone 2 Themes and Apps] 2D-Kun:
mine still does not work,
[ZenFone 2 Themes and Apps] badboy21102000:
if you release new version faster, people will test and give to you more log files, that help you make app bester.
[ZenFone 2 Themes and Apps] SpiderPack:
Jesus, this comment is poisonous! ?*♂️

OP is already breaking all his legs (check the amount of code committed so far), so be patient...
[ZenFone 2 Themes and Apps] dreckneck:
Writing good software is like building a skyscraper: if the foundation is not solid enough, everything above it will fall apart.

I prefer to take more time, because in a well-designed software architeture is easier to fix bugs and add new features.

And there's already a ton of bad-written apps on Android (Facebook Messenger, Uber and Snapchat I'm looking at you guys)
[ZenFone 2 Themes and Apps] prc.kailas:
it says "DNG file created successfully" but i don't know where it is saved !
[ZenFone 2 Themes and Apps] SpiderPack:
[kinda off]

Awesome article posted on XDA about Camera HAL, ROM Blobs and how much a pain in the ass it can be.

https://www.xda-developers.com/came...opers-make-hardware-work-without-source-code/

Maybe this reading can bring some knowledge for those unaware of how complex porting functionalities can be.
[ZenFone 2 Themes and Apps] badboy21102000:
my friend, do you still work with this project ?
[ZenFone 2 Themes and Apps] dreckneck:
Making (and maintaining) custom roms is even harder than I thought. I currently know that Lineage OS is using the Lollipop camera blobs because the MM ones require newer media blobs that are incompatible with AOSP. A lot of XDA devs are making the impossible happen for a ton of devices. Really interesting article, btw.
[ZenFone 2 Themes and Apps] dreckneck:
Yes, sorry for the lack of news. Unfortunately, I've been busy and struggling with real life :silly:
[ZenFone 2 Themes and Apps] Reza Khan:
Thank you very-much for the app.Your work is much appreciated

But have anyone tried shutter speed of 32s to see if actually that feature works or not

if it please let me know thanks :good::good:
[ZenFone 2 Themes and Apps] dreckneck:
If you are using the stock rom, it *should* work.

If you are using Lineage OS or any other, it won't work
[ZenFone 2 Themes and Apps] Ashieboy™:
Man thanks for this, maybe you should upload this to the store and ask for payments since this is a really great project.
[ZenFone 2 Themes and Apps] dreckneck:
Hi guys!

I have some news!

Bad news: (update: I already fixed my phone! :D ) I broke a pin of the usb-board of my Zenfone 2 while trying to replace its battery; so everything connected to the usb-board doesn't work anymore :(

Good news: I ordered a new usb-board from the internet and it should come today.

The 2.0 version of Raw Dumper is ALMOST ready, I just need to fix the "raw-pictures-with-zenfone-2-front-camera-using-Marshmallow-camera-blobs" case, test it on my phone and fix some bugs.

About the 2.0 version:

I will share a patch that will enable raw capture on the Zenfone 2 with custom roms

Raw capture should work on the Motorola Razr I (rear camera only) and on the Zenfone 5 (both cameras)

You can now set the exposure compensation (EV), along with manual/auto ISO and manual/auto ShutterSpeed

The app won't let you select invalid combinations of ISO, Shutter Speed and EV

The app now features ISO and Shutter Speed metering. It shows the current ISO and Shutter Speed in real-time.

New camera opening/closing animations were added

The app is probably going to be released on the Play Store. Since it's open-source, it will be free.

Some interesting stuff: This project has become something waaay larger than I could ever imagine; it's literally the largest personal programming project that I ever made. It was (and still is) super fun to make it. I'm also planning to create a website/blog about it :)

So, stay tuned for more updates!
[ZenFone 2 Themes and Apps] keshav_c17:
We really appreciate your devotion and passion towards the development of ZenFone 2 software. Everyone is benefited by your hard work. Will be looking forward for the stability on custom ROMs. Thank you once again.
[ZenFone 2 Themes and Apps] SpiderPack:
[MENTION=7094526]dreckneck[/MENTION]

I'm speechless! Dude, you've done the unbelievable!

I'll definitely purchase it. Dude... From the bottom of this community's heart: Thank you.

p.s.: the UI is better than a lot of OEMs stock apps out there. Cheers.
[ZenFone 2 Themes and Apps] SpiderPack:
First: Sadly "hide" tag doesn't work on XDA app... So, it was a hell of a flood lol

Have you patched your phone?

OP highlighted on github that LineageOS users must patch a .so file.

I'm using it right now (on LOS, latest build) and works flawlessly.
[ZenFone 2 Themes and Apps] dreckneck:
Thanks for your feedback, I'm going to investigate this crash!

Can you please install this small update here and post the Logcat again?

(the update will still crash, but it will show more details of the crash)

Note: I particularly hate when I post software that crashes on the first try, oh well :b
[ZenFone 2 Themes and Apps] dreckneck:
The cause of the crash doesn't appear to be related to the patched file.

The crash occurred before the code that checks for the patch
[ZenFone 2 Themes and Apps] dreckneck:
I'm using magisk without xposed. I'm not using the latest LineageOS, I'm using LineageOS 14.1 22 setember 2017.

The crash happened with or without the patch?

The "normal" camera app works as expected?

Technical info:

The crash occurs at the Camera.getCameraInfo at ExtraCameraInfo:66, because the camera id is invalid (btw this error should never happen, so it's quite weird)
[ZenFone 2 Themes and Apps] SpiderPack:
I'm using root provided by LOS. No magisk nor xposed.

Doesn't seem the cause of a clean flash... Maybe something with your device? Have you flashed anything related to asus camera before?
[ZenFone 2 Themes and Apps] pcaquercia:
A clean flash did not help, the issue persists.

I do have a broken front camera, but aside from that both the default lineageos and asus cameras work normally.

I can provide a logcat of them if you're interested in further looking into the issue, but it seems clear that the problem is on my end

(as far as I can tell the asus camera log show the app being able to identify the camera, although it gives an error that only one camera is present)

Anyway, I appreciate you guys taking the time to help.