Handbook
Glossary
triangle>aos ( x -- y )
Vocabulary
game
.
models
.
obj
.
private
Inputs
x
a
sequence
Outputs
y
a
sequence
Word description
Convert a sequence of vertex, texture and normal indices into a sequence of vertex, texture and normal values.
Definition
USING:
arrays
combinators
kernel
math
namespaces
sequences
sequences.deep
;
IN:
game.models.obj.private
:
triangle>aos
( x -- y )
dup
length
{
{
3
[
first3
[
1
-
vp
get
nth
]
[
1
-
vt
get
nth
]
[
1
-
vn
get
nth
]
tri*
3array
flatten
]
}
{
2
[
first2
[
1
-
vp
get
nth
]
[
1
-
vt
get
nth
]
bi*
2array
flatten
]
}
}
case
;