Diff of /trunk/IdealistViewer/Application/BaseIdealistViewer.cs
Parent Directory
|
Revision Log
|
Patch
| revision 36, Thu Oct 30 07:14:49 2008 UTC | revision 37, Thu Oct 30 08:26:58 2008 UTC | |
|---|---|---|
| # | Line 386 | Line 386 |
| 386 | doProcessMesh(5); | doProcessMesh(5); |
| 387 | doObjectMods(5); | doObjectMods(5); |
| 388 | CheckAndApplyParent(5); | CheckAndApplyParent(5); |
| 389 | doTextureMods(); | doTextureMods(1); |
| 390 | doSetCameraPosition(); | doSetCameraPosition(); |
| 391 | } | } |
| 392 | //Thread.Sleep(50); | //Thread.Sleep(50); |
| # | Line 475 | Line 475 |
| 475 | ||
| 476 | } | } |
| 477 | ||
| 478 | private void doTextureMods() | private void doTextureMods(int pCount) |
| 479 | { | { |
| 480 | lock (assignTextureQueue) | lock (assignTextureQueue) |
| 481 | { | { |
| 482 | while (assignTextureQueue.Count > 0) | if (assignTextureQueue.Count < pCount) |
| 483 | pCount = assignTextureQueue.Count; | |
| 484 | } | |
| 485 | ||
| 486 | for (int i=0;i < pCount; i++) | |
| 487 | { | { |
| 488 | TextureComplete tx = assignTextureQueue.Dequeue(); | |
| 489 | Texture tex = driver.GetTexture(tx.texture); | TextureComplete tx; |
| 490 | if (tx.node != null) | Texture tex = null; |
| 491 | ||
| 492 | lock (assignTextureQueue) | |
| 493 | { | { |
| 494 | textureMan.applyTexture(tex, tx.node); | if (i >= assignTextureQueue.Count) |
| 495 | break; | |
| 496 | ||
| 497 | tx = assignTextureQueue.Dequeue(); | |
| 498 | tex = driver.GetTexture(tx.texture); | |
| 499 | } | } |
| 500 | ||
| 501 | if (tx.node != null && tex != null) | |
| 502 | { | |
| 503 | textureMan.applyTexture(tex, tx.node); | |
| 504 | } | } |
| 505 | } | } |
| 506 | ||
| 507 | ||
| 508 | } | } |
| 509 | private void doSetCameraPosition() | private void doSetCameraPosition() |
| 510 | { | { |
|
||||||||
| ViewVC Help | |
| Powered by ViewVC 1.0.0 |

