OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2009, Google Inc. | 2 * Copyright 2009, Google Inc. |
3 * All rights reserved. | 3 * All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
7 * met: | 7 * met: |
8 * | 8 * |
9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 1822 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1833 // These are here so they are shared by both V8 and the browser. | 1833 // These are here so they are shared by both V8 and the browser. |
1834 window.g_finished = false; // for selenium | 1834 window.g_finished = false; // for selenium |
1835 window.g_timeMult = 1; | 1835 window.g_timeMult = 1; |
1836 window.g_clock = 0; | 1836 window.g_clock = 0; |
1837 | 1837 |
1838 // Comment out the line below to run the sample in the browser JavaScript | 1838 // Comment out the line below to run the sample in the browser JavaScript |
1839 // engine. This may be helpful for debugging. | 1839 // engine. This may be helpful for debugging. |
1840 o3djs.util.setMainEngine(o3djs.util.Engine.V8); | 1840 o3djs.util.setMainEngine(o3djs.util.Engine.V8); |
1841 | 1841 |
1842 o3djs.util.addScriptUri(''); | 1842 o3djs.util.addScriptUri(''); |
1843 o3djs.util.makeClients(initStep2, 'LargeGeometry'); | 1843 o3djs.util.makeClients(initStep2); |
1844 } | 1844 } |
1845 | 1845 |
1846 /** | 1846 /** |
1847 * Initializes O3D and loads the scene into the transform graph. | 1847 * Initializes O3D and loads the scene into the transform graph. |
1848 * @param {Array} clientElements Array of o3d object elements. | 1848 * @param {Array} clientElements Array of o3d object elements. |
1849 */ | 1849 */ |
1850 function initStep2(clientElements) { | 1850 function initStep2(clientElements) { |
1851 g_materialPanelElement = o3djs.util.getElementById('materialpanel'); | 1851 g_materialPanelElement = o3djs.util.getElementById('materialpanel'); |
1852 g_propPanelElement = o3djs.util.getElementById('proppanel'); | 1852 g_propPanelElement = o3djs.util.getElementById('proppanel'); |
1853 g_effectPanelElement = o3djs.util.getElementById('effectpanel'); | 1853 g_effectPanelElement = o3djs.util.getElementById('effectpanel'); |
(...skipping 800 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2654 | 2654 |
2655 /** | 2655 /** |
2656 * Removes any callbacks so they don't get called after the page has unloaded. | 2656 * Removes any callbacks so they don't get called after the page has unloaded. |
2657 */ | 2657 */ |
2658 function uninit() { | 2658 function uninit() { |
2659 if (g_client) { | 2659 if (g_client) { |
2660 g_client.cleanup(); | 2660 g_client.cleanup(); |
2661 } | 2661 } |
2662 } | 2662 } |
2663 | 2663 |
OLD | NEW |