(no subject)

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

(no subject)

astybaev

Hi,

 

I’m the new guy in development using uDig so please, correct me if you see insufficiencies in my understanding.

Currently I see the following workflow:

 

1). Render starts.

2). Style is set for current rendering process.

3). Some DataSource is loaded to uDig.

4). Rendering process.

5). Render ends.

 

And the question is the following: is there any possibility to change the style on-fly to apply it to the current rendering process?

For example if there is some specific conditions in data that forces the style change.

So I need an update style command between sections 3 and 4 to force the rendering process to use the new style.

Accessing style via Blackboard causes the future renderings to use the proper style but the current render process still uses the old one.

Refreshing the whole layer seems to be the bad idea, because is too time expensive.

 

P.S. The main idea of style change is to change the drawing order of the features, if that can be useful.

 

Regards,

Alex Stybaev

Luxoft Automotive

 



This e-mail and any attachment(s) are intended only for the recipient(s) named above and others who have been specifically authorized to receive them. They may contain confidential information. If you are not the intended recipient, please do not read this email or its attachment(s). Furthermore, you are hereby notified that any dissemination, distribution or copying of this e-mail and any attachment(s) is strictly prohibited. If you have received this e-mail in error, please immediately notify the sender by replying to this e-mail and then delete this e-mail and any attachment(s) or copies thereof from your system. Thank you.

_______________________________________________
udig-users mailing list
[hidden email]
http://lists.refractions.net/mailman/listinfo/udig-users
Reply | Threaded
Open this post in threaded view
|

Re: (no subject)

Jody Garnett-2
Good morning: We tend to use the udig-devel email list for anything to do with programming - preferring this email list for the actual downloadable program.

I will answer your questions on that email list?
-- 
Jody Garnett

On Saturday, 3 March 2012 at 9:09 PM, Stybaev, Aleksandr wrote:

Hi,

 

I’m the new guy in development using uDig so please, correct me if you see insufficiencies in my understanding.

Currently I see the following workflow:

 

1). Render starts.

2). Style is set for current rendering process.

3). Some DataSource is loaded to uDig.

4). Rendering process.

5). Render ends.

 

And the question is the following: is there any possibility to change the style on-fly to apply it to the current rendering process?

For example if there is some specific conditions in data that forces the style change.

So I need an update style command between sections 3 and 4 to force the rendering process to use the new style.

Accessing style via Blackboard causes the future renderings to use the proper style but the current render process still uses the old one.

Refreshing the whole layer seems to be the bad idea, because is too time expensive.

 

P.S. The main idea of style change is to change the drawing order of the features, if that can be useful.

 

Regards,

Alex Stybaev

Luxoft Automotive

 



This e-mail and any attachment(s) are intended only for the recipient(s) named above and others who have been specifically authorized to receive them. They may contain confidential information. If you are not the intended recipient, please do not read this email or its attachment(s). Furthermore, you are hereby notified that any dissemination, distribution or copying of this e-mail and any attachment(s) is strictly prohibited. If you have received this e-mail in error, please immediately notify the sender by replying to this e-mail and then delete this e-mail and any attachment(s) or copies thereof from your system. Thank you.
_______________________________________________
udig-users mailing list


_______________________________________________
udig-users mailing list
[hidden email]
http://lists.refractions.net/mailman/listinfo/udig-users
Reply | Threaded
Open this post in threaded view
|

Re: (no subject)

astybaev

Hi,

 

I apologize for mixing the mailing lists. I think we would better move to udig-devel list.

 

WBR,

Alex

 

From: [hidden email] [mailto:[hidden email]] On Behalf Of Jody Garnett
Sent: Tuesday, March 06, 2012 1:08 AM
To: Stybaev, Aleksandr
Cc: [hidden email]
Subject: Re: [udig-users] (no subject)

 

Good morning: We tend to use the udig-devel email list for anything to do with programming - preferring this email list for the actual downloadable program.

 

I will answer your questions on that email list?

-- 

Jody Garnett

 

On Saturday, 3 March 2012 at 9:09 PM, Stybaev, Aleksandr wrote:

Hi,

 

I’m the new guy in development using uDig so please, correct me if you see insufficiencies in my understanding.

Currently I see the following workflow:

 

1). Render starts.

2). Style is set for current rendering process.

3). Some DataSource is loaded to uDig.

4). Rendering process.

5). Render ends.

 

And the question is the following: is there any possibility to change the style on-fly to apply it to the current rendering process?

