[x3d-public] Missing spaces, normalized ECMAScript. in X3DJSAIL output

John Carlson yottzumm at gmail.com
Sun Jan 28 13:49:09 PST 2018


Missing spaces, normalized ECMAScript (normalized in JSON as well).

See diff:


$ diff HelloWorldProgramOutput.x3d HelloWorldProgramOutput.Nashorn.js.new.x3d   85c85
<                     <!-- alternative XML encoding: Text string='"One, Two, Three" "" "He said, \"Immel did it!\""' -->
---
>                     <!-- alternative XML encoding: Text string='"One, Two, Three""""He said, \"Immel did it!\""' -->
106c106
< ecmascript:
---
> ecmascript: function colorInput (eventValue) // Example source code { colorsOutput = new MFColor(eventValue); // assigning value sends output event // Browser.print('colorInput=' + eventValue + ', colorsOutput=' + colorsOutput + '\n'); }
108,112d107
< function colorInput (eventValue) // Example source code
< {
<    colorsOutput = new MFColor(eventValue); // assigning value sends output event
< // Browser.print('colorInput=' + eventValue + ', colorsOutput=' + colorsOutput + '\n');
< }
208,230c203,204
< ecmascript:
< function initialize ()
< {
<     newColor = diffuseColor; // start with correct color
< }
< function set_enabled (newValue)
< {
<       enabled = newValue;
< }
< function clockTrigger (timeValue)
< {
<     if (!enabled) return;
<     red   = newColor.r;
<     green = newColor.g;
<     blue  = newColor.b;
<
<     // note different modulation rates for each color component, % is modulus operator
<     newColor = new SFColor ((red + 0.02) % 1, (green + 0.03) % 1, (blue + 0.04) % 1);
<       if (enabled)
<       {
<               Browser.print ('diffuseColor=(' + red + ',' + green + ',' + blue + ') newColor=' + newColor.toString() + '\n');
<       }
< }
---
> ecmascript: function initialize () { newColor = diffuseColor; // start with correct color } function set_enabled (newValue) { enabled = newValue; } function clockTrigger (timeValue) { if (!enabled) return; red = newColor.r; green = newColor.g; blue = newColor.b; // note different modulation rates for each color component, % is modulus operator newColor = new SFColor ((red + 0.02) % 1, (green + 0.03) % 1, (blue + 0.04) % 1); if (enabled) { Browser.print ('diffuseColor=(' + red + ',' + green + ',' + blue + ') newColor=' + newColor.toString() + '\n'); } }
>
272c246
<                 <!-- Expected containerField='source', allowed containerField values="texture" "source" "back" "bottom" "front" "left" "right" "top" "backTexture" "bottomTexture" "frontTexture" "leftTexture" "rightTexture" "topTexture" -->
---
>                 <!-- Expected containerField='source', allowed containerField values="texture""source""back""bottom""front""left""right""top""backTexture""bottomTexture""frontTexture""leftTexture""rightTexture""topTexture" -->

coderextreme at DE
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20180128/57a24f16/attachment.html>


More information about the x3d-public mailing list