Live data from Hacker News

Parallax effect from Google Lens Blur photos

depthy.stamina.pl

31–40 of 61 posts

Re: Parallax effect from Google Lens Blur photos

#31

I'm putting the over/under on how long till this is used for porn at 4.5 days. Any takers?

I had the same thought... how this effect could enhance porn picture sites. Given the dominance of "tube" porn sites, I doubt it will be as big as it could have been when picture sites dominated. However I could still see some niche sites using it to "get a better look" or on-page to attract clicks.

Re: Parallax effect from Google Lens Blur photos

#32
post #8

It might be helpful to separate the code that creates the parallax effect from the angular app that displays the website & examples. This is a really cool trick and it would be nice to be able to easily reuse it. For those looking, it seems like the "magic" happens in a couple of spots (I think): https://github.com/panrafal/depthy/blob/master/app/scripts/p... and in https://github.com/panrafal/depthy/blob/master/app/…

There already is a library for extracting the depth map here: https://github.com/spite/android-lens-blur-depth-extractor (internet rocks, isn't it ;) ) As for the Shader - it's just a few lines of actual code. Depthy is a quick weekend hack. There's a loong way before it.

Has anyone managed to replicate the lens blur effect that's being utilized in the new Android camera app? Or at least know what research paper it's based on?

Re: Parallax effect from Google Lens Blur photos

#33
post #5

Surprisingly well faked in face of the fact that there's no real 3D information in the pictures. There simply cannot be new 'pixels' appearing that were (i.e. before applying the effect) hidden from objects in the cameras line-of-sight. This is evident upon closer inspection (look at edges around the approximate middle of the DOF). The trompe-l'œil then falls a bit apart. Interestingly, I did not notice above with th…

It's exactly that - single image, and a depth map calculated from a series of shots made upwards. Both these are bundled in a fake-bokeh image. There is obviously no more pixels. However... If you choose your subject wisely, the effect can be pretty believeable, using a simple displacement map. On iOS though it's something different. There's no depth map in there, just a flat image moving counterwise to your hand mov…

There is more pixels captured compared to a single shot image as you said: "series of shots made upwards". So it captures some pixels that is hidden when the camera moves upwards, but if the simulated parallax is bigger than the original camera movement then there will be still missing pixels. Probably this could be improved by doing bigger movements with the camera, like with other 3D reconstruction software.

Re: Parallax effect from Google Lens Blur photos

#35
post #17

Well done. I have been working with animating 2d images with a hand constructed depth map in the past to a decent 3d effect[1]. The illusion when guided by your mouse as in the OP seems to be much stronger then in left-right strafing that I did. One point that can be worked on, as pointed out by other people here is the occluded pixels (this is an issue when an image has sharp changes in distance from the camera). Yo…

What do you think about this famo.us demo: http://codepen.io/befamous/pen/KIgqh

Re: Parallax effect from Google Lens Blur photos

#37
post #17

Well done. I have been working with animating 2d images with a hand constructed depth map in the past to a decent 3d effect[1]. The illusion when guided by your mouse as in the OP seems to be much stronger then in left-right strafing that I did. One point that can be worked on, as pointed out by other people here is the occluded pixels (this is an issue when an image has sharp changes in distance from the camera). Yo…

5 bottles is really good!

Re: Parallax effect from Google Lens Blur photos

#39
post #5

Surprisingly well faked in face of the fact that there's no real 3D information in the pictures. There simply cannot be new 'pixels' appearing that were (i.e. before applying the effect) hidden from objects in the cameras line-of-sight. This is evident upon closer inspection (look at edges around the approximate middle of the DOF). The trompe-l'œil then falls a bit apart. Interestingly, I did not notice above with th…

People in the machine learning community have been working on this sort of problem for awhile, the results are often very impressive:

http://make3d.cs.cornell.edu/

Post reply on HN