Three. js source code annotation (70) extras/geometries/CubeGeometry. js, three. jsgeometries

Source: Internet
Author: User

Three. js source code annotation (70) extras/geometries/CubeGeometry. js, three. jsgeometries

Wuji (http://blog.csdn.net/omni360)

This article follows the "signature-non-commercial use-consistency" creation public agreement

Reprinted please keep this sentence: Wuji-this blog focuses on Agile development and mobile and IOT device research: data visualization, GOLANG, Html5, WEBGL, THREE. JS. Otherwise, the post from this blog will not be reprinted or reprinted. Thank you for your cooperation.


I also just started learning. Sorry for the errors in many places.

The following code is a comment on the extras/geometries/CubeGeometry. JS file in the THREE. js source code file.

More updates in: https://github.com/omni360/three.js.sourcecode


/*** @ Author mrdoob/http://mrdoob.com/* // CubeGeometry is used to create a cube box object in 3D space. replaced by BoxGeometry object. //// usage: var geometry = new THREE. boxGeometry (1, 1); // var material = new THREE. meshBasicMaterial ({color: 0x00ff00}); // var cube = new THREE. mesh (geometry, material); // scene. add (cube ); * //// <summary> CubeGeometry </summary> /// <param name = "width" type = "float"> cube width </param> /// <param name = "height" type = "float"> cube height </param> // <param name = "depth" type = "float"> cube depth </param>/ // <param name = "widthSegments" type = "int"> Number of cube width segments </param> // <param name = "heightSegments" type = "int"> number of segments in the cube height </param> // <param name = "depthSegments" type = "int"> Number of segments in the cube depth </param> THREE. cubeGeometry = function (width, height, depth, widthSegments, heightSegments, depthSegments) {console. warn ('thee. cubeGeometry has been renamed to THREE. boxGeometry. '); return new THREE. boxGeometry (width, height, depth, widthSegments, heightSegments, depthSegments );};


Wuji (http://blog.csdn.net/omni360)

This article follows the "signature-non-commercial use-consistency" creation public agreement

Reprinted please keep this sentence: Wuji-this blog focuses on Agile development and mobile and IOT device research: data visualization, GOLANG, Html5, WEBGL, THREE. JS. Otherwise, the post from this blog will not be reprinted or reprinted. Thank you for your cooperation.


The following code is a comment on the extras/geometries/CubeGeometry. JS file in the THREE. js source code file.

More updates in: https://github.com/omni360/three.js.sourcecode

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.