-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathft_vcross.c
More file actions
23 lines (20 loc) · 1.05 KB
/
ft_vcross.c
File metadata and controls
23 lines (20 loc) · 1.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_vcross.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: aabdulla <aabdulla@student.unit.ua> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2019/02/19 15:18:17 by aabdulla #+# #+# */
/* Updated: 2019/02/19 15:19:22 by aabdulla ### ########.fr */
/* */
/* ************************************************************************** */
#include "libavec.h"
t_vector ft_vcross(t_vector a, t_vector b)
{
t_vector v;
v.x = a.y * b.z - a.z * b.y;
v.y = a.z * b.x - a.x * b.z;
v.z = a.x * b.y - a.y * b.x;
return (v);
}