From: Phil R. <p.d...@gm...> - 2016-01-29 17:37:02
|
I seem to remember we added those calls in because they are needed to wipe the memory left over at the end of a plot. For example if a user starts plotting with the default colours or colours left over from the previous page then changes them half way through, when the plot is resized and if we didn't have some sort of bop event then the plot would get redrawn with the incorrect new set of colours. Same occurs for line width and other state variables. But in addition, there needs to be a way to set the current subpage, and the subpage size. Otherwise when the clear command comes later the driver does not know how big an area to clear. I think the bop call also does things like reset the scale so that text is the right size - again remembering that we should be able to just play a buffer on an empty driver, which would otherwise have no idea of these variables. The clear is definitely required, because the clear applies to each subpage, not to the whole page and I think the user can set each subpage to a different clear colour. So we need to time the clears correctly when we are clipping to the correct subpage. Phil On 29 January 2016 at 08:13, Greg Jung <gv...@gm...> wrote: > > > On Thu, Jan 28, 2016 at 8:47 PM, Jim Dishaw <ji...@di...> wrote: > >> >> On Jan 28, 2016, at 8:15 PM, Greg Jung <gv...@gm...> wrote: >> >> >> >> Can you describe the wrong behavior? Does it occur when you resize? >> > There's no re-sizing involved. The image is put up via > SetDIBitsToDevice(GetHdc(), 0, 0, rt.right + 1, rt.bottom + 1, 0, > 0, 0, rt.bottom + 1, tv_buf.lpbitmap, & > tv_buf.bi, DIB_RGB_COLORS); > found in {sfnet::GDL}src/gdlwinstream.cpp - gdlwinstream::Paintimage > > > The test involved > part 1: multiple windows, where a simple distribution is laid out. > colors are reloaded > (scmap0) and the distribution is painted. > > a=DIST(xdim, ydim) > b1=REFORM(a,1, xdim, ydim) > b2=REFORM(a,xdim, 1, ydim) > b3=REFORM(a,xdim, ydim, 1) > ; > icolor=0 > MY_WINDOW, 0, a > loadct,icolor & icolor++ > > MY_WINDOW, 1, b1 > loadct,icolor & icolor++ > MY_WINDOW, 2, REFORM(b1) > loadct,icolor & icolor++ > MY_WINDOW, 3, b2 > loadct,icolor & icolor++ > MY_WINDOW, 4, REFORM(b2) > loadct,icolor & icolor++ > MY_WINDOW, 5, b3 > loadct,icolor & icolor++ > MY_WINDOW, 6, REFORM(b3) > loadct,icolor & icolor++ > > where MY_WINDOW = > 1. create window of size to hold the 2-d > 2. Put up the 2-D onto window > For each window a different color table was loaded (icolor++) > [image: Inline image 2] > Then this distribution is applied to sections of a larger window. > This works except on the last test where a different color table should > show for each sub-section. > [image: Inline image 3] > then a few exercises of "TV" routine are made, which puts the saturn.jpg > image on a window where line-plots are already made: > [image: Inline image 4] > The actual wrong behavior; it ranged from segfaults to all of the windows > blanking, to everything showing but the saturn image. > To find when it occurs, I built using historical plplots until I found it > was between Jan 15 and Feb 1. The changes in plbuf were too coarse to use > plgit at that stage so I advanced plbuf from the working version towards > the final plbuf.c: > > greg@Homerw7 MINGW32 /d/dated/plplot-git/plplot-150115 > $ git log > commit cd749d09d1f6cbad3172e1b0b04910fc8ae3f4d8 > Author: Greg Jung <gv...@gm...> > Date: Sun Jan 24 08:15:19 2016 -0800 > > more plbuf.c advances. seqfaults when attempting to implement > rd_data_no_copy etc. > > commit b4411c72cd6c75c506574699adbb6cbfe9a7f8d2 > Author: Greg Jung <gv...@gm...> > Date: Sun Jan 24 06:57:54 2016 -0800 > > see patches/0000-656am.patch. Compiles and runs gdl test_tv > > commit 27096a39cfac94c988b069d3ea94dd4c11fb3848 > Author: Greg Jung <gv...@gm...> > Date: Sun Jan 24 06:22:52 2016 -0800 > > This commit brings 150115 to the edge of break, in caase of > plsdef.c, where > invoking plP_state( PLSTATE_CHR ); at line 208 or > possibly line 255 produces a segfault in win32 builds. > > commit ccfee95ac0370f00f97b0e0deeebc450545b47e1 > Author: Alan W. Irwin <ai...@us...> > Date: Thu Jan 15 13:22:42 2015 -0800 > > Build System: Fix bug for case where no display > > A successful test would have the above pics displayed on the terminal > [image: Inline image 5] > > The patch files below document the changes made from the base ccfee95ac03 > git. Using Winmerge, I compared src/ with later versions to test when a > problem cropped up. > > > ------------------------------------------------------------------------------ > Site24x7 APM Insight: Get Deep Visibility into Application Performance > APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month > Monitor end-to-end web transactions and take corrective actions now > Troubleshoot faster and improve end-user experience. Signup Now! > http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140 > _______________________________________________ > Plplot-devel mailing list > Plp...@li... > https://lists.sourceforge.net/lists/listinfo/plplot-devel > > |