Bug #557
3DSMAX Plugin Crashes in Patch Painter
Status: | Closed | Start date: | 05/20/2009 | |
---|---|---|---|---|
Priority: | Urgent | Due date: | ||
Assignee: | sfb | % Done: | 100% |
|
Category: | Tools: General | |||
Target version: | Version 0.7.0 |
Description
When the 3DSMAX plugins are compiled in a mode other than NL_DEBUG. Per the original report from compilo:
than i select in "Modifier List" the "Nel Patch Painter" and klick on "Paint"! ok. now i select with F1 the "tile mode" and with space i select a "tile set". now when i click on the plane, 3dsMax crash! when i use normal Colors, it works! but i will not work with tileset / tga!
Per Kaetemi's reply:
The problem with that is in tile_far_bank.h. There's no far bank in the tile painter. This code doesn't work, tile_far_bank.h line 126-150:
/// Get a read only far tile pointer. Return NULL if the tile doesn't exist. const CTileFar* getTile (sint tile) const { #ifdef NL_DEBUG if (tile>=(sint)_TileVector.size()) return NULL; #else // NL_DEBUG if (_TileVector.begin()+tile>=_TileVector.end()) return NULL; #endif return &_TileVector[tile]; } /// Get a far tile pointer. Return NULL if the tile doesn't exist. CTileFar* getTile (sint tile) { #ifdef NL_DEBUG if (tile>=(sint)_TileVector.size()) return NULL; #else // NL_DEBUG if (_TileVector.begin()+tile>=_TileVector.end()) return NULL; #endif return &_TileVector[tile]; }
History
#1 Updated by sfb about 9 years ago
I'm unsure as to why this:
1if (tile>=(sint)_TileVector.size())
Is any less efficient than this:
1if (_TileVector.begin()+tile>=_TileVector.end())
So I'm trying to convert tile_far_bank.h to use the #ifdef NL_DEBUG variant - if that works I'll propose that as a patch...
#2 Updated by sfb almost 9 years ago
- Target version changed from 0.8.0 to Version 0.7.0
Moving this to 0.7.0.
#3 Updated by sfb almost 9 years ago
- Status changed from New to Resolved
- % Done changed from 0 to 100
Applied in changeset r1858.
#4 Updated by sfb almost 9 years ago
- Status changed from Resolved to Closed
Painting zone patches no longer crashes when using the Snowballs tilebank.
#5 Updated by kervala almost 8 years ago
- Project changed from NeL to Ryzom
- Category deleted (
Tools) - Target version deleted (
Version 0.7.0)
#6 Updated by kervala almost 8 years ago
- Category set to Tools: General
- Assignee set to sfb
- Target version set to Version 0.7.0