/* Main iterative loop */ void DoRad() { unsigned long shootPatch; while (FindShootPatch(&shootPatch)) { ComputeFormfactors(shootPatch); DistributeRad(shootPatch); DisplayResults(¶ms->displayView); } }
int doOneIteration(void) /* does one radiosity iteration only, returns TRUE when finished */ { if (FindShootPatch(&shootPatch_n)) { ComputeFormfactors(shootPatch_n); DistributeRad(shootPatch_n); return 0; /*FALSE */ } else { printf("Radiosity done \n"); return 1; /* TRUE */ } }