Cruisers Forum
 

Go Back   Cruisers & Sailing Forums > Seamanship, Navigation & Boat Handling > OpenCPN
Cruiser Wiki Click Here to Login
Register Vendors FAQ Community Calendar Today's Posts Log in

Reply
  This discussion is proudly sponsored by:
Please support our sponsors and let them know you heard about their products on Cruisers Forums. Advertise Here
 
Thread Tools Search this Thread Rate Thread Display Modes
Old 29-11-2015, 07:04   #271
Marine Service Provider
 
bdbcat's Avatar

Join Date: Mar 2008
Posts: 7,502
Re: OpenCPN Beta test 4.1.1108 Release

TDan...

re:
Maybe you or someone else knowing how chcanv.cpp works could check out this patch:

OK, does the job fine. Corner case not well tested, I guess. Code style a little off.

Better:
Code:
            if( ( pRouteDraw == active_route ) || ( pRouteDraw == active_track ) ){
                node = node->GetNext();
                continue;
            }
Thanks
Dave
bdbcat is offline   Reply With Quote
Old 29-11-2015, 07:30   #272
Registered User

Join Date: Jun 2015
Posts: 379
Re: OpenCPN Beta test 4.1.1108 Release

Quote:
Originally Posted by NahanniV View Post
Thanks, for that explanation. My sleep deprived brain is not always working properly when using OpenCPN at night.

So, is doing the compression 4 times a reasonable solution to this ?

Is RGB necessary ?

There was a suggestion (with pull request?) to have an indicator on screen when any of the modifiers, like "S"oundings, "C"olour, etc..., were active. It seems like a good idea, but unfortunately it did not get included.

Cheers,
JM.
Yes if you're actually using DUSK and NIGHT schemes you can compress textures, select DUSK then option, rebuild cache, and so on, it works, of course your cache will be bigger.
did-g is offline   Reply With Quote
Old 29-11-2015, 08:38   #273
Registered User

Join Date: Aug 2009
Location: oriental
Boat: crowther trimaran 33
Posts: 4,426
Re: OpenCPN Beta test 4.1.1108 Release

it would be nice to somehow use a fragment shader to apply color schemes. This would avoid the enlarged cache, it would allow for infinite customizable schemes (so alternate schemes for day etc...)
seandepagnier is offline   Reply With Quote
Old 29-11-2015, 12:06   #274
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,290
Re: OpenCPN Beta test 4.1.1108 Release

Dave.. Test result below.
Sum: AIS ON/OFF seems to be the "rascal".

Quote:
Originally Posted by bdbcat View Post
Hakan...

OK, lets focus in here on the leak. I want to narrow this down to a specific feature/function that induces the problem.

Questions:
1. Is it obvious in a few minutes that the memory is growing, or do you have to wait some hours to detect it?
It's really obvious. Once the VDR file starts to play from the other O instance the the memory start to grow say 200 kB every second.
Quote:

2. Do you have a custom ownship icon?
No, the inbound real scale vector type. I changed to default and no difference in M building up.
Quote:
Lets narrow down to a specific test set, so we can get repeatability.

