# HG changeset patch # User NEO # Date 2009-07-09 01:41:56 # Node ID a50a7b87ef9c5cd42e530a02f315bf4538b43c9d # Parent 83227db1cee81ecafe45dc243b3552f89fcf1762 changed hcfjob+1; to hcfjob++; changed a lot of if(blah = blah) to if(blah == blah) thanks to ohnobinki for pointing out my errors :) diff --git a/src/server/distrend.c b/src/server/distrend.c --- a/src/server/distrend.c +++ b/src/server/distrend.c @@ -113,7 +113,7 @@ int main(int argc, char *argv[]) // Begin non-working framework? int distrend_do_config(int argc, char *argv[], struct distrend_config *config) { - cfg_opt_t myopts_listen[] = + cfg_opt_t myopts_listen[] = { CFG_SIMPLE_STR("type", NULL), CFG_SIMPLE_STR("path", NULL), @@ -214,7 +214,7 @@ void frame_num_struct_builder(int sframe // matches your computer up with a lovely frame to render int frame_finder(){ - int your_frame = NULL; // your_frame is an interger value that will be given to the client as the frame number to render + int your_frame = null; // your_frame is an interger value that will be given to the client as the frame number to render int finder_jobnum = 0; int frameset_count = 0; // the frameset number, note* frames in an animation don't start at zero short int done = 0; @@ -224,35 +224,35 @@ int frame_finder(){ finder_jobnum = hcfjob + 1; // reset it to start scanning at first uncompleted job for the pass at each priority level while(finder_jobnum <= highest_jobnum){ - if(blendjob[finder_jobnum].priority = priority){ // looks for a job with the current priority value + if(blendjob[finder_jobnum].priority == priority){ // looks for a job with the current priority value done = 1; // notice it starts by looking at the oldest job first break; } - if((done) = 1) // If it has found a job with the current priority value, it will break out of the loop + if((done) == 1) // If it has found a job with the current priority value, it will break out of the loop break; // If none is found it goes to the next job to see if it is of the current priority value else finder_jobnum++; } - if(done = 1) // if job has been found, it lets it out of the priority changer loop + if(done == 1) // if job has been found, it lets it out of the priority changer loop break; priority--; } while(your_frame < blendjob[finder_jobnum].total_frames){ // Finds the frameset number with a frame that needs to be rendered - if (blendjob[finder_jobnum].frameset[frameset_count].frame_status = 0) // If frame that is not assigned has been found, frameset_count is not changed + if (blendjob[finder_jobnum].frameset[frameset_count].frame_status == 0) // If frame that is not assigned has been found, frameset_count is not changed break; // and frameset_count is used to give the frame number later in this funciton - x++; // If frame is assigned or done, it goes to next frame + frameset_count++; // If frame is assigned or done, it goes to next frame } blendjob[jobnum].frameset[x].frame_status++; // sets the value of the frame to 2, which means its taken your_frame = blendjob[jobnum].frameset[x].frame_num; // Takes the frameset found in the while statement above, and extracts the frame number from it and assigns it to the int your_frame -if(your_frame = null) // If that job had no open frames for some reason, run the status report generator so that +if(your_frame == null) // If that job had no open frames for some reason, run the status report generator so that status_report_generator(); //the job priority can be changed to 0 return your_frame; // your_frame is returned as the frame to be rendered @@ -263,7 +263,7 @@ return your_frame; // your_frame is retu void status_report_generator(){ while(blendjob[(hcfjob+1)].priority = 0) //If the job after the highest consecutively finished job is finished - hcfjob+1; // adds 1 to the highest consecutively finished job and checks the next one, till the job after the hcfjob is not done + hcfjob++; // adds 1 to the highest consecutively finished job and checks the next one, till the job after the hcfjob is not done int num1 = hcfjob+1; // to scan through jobs int num2 = 0; // to scan through frames