Control noise strength from script

Control noise strength from script

matthew_turnerE7B7E
Observer Observer
824 Views
5 Replies
Message 1 of 6

Control noise strength from script

matthew_turnerE7B7E
Observer
Observer

So the script below is supposed to create a position list, then a noise controller, this works. However I then need to animate the noise strength.. this is where I have problems and the script no longer works.. any ideas ? Thanks 😊 

$.pos.controller = PositionList () -- adds position list

$.pos.controller.setActive 1  -- makes controller active

$.pos.Available.controller = Noise_position () -- adds noise controller
	
	
set animate on
		
sliderTime = 10f
	
			$.pos.Available.controller.noise_strength = [0,0,0] 	
-- puts a key frame with custom strength sizes 
	
	set animate off

 

0 Likes
Accepted solutions (1)
825 Views
5 Replies
Replies (5)
Message 2 of 6

denisT.MaxDoctor
Advisor
Advisor
Accepted solution
delete objects
gc()

t = teapot name:#sick_teapot isselected:on
c = t.pos.controller = position_list()
n = c.available.controller = noise_position()
c.setactive 2
s = n.noise_strength.controller = bezier_point3()
animate on
(
	at time 0f s.value = [0,0,0]
	at time 100f s.value = [0,0,100]
)
0 Likes
Message 3 of 6

domo.spaji
Advisor
Advisor

Don't have to set it active?

Or do you?

0 Likes
Message 4 of 6

denisT.MaxDoctor
Advisor
Advisor

You will decide. The #active state does not affect the ability to animate #strength.

By setting the #noise controller to active, we "block" editing of the original translation through the user interface.

0 Likes
Message 5 of 6

matthew_turnerE7B7E
Observer
Observer

Ace! Thank you 🙏 

0 Likes
Message 6 of 6

domo.spaji
Advisor
Advisor

Ah, OK.

Tnx

 

0 Likes