AngelJ wrote:... Thanks for the heads up about TEXT(). I couldn't find any documentation on MSDN though. Do you have a link so I can read up on it?
I finally had a chance to try the version of Deskope you modified. I'm having a hard time spotting any differences between ours. I'd be curious to know what differences people are seeing that made yours seem a lot better.
The TEXT() macro prevents compiler errors:
http://msdn.microsoft.com/en-us/library ... 85%29.aspx
It automatically translates to either Unicode (16-bit) or ANSI (8-bit) characters, depending on how the compiler is configured. I needed it because I was getting string conversion errors. Some newer compilers (but not 2010 and older) let you just put an L in front instead (i.e. L"Deskope"). But for VS 2010 I just used the more universal TEXT() macro (which worked since Unicode was first adopted years ago). I really prefer UTF-8 characters that Linux uses, which are 8-bits for the ANSI subset of Unicode, and 16-bits for all the rest, so you do not need to worry about it...
My version uses a wider IPD offset, pushing the display "to infinity and beyond!". Well, the "beyond" part is bad because you need to diverge your eyes like Marty Feldman. But it is about 64mm or so, which is the RiftDK "standard" IPD for things place at inifinity. I actually backed off a little from that, so it would not cause problems for you, which makes the display look huge and far away, but not at infinity (for me). It all depends on your IPD. I just did it so it "looks good" for me, which meant changing the "Right Offset" value from 110 (yours) to 85 (mine). Looking at the code, that actually looks REVERSED (yours was farther apart than mine) ??? Hmmm... Was your setting requiring eye divergence? Not that I noticed. Something seems strange with those numbers...
Okay, let's actually try approaching this with numbers. The RiftDK display has square pixels and is 1280x800. 800*16/1280 = 10, so it is a 16:10 aspect ratio. The diagonal (d) measures 7-inches, so to calculate horizontal (x) and vertical (y) dimensions, we need to solve x for: y = x*10/16, and x*x + y*y = d*d. So lets simplify with a substitution:
d = 7
x*x + (x*10/16)*(x*10/16) = 49
x*x + (x*x*100/256) = 49
x*x*356/256 = 49
x*x = 49*256/356
x = sqrt(49*256/356) = 5.93 inches
So we know the screen is approximately 6-inches wide, or 3-inches per eye. Measuring my Nexus 7, it seems that the 6-inches looks accurate, but the 7-inch diagonal is only approximate. The screen centers for each eye are 3-inches apart (about 76mm), but the Rift lenses are 64mm apart, so for a 64mm IPD we need to shift the image centers 12mm inward (76 - 64). We can shift one of them 12mm (as done in this program) or each of them 6mm (which I do in my code), for the RiftDK "standard" 64mm IPD.
Some people with different IPD will need more or less image shift offset. We know that the screen is sqrt(1280*1280 + 800*800) = 1509 pixels per 7-inch diagonal, or 1509/7 = 216 PPI (pixels per inch). So a 12mm non-overlap offset would be 12mm/(25.4mm/in)*216px/in = 102 pixels. So that tells us the RiftDK "standard" non-overlap offset is 102 pixels. If we use less than 102 pixel offset, anybody with more than 64mm IPD will see things onscreen as being closer too them (not a problem), while anybody with less than 64mm (like children, females, or asian descent) will experience discomfort for distant objects that will appear beyond infinity (divergent gaze).
Your original 110 pixel offset (extra 8 pixels) gives 8px/(216pix/in)*25.4mm/in = 0.94mm (about 65mm total IPD). For a more general audience, it might be better to use a smaller offset rather than larger. I set the offset to 85 pixels, which looked good to me, and will avoid eyestrain for people with relatively small IPD.