Hello, interesting topic. Like you, I am also playing with the files a bit. I am quite impressed with these scanners, but I feel like the software is currently holding back the true potential of the hardware a bit. Probably some potential is sacrificed to make it more user-friendly and better suited for the average user, which is unfortunate for some of us.
Main thing I would like to improve is the compounding error problem, as this limits the scanner in some cases. I feel like some post-processing, an extra alignment step after completing the scan for example, could offer great improvements to the end result. I would gladly run a “second alignment”-algorithm on my laptop for a day, if that yields better scan results…
As far as I can tell, there is no way to export scan frames without some kind of post-processing being done. So I decided to have a look at the files. I wasn’t certain at what point the distortion correction was applied (this could have been done on the scanner, before the initial alignment) and I wasn’t quite sure where to start with that, so I decided to skip the param folder for now and tackle the .dph and .inf side first. Perhaps that would even be good enough to realign the scans and adjust the .inf files.
I am far from done with this, but I think I can add some info, especially for the .inf-files. In every sentence that follows you can add “appears to be” or “I believe”, since most of it still needs to be verified on a larger scale.
The .dph-files contain the depth view. This is like a pyramid, with its tip offset from the center. Lowest value accepted by Revo Scan for the dph is 2, highest is 6000. Looking at the raw_preview.ply-files, a simple linear interpolation is enough to recreate point clouds from a dph-file. Point clouds that I have created in this way appear to be correct, when I put them into cloud compare for example, but I have not done a very good check on this, just a quick visual inspection and I couldn’t see any obvious flaws.
After that I shifted my focus to the .inf-files, since I suspected these to contain the key to the 6-DOF of the individual frames. I have not fully figured out the .inf file, but here is what I have currently got:
I parse these files into a hex-view. A typical file looks something like this:
00 00 00 00 01 02 00 02 00 00 00 00 00 00 00 00
3D F2 4F DD 69 88 EF 3F 42 96 45 6F B7 55 B4 BF
12 7D A2 53 16 46 C3 BF C0 2B A4 43 1C 11 78 C0
67 4E E0 66 A6 00 A7 3F 38 05 21 94 BD 2E EF 3F
EB BA FD A2 48 2A CC BF B0 8B 57 11 2C 9C B3 40
80 0B C6 5C C8 04 C5 3F DE 37 29 F5 5A E3 CA 3F
9A AF 3C 8A 71 D7 EE 3F D9 EC AE 24 5B D3 99 C0
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 F0 3F
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 F0 3F 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 F0 3F
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 F0 3F 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 F0 3F
The first row contains some information about the frame number, but it looks like it can be ignored for what I want. The next six rows are the interesting bit, and I am focusing on those now. The rows after that are empty/unused.
The interesting six rows are, as far as I can tell, copied directly (without changes) into the global_register_pose.pose by Revo Scan. There appears to be a lot of random nonsense in these six rows, kind of obscuring what is going on. After looking at a lot of files, some patterns started to become clear. On the 8th and 16th rows there are a lot of 3F, BF, 3E, BE, C0 and 40. Those are like a multiplication factor. These give us a direction (positive/negative) and order of magnitude (small/large). The bytes directly before them are the values that should be multiplied by the factors. How many significant bytes there are, I don’t know. I am fairly certain that it is not the full 7 and possibly only 2.
The values & factors contain information about scaling, skewing and translating. Skew in two directions and you have rotated a mesh. Add scale and translate and you are the master of all 6 DOF. Below is where the position of the translations, skewing and scaling are found.
\ 1-8 | 9-16
1 Scaling X-direction | Skew X-dir., Z-dependent.
2 Skew X-dir., Y-dep. | Translation X-dir.
3 Skew Z-dir., X-dep. | Scale Z-dir.
4 Skew Z-dir., Y-dep. | Translation Z-dir.
5 Skew Y-dir., X-dep. | Skew Y-dir, Z-dep.
6 Scale Y-dir. | Translation Y-dir.
For the factors; 3F & BF are coupled, they do the same thing, but in the opposite direction. The same goes for 3E & BE and 40 & C0. BE & 3E I have only seen used for skewing. C0 & 40 only for translations. You could add 00 to the list of factors, but I have only seen those in the first frame, since that is placed in origin, so all values are zero there.
For the values; 00 = smallest/zero, FF = largest.
This is about as far as I have gotten right now. I am currently looking at ways to verify that this information is indeed correct. Next steps for me will be to create point clouds based on .dph and .inf files.