Hi, My current plan is to test my code internally and make it robust, since this affects lots of tools and renderers. Once I feel comfortable, I'll check out the latest OJ and port the change to it. Some of classes are heavily customized in my project so I need carefully select the parts that are generic and back port them to OJ. This will take some time I expect, but something I plan to do. I'd be glad to make contribution to OJ.
Bing -------------------------------------------------- From: "Sunburned Surveyor" <sunburned.surve...@gmail.com> Sent: Friday, April 10, 2009 9:59 PM To: "OpenJump develop and use" <jump-pilot-devel@lists.sourceforge.net> Subject: Re: [JPP-Devel] modelToViewTransform > Thanks for the explanaiton Bing. Any chance we will be able to > integrate your code back into the OpenJUMP core? I know a little about > the rendering system in JUMP and would be happy to review the code and > discuss with others before we commit. > > The Sunburned Surveyor > > On Thu, Apr 9, 2009 at 7:32 PM, Bing Ran <bing_...@hotmail.com> wrote: >> You're right. The double buffering provided by swing is too low level. >> The >> back buffer I'm using is bigger than the size of the LayerViewPanel, so >> that >> while moving around with mouse, I immediately see the pre-buffered region >> surrounding the current viewport, instead of seeing blank space, very >> much >> similar to panning on Google Map. >> >> >> >> -------------------------------------------------- >> From: "Sunburned Surveyor" <sunburned.surve...@gmail.com> >> Sent: Thursday, April 09, 2009 10:51 PM >> To: "OpenJump develop and use" <jump-pilot-devel@lists.sourceforge.net> >> Subject: Re: [JPP-Devel] modelToViewTransform >> >>> Bing and others: >>> >>> I thought that Swing was already double-buffered, which would make >>> this modificaiton unnecessary. Are we double double-buffering? Or does >>> the improvement come because Swing is only double-buffering the actual >>> LVP envelope, while Bing is developing beyond this envelope? >>> >>> The Sunburned Surveyor >>> >>> On Thu, Apr 9, 2009 at 6:09 AM, Larry Becker <becker.la...@gmail.com> >>> wrote: >>>> Hi Bing, >>>> >>>> I haven't studied this code for a while, but it seems like the line >>>> is >>>> moving the origin (top for window coordinate system, bottom for world). >>>> >>>> regards, >>>> Larry >>>> >>>> 2009/4/9 Bing Ran <bing_...@hotmail.com> >>>>> >>>>> Hi list, >>>>> >>>>> Recently I started introducing an image back buffer in the >>>>> LayerViewPanel >>>>> in my project for the purpose creating a (another) flicker free >>>>> panning >>>>> tool. It was the first thing I was planning to do when I started with >>>>> OJ. So >>>>> far I have made nice progress. >>>>> >>>>> Basically I have a back buffer in the LVP that is bigger than the >>>>> viewport >>>>> and the RenderingManager and all the style renderer only render to the >>>>> back >>>>> buffer and then the proper portion of the back buffer is copied to the >>>>> LVP >>>>> graphics. Additionally the back buffer is used as a cache of the >>>>> previous >>>>> rendering result and the final viewport display uses part of the back >>>>> buffer >>>>> instead of rendering afresh to reduce flickering. >>>>> >>>>> The preliminary effect of change is much appreciated by the CSRs in >>>>> our >>>>> call center. >>>>> >>>>> >>>>> I'm still having issues converting geometries correctly and precisely >>>>> in >>>>> the process though. >>>>> >>>>> >>>>> Now that I'm looking at the code of LVP.modelToViewTransform(...) I'm >>>>> wondering why this line is there: >>>>> >>>>> modelToViewTransform.translate(0, panelHeight); >>>>> >>>>> It seems to me these three lines are sufficient to convert a model >>>>> point >>>>> to a view point. >>>>> >>>>> modelToViewTransform.scale(1, -1); >>>>> modelToViewTransform.scale(scale, scale); >>>>> modelToViewTransform.translate(-originInModel.getX(), >>>>> -originInModel.getY()); >>>>> >>>>> or even: >>>>> >>>>> modelToViewTransform.scale(scale, -scale); >>>>> modelToViewTransform.translate(-originInModel.getX(), >>>>> -originInModel.getY()); >>>>> >>>>> >>>>> Can someone share insight with this? >>>>> >>>>> >>>>> Thanks >>>>> >>>>> Bing >>>>> >>>>> >>>>> >>>>> >>>>> ------------------------------------------------------------------------------ >>>>> This SF.net email is sponsored by: >>>>> High Quality Requirements in a Collaborative Environment. >>>>> Download a free trial of Rational Requirements Composer Now! >>>>> http://p.sf.net/sfu/www-ibm-com >>>>> _______________________________________________ >>>>> Jump-pilot-devel mailing list >>>>> Jump-pilot-devel@lists.sourceforge.net >>>>> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel >>>>> >>>> >>>> >>>> >>>> -- >>>> http://amusingprogrammer.blogspot.com/ >>>> >>>> ------------------------------------------------------------------------------ >>>> This SF.net email is sponsored by: >>>> High Quality Requirements in a Collaborative Environment. >>>> Download a free trial of Rational Requirements Composer Now! >>>> http://p.sf.net/sfu/www-ibm-com >>>> _______________________________________________ >>>> Jump-pilot-devel mailing list >>>> Jump-pilot-devel@lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel >>>> >>>> >>> >>> ------------------------------------------------------------------------------ >>> This SF.net email is sponsored by: >>> High Quality Requirements in a Collaborative Environment. >>> Download a free trial of Rational Requirements Composer Now! >>> http://p.sf.net/sfu/www-ibm-com >>> _______________________________________________ >>> Jump-pilot-devel mailing list >>> Jump-pilot-devel@lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel >>> >> >> ------------------------------------------------------------------------------ >> This SF.net email is sponsored by: >> High Quality Requirements in a Collaborative Environment. >> Download a free trial of Rational Requirements Composer Now! >> http://p.sf.net/sfu/www-ibm-com >> _______________________________________________ >> Jump-pilot-devel mailing list >> Jump-pilot-devel@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel >> > > ------------------------------------------------------------------------------ > This SF.net email is sponsored by: > High Quality Requirements in a Collaborative Environment. > Download a free trial of Rational Requirements Composer Now! > http://p.sf.net/sfu/www-ibm-com > _______________________________________________ > Jump-pilot-devel mailing list > Jump-pilot-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel > ------------------------------------------------------------------------------ This SF.net email is sponsored by: High Quality Requirements in a Collaborative Environment. Download a free trial of Rational Requirements Composer Now! http://p.sf.net/sfu/www-ibm-com _______________________________________________ Jump-pilot-devel mailing list Jump-pilot-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel