Skip to content
Snippets Groups Projects
Commit 22767467 authored by Neil Gershenfeld (test)'s avatar Neil Gershenfeld (test)
Browse files

layers fix

parent cbffc256
No related branches found
No related tags found
No related merge requests found
Pipeline #22990 passed
......@@ -88,6 +88,7 @@ int nx = (xmax-xmin)/delta;
int ny = (ymax-ymin)/delta;
int *m = (int*) calloc(nx*ny,sizeof(int));
float layers[] = {{{layers}}};
int nlayers = {nlayers};
int nthreads = std::thread::hardware_concurrency();
//
int fn(float X,float Y,float Z) {{
......@@ -96,7 +97,7 @@ int fn(float X,float Y,float Z) {{
//
void calc(int nx,int ny,int nthreads,int thread) {{
int intensity;
for (int layer = 0; layer < 2; ++layer) {{
for (int layer = 0; layer < nlayers; ++layer) {{
float z = layers[layer];
if (thread == 0)
cout << " z = " << z << endl;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment