Placing an image in the camera frustum?

Hi,

I frequently use Rhino to match images taken from real-world cameras. You can imagine a surveillance camera capturing an object, and maybe I want to locate where that object is in space using a point cloud of the scene and a mesh of the object. My workflow is to undistort the image I’m interested in, locate the camera in the point cloud in Rhino, place the Rhino virtual camera at that location, and then manually adjust the target point, rotation, and focal length until I get a match. I will resize the viewport so that I can look at the boundaries of the image to aid in my matching, for example 640x480 pixels.

The thing that is tedious is that every time I make a camera adjustment I need to produce a new Rhino image to overlay on the actual image to see if my camera is a match. Is it possible to place a transparent image in the Rhino camera frustum, that rotates and translates with camera adjustments? This would greatly speed up my workflow.

I found these options for the camera frustum but nothing stood out: ViewportInfo Properties

Thanks.

Hi Evan,

I don’t think there is a way in standard Rhino. I am sure it is possible to do via some advanced RhinoCommon scripting that involves dealing with DisplayConduits (which is way above my head).

However there is a small piece of software that can be very helpful for similar situation, it would let you overlay a copy of any open Windows window on top of all open applications. So the way to do it would be to open your image in Windows Photo / Image viewer, then using OnTopReplica clone that window, set its transparency to 50 or 75%, then from RMB->Advanced options pick EnableClickThrough to be able to work under the overlay window. That way you can position this over Rhino viewport for the camera matching process.
GitHub - LorenzCK/OnTopReplica: A real-time always-on-top “replica” of a window of your choice (on Windows).

hth,

–jarek

What about using the wall paper? It is in the back, but may be enough for what you are doing?

1 Like

Jarek, thank you. I was going to ask if someone knew of a program like this to make images transparent, but I imagined the program window would disappear behind Rhino once I clicked into Rhino. I will give this a try!

Hi Nathan. Thanks, I was not aware of Wallpaper or PerspectiveMatch. PerspectiveMatch | Rhino 3-D modeling

That may work as well!

I found that the best way to deal with wallpaper is to have an extra wide viewport that can show the wallpaper fully fitted within the safe frame (at least for my case with V-Ray) I suggest having your perspective match viewport as a floating one.

Sounds good, from many ways I have tried, including wallpaper etc. in Rhino that method works the best so far for me. The problem with wallpaper is it gets covered by dense models, wireframes, selection etc. - having the image float on top with transparency if far better.
Perhaps the option to “draw on top” with controllable transparency can be added to Rhino Wallpaper option? (@nathanletwory ?)

–jarek

1 Like

Wallpaper is a background option, although I understand your request for the current feature it doesn’t make much sense (semantically). But I can see the need for a wallpaper-like feature that does indeed draw on top of everything with transparency.

3 Likes

A very important first step! :slightly_smiling_face: