#1
|
|||
|
|||
viz.Screen Images overlap and Interface Button
Hi,
I created an interface that stick to the screen by using TexQuad and viz.Screen. The interface resemble a video player that can play video. Since the interface would be overlapping with the video, what I did was, I initialized the interface first then the video, and these enabled the video to be displayed in front the interface. The problem is, when I applied the alpha to the interface, why did the video's opacity was affected as well? here is the sample code.. Code:
#the player interface intface = viz.add('videoPlayer.jpg') vidPlayer = viz.addTexQuad(parent=viz.SCREEN,pos=(0.5,0.5,0.1)) vidPlayer.alpha(0.75) vidPlayer.setScale([12,6,0]) vidPlayer.texture(intface) #the video vid = viz.addVideo('vizard.mpg',loop=1,play=1) movie = viz.addTexQuad(parent=viz.SCREEN,pos=(0.5,0.52,0)) movie.setScale([4,4,0]) movie.texture(vid) Another matter is, I was wondering, how do I create the button for this Player? Is it by creating another image,a Close button for instant, translate it to the desired location, and apply the 'vizact.onpick' function. Or do you have any better solution? Thanks |
#2
|
|||
|
|||
Try giving the video quad a very high draw order. This should force it to render after the interface:
Code:
movie.drawOrder(100) |
|
|