r3wp [groups: 83 posts: 189283]
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

World: r3wp

[!REBOL3 Proposals] For discussion of feature proposals

Steeve
27-Jan-2011
[871]
Ok, if you use only one object/gob then the whole thing is rendered 
each time
Maxim
27-Jan-2011
[872x3]
each layer creates a tiny object for every widget, but the size of 
the draw blocks is immense, so it will save memory in the end.  if 
we have 10 objects storing  10000 items 10 times 

vs 10 storing parts of those 10000 objects 10 times the memory saving 
should be significant.
its like 10000 * 10 vs 100 * 10.   the bigger the scene, the bigger 
the savings.
and then I can just render 3 of those at a time, so instead of rendering 
10000 times I can just render 100... in rendering that will help 
too.
TomBon
27-Jan-2011
[875]
maxim, do you plan to add more widgets to glass?
Steeve
27-Jan-2011
[876]
Ok for the rebol side, but the graphic engine will have to render 
the whole scene each time. It could ne slow in some cases
Maxim
27-Jan-2011
[877]
Tom, I'm working on the most advanced text editing widget you've 
ever used right now.
TomBon
27-Jan-2011
[878x2]
great! important one. something linke treeview, ribbons etc.?
looks like esp. treeviews are quite difficult?
Maxim
27-Jan-2011
[880x2]
steeve, with layers, I split up the rendering into different things. 
  bg/fg/interactive.  and I don't have to render the bg all the time, 
only on resize. 

I'll also be able to render just a single widget directly on a bitmap, 
using AGG clipping to that widget.
I just realized where really in the wrong group ;-)
Andreas
27-Jan-2011
[882x3]
given that the default-extension in R3 is currently %.reb, are we 
actually supposed to use this?
or is it likely that this will be switched to %.r3 anytime soon?
(given that most people currently seem to use either %.r3 or %.r)
BrianH
28-Jan-2011
[885x3]
No, you're not really supposed to use .reb, you're supposed to change 
the setting to what you were going to use anyways.
That's why the setting is .reb: There is no consensus on what extension 
to use, so the setting is set to something noone uses.
See http://issue.cc/r3/1573for remove-duplicates and the reason 
it's not as good an idea as you might think. It turns out that the 
set functions have to allocate a new series to do their work (for 
series larger than trivial size), even if they were changed to modify 
in place. So you can't avoid the allocation; might as well benefit 
from it.
Maxim
28-Jan-2011
[888]
its a good idea, because I can't copy the series, its linked in many 
places.
BrianH
28-Jan-2011
[889x2]
Look a the proposal in that ticket. It works the same as yours but 
faster.
And it's order safe.
Maxim
28-Jan-2011
[891x3]
and if the function does this internally in C it will still be MUCH 
faster  which is why I'd much prefer having refinements for in-place 
functioning of all set functions.
yeah, that implementation is pretty neat.
using refinements also means less functions to remember... there 
are quite a few set functions.  I don't want to have each one duplicated 
as a mezz function.
BrianH
28-Jan-2011
[894]
It has to allocate another series anyways, as the set functions do 
hashing. In-place is just for convenience, not to save memory.
Maxim
28-Jan-2011
[895x3]
I know, but everything that's done in the C side will save on speed 
and memory, since the C doesn't have to go through the GC and all 
that.  in tight loops and real-time continual processing, these details 
make a big difference in overall smoothness of the app.
which is why its preferable to do it there anyways... and the fact 
that we only have one function name to remember for the two versions 
is also a big deal for simplicitie's sake.
I just realized that if Carl is using a hash table for some of the 
set functions... does this mean that its subject to the 24 bit hash 
problem we discovered in maps?
BrianH
28-Jan-2011
[898x3]
Yes, until that's fixed.
See also http://issue.cc/r3/1574
You could add /no-copy refinements to the set functions though. Of 
course this would switch which half of the set functions are misnamed 
:)
Maxim
28-Jan-2011
[901x2]
/no-copy would be really nice... its been a recurring discussion 
for years by many of us, which proves that its a required feature 
IMHO.
copy or not, there is no more "correct" version, they both are.
BrianH
28-Jan-2011
[903x2]
No, I mean that modifying functions should have verb names and non-modifying, 
not-for-effect functions shouldn't. So for the current set functions 
UNIQUE, DIFFERENCE and UNION have good names, but EXCLUDE should 
be called EXCLUDING and INTERSECT should be called INTERSECTING; 
this gets reversed for modifying versions :)
But that's just being silly, unless we're adding new functions that 
need names.
Maxim
28-Jan-2011
[905]
yeah.
BrianH
28-Jan-2011
[906]
Doesn't matter. The non-modifying version of APPEND is called JOIN, 
and both of those are verbs.
Maxim
28-Jan-2011
[907]
does JOIN still reduce like it did in R2?
BrianH
28-Jan-2011
[908]
Yup, so it's not a direct correspondance.
Maxim
28-Jan-2011
[909]
I always wondered why it reduced... I find that very annoying... 
many times I'd use it and It ends up mucking up my data, so I just 
almost never use it.
BrianH
28-Jan-2011
[910]
I mostly use REJOIN and AJOIN instead of JOIN, or maybe APPEND COPY.
Maxim
28-Jan-2011
[911]
me to.
Ladislav
28-Jan-2011
[912]
I am pretty sure, that:


1) the set operations in Rebol are in fact GC-safe using the standard 
meaning of the sentence

2) it is always necessary to use auxiliary data, if the wish is to 
do the set operation efficiently

3) nobody pretending to need a modifying version really needs an 
inefficient variant, which does not use any auxiliary data
Maxim
28-Jan-2011
[913]
why do you say we "pretend"?
BrianH
28-Jan-2011
[914]
I think that people who need a modifying version really need it, 
but the rest of us need the non-modifying default :)
Ladislav
28-Jan-2011
[915x2]
really need it

 - does that mean they need what I specified - an inefficient variant 
 not using any auxiliary data?
I suppose that is nonsense
BrianH
28-Jan-2011
[917]
Nope, it just means they need the first argument modified to contain 
the result instead of what it originally contained.
Maxim
28-Jan-2011
[918]
no one is saying to use anything less efficient than the copy returning 
version.
BrianH
28-Jan-2011
[919]
The only difference between the DEDUPLICATE code in the ticket and 
a native version is that the auxiliary data could be deleted immediately 
after use instead of at the next GC run.
Maxim
28-Jan-2011
[920]
and the data is managed directly by C, not by the interpreter, which 
is faster for sure.