World: r3wp
[AGG] to discus new Rebol/View with AGG
older newer | first last |
DideC 21-Jul-2005 [421] | So there is no more POP command ? |
shadwolf 22-Jul-2005 [422x4] | I thought matrix was only a way to merge scale rotate and translate values... |
Cyphre have you an idea when the bug with matrix will be solved ? | |
same 4 gradients :) ? | |
Didec work like a layer difinition and manager Using push the matrix or other trnasformation information are apply only on the push block content. outside the push block the matrix informations are not affected | |
Robert 22-Jul-2005 [426] | If I use TEXT I can specify the offset. Is there a way to specify the size as well and that the rest is clipped? |
Gabriele 22-Jul-2005 [427] | not afaik, but i think you could use the clip command. |
Robert 22-Jul-2005 [428] | Hm... but I don't know how big a text will render. And I can't referr to the text to clip it. |
Anton 22-Jul-2005 [429x10] | I have a feeling that draw TEXT is still using old draw code, and not merged so well with AGG yet. I noticed that draw text offset doesn't scale: |
view layout [box navy effect [draw [scale 0.1 0.1 text "hello" 40x40]]] | |
I also noticed line-width doesn't scale: | |
view layout [b: box 200x200 effect [draw [scale 1 1 pen 192.0.0 line-width 32 line 10x10 190x190]] scroller 200x20 [b/effect/draw/scale: b/effect/draw/3: face/data show b]] | |
No luck using TRANSFORM instead of SCALE either: | |
view layout [b: box 200x200 effect [draw [transform 0 0x0 1 1 0x0 pen 192.0.0 line-width 32 line 10x10 190x190]] scroller 200x20 [change/dup at b/effect/draw 4 face/data 2 show b]] | |
More weirdness with scale, line-width and arc: - a 360 degree arc doesn't quite make it all the way around (small section missing at the join) - arc loses its resolution (arc becomes an obvious polygon approximation to an arc) | |
view lay: layout [ size 500x500 backeffect [draw [translate 250x250 scale 0.2 0.2 line-width 1 circle 0x0 300]] scroller [change/dup at lay/effect/draw 4 face/data 2 show lay] scroller [lay/effect/draw/line-width: face/data * 100 show lay] ] | |
(I showed circle, but 360 degree arc looks the same) | |
arc 0x0 200x200 0 360 | |
Volker 22-Jul-2005 [439] | text-size: you can use size-text. setup a face with /text, font and nothing else, get the size, use same text in draw. |
Gabriele 22-Jul-2005 [440x2] | anton: you need to use text vectorial if you want to apply transforms |
robert: then you can't use draw. | |
Anton 22-Jul-2005 [442] | Gabriele: great! Thankyou. :) |
Anton 24-Jul-2005 [443] | rebol [ date: 24-Jul-2005 author: "Anton Rolls" comment: { Investigating why adding/removing 'merge from effect block seems to change line-width on arc, circle etc.: ToDo: - try to - It looks like the AGG anti-aliasing is with the default window background color ? When MERGE is added, then it's with the actual color that is merged (seems ok and good to me). - so try to set b1/color so it's the same as the color anti-aliased against in the merged version Perhaps default window background color (200.200.200) is close to the default agg anti-aliasing color ? (do not use custom window color) - try a simple LINE - report to RAMBO or AGG group - submit to RAMBO This shows that the addition of 'merge seems to add 0.5... (?) or some scaled factor to the line-width: } ] effect-blk: [ draw [ pen black line-width 0 translate 25x25 scale 1 1 circle 0x0 24 ;arc 0x0 24x24 0 270 ] ] make-2nd-effect: func [/local result][ result: copy/deep effect-blk insert result 'merge ;result/draw/line-width: result/draw/line-width - 0.5 ; <- even with this they don't look quite the same result/draw/line-width: result/draw/line-width - any [attempt [correction-scr/data * 0.1 + 0.5] 0] result ] refresh: does [ b2/effect: make-2nd-effect show [b1 b2] big1/image: to-image b1 big2/image: to-image b2 diff/image: xor big1/image big2/image same-txt/text: join "same? " big1/image = big2/image show [big1 big2 diff same-txt] ] view/new window: center-face layout compose/only [ across label 80 "scale" scroller 200x20 with [data: 1][ change/dup next find b1/effect/draw 'scale face/data 2 refresh ] return label 80 "line-width" scroller 200x20 [ b1/effect/draw/line-width: face/data * 4 refresh ] return label "line-width correction" correction-scr: scroller 200x20 [ refresh ] return b1: box 50x50 [refresh] effect (effect-blk) b2: box 50x50 [refresh] effect (make-2nd-effect) same-txt: text 200 return big1: image 200x200 big2: image 200x200 return diff: image 200x200 ] refresh do-events |
Robert 6-Aug-2005 [444] | I just took a look at Zeta (the BeOS clone) and saw that they use AGG for the rendering system. Nice. |
Kaj 6-Aug-2005 [445] | Yes, I have proposed it for Syllable, as well |
Graham 27-Aug-2005 [446] | What's the likelyhood, or possibility of a PDF renderer now for View/Agg ? |
Chris 27-Aug-2005 [447] | I'm sure fonts would be the major obstacle, as it would be for SWF viewing? |
Kaj 27-Aug-2005 [448x4] | It seems Carl wants to integrate FreeType, so that would remove the fonts obstacle |
By the way, our video expert evaluated several drawing libraries, among which AGG and Cairo, and deemed them unsuitable for the Syllable graphics system | |
I don't know his reasons in detail, but he's working on adding window backbuffering to the video driver framework. The few higher-level drawing functions that we have now, like drawing lines, are going to be tightly integrated into that | |
AGG could still be ported to Syllable, but I guess, being a crossplatform library, it would have lower performance | |
Chris 28-Aug-2005 [452] | Kaj, I was thinking more embedded fonts -- would the author of a viewer need to parse the embedded font data before passing them to FreeType? |
Graham 28-Aug-2005 [453] | What about pdfs that are the output of scanners and pdf printer drivers? Presumably these are just images wrapped inside a pdf ? |
Kaj 28-Aug-2005 [454] | Yes, I think you have to extract font data to pass it to FreeType. But FreeType interprets the font data itself, so how hard could extracting it be? |
shadwolf 31-Aug-2005 [455] | I would like to know when the problem with Agg Matrix will be solved and when Carl plans to integrate in REBOL/AGG a radiant function that can better feet with SVG datas ? I started 3 month ago an SVG engine and since then I'm stuck because of those 2 problems... SVG without transformation matrix and without gradients it's like nothing .... ( see greoup SVG renderer for more informations and test code) |
Cyphre 31-Aug-2005 [456] | shadwolf: please see my reply in 'Carl Only' group. |
Rebolek 1-Sep-2005 [457x2] | It's 1:04AM here, not a time for serious work, so I'm fiddling little bit with some eye-candies in new DRAW and I must say it's SO powerful. I'm just starting to see the potential...whooo! Thanks |
ft: make face/font [size: 60] view center-face layout [ origin 0 box 400x80 white effect [ draw [ fill-pen linear 0x0 0 100 30 1 1 black white black white black white font ft text 0x0 "Wavin' REBOL" vectorial ] emboss ] with [ rate: 0 n: 0 feel: make feel [ engage: func [f a e][ f/effect/draw/3/x: n: n + 2 show f ] ] ] ] | |
james_nak 1-Sep-2005 [459] | That's very cool. |
Volker 1-Sep-2005 [460] | Wow. Can you made an animated gif from that? :) |
Izkata 1-Sep-2005 [461] | 'save doesn't support GIF, so I doubt it... Unless, of course, someone who understands GIF files hacks something together >.< |
Volker 1-Sep-2005 [462] | I guess Kru can save multiple images and use some external converter? :) |
Izkata 1-Sep-2005 [463] | Or that. |
Geomol 2-Sep-2005 [464] | Cool Kru! :-) |
Rebolek 2-Sep-2005 [465] | thanks :) |
Geomol 5-Sep-2005 [466] | In the new DRAW dialect, should SCALE have influence on LINE-WIDTH? |
Gabriele 5-Sep-2005 [467x2] | that is a very hard question, because in most vector drawing apps it doesn't, while it is also arguable that it should. |
also, i don't know if AGG is able to scale a line width if the scale is not the same for x and y. | |
Anton 6-Sep-2005 [469] | That seems like a frustrating issue. |
shadwolf 6-Sep-2005 [470] | Cyphre thank you for your answer You need more infos on Gradient here is the official webpage on the topic hopes it could help you to make a svg gradient complying fonction in draw ...:) |
older newer | first last |