Hi,
I feel a bit stupid, I never had to deal with this simple problem in the past year.
In my kernel I have two float4 variables : a and b.
I want to call a function that will modify them.
Is this working?
void f(float4 a, float4 b){
a.x = 0;
b.x = 1;
}
or should I use this?
void f(float4 * a, float4 * b){
(*a).x = 0;
(*b).x = 1;
}
If float4 is just a float[4], solution 1 should work no?
Thanks for your help !