Hi all, I am currently working on an "expression compiler". This will allow to execute (some) expressions server side. Currently postgres is the main target but it can be adapted to others as well. This makes it very easy to write provider-independent code that is able to make use of database indexes, reduce network traffic and relocate CPU usage to a server. I will write more about this later.
One thing that I am currently working on is to apply this to the rule-based renderer. Especially for small-scale situations where a lot of features are in the visible extent but only a small fraction meeting certain criteria shall be rendered this can improve rendering speed. The problem that I am currently facing is, that the feature request does not allow combining a filterRect (extent) and an expression, since you can either set the request to filter by extent OR by expression. I thought about removing the FilterRect type and instead always combine it with the active filter type. E.g. if the filterType is filterExpression "class = 2" and a rect is set the two clauses will be joined by an AND. This may change the behavior of existing code in some cases but probably not much. Worse is that all providers will need to be revised to change this behavior... Another option would be to set the filterType to Expression and append an "AND INTERSECTS ..." to the expression. Probably this has to be done conditionally only for providers that can compile expressions because such a solution would bypass spatial indexes that work with filterRect (but not with the INSERSECTS operator). I am trying not to overcomplicate this. Are there any opinions, ideas, caveats, etc. that others can think of? Thank you for any feedback, Matthias
signature.asc
Description: OpenPGP digital signature
_______________________________________________ Qgis-developer mailing list Qgis-developer@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/qgis-developer