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

World: r3wp

[Rebol School] Rebol School

Geomol
16-Feb-2009
[2207]
All functions are in a situation like this. {<%level%>} is just a 
string giving to a function.
kib2
16-Feb-2009
[2208]
I've never seen such a behavior in whatever langage I've used, but 
I'm starting to understand it : thanks for the clarification.
Geomol
16-Feb-2009
[2209x2]
Maybe you can think of it as two persons, one giving the other a 
string. The person receiving the string read "<%level%>". That person 
now have to figure out, what level mean. The person live in a context 
(the global context in this situation, because everybody can call 
build-markup). So it look up level in the global context and find 
nothing, so it gives an error.
If you instead write: rejoin ["<%" level "%>"]

then level is replaced by the value of level and a string is made, 
and this new string is sent to build-markup.
kib2
16-Feb-2009
[2211x2]
Yes, nice comparison Geomol, we see that you live in the stars :)
It's all clear now, but I shall forget about my bad habbits.
Geomol
16-Feb-2009
[2213]
Learning REBOL is also about unlearning what you're used to. :-)
kib2
16-Feb-2009
[2214x2]
and sometimes unlearning if even more difficult than learning !
is RebGUI widely used ?
Rebolek
16-Feb-2009
[2216]
I used it for one program that was used to fix translation of Windows 
Vista in 15 or 19 different languages. It depends on your definition 
of "widely".
kib2
16-Feb-2009
[2217]
Rebolek: I meant "was it a good alternative to VID ?". The only thing 
I miss in every Rebol GUI I've seen is font antialiasing.
Geomol
16-Feb-2009
[2218x3]
kib, if you run under Windows and wants anti-aliasing:

view layout [box black effect [draw [text "Hello World!"]]]
font-A: make face/font [size: 32]

view layout [box 200x100 black effect [draw [font font-A text "Hello 
World!"]]]
view layout [box 200x100 black effect [draw [pen red fill-pen yellow 
font font-A text "Hello W
orld!" vectorial]]]
kib2
16-Feb-2009
[2221x2]
Geomol: in this case, you're drawing them with AGG. Your text is 
not selectable.
But that gives me an idea : is there something like NodeBox in Rebol 
?
Geomol
16-Feb-2009
[2223]
right, you figure that part out and make a nice GUI for us! :-)
kib2
16-Feb-2009
[2224]
No problem! give me just a min ... or a year :)
Geomol
16-Feb-2009
[2225]
NodeBox? Something like splash?

do http://www.rebol.com/view/demos/splash.r
kib2
16-Feb-2009
[2226x2]
No, NodeBox is for poets : http://nodebox.net/code/index.php/Gallery
. Have a look at the Helsinki gallery : it's really beautiful.
Brendan Dawes' work is also interesting.
Geomol
16-Feb-2009
[2228x2]
ok, looks nice!
I don't know, if anyone has done something similar in REBOL. There 
are demos flying around. I made a very simple Bezier demo once:

do http://www.fys.ku.dk/~niclasen/rebol/fysik/bezier.r

It could be a start to make something better and more beautiful.
kib2
16-Feb-2009
[2230]
It's like Processing ( http://processing.org/), I like this page 
made with it : http://www.wblut.com/2009/01/27/strange-symmetry-2-lite/
Geomol
16-Feb-2009
[2231]
and REBOL got the speed, I think, if you try Cyphres demo:

do http://www.rebol.com/view/demos/cyphre.r
kib2
16-Feb-2009
[2232]
Fun! And you can had more control points I suppose ?
Geomol
16-Feb-2009
[2233]
yes, shouldn't be too hard.
kib2
16-Feb-2009
[2234x2]
Whao, cypher is really quick and beautiful.
cypher --> cyphre
Geomol
16-Feb-2009
[2236x2]
yup
LOL just found this:

do http://www.rebol.com/view/demos/imagination.r

move your mouse around.
kib2
16-Feb-2009
[2238]
Yes, wonderful job. Who did these demos ? Amiga fans ?!
Geomol
16-Feb-2009
[2239]
hehe, they may be from a contest a few years ago. You can find them 
on the ViewTop under REBOL.com/Demos/
RZoom is also nice (by Henrik).
kib2
16-Feb-2009
[2240]
I'm amazed by cyphre source file : just a few lines.
Anton
17-Feb-2009
[2241x2]
I've made a C DLL on linux which has the rudiments of an image processing 
function. At the moment it just sets one pixel.
I've made C DLL on windows previously, so I will try to make it cross-platform.
kib2
17-Feb-2009
[2243]
Anton: interesting...do you have any screenshot ?
Anton
17-Feb-2009
[2244]
Boring... my test image is 2x2.
kib2
17-Feb-2009
[2245]
:)
Anton
17-Feb-2009
[2246]
What platform are you on ?
kib2
17-Feb-2009
[2247]
Windows (Seven)
Anton
17-Feb-2009
[2248]
Ugh...
kib2
17-Feb-2009
[2249]
I never had a problem with it since a month. It's really stable.
Anton
17-Feb-2009
[2250x2]
Ok, whatever. :-P
(-; I don't mean to be rude by that..)
kib2
17-Feb-2009
[2252]
No problem
Vladimir
17-Feb-2009
[2253]
Anton, have you seen new speedy version of my tunnel script ? :)

Lookup table for pixels position and tunnel coordinates helped a 
lot...

I guess your dll would help. Would you keep acceleration only for 
pixel drawing? or maybe some higher functions?
Anton
17-Feb-2009
[2254x3]
Oh no! Calling a DLL function just to draw one pixel would be so 
slow! I will of course make it process a whole frame at a time. So 
basically, I think the tunnel drawing function will move into C.
Just tried latest version - framerate at least double.
Ok, so you've pre-calculated the pixel mapping, avoiding the square-root 
and arc-tangent etc. in the main loop.