summaryrefslogtreecommitdiff
path: root/scripts/content_tools/anim_tool.py
diff options
context:
space:
mode:
authorBrad Payne (Vir Linden) <vir@lindenlab.com>2016-06-14 10:54:30 -0400
committerBrad Payne (Vir Linden) <vir@lindenlab.com>2016-06-14 10:54:30 -0400
commit27bb57126ce3849bd72d4bb56e659f25ac5a35db (patch)
tree5527b0c108c9bbb284956b26d40abcb1fdedf1c3 /scripts/content_tools/anim_tool.py
parent93bafda56b7ba006da3a14a6c6783e235413176a (diff)
SL-353 - additional anim_tool.py option, --num_pos, to enable creation of large test files
Diffstat (limited to 'scripts/content_tools/anim_tool.py')
-rw-r--r--scripts/content_tools/anim_tool.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/scripts/content_tools/anim_tool.py b/scripts/content_tools/anim_tool.py
index 0cb1e1022e..5883a69360 100644
--- a/scripts/content_tools/anim_tool.py
+++ b/scripts/content_tools/anim_tool.py
@@ -518,6 +518,7 @@ if __name__ == "__main__":
parser.add_argument("--rand_pos", help="request random positions", action="store_true")
parser.add_argument("--reset_pos", help="request original positions", action="store_true")
parser.add_argument("--pos", help="specify sequence of positions", type=float_triple, nargs="+")
+ parser.add_argument("--num_pos", help="number of positions to create", type=int, default=2)
parser.add_argument("--delete_joints", help="specify joints to be deleted", nargs="+")
parser.add_argument("--joints", help="specify joints to be added or modified", nargs="+")
parser.add_argument("--summary", help="print summary of the output animation", action="store_true")
@@ -566,7 +567,7 @@ if __name__ == "__main__":
anim.add_pos(joints, args.pos)
if joints and args.rand_pos:
for joint in joints:
- pos_array = list(tuple(random.uniform(-1,1) for i in xrange(3)) for j in xrange(2))
+ pos_array = list(tuple(random.uniform(-1,1) for i in xrange(3)) for j in xrange(args.num_pos))
pos_array.append(pos_array[0])
anim.add_pos([joint], pos_array)
if joints and args.reset_pos: