WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
Old 04-05-2012, 07:27 PM
allanjjj allanjjj is offline
Join Date: Mar 2012
Posts: 2
Unhappy Cannot moving AR model......

I would like to animate AR model by keyboard input after the model is shown by detecting marker. The model is shown correctly in the center of marker but it cannot move. It just sticks on the marker no matter what key I pressed. Here is the code:

import viz
import vizact

ar = viz.add('artoolkit.dle')
camera = ar.addWebCamera()
marker = camera.addMarker('ar/patt.worldviz',width=1000)
wheel = viz.add('wheelbarrow.ive'),wheel)

moveForward = vizact.move(0,0,2,1)
moveBack = vizact.move(0,0,-2,1)
turnRight = vizact.spin(0,1,0,90,1)
turnLeft = vizact.spin(0,1,0,-90,1)

def mykeyboard(whichKey):
if whichKey == viz.KEY_UP:
elif whichKey == viz.KEY_DOWN:
elif whichKey == viz.KEY_LEFT:
elif whichKey == viz.KEY_RIGHT:

viz.callback(viz.KEYDOWN_EVENT, mykeyboard)

Can anyone help me out? many thanks~
Reply With Quote


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
change a model between scenes? Darkmax Vizard 2 05-25-2010 03:14 PM
Change model alpha and memory leak hosier Vizard 2 06-25-2009 10:55 AM
Importing a 3d human model and getting it to interact. yak Vizard 3 06-01-2009 02:19 PM
Stop moving after few seconds?? Chrissy2009 Vizard 8 05-10-2009 02:47 PM
Model sizes Pastscapian Vizard 15 10-07-2006 02:48 PM

All times are GMT -7. The time now is 06:16 AM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2022, vBulletin Solutions, Inc.
Copyright 2002-2018 WorldViz LLC