Return-Path: Received: from mail-qc0-f173.google.com ([209.85.216.173] verified) by media-motion.tv (CommuniGate Pro SMTP 4.2.10) with ESMTP-TLS id 5284050 for AE-List@media-motion.tv; Tue, 12 Nov 2013 23:17:14 +0100 Received: by mail-qc0-f173.google.com with SMTP id m4so2654779qcy.18 for ; Tue, 12 Nov 2013 14:19:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=poS9b9XvWxX2ZvOUn0dlA3xwHgDBT4xQiEQYDQ56Sgc=; b=zL0x/enncItEL7+ya8DvVAK45NlqEoAnqe+2+ZdWdVla3/9Xx+JkQhJ8j841rVIa6w f3o05TW3DUophd9PyO7i8FX0lnjccyVt3td1AjRcH0by06UCZhFTTCE1oFROSqz/O0yv Z4Xy/w1zfbud3BTHX+JliweuA674Ofukvj0v1hzh7vjwnB3pZ47p2Iq0BPzQgK53JEvG 749XPXLh8ZEzXehZvInyvpNiyhvQ22YigFar7enrLcZcHrCarHIIedfaC1GVJrv42/KZ 64VjC0bMdrVWI57nkHI3k8sWh1pjYUU6CiBiK5JCDxz2tTEmdh9RKUA+ND58+RCHtQaX j1FA== MIME-Version: 1.0 X-Received: by 10.49.101.8 with SMTP id fc8mr60237865qeb.31.1384294739937; Tue, 12 Nov 2013 14:18:59 -0800 (PST) Received: by 10.229.104.131 with HTTP; Tue, 12 Nov 2013 14:18:59 -0800 (PST) Date: Tue, 12 Nov 2013 17:18:59 -0500 Message-ID: Subject: freeze frame from precomp - expression needed to not get duplicates From: Greg Balint To: After Effects Mail List Content-Type: multipart/alternative; boundary=001a11c2bd8e3d10e304eb023cbb --001a11c2bd8e3d10e304eb023cbb Content-Type: text/plain; charset=ISO-8859-1 Got a quick one here.. something i'm probably just either not familiar with, or I'm thinking too hard about it. I've got a large grid wall of squares with people's faces in them. Each face panel is the same precomp with this expression in the time-remap attribute. seedRandom(index,true); myFrame = Math.floor(random(303)); framesToTime(myFrame) Basically this grabs a random frame from the precomp, which is about 10 seconds long, and shows it as a freeze frame for that particular layer. I've got 125 face panels all using this expression, and for the most part it works wonderfully.. they all have random faces on them, and if I add another layer, the random seed changes and I get a whole new slew of faces (which doesn't matter in this instance, but i could see that as a problem in others) My issue is, even though I've got over 300 frames (each frame with a new face) in my precomp.. the randomness is grabbing duplicates.. in some cases 2-3 pairs of duplicates over the course of the 125 it chooses. Anyone know of a way to append this script so that it does not choose something it has already? I'd even be fine if there were a way to use an expression to grab frames sequentially from the precomp and then I could just hand choose to make sure there's no duplicates in the first 125 frames. I think i might just be overthinking this, but I'm not sure if I've seen a "check for duplicate and don't use" sort of expression before. thanks in advance. -- ///Greg Balint //Art Director / Motion Graphics Designer /321.514.4839 delRAZOR.com/ --001a11c2bd8e3d10e304eb023cbb Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Got a quick one here.. something i'm probably just eit= her not familiar with, or I'm thinking too hard about it.

I've got a large grid wall of squares with people's faces in = them. =A0Each face panel is the same precomp with this expression in the ti= me-remap attribute.

seedRandom(index,true);
myFrame =3D Math= .floor(random(303));
framesToTime(myFrame)

Basically this grabs a random frame from the precomp, which is about 10 = seconds long, and shows it as a freeze frame for that particular layer.

I've got 125 face panels all using this expression,= and for the most part it works wonderfully.. they all have random faces on= them, and if I add another layer, the random seed changes and I get a whol= e new slew of faces (which doesn't matter in this instance, but i could= see that as a problem in others)

My issue is, even though I've got over 300 frames (= each frame with a new face) in my precomp.. the randomness is grabbing dupl= icates.. in some cases 2-3 pairs of duplicates over the course of the 125 i= t chooses.


Anyone know of a way to append this scri= pt so that it does not choose something it has already?

I'd even be fine if there were a way to use an expression to grab= frames sequentially from the precomp and then I could just hand choose to = make sure there's no duplicates in the first 125 frames.

I think i might just be overthinking this, but I'm = not sure if I've seen a "check for duplicate and don't use&quo= t; sort of expression before.

thanks in advance.

--
///Greg Balint
//Art Director / Motion Graphics Designer
/321.514.4839
delRAZOR.com/ 
--001a11c2bd8e3d10e304eb023cbb--