#1
|
|||
|
|||
Maximum Number of Avatars?
I'm doing some research into some upcoming projects, and trying to answer some questions...such as:
1. What is the maximum number of avatars that Vizard can support? 2. If there isn't a limit in the software, what level of hardware capability would be needed to run 100 avatars? 3. What problems might we expect to encounter at this level? 4. What could we do to streamline or reduce the impact of this many avatars? 5. How complex of behaviors could we achieve without causing a large amount of lag? |
#2
|
|||
|
|||
The CPU limiting factor with avatars is recomputing their mesh for each frame of animation. So to reduce this load:
>Use lower polygon avatars. >Decrease the number of times the avatar's animation is recomputed with the avatar.updaterate() function. Its best to use these two options on avatars that are further from the viewer. You could also set avatar's updaterate to 0 when they are out of view. The viz.MainWindow.isCulled(avatar) returns True if the avater is out of view. Don't know what it takes to get 100 animating avatars, but upgrading the CPU should improve performance.
__________________
Paul Elliott WorldViz LLC |
#3
|
|||
|
|||
Thanks, that should be pretty helpful.
-MJ |
#4
|
|||
|
|||
Dance party test
Here is an avatar stress test script. Sliders control the number of avatars and the update rate.
Code:
import viz import vizact viz.go() MAX_AVATARS = 100 START_COUNT = 10 viz.MainView.setPosition([0, 1.5, -5]) viz.window.framerate(viz.NICE) #dance beat music = viz.add('carousel.wav',volume=0.15,loop=1) music.play() avatars = [] updateRate = 0 def addAvatar(): a = viz.add('vcc_female.cfg') a.state(5) a.setPosition([.5*len(avatars), 0, 0]) a.updaterate(updateRate) avatars.append(a) for i in range(START_COUNT): addAvatar() def removeAvatar(): avatars.pop().remove() import vizinfo info = vizinfo.add('') avatarSlider = info.add(viz.SLIDER, 'avatar count '+str(START_COUNT)) updateRateSlider = info.add(viz.SLIDER, 'update rate 0 ') def onAvatarSlider(pos): targetCount = int(pos * MAX_AVATARS) avatarSlider.label.message('avatar count: ' + str(targetCount)) countDiff = targetCount - len(avatars) if countDiff > 0: #add avatars for i in range(countDiff): addAvatar() else: #subtract avatars for i in range(-countDiff): removeAvatar() vizact.onslider(avatarSlider, onAvatarSlider) def setUpdateRate(rate): global updateRate updateRate = rate * .2 updateRateSlider.label.message('update rate' + str(round(updateRate, 3))) for a in avatars: a.updaterate(updateRate) vizact.onslider(updateRateSlider, setUpdateRate)
__________________
Paul Elliott WorldViz LLC |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Randomly and Continuously Change Avatar's Face Texture | Karla | Vizard | 4 | 08-22-2008 01:14 PM |
avatars | dig | Vizard | 4 | 09-20-2007 04:29 PM |
Avatars in an array and link/unlink | betancourtb82 | Vizard | 7 | 09-05-2006 05:06 PM |
maximum number of markers | tavaksai | Precision Position Tracker (PPT) | 1 | 02-02-2006 10:09 PM |
number of faces to load using the 'old' txt version of avatars | bailenson | Vizard | 1 | 06-06-2004 01:30 PM |