View Single Post
Old 12-31-2021, 01:53 PM   #25
amd
Junior Member
amd began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Dec 2021
Device: Boox Note Air2
Quote:
Originally Posted by dnquark View Post
I just grabbed the db files and poked around If you are curious, I suggest getting the backup zip file from local storage (it will be in `/sdcard/note/backup/local/`), and opening it with SQLite browser. Most of the fields are fairly self-explanatory with the exception of binary stroke blobs, but these are arrays of 24-byte structs, (4 floats and a long, big-endian, corresponding to x, y, pressure, size, timestamp). Size is always 0. It seems that for strokes, if the SVG I get from PDF has N points, there will be 2N points in the binary blob. The scaling/units in the float values isn't clear, so it's difficult to do side-by-side comparison with SVG output. But if you just do a scatterplot of the points, you get the strokes you expect.

That's about all I found out, if you are able to reverse-engineer more of the file format that would be pretty cool. It seems quite doable, but I don't really have the bandwidth for it now.
It has been quite some time since the last post, however if someone is still interested, I have had a look at the format as well, thanks for the pointers
Here is a simple python script I threw together. It parses the sqlite db's and the binary blobs as well and renders the result to a skia canvas that can be saved to a png. I also extracted the keywords that are stored in the sqlite database (the Boox Note App does handwriting recognition quite well) and you can also pass a search term to the python script and it will draw a red rectangle around the recognized word if one is found.
Here is the code:
https://github.com/DAmesberger/boox-notes-backup-parser

I am now considering porting this to a proper implementation in Rust to convert this into SVG and attach it to Joplin Notes.
amd is offline   Reply With Quote