| 342 | } |
| 343 | |
| 344 | BOOL J2DPictureEx::remove(u8 id) |
| 345 | { |
| 346 | if (!isRemove(id)) { |
| 347 | return FALSE; |
| 348 | } |
| 349 | u8 texGenNum = mMaterial->getTexGenBlock()->getTexGenNum(); |
| 350 | u8 tevStageNum = (u8)mMaterial->getTevBlock()->getTevStageNum(); |
| 351 | bool v1 = (tevStageNum == (texGenNum + 1)) ? false : true; |
| 352 | shiftSetBlendRatio(id, 0.0f, true, false); |
| 353 | shiftSetBlendRatio(id, 0.0f, false, false); |
| 354 | texGenNum--; |
| 355 | mMaterial->getTexGenBlock()->setTexGenNum(texGenNum); |
| 356 | |
| 357 | // it needs to stop optimising texGenNum - 1 down into a new variable and dynamically do it |
| 358 | mMaterial->getTevBlock()->removeTexture(id); |
| 359 | if (texGenNum != 1) { |
| 360 | tevStageNum = texGenNum + (v1 ? 2 : 1); |
| 361 | } else { |
| 362 | tevStageNum = v1 ? 2 : 1; |
| 363 | } |
| 364 | mMaterial->getTevBlock()->setTevStageNum(tevStageNum); |
| 365 | setTevOrder(texGenNum, tevStageNum, v1); |
| 366 | setTevStage(texGenNum, tevStageNum, v1); |
| 367 | setTevKColor(texGenNum); |
| 368 | setTevKColorSel(texGenNum); |
| 369 | setTevKAlphaSel(texGenNum); |
| 370 | return TRUE; |
| 371 | } |
| 372 | |
| 373 | BOOL J2DPictureEx::remove() |
| 374 | { |
nothing calls this directly
no test coverage detected