__kernel void update(__global float4* pos, __global float4* aux, float count, float maxcount, float acctime)
{
	int i = get_global_id(0);
	float f = (float)i/7700.0f;

	float x=0;float y=0;float z=0;

	float fpi = 3.14159*2*f*2*0.3;
	float t = acctime*0.15;

	
	x = cos(fpi+t*2.3)+sin(fpi*31+t)+cos(fpi*37)*sin(fpi*23);
	y = cos(fpi*17+t*1.9)+sin(fpi*30)+cos(fpi*31+t*0.7)*sin(fpi*13);
	
	z = cos(fpi*11)+sin(fpi*29+t*1.1)+cos(fpi*47)*sin(fpi*19+t*1.3)+2*f*138.0*5.0;
	x*=5;
	y*=5;
	pos[i] = (float4)(x,y,z, 1.0);
}
__kernel void zero(__global float4* pos, __global float4* aux){
	pos[get_global_id(0)] = (float4)(0.0,0.0,0.0,0.0);
	aux[get_global_id(0)] = (float4)(0.0,0.0,0.0,0.0);
}