Skip to content

Commit

Permalink
Merge pull request #325 from YewonCALLI/patch-4
Browse files Browse the repository at this point in the history
[p5.js KO] update korean translation (Foundation, 3D)
  • Loading branch information
limzykenneth committed May 8, 2024
2 parents 803b7f5 + cefda39 commit 7e514e7
Show file tree
Hide file tree
Showing 31 changed files with 516 additions and 1,227 deletions.
49 changes: 16 additions & 33 deletions src/content/reference/ko/p5/Array.mdx
Original file line number Diff line number Diff line change
@@ -1,42 +1,34 @@
---
title: Array
module: Foundation
submodule: Foundation
module: 기초론
submodule: 기초론
file: src/core/reference.js
description: >
<p>A list that keeps several pieces of data in order.</p>
<p>배열은 여러 개의 데이터를 순서대로 저장하는 목록입니다.</p>
<p>Arrays are helpful for storing related data. They can contain data of any
type. For example, an array could contain a list of someone's favorite
colors as strings. Arrays are created as follows:</p>
<p>배열은 서로 관련된 데이터를 저장하는 데 유용합니다.
배열은 모든 유형의 데이터를 포함할 수 있습니다.
예를 들어 배열은 문자열로 된 색상 목록을 포함할 수 있습니다. 배열은 다음과 같이 생성됩니다:</p>
<code>
let colors = ['deeppink', 'darkorchid', 'magenta'];
</code>
<p>배열의 각 데이터는 요소라고 불립니다. 각 요소는 배열 내에서 주소 또는 인덱스를 가집니다.
<p>Each piece of data in an array is called an element. Each element has an
address, or index, within its array. The variable <code>colors</code> refers
to an
array with three <a href="/reference/p5/String">String> elements,
<code>'deeppink'</code>,
변수 <code>colors</code>는 세 개의 <a href="/reference/p5/String">String</a> 요소인
<code>'darkorchid'</code>, and <code>'magenta'</code>. Arrays are
zero-indexed, which means
<code>'deeppink'</code>, <code>'darkorchid'</code>, <code>'magenta'</code>를 가리킵니다.
that <code>'deeppink'</code> is at index 0, <code>'darkorchid'</code> is at
index 1, and
배열은 0부터 시작하는 인덱스를 가지며, 따라서 <code>'deeppink'</code>는 인덱스 0에,
'<code>magenta'</code> is at index 2. Array elements can be accessed using
their
<code>'darkorchid'</code>는 인덱스 1에, '<code>magenta'</code>는 인덱스 2에 있습니다.
indices as follows:</a></p>
배열 요소는 다음과 같이 인덱스를 사용하여 액세스할 수 있습니다:</p>
<code>
Expand All @@ -48,26 +40,17 @@ description: >
</code>
<p>Elements can be added to the end of an array by calling the
<code>push()</code>
method as follows:</p>
<p>요소는 <code>push()</code> 메서드를 호출하여 배열의 끝에 추가할 수 있습니다.</p>
<code>
colors.push('lavender');
<p>let third = colors[3]; // 'lavender'
</p></code>
<p>See <a
href="https://developer.mozilla.org/en-US/docs/Learn/JavaScript/First_steps/Arrays"
target="_blank">MDN</a>
for more information about arrays.</p>
<p>배열에 대한 자세한 내용은 <a href="https://developer.mozilla.org/en-US/docs/Learn/JavaScript/First_steps/Arrays" target="_blank">MDN</a>에서 확인할 수 있습니다.</p>
line: 1137
isConstructor: false
itemtype: property
Expand Down
40 changes: 15 additions & 25 deletions src/content/reference/ko/p5/TEXTURE.mdx
Original file line number Diff line number Diff line change
@@ -1,44 +1,34 @@
---
title: texture
module: 3D
submodule: Material
submodule: 재질
file: src/webgl/material.js
description: >
<p>Sets the texture that will be used on shapes.</p>
<p>도형에 사용할 텍스처를 설정합니다.</p>
<p>A texture is like a skin that wraps around a shape. <code>texture()</code>
works with
<p>텍스처는 도형을 감싸는 피부와 같은 역할을 합니다. <code>texture()</code>는
built-in shapes, such as <a href="/reference/p5/square">square()</a> and
내장된 <a href="/reference/p5/square">square()</a>나 <a href="/reference/p5/sphere">sphere()</a>와 같은
<a href="/reference/p5/sphere">sphere()</a>, and custom shapes created with
도형과, <a href="/reference/p5/buildGeometry">buildGeometry()</a>와 같은 함수로 생성된 사용자 정의 도형에서 작동합니다.
functions such as <a href="/reference/p5/buildGeometry">buildGeometry()</a>.
To
<a href="/reference/p5/beginShape">beginShape()</a>로 생성된 기하에 텍스처를 입히려면
texture a geometry created with <a
href="/reference/p5/beginShape">beginShape()</a>,
각 <a href="/reference/p5/vertex">vertex()</a> 호출에 uv 좌표를 전달해야 합니다.</p>
uv coordinates must be passed to each
<p><code>tex</code>는 텍스처를 적용할 매개변수입니다.
<a href="/reference/p5/vertex">vertex()</a> call.</p>
<code>texture()</code>는 이미지, 비디오, <a href="/reference/p5/p5.Graphics">p5.Graphics</a>
<p>The parameter, <code>tex</code>, is the texture to apply.
<code>texture()</code> can use a range
<a href="/reference/p5/p5.Framebuffer">p5.Framebuffer</a> 객체와 같은
of sources including images, videos, and offscreen renderers such as
화면 밖 렌더러를 포함한 다양한 소스를 사용할 수 있습니다.</p>
<a href="/reference/p5/p5.Graphics">p5.Graphics</a> and
<p><a href="/reference/p5/beginShape">beginShape()</a>로 생성된 기하학에 텍스처를 적용하려면
<a href="/reference/p5/p5.Framebuffer">p5.Framebuffer</a> objects.</p>
<a href="/reference/p5/vertex">vertex()</a>에서 uv 좌표를 지정해야 합니다.</p>
<p>To texture a geometry created with <a
href="/reference/p5/beginShape">beginShape()</a>,
you will need to specify uv coordinates in <a
href="/reference/p5/vertex">vertex()</a>.</p>
<p>Note: <code>texture()</code> can only be used in WebGL mode.</p>
<p>참고: <code>texture()</code>는 WebGL 모드에서만 사용할 수 있습니다.</p>
line: 861
isConstructor: false
itemtype: method
Expand Down Expand Up @@ -194,7 +184,7 @@ class: p5
params:
- name: tex
description: |
<p>media to use as the texture.</p>
<p>텍스처로 사용할 미디어.</p>
type: >-
p5.Image|p5.MediaElement|p5.Graphics|p5.Texture|p5.Framebuffer|p5.FramebufferTexture
chainable: true
Expand Down
77 changes: 18 additions & 59 deletions src/content/reference/ko/p5/ambientLight.mdx
Original file line number Diff line number Diff line change
@@ -1,57 +1,21 @@
---
title: ambientLight
module: 3D
submodule: Lights
submodule: 조명
file: src/webgl/light.js
description: >
<p>Creates a light that shines from all directions.</p>
<p>모든 방향에서 비추는 빛을 생성합니다.</p>
<p>Ambient light does not come from one direction. Instead, 3D shapes are
<p>주변광(ambient light)은 한 방향에서 오지 않습니다. 대신, 3D 형태는 모든 면에서 균등하게 비춰집니다. 주변광은 거의 대부분 다른 유형의 조명과 함께 사용됩니다. <code>ambientLight()</code> 를 호출하는 세 가지 방법이 있으며, 이들은 모두 선택적 매개변수를 사용하여 빛의 색상을 설정합니다.</p>
lit evenly from all sides. Ambient lights are almost always used in
<p><code>ambientLight()</code> 는 두 개의 매개변수인 <code>gray</code>와 <code>alpha</code>를 가집니다.
combination with other types of lights.</p>
<code>alpha</code>는 선택 사항입니다. 0과 255 사이의 회색조(gray) 값과 투명도(alpha) 값이 <code>ambientLight(50)</code> 또는 <code>ambientLight(50, 30)</code>과 같이 주변광의 색상을 설정하는 데 전달될 수 있습니다.</p>
<p>두 번째 방법은 하나의 매개변수인 색상을 가집니다. <a href="/reference/p5/p5.Color">p5.Color</a> 객체, 색상값의 배열, 또는 CSS 색상 문자열을 <code>ambientLight('magenta')</code>와 같이 전달하여 주변광의 색상을 설정할 수 있습니다.</p>
<p>There are three ways to call <code>ambientLight()</code> with optional
parameters to
set the light’s color.</p>
<p>The first way to call <code>ambientLight()</code> has two parameters,
<code>gray</code> and
<code>alpha</code>. <code>alpha</code> is optional. Grayscale and alpha values
between 0 and 255
can be passed to set the ambient light’s color, as in
<code>ambientLight(50)</code> or
<code>ambientLight(50, 30)</code>.</p>
<p>The second way to call <code>ambientLight()</code> has one parameter,
color. A
<a href="/reference/p5/p5.Color">p5.Color</a> object, an array of color
values, or a
CSS color string, as in <code>ambientLight('magenta')</code>, can be passed to
set the
ambient light’s color.</p>
<p>The third way to call <code>ambientLight()</code> has four parameters,
<code>v1</code>, <code>v2</code>,
<code>v3</code>, and <code>alpha</code>. <code>alpha</code> is optional. RGBA,
HSBA, or HSLA values can be
passed to set the ambient light’s colors, as in <code>ambientLight(255, 0,
0)</code>
or <code>ambientLight(255, 0, 0, 30)</code>. Color values will be interpreted
using
the current <a href="/reference/p5/colorMode">colorMode()</a>.</p>
<p>세 번째 방법은 네 개의 매개변수인 <code>v1</code>, <code>v2</code>, <code>v3</code>, <code>alpha</code>를 가집니다. <code>alpha</code>는 선택 사항입니다. RGBA, HSBA, 또는 HSLA 값이 <code>ambientLight(255, 0,
0)</code> 또는 <code>ambientLight(255, 0, 0, 30)</code>과 같이 주변광의 색상을 설정하는 데 전달될 수 있습니다. 색상값은 현재 <a href="/reference/p5/colorMode">colorMode()</a>를 사용하여 해석됩니다.</p>
line: 10
isConstructor: false
itemtype: method
Expand Down Expand Up @@ -178,31 +142,27 @@ overloads:
params:
- name: v1
description: |
<p>red or hue value in the current
<a href="#/p5/colorMode">colorMode()</a>.</p>
<p><a href="#/p5/colorMode">colorMode()</a>에서의 빨강 또는 색조값입니다.</p>
type: Number
- name: v2
description: |
<p>green or saturation value in the current
<a href="#/p5/colorMode">colorMode()</a>.</p>
<p><a href="#/p5/colorMode">colorMode()</a>에서의 초록 또는 채도값입니다.</p>
type: Number
- name: v3
description: |
<p>blue, brightness, or lightness value in the current
<a href="#/p5/colorMode">colorMode()</a>.</p>
<p><a href="#/p5/colorMode">colorMode()</a>에서의 파랑 또는 밝기값입니다.</p>
type: Number
- name: alpha
description: |
<p>alpha (transparency) value in the current
<a href="#/p5/colorMode">colorMode()</a>.</p>
<p>현재 <a href="#/p5/colorMode">colorMode()</a>에서의 알파(투명도)값입니다.</p>
type: Number
optional: true
chainable: 1
chainable: 1
- line: 164
params:
- name: gray
description: |
<p>grayscale value between 0 and 255.</p>
<p>0에서 255 사이의 회색조값입니다.</p>
type: Number
- name: alpha
description: ''
Expand All @@ -213,22 +173,21 @@ overloads:
params:
- name: value
description: |
<p>color as a CSS string.</p>
<p>CSS 문자열로 표현된 색상입니다.</p>
type: String
chainable: 1
- line: 177
params:
- name: values
description: |
<p>color as an array of RGBA, HSBA, or HSLA
values.</p>
<p>RGBA, HSBA, HSLA 값의 배열로 표현된 색상입니다.</p>
type: 'Number[]'
chainable: 1
- line: 184
params:
- name: color
description: |
<p>color as a <a href="#/p5.Color">p5.Color</a> object.</p>
<p><a href="#/p5.Color">p5.Color</a> 객체로 표현된 색상입니다.</p>
type: p5.Color
chainable: 1
chainable: true
Expand Down
21 changes: 11 additions & 10 deletions src/content/reference/ko/p5/boolean.mdx
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
---
title: boolean
module: Data
submodule: Conversion
module: 데이터
submodule: 변환
file: src/utilities/conversion.js
description: |
<p>Converts a number or string to its boolean representation.
For a number, any non-zero value (positive or negative) evaluates to true,
while zero evaluates to false. For a string, the value "true" evaluates to
true, while any other value evaluates to false. When an array of number or
string values is passed in, then a array of booleans of the same length is
returned.</p>
<p>숫자 또는 문자열을 해당 불리언 표현으로 변환합니다.
숫자의 경우 0이 아닌 값은 참, 0은 거짓으로 평가됩니다.
문자열의 경우, "true"라는 값은 true로 평가되며, 다른 모든 값은 false로 평가됩니다.
숫자나 문자열 값의 배열이 입력되면, 동일한 길이의 불리언 배열이 변환됩니다.</p>
line: 112
isConstructor: false
itemtype: method
Expand All @@ -27,10 +28,10 @@ class: p5
params:
- name: 'n'
description: |
<p>value to parse</p>
<p>변환할 값</p>
type: String|Boolean|Number|Array
return:
description: boolean representation of value
description: 값의 불리언 표현
type: Boolean
chainable: false
---
Expand Down
6 changes: 3 additions & 3 deletions src/content/reference/ko/p5/class.mdx
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
---
title: class
module: Foundation
submodule: Foundation
module: 기초론
submodule: 기초론
file: src/core/reference.js
description: "<p>A template for creating objects of a particular type.</p>\n<p>Classes can make it easier to program with objects. For example, a <code>Frog</code>\nclass could create objects that behave like frogs. Each object created\nusing a class is called an instance of that class. All instances of a class\nare the same type. Here's an example of creating an instance of a <code>Frog</code>\nclass:</p>\n<code>\nlet fifi = new Frog(50, 50, 20);\n</code>\n\n<p>The variable <code>fifi</code> refers to an instance of the <code>Frog</code> class. The keyword\n<code>new</code> is used to call the <code>Frog</code> class' constructor in the statement\n<code>new Frog()</code>. Altogether, a new <code>Frog</code> object was created and assigned to\nthe variable <code>fifi</code>. Classes are templates, so they can be used to create\nmore than one instance:</p>\n<code>\n// First Frog instance.\nlet frog1 = new Frog(25, 50, 10);\n\n<p>// Second Frog instance.\nlet frog2 = new Frog(75, 50, 10);\n</p></code>\n<p>A simple <code>Frog</code> class could be declared as follows:</p>\n<code>\nclass Frog {\n constructor(x, y, size) {\n // This code runs once when an instance is created.\n this.x = x;\n this.y = y;\n this.size = size;\n }\n\n<p> show() {\n // This code runs once when myFrog.show() is called.\n textAlign(CENTER, CENTER);\n textSize(this.size);\n text('\U0001F438', this.x, this.y);\n }</p>\n<p> hop() {\n // This code runs once when myFrog.hop() is called.\n this.x += random(-10, 10);\n this.y += random(-10, 10);\n }\n}\n</p></code>\n<p>Class declarations begin with the keyword <code>class</code> followed by the class\nname, such as <code>Frog</code>, and curly braces <code>{}</code>. Class names should use\n<code>PascalCase</code> and can't have spaces in their names. For example, naming a\nclass <code>Kermit The Frog</code> with spaces between each word would throw a\n<code>SyntaxError</code>. The code between the curly braces <code>{}</code> defines the class.</p>\n<p>Functions that belong to a class are called methods. <code>constructor()</code>,\n<code>show()</code>, and <code>hop()</code> are methods in the <code>Frog</code> class. Methods define an\nobject's behavior. Methods can accept parameters and return values, just\nlike functions. Note that methods don't use the <code>function</code> keyword.</p>\n<p><code>constructor()</code> is a special method that's called once when an instance of\nthe class is created. The statement <code>new Frog()</code> calls the <code>Frog</code> class'\n<code>constructor()</code> method.</p>\n<p>A class definition is a template for instances. The keyword <code>this</code> refers\nto an instance's data and methods. For example, each <code>Frog</code> instance has\nunique coordinates stored in <code>this.x</code> and <code>this.y</code>. The <code>show()</code> method\nuses those coordinates to draw the frog. The <code>hop()</code> method updates those\ncoordinates when called. Once a <code>Frog</code> instance is created, its data and\nmethods can be accessed using the dot operator <code>.</code> as follows:</p>\n<code>\n// Draw a lily pad.\nfill('green');\nstroke('green');\ncircle(fifi.x, fifi.y, 2 * fifi.size);\n\n<p>// Show the Frog.\nfifi.show();</p>\n<p>// Hop.\nfifi.hop();\n</p></code>\n"
description: "<p>특정 유형의 객체를 생성하기 위한 템플릿입니다.</p>\n<p>클래스는 객체를 사용한 프로그래밍을 보다 쉽게 만듭니다. 예를 들어, <code>Frog</code> 클래스는 개구리처럼 행동하는 객체를 생성할 수 있습니다. 클래스를 사용하여 생성된 각 객체를 그 클래스의 인스턴스라고 합니다. 클래스의 모든 인스턴스는 동일한 유형입니다. <code>Frog</code> 클래스의 인스턴스를 생성하는 예는 다음과 같습니다 : <code>\nlet fifi = new Frog(50, 50, 20);\n</code>\n\n<p><code>fifi</code>는 <code>Frog</code> 클래스의 인스턴스를 참조합니다. 키워드 <code>new</code>는 <code>new Frog()</code> 문에서 <code>Frog</code> 클래스의 생성자를 호출하는 데 사용됩니다. 전체적으로 새로운 <code>Frog</code> 객체가 생성되어 변수 <code>fifi</code>에 할당되었습니다. 클래스는 템플릿이므로 하나 이상의 인스턴스를 생성하는 데 사용할 수 있습니다:</p>\n<code>\n// First Frog instance.\nlet frog1 = new Frog(25, 50, 10);\n\n<p>// Second Frog instance.\nlet frog2 = new Frog(75, 50, 10);\n</p></code>\n<p>간단한 <code>Frog</code> 클래스는 다음과 같이 선언할 수 있습니다:</p>\n<code>\nclass Frog {\n constructor(x, y, size) {\n // This code runs once when an instance is created.\n this.x = x;\n this.y = y;\n this.size = size;\n }\n\n<p> show() {\n // This code runs once when myFrog.show() is called.\n textAlign(CENTER, CENTER);\n textSize(this.size);\n text('\U0001F438', this.x, this.y);\n }</p>\n<p> hop() {\n // This code runs once when myFrog.hop() is called.\n this.x += random(-10, 10);\n this.y += random(-10, 10);\n }\n}\n</p></code>\n<p>클래스 선언은 <code>class</code> 키워드로 시작하며, 그 다음에 <code>Frog</code> 같은 클래스 이름과 중괄호 <code>{}</code>가 따릅니다. 클래스 이름은 <code>PascalCase</code>를 사용해야 하며 이름에 공백이 있으면 안 됩니다. 예를 들어, 클래스 이름을 각 단어 사이에 공백이 있는 <code>Kermit The Frog</code>로 지정하면 <code>SyntaxError</code>가 발생합니다. 중괄호 <code>{}</code> 사이의 코드는 클래스를 정의합니다. 클래스에 속한 함수를 메소드라고 합니다. <code>constructor()</code>,<code>show()</code>, 그리고 <code>hop()</code>는 매개변수를 받을 수 있고 값도 반환할 수 있습니다. 함수와 같지만 <code>function</code> 키워드를 사용하지 않습니다.</p>\n<p><code>constructor()</code>는 클래스의 인스턴스가 생성될 때 한 번 호출되는 특별한 메소드입니다. <code>new Frog()</code> 문은 <code>Frog</code> 클래스의 <code>constructor()</code> 메소드를 호출합니다. </p>\n<p>클래스 정의는 인스턴스의 템플릿입니다. 키워드 <code>this</code>는 인스턴스의 데이터와 메소드를 참조합니다. 예를 들어, 각 <code>Frog</code>인스턴스는 <code>this.x</code>와 <code>this.y</code>에 고유한 좌표를 저장합니다. <code>show()</code> 메소드는 그 좌표를 사용하여 개구리를 그립니다. <code>hop()</code> 메소드는 호출될 때 그 좌표를 업데이트합니다. <code>Frog</code> 인스턴스가 생성되면, 점 연산자 <code>.</code>를 사용하여 다음과 같이 데이터와 메소드를 업데이트 할 수 있습니다:</p>\n<code>\n// Draw a lily pad.\nfill('green');\nstroke('green');\ncircle(fifi.x, fifi.y, 2 * fifi.size);\n\n<p>// Show the Frog.\nfifi.show();</p>\n<p>// Hop.\nfifi.hop();\n</p></code>\n"
line: 1325
isConstructor: false
itemtype: property
Expand Down

0 comments on commit 7e514e7

Please sign in to comment.