if (d >= 0) clipflags &= ~(1<<i); EDIT: I understand the bitshifting part (in this case multiplying by 2)