View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0002759 | FSSCP | models | public | 2012-12-22 22:41 | 2012-12-24 05:53 |
| Reporter | FUBAR-BDHR | Assigned To | FUBAR-BDHR | ||
| Priority | normal | Severity | minor | Reproducibility | always |
| Status | resolved | Resolution | fixed | ||
| Product Version | 3.6.15 | ||||
| Fixed in Version | 3.6.15 | ||||
| Summary | 0002759: Docking points not checked for null normals | ||||
| Description | Found an old model the other day with both points of it's rearm dock having normals of 0:0:0. Figured this is something that should be checked for. | ||||
| Steps To Reproduce | Edit any model and change a dock point normal to 0:0:0. Load model. No errors. | ||||
| Additional Information | Attached is a patch with warning. | ||||
| Tags | No tags attached. | ||||
|
|
dock_null_norm.patch (561 bytes)
Index: model/modelread.cpp
===================================================================
--- model/modelread.cpp (revision 9460)
+++ model/modelread.cpp (working copy)
@@ -1724,6 +1724,9 @@
for (j = 0; j < bay->num_slots; j++) {
cfread_vector( &(bay->pnt[j]), fp );
cfread_vector( &(bay->norm[j]), fp );
+ if(vm_vec_mag(&(bay->norm[j])) <= 0.0f) {
+ Warning(LOCATION, "Model '%s' dock point '%s' has a null normal. ", filename, bay->name);
+ }
}
if(vm_vec_same(&bay->pnt[0], &bay->pnt[1])) {
|
|
|
Committed r9463 |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2012-12-22 22:41 | FUBAR-BDHR | New Issue | |
| 2012-12-22 22:41 | FUBAR-BDHR | Status | new => assigned |
| 2012-12-22 22:41 | FUBAR-BDHR | Assigned To | => FUBAR-BDHR |
| 2012-12-22 22:41 | FUBAR-BDHR | File Added: dock_null_norm.patch | |
| 2012-12-22 22:41 | FUBAR-BDHR | Status | assigned => code review |
| 2012-12-24 05:53 | FUBAR-BDHR | Note Added: 0014573 | |
| 2012-12-24 05:53 | FUBAR-BDHR | Status | code review => resolved |
| 2012-12-24 05:53 | FUBAR-BDHR | Fixed in Version | => 3.6.15 |
| 2012-12-24 05:53 | FUBAR-BDHR | Resolution | open => fixed |