Jump to content

Fish eye and reverse fish eye


ozRocker
 Share

Recommended Posts

No clue about the webcam part.  Maybe this discussion will give you a clue.  To make a fisheye scene camera, you can just set the FOV.  A 10mm focal length lens == 2.024394 radian FOV.

camera.fov = 2.024394;

I am using a 120mm "lens" for my close up scenes (0.265103 radian FOV).  BJS's default is 45.8mm.  The default for a Blender exported camera is 35mm.  Here are some effects:

45.8mm: (BJS default)

45-8mm.thumb.jpg.d5e6d6dce6fb64a49561654fba866b9b.jpg

120 mm: (wide angle)

120mm.thumb.jpg.2e359372211ad8eb4ac107e652b9084b.jpg

10 mm: (fisheye)

10mm.thumb.jpg.06a332a6456a9d84a4e75b98d377c200.jpg

Link to comment
Share on other sites

17 minutes ago, JCPalmer said:

No clue about the webcam part.  Maybe this discussion will give you a clue.  To make a fisheye scene camera, you can just set the FOV.  A 10mm focal length lens == 2.024394 radian FOV.


camera.fov = 2.024394;

 

This doesn't change the appearance of the video on the plane though.

Here's an example using a video texture https://www.babylonjs-playground.com/#1R77YT#7

Link to comment
Share on other sites

Here's my shader that alternates between barrel and pin-cushion

http://www.babylonjs-playground.com/#TRNYD#20

 

I used this shader:

https://www.shadertoy.com/view/lttXD4

I'm not really certain if "iResolution" is meant to be the full screen size.  My texture looks massive so something is off. But at least I understand shaders a little more now.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...