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

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

src/p/y/pygly-20121125/pygly/uv_generators/planar.py   pygly(Download)
 
        right = vector.cross(
            self.plane[ plane.normal ],
            self.plane[ plane.up ]
            )

src/p/y/Pyrr-HEAD/pyrr/geometric_tests.py   Pyrr(Download)
    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

src/p/y/pyrr-20130321/pyrr/geometric_tests.py   pyrr(Download)
    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

src/p/y/Pyrr-HEAD/pyrr/test/test_vector.py   Pyrr(Download)
        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 )