View Single Post
  #3  
Old 12-19-2008, 10:08 AM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
I downloaded a sample video from the Point Grey Ladybug website and used the following script to view the video:
Code:
import viz
import math
viz.go()

#Add panorama video
video = viz.add('video.avi',play=1,loop=1)

#Radius depends on aspect ratio of video
w,h,_ = video.getSize()
HEIGHT = 5.0
RADIUS = (w * HEIGHT) / (float(h) * 2.0 * math.pi)

#Add panorama cylinder
panorama = viz.add('pano_cylinder.ive',scale=(RADIUS,HEIGHT,RADIUS))
panorama.texture(video)

#Make sure panorama appears at infinite distance
panorama.disable(viz.DEPTH_TEST)
panorama.drawOrder(-100)

#Keep panorama centered around main view
viz.link(viz.MainView,panorama,mask=viz.LINK_POS)

#Setup a panorama camera navigation
import vizcam
vizcam.PanoramaNavigate()
I've attached pano_cylinder.ive file to this post. It is simply a cylinder that faces inward. Let me know if this works for you.
Attached Files
File Type: zip pano_cylinder.zip (944 Bytes, 1475 views)
Reply With Quote