From 0f204f932c9e505920f74acc8c48f909686a6dab Mon Sep 17 00:00:00 2001 From: Stephen Birarda Date: Tue, 8 Apr 2014 18:00:24 -0700 Subject: [PATCH] add apache license information to more js files --- examples/globalCollisionsExample.js | 2 ++ examples/gun.js | 2 ++ examples/hideAvatarExample.js | 2 ++ examples/hydraMove.js | 2 ++ examples/includeExample.js | 3 +++ examples/inspect.js | 3 +++ examples/lookAtExample.js | 2 ++ examples/lookWithMouse.js | 2 ++ examples/lookWithTouch.js | 2 ++ examples/menuExample.js | 3 +++ examples/multitouchExample.js | 3 +++ examples/overlaysExample.js | 2 ++ examples/paintGun.js | 3 +++ examples/particleBird.js | 3 +++ examples/particleModelExample.js | 3 +++ examples/playSound.js | 2 ++ examples/rayPickExample.js | 2 ++ examples/ribbon.js | 3 +++ examples/rideAlongWithAParticleExample.js | 3 +++ examples/seeingVoxelsExample.js | 3 +++ examples/selectAudioDevice.js | 3 +++ examples/settingsExample.js | 6 +++--- examples/spaceInvadersExample.js | 3 +++ examples/toyball.js | 2 ++ examples/voxelDrumming.js | 3 +++ 25 files changed, 64 insertions(+), 3 deletions(-) diff --git a/examples/globalCollisionsExample.js b/examples/globalCollisionsExample.js index 6dfd4ee3f8..b9d1dceefe 100644 --- a/examples/globalCollisionsExample.js +++ b/examples/globalCollisionsExample.js @@ -7,6 +7,8 @@ // // This is an example script that demonstrates use of the Controller class // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html // diff --git a/examples/gun.js b/examples/gun.js index 6d3bbb2193..85d0f9c1e5 100644 --- a/examples/gun.js +++ b/examples/gun.js @@ -10,6 +10,8 @@ // It reads the controller, watches for trigger pulls, and launches particles. // When particles collide with voxels they blow little holes out of the voxels. // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html // diff --git a/examples/hideAvatarExample.js b/examples/hideAvatarExample.js index 046ebc1a3b..d9e4b350f4 100644 --- a/examples/hideAvatarExample.js +++ b/examples/hideAvatarExample.js @@ -7,6 +7,8 @@ // // This is an example script that demonstrates how to enable or disable local rendering of your own avatar // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html // function keyReleaseEvent(event) { diff --git a/examples/hydraMove.js b/examples/hydraMove.js index 9ff776c0eb..e2dd608b4a 100644 --- a/examples/hydraMove.js +++ b/examples/hydraMove.js @@ -8,6 +8,8 @@ // This is an example script that demonstrates use of the Controller and MyAvatar classes to implement // avatar flying through the hydra/controller joysticks // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html // var damping = 0.9; diff --git a/examples/includeExample.js b/examples/includeExample.js index 68c9828630..e82a95fc63 100644 --- a/examples/includeExample.js +++ b/examples/includeExample.js @@ -7,6 +7,9 @@ // // This is an example script that demonstrates use of the Script.include() feature // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// // You can include scripts from URLs Script.include("http://public.highfidelity.io/scripts/lookWithTouch.js"); diff --git a/examples/inspect.js b/examples/inspect.js index 1b220ad333..5402a6a830 100644 --- a/examples/inspect.js +++ b/examples/inspect.js @@ -13,6 +13,9 @@ // Once you are in a mode left click on the object to inspect and hold the click // Dragging the mouse will move your camera according to the mode you are in. // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// var PI = 3.14 // No need for something more precise diff --git a/examples/lookAtExample.js b/examples/lookAtExample.js index c76273a3c7..6e208ddbdd 100644 --- a/examples/lookAtExample.js +++ b/examples/lookAtExample.js @@ -12,6 +12,8 @@ // on the face of the voxel that you clicked. Click again and it will stop looking at that point. While in this fixed mode // you can use the arrow keys to change the position of the camera. // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html // var lookingAtSomething = false; diff --git a/examples/lookWithMouse.js b/examples/lookWithMouse.js index 02bf9fbe13..4293654ae5 100644 --- a/examples/lookWithMouse.js +++ b/examples/lookWithMouse.js @@ -7,6 +7,8 @@ // // This is an example script that demonstrates use of the Controller class // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html // var alwaysLook = true; // if you want the mouse look to happen only when you click, change this to false diff --git a/examples/lookWithTouch.js b/examples/lookWithTouch.js index 71d0137533..0278d2b7b2 100644 --- a/examples/lookWithTouch.js +++ b/examples/lookWithTouch.js @@ -7,6 +7,8 @@ // // This is an example script that demonstrates use of the Controller class // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html // var startedTouching = false; diff --git a/examples/menuExample.js b/examples/menuExample.js index 92081038f5..d448c32bf8 100644 --- a/examples/menuExample.js +++ b/examples/menuExample.js @@ -7,6 +7,9 @@ // // This is an example script that demonstrates use of the Menu object // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// function setupMenus() { diff --git a/examples/multitouchExample.js b/examples/multitouchExample.js index 4a4b6427f8..b76902f57a 100644 --- a/examples/multitouchExample.js +++ b/examples/multitouchExample.js @@ -11,6 +11,9 @@ // * Four finger rotate gesture will rotate your avatar. // * Three finger swipe up/down will adjust the pitch of your avatars head. // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// var lastX = 0; var lastY = 0; diff --git a/examples/overlaysExample.js b/examples/overlaysExample.js index 5b2c89391e..ec54438692 100644 --- a/examples/overlaysExample.js +++ b/examples/overlaysExample.js @@ -7,6 +7,8 @@ // // This is an example script that demonstrates use of the Overlays class // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html // diff --git a/examples/paintGun.js b/examples/paintGun.js index e7477318ed..fa2d4f1e1f 100644 --- a/examples/paintGun.js +++ b/examples/paintGun.js @@ -5,6 +5,9 @@ // Created by Brad Hefta-Gaub on 12/31/13. // Copyright (c) 2013 HighFidelity, Inc. All rights reserved. // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// // initialize our triggers var triggerPulled = new Array(); diff --git a/examples/particleBird.js b/examples/particleBird.js index 86ee6e7aa4..59ada1950e 100644 --- a/examples/particleBird.js +++ b/examples/particleBird.js @@ -4,6 +4,9 @@ // // This sample script moves a voxel around like a bird and sometimes makes tweeting noises // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// function vLength(v) { return Math.sqrt(v.x * v.x + v.y * v.y + v.z * v.z); diff --git a/examples/particleModelExample.js b/examples/particleModelExample.js index 5f99c46d7b..96b16c503d 100644 --- a/examples/particleModelExample.js +++ b/examples/particleModelExample.js @@ -7,6 +7,9 @@ // // This is an example script that demonstrates creating and editing a particle // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// var count = 0; var stopAfter = 100; diff --git a/examples/playSound.js b/examples/playSound.js index 18857826ea..7715604de2 100644 --- a/examples/playSound.js +++ b/examples/playSound.js @@ -1,6 +1,8 @@ // // This sample script loads a sound file and plays it at the 'fingertip' of the // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html // First, load the clap sound from a URL var clap = new Sound("https://s3-us-west-1.amazonaws.com/highfidelity-public/sounds/Animals/bushtit_1.raw"); diff --git a/examples/rayPickExample.js b/examples/rayPickExample.js index 7e20a4e95d..13ab285af5 100644 --- a/examples/rayPickExample.js +++ b/examples/rayPickExample.js @@ -7,6 +7,8 @@ // // This is an example script that demonstrates use of the Camera class // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html // function mouseMoveEvent(event) { diff --git a/examples/ribbon.js b/examples/ribbon.js index be8b521f7c..5e48ee3193 100644 --- a/examples/ribbon.js +++ b/examples/ribbon.js @@ -5,6 +5,9 @@ // Created by Andrzej Kapolka on 2/24/14. // Copyright (c) 2014 High Fidelity, Inc. All rights reserved. // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// function vectorMultiply(vector, scalar) { return [ vector[0] * scalar, vector[1] * scalar, vector[2] * scalar ]; diff --git a/examples/rideAlongWithAParticleExample.js b/examples/rideAlongWithAParticleExample.js index ce0133b25c..a6decbc2c2 100644 --- a/examples/rideAlongWithAParticleExample.js +++ b/examples/rideAlongWithAParticleExample.js @@ -7,6 +7,9 @@ // // This is an example script that demonstrates "finding" particles // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// var iteration = 0; var lengthOfRide = 2000; // in iterations diff --git a/examples/seeingVoxelsExample.js b/examples/seeingVoxelsExample.js index e7a9e9f07a..e0f991ea40 100644 --- a/examples/seeingVoxelsExample.js +++ b/examples/seeingVoxelsExample.js @@ -7,6 +7,9 @@ // // This is an example script // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// var count = 0; var yawDirection = -1; diff --git a/examples/selectAudioDevice.js b/examples/selectAudioDevice.js index be3f621cdb..668e467254 100644 --- a/examples/selectAudioDevice.js +++ b/examples/selectAudioDevice.js @@ -7,6 +7,9 @@ // // This is an example script that demonstrates use of the Menu object // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// if (typeof String.prototype.startsWith != 'function') { String.prototype.startsWith = function (str){ diff --git a/examples/settingsExample.js b/examples/settingsExample.js index 53e8a8a63c..816fc956a3 100644 --- a/examples/settingsExample.js +++ b/examples/settingsExample.js @@ -7,9 +7,9 @@ // // This is an example script that demonstrates use of the Menu object // - - - +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// print("mySetting: " + Settings.getValue("mySetting")); Settings.setValue("mySetting", "spam"); diff --git a/examples/spaceInvadersExample.js b/examples/spaceInvadersExample.js index 7dd5037cda..be4fcf445f 100644 --- a/examples/spaceInvadersExample.js +++ b/examples/spaceInvadersExample.js @@ -7,6 +7,9 @@ // // This is an example script that demonstrates a simple space invaders style of game // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// var iteration = 0; diff --git a/examples/toyball.js b/examples/toyball.js index 9b57987eca..52646c94b4 100644 --- a/examples/toyball.js +++ b/examples/toyball.js @@ -11,6 +11,8 @@ // The particles it creates have a script that when they collide with Voxels, the // particle will change it's color to match the voxel it hits. // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html // // maybe we should make these constants... diff --git a/examples/voxelDrumming.js b/examples/voxelDrumming.js index e8f852ccf2..f064d6736e 100644 --- a/examples/voxelDrumming.js +++ b/examples/voxelDrumming.js @@ -9,6 +9,9 @@ // // It adds Hydra controller "fingertip on voxels" drumming // +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// Menu.addMenuItem({ menuName: "Developer > Hand Options",