Original Post
The final line of the code i''ve posted is where my program crashes, on it''s first iteration. Can anyone see anything wrong with the code itself, or is there likely to be a problem with the data I''m sending it?
void CalcWorldLight(vertex_t **ob, light_t *lights, int wverts, int hverts, int numlights)
{
int vwcnt, vhcnt, lcnt;
for (vwcnt = 0; vwcnt <= wverts; vwcnt++)
{
for (vhcnt = 0; vhcnt <= hverts; vhcnt++)
{
ob[vwcnt][vhcnt].final_colour = ob[vwcnt][vhcnt].colour.emissive;