| 464 | } |
| 465 | |
| 466 | void CRender::LoadSWIs(CStreamReader* base_fs) |
| 467 | { |
| 468 | // allocate memory for portals |
| 469 | if (base_fs->find_chunk(fsL_SWIS)) |
| 470 | { |
| 471 | CStreamReader* fs = base_fs->open_chunk(fsL_SWIS); |
| 472 | const u32 item_count = fs->r_u32(); |
| 473 | |
| 474 | xr_vector<FSlideWindowItem>::iterator it = SWIs.begin(); |
| 475 | const xr_vector<FSlideWindowItem>::iterator it_e = SWIs.end(); |
| 476 | |
| 477 | for (; it != it_e; ++it) |
| 478 | xr_free((*it).sw); |
| 479 | |
| 480 | SWIs.clear(); |
| 481 | |
| 482 | SWIs.resize(item_count); |
| 483 | for (u32 c = 0; c < item_count; c++) |
| 484 | { |
| 485 | FSlideWindowItem& swi = SWIs[c]; |
| 486 | swi.reserved[0] = fs->r_u32(); |
| 487 | swi.reserved[1] = fs->r_u32(); |
| 488 | swi.reserved[2] = fs->r_u32(); |
| 489 | swi.reserved[3] = fs->r_u32(); |
| 490 | swi.count = fs->r_u32(); |
| 491 | VERIFY(NULL == swi.sw); |
| 492 | swi.sw = xr_alloc<FSlideWindow>(swi.count); |
| 493 | fs->r(swi.sw, sizeof(FSlideWindow) * swi.count); |
| 494 | } |
| 495 | fs->close(); |
| 496 | } |
| 497 | } |
| 498 | |
| 499 | void CRender::Load3DFluid() |
| 500 | { |
nothing calls this directly
no test coverage detected