def convert_vec2_to_vec4(scale, data):
    """transforms an array of 2d coords into 4d"""
    it = iter(data)
    while True:
        yield next(it) * scale  # x
        yield next(it) * scale  # y
        yield 0.0       # z
        yield 1.0
def convert_vec2_to_vec4 ( scale , data ) : it = iter ( data ) while True : yield next ( it ) * scale yield next ( it ) * scale yield 0.0 yield 1.0
transforms an array of 2d coords into 4d