hello
I try to get this brook example up and running in vs.net (2005). Im using the ATI brook + 1.4.0_beta sdk.
I added the dependency's, the .h folder and i setted the outputfolder + command line like I read in this topic:
http://forums.amd.com/devforum/messageview.cfm?catid=328&threadid=92344&STARTPAGE=1&FTVAR_FORUMVIEWT...
When i try to build the application i get 56 errors
Have a look at the first 5 errors:
Error1error C4430: missing type specifier - int assumed. Note: C++ does not support default-intc:\users\gebruiker\documents\school\gent 2008-2010\eindwerk\project\gpu\projgpu\projgpu\sum.br2
Error2error C2143: syntax error : missing ',' before '&'c:\users\gebruiker\documents\school\gent 2008-2010\eindwerk\project\gpu\projgpu\projgpu\sum.br2
Error3error C2065: 'c' : undeclared identifierc:\users\gebruiker\documents\school\gent 2008-2010\eindwerk\project\gpu\projgpu\projgpu\sum.br5
Error4error C2065: 'a' : undeclared identifierc:\users\gebruiker\documents\school\gent 2008-2010\eindwerk\project\gpu\projgpu\projgpu\sum.br5
Error5error C2065: 'b' : undeclared identifierc:\users\gebruiker\documents\school\gent 2008-2010\eindwerk\project\gpu\projgpu\projgpu\sum.br5
all the other errors are more the less the same. I think it has something to do with the linker? But I'm not sure, don't even have a clue where to start looking for errors.
can someone help me?
#include <stdio.h> #include <stdafx.h> kernel void sum (float a<>, float b<>, out float c<>){ c = a + b; } int main(int argc, char** argv){ int i, j; float a<10, 10>; float b<10, 10>; float c<10, 10>; float input_a[10][10]; float input_b[10][10]; float input_c[10][10]; for(i = 0; i < 10; i++){ for(j = 0; j < 10; j++){ input_a = (float) i; input_b = (float) j; } } streamRead(a, input_a); streamRead(b, input_b); sum(a, b, c); streamWrite(c, input_c); for(i = 0; i < 10; i++){ for(j = 0; j < 10; j++){ printf("%6.2f ", input_c); } } return 0; }