Did I find the right examples for you? yes no      Crawl my project      Python Jobs

# pyrr.vector.cross

All Samples(11)  |  Call(11)  |  Derive(0)  |  Import(0)

```
right = vector.cross(
self.plane[ plane.normal ],
self.plane[ plane.up ]
)
```

```    rl = line[ 1 ] - line[ 0 ]
rp = point - line[ 0 ]
cross = vector.cross( rl, rp )

# check if the cross product is zero
```
```    rl = line[ 1 ] - line[ 0 ]
rp = point - line[ 0 ]
cross = vector.cross( rl, rp )
dot = vector.dot( rp, rl )
squared_length = vector.squared_length( rl )
```
```    # we cross product the 2 vectors
# if the result is 0, then they are parallel
cross = vector.cross( v1, v2 )
return 0 == numpy.count_nonzero( cross )

```
```        # get the cross product of the ray delta and
# the direction of the rays
cross = vector.cross( delta, ray2[ 1 ] )

# if the cross product is zero, the start of the
```

```    rl = line[ 1 ] - line[ 0 ]
rp = point - line[ 0 ]
cross = vector.cross( rl, rp )

# check if the cross product is zero
```
```    rl = line[ 1 ] - line[ 0 ]
rp = point - line[ 0 ]
cross = vector.cross( rl, rp )
dot = vector.dot( rp, rl )
squared_length = vector.squared_length( rl )
```
```    # we cross product the 2 vectors
# if the result is 0, then they are parallel
cross = vector.cross( v1, v2 )
return 0 == numpy.count_nonzero( cross )

```
```        # get the cross product of the ray delta and
# the direction of the rays
cross = vector.cross( delta, ray2[ 1 ] )

# if the cross product is zero, the start of the
```

```        def single_vector():
vec1 = numpy.array( [1.0, 0.0, 0.0] )
vec2 = numpy.array( [0.0, 1.0, 0.0] )

result = vector.cross( vec1, vec2 )
```
```            batch2 = numpy.tile( vec2, (3,1) )

result = vector.cross( batch1, batch2 )

expected = numpy.cross( vec1, vec2 )
```