You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
voidsetup() {
size(100, 100, P3D);
background(0);
noStroke();
}
voiddraw() {
// Adiciona um luz ao início de // draw() para torná-la persistente lights();
translate(20, 50, 0);
sphere(30);
translate(60, 0, 0);
sphere(30);
}
Descrição
Especifica o valor padrão de luz ambiente, direcionada, *falloff *(n.t.
decaimento), e especular. Os valores padrão são
ambientLight(128, 128, 128), directionalLight(128, 128, 128, 0, 0, -1),
falloff(1, 0, 0), e specular(0, 0, 0). Luzes são
incluídas na função draw() para permanecerem
persistentes em programas em laço. Sua chamda em setup() em um
programa em laço terá efeito apenas na primeira vez que
se percorrer este.