For example if there is some specific conditions in data that forces the style change.

So I need an update style command between sections 3 and 4 to force the rendering process to use the new style.

Accessing style via Blackboard causes the future renderings to use the proper style but the current render process still uses the old one.

Refreshing the whole layer seems to be the bad idea, because is too time expensive.

 

P.S. The main idea of style change is to change the drawing order of the features, if that can be useful.

 

Regards,

Alex Stybaev

Luxoft Automotive

 

 


This e-mail and any attachment(s) are intended only for the recipient(s) named above and others who have been specifically authorized to receive them. They may contain confidential information. If you are not the intended recipient, please do not read this email or its attachment(s). Furthermore, you are hereby notified that any dissemination, distribution or copying of this e-mail and any attachment(s) is strictly prohibited. If you have received this e-mail in error, please immediately notify the sender by replying to this e-mail and then delete this e-mail and any attachment(s) or copies thereof from your system. Thank you.

_______________________________________________

udig-users mailing list

 



This e-mail and any attachment(s) are intended only for the recipient(s) named above and others who have been specifically authorized to receive them. They may contain confidential information. If you are not the intended recipient, please do not read this email or its attachment(s). Furthermore, you are hereby notified that any dissemination, distribution or copying of this e-mail and any attachment(s) is strictly prohibited. If you have received this e-mail in error, please immediately notify the sender by replying to this e-mail and then delete this e-mail and any attachment(s) or copies thereof from your system. Thank you.

_______________________________________________
udig-users mailing list
[hidden email]
http://lists.refractions.net/mailman/listinfo/udig-users
Reply | Threaded
Open this post in threaded view
|

Re: (no subject)

Jody Garnett-3
<base href="x-msg://8/">I apologize for mixing the mailing lists. I think we would better move to udig-devel list.

Thanks; now lets see if I can help ...

Hi,
 
I’m the new guy in development using uDig so please, correct me if you see insufficiencies in my understanding.

Not to worry! Can I ask if you have gone through the tutorials? Some of the tutorials are only available as source code; including the one that answers your question.


Note: If you want to take a uDig training course; or are from an academic institution we can arrange access to these workbooks.

Currently I see the following workflow:
1). Render starts.
2). Style is set for current rendering process.
3). Some DataSource is loaded to uDig.
4). Rendering process.
5). Render ends.

Workflow is actually:
1) Map is created
2) Layer is created (using a GeoResource and using a default Style generated from the geoResource)

3) Layer is added to the Map
4) RenderManager watches the map; and now since things have changed it goes through and figures out what renderer to use for each layer
5) RenderManager passes the final list of renderers to the RenderExecutor
6) RenderExecutor uses the renders to draw on the screen (as the user pans and zooms around)
- Each renderer is responsible for drawing the content of its Layer
- How this is done is up to each renderer
- As an example the BasicFeatureRenderer calls geoResource.resolve( FeatureSource ) to get a GeoTools FeatureSource and grabs the GeoTools Style from the layer style blackboard;  tt then uses the GeoTools StreamingRenderer to draw featureSource+Style
6) Whenever the layers or styles change step (4) is run again

 
And the question is the following: is there any possibility to change the style on-fly to apply it to the current rendering process?
Yes; everytime you change anything on the "style blackboard" render occurs again - it is what it is for.

For example if there is some specific conditions in data that forces the style change.

No in the raw data (ie from the FeatureSource). But if you change the Style (and put the changed style on the style blackboard) the rendering engine will figure out what to do again.

So I need an update style command between sections 3 and 4 to force the rendering process to use the new style.

You can update the style from any thread; this will trigger the layer to redraw.

Accessing style via Blackboard causes the future renderings to use the proper style but the current render process still uses the old one.

You may need to call styleBlackboard.put( style ) to trigger the redraw. In general you don't modify the style in place (since it is being used by another thread). Grab a copy; modify; and replace.

Refreshing the whole layer seems to be the bad idea, because is too time expensive.

You can call layer.refresh( ReferencedEnvelope ) to only redraw part of the screen.

P.S. The main idea of style change is to change the drawing order of the features, if that can be useful.

Interesting; not sure how you plan to do that? You could make two feature type styles with two different filters. That would allow you to choose what features to draw into each group (and thus make some appear to be drawn over top of another).

Jody


_______________________________________________
udig-users mailing list
[hidden email]
http://lists.refractions.net/mailman/listinfo/udig-users