On 8/1/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > Hi Holger, > > [email protected] <svg-developers%40yahoogroups.com> wrote on > 08/01/2006 11:07:03 AM: > > > >> I would like to get an element from a x,y point > >> (like in HTML)[..] Does anyone know such a function ? > > > > there are four methods of the SVGSVGElement ( > > http://www.w3.org/TR/SVG11/struct.html#InterfaceSVGSVGElement ) which > > you could use: > > > > NodeList getIntersectionList ( in SVGRect rect, in SVGElement > referenceElement ); > > NodeList getEnclosureList ( in SVGRect rect, in SVGElement > referenceElement ); > > boolean checkIntersection ( in SVGElement element, in SVGRect > rect ); > > boolean checkEnclosure ( in SVGElement element, in SVGRect rect > ); > > > > but unfortunatly they are not implemented anywhere. > > Actually they are all implemented in the SVN version of Batik. ;) > > > > I doubt that you will be able to write a function to get a points color > > either, as there are no pixels in SVG, and therefor you dont have access > > > > to pixel values. > > Quite correct. The WG will likely specify something along these > lines but to be honest I think it will be problematic (too many cases > where it won't give/do what people want or else be nigh impossible to > implement, I think). > > > I like to share with you on my point of view (as an SVG render developer). The Scenario is this: You have SVG draw you a Black line with 0.5 opacity (stroke-opacity="0.5"). As in ZipProtocol I can give you the color that SVG generate which is 0x80000000. where the 80 stand for 50% opacity and the rest 000000 is black color. Now we go to SVG developer point of view.
- If that line is on the RED background the actual color is Dark RED.(RGB=0x800000) or - If the Background is WHITE then the actual color is GRAY (RGB=0x808080). Using this scheme I can have that black line in any color I want with RED range form 0x80 ->0, GREEN from 0x80->0 and BLUE from 0x80->0. Remember that the background can be anything even outside of the browser control such as :system background color, button color or even an image, flash image etc They are not under the control of the SVG render. In my case; I can only give developer the the Color and the opacity of what the SVG render generates But the true color can be where on the spectrum I describe above (Depend on the background.) At this time it is impossible for the developer to know what pixel color at a given point. Hoppefully in the future. If that capacity is there then it is the work of the browsers however I don't know how they can do it in the situation that the image that plug-in produced such as flash?. Hope this help. -- Phi - Tran Hugely increase your speed, saving your band-width with ZipProtocol plus crystal clear SVG Rendering image at HTTP://oneplusplus.com [Non-text portions of this message have been removed] ----- To unsubscribe send a message to: [EMAIL PROTECTED] -or- visit http://groups.yahoo.com/group/svg-developers and click "edit my membership" ---- Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/svg-developers/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/

