Opened 11 years ago

Closed 11 years ago

Last modified 11 years ago

#259 closed defect (fixed)

wxGUI: visualization problems with multiple rasters and vectors. not stable bug...

Reported by: giohappy Owned by: grass-dev@…
Priority: major Milestone: 6.4.0
Component: wxGUI Version: svn-develbranch6
Keywords: Cc:
CPU: x86-32 Platform: Linux

Description

I find difficult to describe this problem because it seems to happen randomly. I can't find a rule... If I add various rasters and vectors I often have problems in the visualization. I try to describe some situations I have faced using 1,2,3,...,n to define the layers from bottom to the top of the stack:

FIRST CASE

(3) points vector (2) raster (1) raster

it happens that (2) hides the points layer. If I switch off raster (2) I can see the points again. If I move up and down various times the vector in the layer manager... magically it gets workin correctly: I see the whoole stack in the map window.

SECOND CASE

(3) points vector (2) polygons vector (1) raster

Same as above. Sometimes (not always) the layer (2) hides layer (1). If I randomly switch on and off, move up and down, the layers... sometimes I can see the things as they should. You can see this case in the image attached: the points aren't visible.

I know it's too generic, but I really can't be more accurate in the description. Anyway I hope it helps...

Attachments (1)

wxGUIbug.png (199.7 KB) - added by giohappy 11 years ago.
wxGUI bug - ticket #259

Download all attachments as: .zip

Change History (11)

Changed 11 years ago by giohappy

Attachment: wxGUIbug.png added

wxGUI bug - ticket #259

comment:1 Changed 11 years ago by cmbarton

Please specify which version you are using and exactly when you got it. A series of problems that sound like this were fixed over the past several weeks in GRASS 6.4 and GRASS 7.

comment:2 in reply to:  1 Changed 11 years ago by giohappy

I'm referring to Revision 32726, 08/12/08 Not weeks ago...

comment:3 Changed 11 years ago by cmbarton

I can confirm this behavior. It looks like recent changes have caused this to happen again. I just submitted a bug fix to the GRASS 6.4 and GRASS 7 source trees that I hope will fix it for good. Could you please test? I'll keep this open until I hear back.

Michael

comment:4 in reply to:  3 ; Changed 11 years ago by giohappy

Thanks Michael. It seems to work now. Let's keep this open for one day more, so I can do more tests. Two remarks:

1 - about the FIRST CASE (add a raster and a point, and then add another raster between the twos), it needs the "re-render" button to be used, because the "display map" isn't enough: the new raster hides the points. Why don't we use the same method of all the other GIS: when one adds a layer, the map is automatically rebuilt. It would avoid having to push the "display" and the "re-render" buttons every time... It could be in option in the preferences.

2 - the "fcolor" option of polygons in tcltk permits to choose the "None" value to do not make the polygons filled. This option doesn't appear in wxGUI, in which one is obligated to choose a color. The same for lines...

comment:5 in reply to:  4 ; Changed 11 years ago by martinl

Replying to giohappy: new raster hides the points. Why don't we use the same method of all the other GIS: when one adds a layer, the map is automatically rebuilt. It would avoid having to push the "display" and the "re-render" buttons every time...

Do you mean "render" checkbox in status bar?

Martin

comment:6 in reply to:  4 Changed 11 years ago by martinl

Replying to giohappy:

2 - the "fcolor" option of polygons in tcltk permits to choose the "None" value to do not make the polygons filled. This option doesn't appear in wxGUI, in which one is obligated to choose a color. The same for lines...

should be fixed now r32837 (r32838).

comment:7 in reply to:  5 ; Changed 11 years ago by giohappy

Replying to martinl:

Do you mean "render" checkbox in status bar?

I mean: the "FIRST CASE" problem I've descriped is solved only if I click on the "re-render" button in the Map window top-bar. If I only click the "Draw" button (the first from left) the rendered raster hides the top, point, layer. It happens only if I add the raster in a second moment layer, after having loaded the point layers.

IMHO a modern GIS should automatically manage the display of the layers as the user interact with the Layer Manager. For example, if a user add a layer, it should be automatically added to the Map, triggering the "draw" or the "re-render" action...

comment:8 Changed 11 years ago by martinl

Hopefully fixed in r32839 (r32840).

comment:9 Changed 11 years ago by martinl

Resolution: fixed
Status: newclosed

It's seems to be fixed, closing ticket. Please reopen, if necessary. Martin

comment:10 in reply to:  7 Changed 11 years ago by glynn

Replying to giohappy:

IMHO a modern GIS should automatically manage the display of the layers as the user interact with the Layer Manager. For example, if a user add a layer, it should be automatically added to the Map, triggering the "draw" or the "re-render" action...

The main issue here is that Tk doesn't support masked, true-colour images; it supports GIF (masked, 256 colours) or PPM (true-colour, no mask). So you can't take the approach that you would in a C program, i.e. load all of the layers, then just redraw whenever the layer stack changes.

Instead, it has to store the layers as image files. Whenever the layer stack changes, it has to call an external program (g.pnmcomp) to compose the layers into a single image, which it then loads and displays.

The end result is that changing the set of layers could realistically be a hundred times slower than the ideal case (storing the layers in video memory, and having the GPU compose them).

So, automatic updates should probably be user-selectable.

Note: See TracTickets for help on using tickets.