Home > Designing > Panda3D video cube example

Panda3D video cube example

One of the major drawbacks of the Blender game engine is that it doesn’t support video textures. There is something under development but it is still in its early stages.

Panda3D on the other hand has solid support for video textures. Getting it to work is really easy:

import direct.directbase.DirectStart

#load movie texture from disk
tex = loader.loadTexture("trailer.avi")
#load 3D cube model (.egg file) from disk
cube = loader.loadModel("videotexttest")
#put the cube in the scenegraph
#set the cube's position
#apply the texture
#rotate the cube
#scale the cube

#run the program

The cube was created with Blender and then exporter with Chicken, a blender to .egg exporter.

Categories: Designing Tags: , ,
  1. No comments yet.
  1. No trackbacks yet.
You must be logged in to post a comment.