View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0001945 | FSSCP | graphics | public | 2009-06-29 00:05 | 2009-12-11 12:06 |
Reporter | KeldorKatarn | Assigned To | Hery | ||
Priority | high | Severity | major | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Platform | IBM PC | OS | Windows | OS Version | Vista SP1 |
Product Version | 3.6.11 | ||||
Target Version | 3.6.12 RC1 | Fixed in Version | 3.6.11 | ||
Summary | 0001945: Black background in nebula missions with cutscene bars activated. | ||||
Description | In nebula missions the background turns black during cutscenes. Tested with latest trunk EXE. See two pictures attached. | ||||
Steps To Reproduce | Simply open a nebula mission and activate a cutscene (using the bars). I don't know if changing camera is needed. That's possible. It happens in Saga's autopilot cutscenes, so using the hardcoded autopilot cutscenes should cause this to show up as well. | ||||
Tags | No tags attached. | ||||
2009-06-29 00:05
|
|
2009-06-29 00:06
|
|
|
recorded a video to show what'S exactly going wrong http://www.wcsaga.net/database/tolwyn/fs2_open_3_6_11r_5610_1.avi |
|
Bumping since this is a show stopper. |
|
Apparently, someone tried to fix that problem, but failed. Now the background doesn't turn black, but cutscene bars are no longer black (also when player dies). |
2009-11-11 21:15
|
cutscene_bars.patch (1,837 bytes)
Index: code/freespace2/freespace.cpp =================================================================== --- code/freespace2/freespace.cpp (revision 5644) +++ code/freespace2/freespace.cpp (working copy) @@ -2803,6 +2803,11 @@ // Set the clip region for the letterbox "dead view" int yborder = gr_screen.max_h/4; + // Ensure that the bars are black + gr_set_color(0,0,0); + gr_rect(0, 0, gr_screen.max_w, yborder, false); + gr_rect(0, gr_screen.max_h-yborder, gr_screen.max_w, yborder, false); + // Numeric constants encouraged by J "pig farmer" S, who shall remain semi-anonymous. // J.S. I've changed my ways!! See the new "no constants" code!!! gr_set_clip(0, yborder, gr_screen.max_w, gr_screen.max_h - yborder*2, false ); @@ -4545,9 +4550,9 @@ yborder = gr_screen.max_h/CUTSCENE_BAR_DIVISOR - fl2i(Cutscene_bars_progress*(gr_screen.max_h/CUTSCENE_BAR_DIVISOR)); //Set rectangles - //gr_set_color(0,0,0); - //gr_rect(0, 0, gr_screen.max_w, yborder, false); - //gr_rect(0, gr_screen.max_h-yborder, gr_screen.max_w, yborder, false); + gr_set_color(0,0,0); + gr_rect(0, 0, gr_screen.max_w, yborder, false); + gr_rect(0, gr_screen.max_h-yborder, gr_screen.max_w, yborder, false); //Set clipping gr_reset_clip(); gr_set_clip(0, yborder, gr_screen.max_w, gr_screen.max_h - yborder*2, false ); @@ -4556,9 +4561,9 @@ { int yborder = gr_screen.max_h/CUTSCENE_BAR_DIVISOR; - //gr_set_color(0,0,0); - //gr_rect(0, 0, gr_screen.max_w, yborder, false); - //gr_rect(0, gr_screen.max_h-yborder, gr_screen.max_w, yborder, false); + gr_set_color(0,0,0); + gr_rect(0, 0, gr_screen.max_w, yborder, false); + gr_rect(0, gr_screen.max_h-yborder, gr_screen.max_w, yborder, false); gr_reset_clip(); gr_set_clip(0, yborder, gr_screen.max_w, gr_screen.max_h - (yborder*2), false ); } |
|
If you're working with the cutscene bars you will almost certainly want to look at 0001768. |
|
chief1983 committed my patch to the trunk. |
|
This still doesn't work with build fs2_open_3_6_11r-20091125_r5686 |
|
I can't reproduce this bug, but I found another one (when player dies in nebula with cutscene bars on). http://quarnos.org/dl/cutscene_bars_build.zip KeldorKatarn, check if this build fixes your problem. |
|
Yes, no more black background with that one. What did you change? |
2009-12-10 21:47
|
nebula_bars.patch (2,235 bytes)
Index: code/freespace2/freespace.cpp =================================================================== --- code/freespace2/freespace.cpp (revision 5710) +++ code/freespace2/freespace.cpp (working copy) @@ -3904,6 +3904,8 @@ gr_zbuffer_clear(TRUE); clip_frame_view(); + neb2_set_frame_backg(); + #ifndef DYN_CLIP_DIST if (!Cmdline_nohtl) { gr_set_proj_matrix(Proj_fov, gr_screen.clip_aspect, Min_draw_distance, Max_draw_distance); Index: code/nebula/neb.cpp =================================================================== --- code/nebula/neb.cpp (revision 5710) +++ code/nebula/neb.cpp (working copy) @@ -470,6 +470,23 @@ } } +void neb2_set_frame_backg() { + ubyte tr = gr_screen.current_clear_color.red; + ubyte tg = gr_screen.current_clear_color.green; + ubyte tb = gr_screen.current_clear_color.blue; + + neb2_get_fog_color( + &gr_screen.current_clear_color.red, + &gr_screen.current_clear_color.green, + &gr_screen.current_clear_color.blue); + + gr_clear(); + + gr_screen.current_clear_color.red = tr; + gr_screen.current_clear_color.green = tg; + gr_screen.current_clear_color.blue = tb; +} + // call before beginning all rendering void neb2_render_setup(camid cid) { @@ -485,21 +502,8 @@ if (Neb2_render_mode == NEB2_RENDER_HTL) { // RT The background needs to be the same colour as the fog and this seems // to be the ideal place to do it - ubyte tr = gr_screen.current_clear_color.red; - ubyte tg = gr_screen.current_clear_color.green; - ubyte tb = gr_screen.current_clear_color.blue; + neb2_set_frame_backg(); - neb2_get_fog_color( - &gr_screen.current_clear_color.red, - &gr_screen.current_clear_color.green, - &gr_screen.current_clear_color.blue); - - gr_clear(); - - gr_screen.current_clear_color.red = tr; - gr_screen.current_clear_color.green = tg; - gr_screen.current_clear_color.blue = tb; - return; } Index: code/nebula/neb.h =================================================================== --- code/nebula/neb.h (revision 5710) +++ code/nebula/neb.h (working copy) @@ -140,5 +140,8 @@ void neb2_get_fog_color(ubyte *r, ubyte *g, ubyte *b); +// set frame background color +void neb2_set_frame_backg(); + #endif |
|
Now, background color is set twice, similarly to the clipping settings. This is necessary because of RTT code which needs to change current configuration for its own purpose, but doesn't restore it afterwards. Patch attached. |
|
Fix committed. |
Date Modified | Username | Field | Change |
---|---|---|---|
2009-06-29 00:05 | KeldorKatarn | New Issue | |
2009-06-29 00:05 | KeldorKatarn | File Added: screen0211.jpg | |
2009-06-29 00:06 | KeldorKatarn | File Added: screen0210.jpg | |
2009-10-02 07:18 | Tolwyn | Note Added: 0011206 | |
2009-11-10 03:39 | chief1983 | Note Added: 0011234 | |
2009-11-10 03:39 | chief1983 | Priority | normal => high |
2009-11-10 03:39 | chief1983 | Target Version | => 3.6.12 RC1 |
2009-11-11 17:47 | Hery | Note Added: 0011246 | |
2009-11-11 17:47 | Hery | Status | new => assigned |
2009-11-11 17:47 | Hery | Assigned To | => Hery |
2009-11-11 21:15 | Hery | File Added: cutscene_bars.patch | |
2009-11-12 05:08 | chief1983 | Note Added: 0011247 | |
2009-11-19 13:30 | Hery | Note Added: 0011308 | |
2009-11-19 13:30 | Hery | Status | assigned => resolved |
2009-11-19 13:30 | Hery | Fixed in Version | => 3.6.12 RC1 |
2009-11-19 13:30 | Hery | Resolution | open => fixed |
2009-12-10 16:32 | KeldorKatarn | Note Added: 0011397 | |
2009-12-10 16:32 | KeldorKatarn | Status | resolved => feedback |
2009-12-10 16:32 | KeldorKatarn | Resolution | fixed => reopened |
2009-12-10 17:55 | Hery | Note Added: 0011398 | |
2009-12-10 21:29 | KeldorKatarn | Note Added: 0011399 | |
2009-12-10 21:47 | Hery | File Added: nebula_bars.patch | |
2009-12-10 21:53 | Hery | Note Added: 0011400 | |
2009-12-11 12:06 | Hery | Note Added: 0011401 | |
2009-12-11 12:06 | Hery | Status | feedback => resolved |
2009-12-11 12:06 | Hery | Fixed in Version | 3.6.12 RC1 => 3.6.11 |
2009-12-11 12:06 | Hery | Resolution | reopened => fixed |