![]() |
|
|||||||
| Development Help Help for building applications or diagnosing problems with WWJ |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Junior Member
Join Date: Nov 2008
Posts: 8
![]() |
I'm showing a SurfaceImage on the ground of WW that is changing continuosly. I want to calculate in some way how much this image is visible or how much i'm close to the image. Precisly, but I think it's so difficoult to calculate, the percentuage of the visible ground that this image occupies.
I want to stop changing the image if it is not more visible or partialy visible. I'm working at the Layer level, so I can manage the DrawingContext. Thanks |
|
|
|
|
|
#2 |
|
WWJ Consultant
Join Date: Jun 2005
Location: Saint-Paul de Vence, Alpes Maritimes, France
Posts: 3,412
![]() |
What you can try is to compute the bounding cylinder extent of your image (globe.computeBoundingCylindert(sector)) . Then, before rendering, you can test for the extent.intersect(dc.getView().getFrustum InModelCoordinates()).
|
|
|
|
|
|
#3 |
|
Junior Member
Join Date: Nov 2008
Posts: 8
![]() |
Thank you for the replay. The solution tha you gave me is only for one problem that I had.
The second one is that I want to increase the quality of the image if i'm closer to it. The DrawContext.getVisibleSertor() gives me an approximated sector so I cannot be precise calculating the ratio between the size of the visible and image sectors. Is there a way to calculate how much of visible terrain an image occupies? Thanks |
|
|
|
|
|
#4 |
|
WWJ Consultant
Join Date: Jun 2005
Location: Saint-Paul de Vence, Alpes Maritimes, France
Posts: 3,412
![]() |
Tiled image layers do handle the eye proximity to image tiles so as to split them when getting close enough and increase their resolution. Have a look at layers.TiledImageLayer.needToSplit(DrawC ontext, Sector).
|
|
|
|
![]() |
| Tags |
| percentuage, surfaceimage, visibility |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Elevated SurfaceImage with Sector.FULL_SPHERE (Global Clouds) | lembas | Development Help | 13 | 02-07-2012 09:07 AM |
| Large SurfaceImage | eenglund | Development Help | 11 | 07-04-2008 12:03 AM |
| SurfaceImage reloaded... | asantiago | Development Help | 0 | 11-26-2007 11:24 PM |
| Movable SurfaceImage | asantiago | Development Help | 0 | 11-21-2007 08:38 PM |
| Updated SurfaceImage | asantiago | Development Help | 3 | 11-20-2007 10:33 PM |