Try this configuration, please.
Test 1:
a. VDR recording playback, Sweden.
b. cm93 only
c. AIS OFF (toolbar button grey'ed out)
d. Not auto following, but ownship on-screen somewhere, and moving.
- No memory build-up. Just normal memory use and release on scale changes etc.
- Add Auto follow: No memory built-up.
- Add AIS ON. - Direct memory build-up as earlier. AIS=OFF stops memory build-up but don't release erlier built-up.
Auto follow = OFF or ON, the same result.
And, the results using raster charts are the same.
Quote:
Next test:
Test 2:
a. Remove all charts, or set up an empty group. No charts shown at all except world background.
b. Auto-follow ON.
c. Same VDR playback.
d. AIS OFF
e. Large scale, so that the chart moves fairly quickly.
- No memory build-up.
- Auto-follow ON, > No memory build-up.
- AIS ON, > memory build-up at the same rate as before.
- Changed to a not empty chart group and no difference in memory build-up rate.

Thanks for the good test instructions. Are the results narrow enough or do you need more? Please advice.

Håkan
Hakan is offline   Reply With Quote
Old 29-11-2015, 14:26   #275
Marine Service Provider
 
bdbcat's Avatar

Join Date: Mar 2008
Posts: 7,502
Re: OpenCPN Beta test 4.1.1108 Release

Hakan...

I think we are narrowing down to AIS.

Funny, I think I am seeing the same thing here, although on a linux system.
Lets try to absolutely confirm this.

Please run a test with full cm93, autofollow on, VDR playback, and AIS disabled. Then again with AIS enabled, no other change at all.

I'll do the same.

Thanks
Dave
bdbcat is offline   Reply With Quote
Old 29-11-2015, 14:55   #276
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,290
Re: OpenCPN Beta test 4.1.1108 Release

Dave
I got the same result again:
"Add AIS ON. - Direct memory build-up as earlier. AIS=OFF stops memory build-up but don't release earlier built-up."

Just to stress is more I used full screen and small screen, auto follow and look ahead mode.
AIS=ON Memory build-up, AIS=OFF no memory build-up.

But: If I, with AIS=ON, switch to scale like 50 000 000 the memory build-up stops and returns at less then ~500 000.

Håkan
Hakan is offline   Reply With Quote
Old 29-11-2015, 15:18   #277
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,766
Images: 2
Re: OpenCPN Beta test 4.1.1108 Release

Yeah! You guys figured out the source of the leak! I was going to say I have a opencpn_4.1.718_setup.exe if that will help. It is uploaded to main directory of Opencpn Beta File Thingie rguser rgpass


but isn't this strange to occur?
Quote:
"But: If I, with AIS=ON, switch to scale like 50 000 000 the memory build-up stops and returns at less then ~500 000. "
rgleason is offline   Reply With Quote
Old 29-11-2015, 18:25   #278
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,766
Images: 2
Re: OpenCPN Beta test 4.1.1108 Release

After a short test with hakefjord.txt I can confirm that when the
AIS Icon is ON and AIS is displaying in the screen (with alerts off) Memory is used up.
AIS Icon is off Memory is not used up.
AIS Icon is off, Alerts are on, Memory is not used up.
rgleason is offline   Reply With Quote
Old 29-11-2015, 19:09   #279
Marine Service Provider
 
bdbcat's Avatar

Join Date: Mar 2008
Posts: 7,502
Re: OpenCPN Beta test 4.1.1108 Release

Hakan/Rick, etc...

Memory leak:

Resolved. Issue was OpenGL texture leak (failure to delete) related to texture-based rendering of AIS target names.

If the target names are not displayed, there is no leak. If target names are displayed, it leaks about 1 texture per second, about 150KB, depending on the font used.

Hard to say exactly when this bug was introduced. Long time, anyway...

Fixed in github now.

Thanks for all your extra effort to help isolate and zap this one.
Dave
bdbcat is offline   Reply With Quote
Old 29-11-2015, 21:39   #280
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,290
Re: OpenCPN Beta test 4.1.1108 Release

Dave
And thank you for listening and your knowledge to find the cause.
"The simple is the hard to find" (- or something like that)
Håkan
Hakan is offline   Reply With Quote
Old 30-11-2015, 04:25   #281
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,766
Images: 2
Re: OpenCPN Beta test 4.1.1108 Release

Thankyou bdcat and hakan for finding it! A very good one to swat.
rgleason is offline   Reply With Quote
Old 30-11-2015, 16:54   #282
Registered User

Join Date: Dec 2005
Location: Helsingborg
Boat: Dufour 35
Posts: 3,891
Re: OpenCPN Beta test 4.1.1108 Release

Quote:
Originally Posted by bdbcat View Post
Hakan/Rick, etc...

Memory leak:

Resolved. Issue was OpenGL texture leak (failure to delete) related to texture-based rendering of AIS target names.

If the target names are not displayed, there is no leak. If target names are displayed, it leaks about 1 texture per second, about 150KB, depending on the font used.

Hard to say exactly when this bug was introduced. Long time, anyway...

Fixed in github now.

Thanks for all your extra effort to help isolate and zap this one.
Dave
Dave & All

Great catch. I have used v 4.0 for some time now. (We just arrived in the B.V.I.) In the AIS "Zoo" called the North Sea & English Channel, with constantly new targets appearing I had crashes about every 2-3 days. Across the Atlantic, with very few targets, no crash at all after 3-4 weeks.
Now I know why! I'm just in the process of changing to the beta series. Hopefully I'll be able to contribute to the testing, depending on wifi connections etc.

Cheers
/Thomas
cagney is offline   Reply With Quote
Old 30-11-2015, 17:00   #283
Marine Service Provider
 
bdbcat's Avatar

Join Date: Mar 2008
Posts: 7,502
Re: OpenCPN Beta test 4.1.1108 Release

Thomas!

A voice returns from the great blue sea.

Congratulations. I hope you had a good passage, and all well aboard. Looking forward to your Beta test contributions.

Dave
bdbcat is offline   Reply With Quote
Old 30-11-2015, 19:22   #284
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,766
Images: 2
Re: OpenCPN Beta test 4.1.1108 Release

Win7 v4.1.1108 getting back to charts.
I had to delete the Opengl Texture cache because of recent compile.
Opengl with texture caching.
With quilting on and unchecked No full quiliting on the advanced tab.

ENC and CM93 seem to work acceptably fast, even as the texture cache gets filed and SENC files are being made. CM93 appears to be seamless when zooming with hardly a pause.

RNC iappears a problem. It appears to be slow to respond when zooming in or out and sometimes hangs. Sometimes it just sits there with the wheel spinning. More about this tomorrow after some more testing.
rgleason is offline   Reply With Quote
Old 30-11-2015, 23:59   #285
Registered User

Join Date: Aug 2009
Location: oriental
Boat: crowther trimaran 33
Posts: 4,426
Re: OpenCPN Beta test 4.1.1108 Release

Rick,

I just want to confirm that this is because it is building the cache in the background. If you rebuild the texture cache is it acceptably fast?

Sean
seandepagnier is offline   Reply With Quote
Reply

Tags
enc, lease, opencpn


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
OpenCPN Beta test 4.1.1022 Release bdbcat OpenCPN 122 07-11-2015 01:12
OpenCPN Beta test 4.1.925 Release bdbcat OpenCPN 177 04-11-2015 08:16
OpenCPN Beta test 4.1.602 Release bdbcat OpenCPN 193 13-10-2015 08:19
OpenCPN Version 2.2 Beta Test bdbcat OpenCPN 437 15-12-2010 19:17
OpenCPN Version 2.2 Beta Test Bugs / Discussion bdbcat OpenCPN 120 26-09-2010 02:53

Advertise Here


All times are GMT -7. The time now is 00:36.


Google+
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Social Knowledge Networks
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2024, vBulletin Solutions, Inc.

ShowCase vBulletin Plugins by Drive Thru Online, Inc.