<commit_before>/*
 This example demonstrates how to define geometry, in this case a simple cube
 object that supports texturing.

 <NAME>,
 <EMAIL>

 This example assumes that you have looked at a few of the other examples
 and now have an understanding of concepts such as basic SceneJS syntax,
 lighting, material, data flow etc.

 Scroll down to the SceneJS.geometry node about one third of the way down
 this file and I'll guide you from there.

 */


SceneJS.createNode({
    type: "scene",
    id: "the-scene",
    canvasId: "theCanvas",
    loggingElementId: "theLoggingDiv",

    nodes: [
        {
            type: "lookAt",
            eye : { x: 40.0, y: 10.0, z: -35 },
            look : { x:13.0, y: -2.0, z: -5.0 },
            up : { y: 1.0 },

            nodes: [
                {
                    type: "camera",
                    optics: {
                        type: "perspective",
                        fovy : 25.0,
                        aspect : 1.47,
                        near : 0.10,
                        far : 300.0
                    },
                    nodes: [
                      {
                          type: "material",
                          baseColor:      { r: 1.0, g: 1.0, b: 1.0 },
                          specularColor:  { r: 0.9, g: 0.9, b: 0.9 },
                          specular:       0.9,
                          shine:          6.0,
                          nodes: [
                              {
                                  type: "billboard",
                                  nodes: [
                                      {
                                          type: "geometry",
                                          resource: "my-geometry",
                                          primitive: "triangles",
                                          positions: [
                                              -1,  1, 0,
                                               1,  1, 0,
                                               1, -1, 0,
                                              -1, -1, 0 ],
                                          indices: [ 0, 1, 2, 0, 2, 3 ]
                                      }
                                  ]
                              }
                            ]
                        }
                    ]
                }
            ]
        }
    ]
});


var yaw = 30;
var pitch = -30;<commit_msg>Add additional translation & rotation to the billboard example to check that model space transformations work correctly<commit_after>/*
 This example demonstrates how to define geometry, in this case a simple cube
 object that supports texturing.

 <NAME>,
 <EMAIL>

 This example assumes that you have looked at a few of the other examples
 and now have an understanding of concepts such as basic SceneJS syntax,
 lighting, material, data flow etc.

 Scroll down to the SceneJS.geometry node about one third of the way down
 this file and I'll guide you from there.

 */


SceneJS.createNode({
    type: "scene",
    id: "the-scene",
    canvasId: "theCanvas",
    loggingElementId: "theLoggingDiv",

    nodes: [
        {
            type: "lookAt",
            eye : { x: 40.0, y: 10.0, z: -35 },
            look : { x:13.0, y: -2.0, z: -5.0 },
            up : { y: 1.0 },

            nodes: [
                {
                    type: "camera",
                    optics: {
                        type: "perspective",
                        fovy : 25.0,
                        aspect : 1.47,
                        near : 0.10,
                        far : 300.0
                    },
                    nodes: [
                        {
                            type: "material",
                            baseColor:      { r: 1.0, g: 1.0, b: 1.0 },
                            specularColor:  { r: 0.9, g: 0.9, b: 0.9 },
                            specular:       0.9,
                            shine:          6.0,
                            nodes: [
                                {
                                    type: "rotate",
                                    x: 1.0,
                                    angle: 45.0,
                                    nodes: [
                                        {
                                            type: "translate",
                                            y: -2.0, z: -5.0,
                                            nodes: [
                                                {
                                                    type: "billboard",
                                                    nodes: [
                                                        {
                                                            type: "geometry",
                                                            resource: "my-geometry",
                                                            primitive: "triangles",
                                                            positions: [
                                                                -1,  1, 0,
                                                                 1,  1, 0,
                                                                 1, -1, 0,
                                                                -1, -1, 0 ],
                                                            indices: [ 0, 1, 2, 0, 2, 3 ]
                                                        }
                                                    ]
                                                }
                                            ]
                                        }
                                    ]
                                }
                            ]
                        }
                    ]
                }
            ]
        }
    ]
});


var yaw = 30;
var pitch = -30;
{'fraction_non_alphanumeric': 0.07696211096075778, 'fraction_numerical': 0.02452638700947226, 'mean_word_length': 0.5188800410994092, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 71, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1194601', 'n_tokens_mistral': 1303, 'n_tokens_neox': 1153, 'n_words': 370}