Cruisers Forum
 


Reply
 
Thread Tools Search this Thread Rate Thread Display Modes
Old 15-07-2011, 14:40   #1
Registered User

Join Date: Aug 2009
Location: oriental
Boat: crowther trimaran 33
Posts: 4,414
opengl Support

If opencpn used WxGLCanvas it could render faster and make use of more hardware accelerations. This would make zooming and panning completely smooth, as well as offer hardware accelerated alpha blending for overlays and routes etc.. It would improve performance which could make a big difference on some handhelds.

I just want to know if anyone is working on this or not so I am not wasting time. Since I only have linux I would need some people to be willing to test and make it build on other operating systems. We could keep the default rendering too incase of lack of opengl.
seandepagnier is offline   Reply With Quote
Old 17-07-2011, 17:16   #2
Marine Service Provider
 
bdbcat's Avatar

Join Date: Mar 2008
Posts: 7,387
Re: opengl Support

geckosenator....

I worked on this a bit last winter. Inconclusive results. The major issues (at least for raster charts) involve texture mapping, as I'm sure you know. You need a lot of texture memory on the graphics card to make this work right.

When I found that with my feeble video hardware, the performance was worse, I dropped the effort.

I encourage you to carry on with this effort. I believe it would be a good step forward in functionality and performance with the right hardware.

Good luck
Dave
bdbcat is offline   Reply With Quote
Old 17-07-2011, 21:17   #3
Registered User

Join Date: Aug 2009
Location: oriental
Boat: crowther trimaran 33
Posts: 4,414
Re: opengl Support

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

I worked on this a bit last winter. Inconclusive results. The major issues (at least for raster charts) involve texture mapping, as I'm sure you know. You need a lot of texture memory on the graphics card to make this work right.

When I found that with my feeble video hardware, the performance was worse, I dropped the effort.

I encourage you to carry on with this effort. I believe it would be a good step forward in functionality and performance with the right hardware.

Good luck
Dave
I got it rendering through opengl today! Like you say, it uses textures in video memory (although opengl can store textures in ram too) I bypassed quilting support, so that isn't working yet (having multiple charts, or huge charts in video memory could prove difficult), as well as all the other stuff (routes tides etc...) but that part shouldn't be too hard to convert. So far I have to do quite a bit more to actually get the smooth scrolling, rotation support, and smooth zooming I am looking for.

I noticed opencpn does a lot of image manipulation in software which is generally much slower than if hardware accelerated. Right now I am basically leaving it mostly the way it is, then having it copy the current chart into a texture which is rather slow, but happens only once when you switch textures, then when manipulating that chart, everything is in video memory and hardware accelerated. It really isn't that much slower even if I copy it every frame which I don't need to, so it isn't that bad. It could likely be speed up significantly with various other rearrangements to bypass the use of wxdc's althogether, but it's too much code for me to swallow at once.

As for vector charts, it would be great to have native support in GL, but initially I might "rasterize" them in software to a texture since it is easier, but of course, slower and more memory intensive.

I kept the normal rendering code intact so it will let you choose opengl or not in the config window. That way if there are bugs anywhere (maybe even in the driver) it is easy for users to toggle it on or off, and if you compile on a system without all the needed opengl libraries, it will still work.

Hopefully in a few days or a week I will have a patch. Then we can get all the ends tied up and try to build it on other operating systems. It is sure to break on windows, and I imagine this will require a bunch of ifdefs to make things right.
seandepagnier is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

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
Thumbs Down to Raymarine Support for ST6002 Wheel Drive sailorboy1 Product or Service Reviews & Evaluations 23 12-07-2011 04:53
S-57 3.1 format support vlad.1 OpenCPN 2 02-07-2011 04:32

Advertise Here


All times are GMT -7. The time now is 04:33.


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.