You are viewing a plain text version of this content. The canonical link for it is here.
Posted to batik-users@xmlgraphics.apache.org by ma zhenduo <ma...@yahoo.com> on 2002/03/16 02:18:46 UTC

problem about "nodeHitAt"

There are some problem about "nodeHitAt".
 When the filter ( <filter id="f1"><feOffset dx="50" dy="50" /></filter>) is
appled on the shape
    ( <circle cx="85"  cy="135" r="50" filter="url(#f1)" />),
    I can't find it by calling "nodeHitAt(rootGraphicsNode)".
    But another filter
        ( <filter id="f1"><feSpecularLighting in="FillPaint"
in2="SourceAlpha" lighting-color="blue" result="specOut">
                <fePointLight/>
          </feSpecularLighting>
          <feComposite in="specOut" in2="SourceAlpha" operator="in"
result="specOut"/>filter>
        ) is no problem.

thanks in advance.

RE: problem about "nodeHitAt"

Posted by Thierry Kormann <tk...@ilog.fr>.
No idea. I can make a try when I am back from the next SVG face2face meeting
(after april 7th).

  Help me, tell me if the lower problem will be solve? When it will be
solve?
  My boss want to know.
  I don't think I can solve it.
  It is a complicated problem and Adobe's browser can't solve it too.

Re: problem about "nodeHitAt"

Posted by ma zhenduo <ma...@yahoo.com>.
Help me, tell me if the lower problem will be solve? When it will be solve?
My boss want to know.
I don't think I can solve it.
It is a complicated problem and Adobe's browser can't solve it too.
  ----- Original Message -----


  There are some problem about "nodeHitAt".
       When the filter ( <filter id="f1"><feOffset dx="50" dy="50"
/></filter>) is appled on the shape
          ( <circle cx="85"  cy="135" r="50" filter="url(#f1)" />),
          I can't find it by calling "nodeHitAt(rootGraphicsNode)".
          But another filter
              ( <filter id="f1"><feSpecularLighting in="FillPaint"
in2="SourceAlpha" lighting-color="blue" result="specOut">
                      <fePointLight/>
                </feSpecularLighting>
                <feComposite in="specOut" in2="SourceAlpha" operator="in"
result="specOut"/>filter>
              ) is no problem.

      thanks in advance

      The nodeHitAt method is using the GraphicsNode's raw geometry to
determine whether or not it contains the (x, y) coordinate .  That means
that any filter, mask or clip is taken into account (similar to
getPrimitiveBounds).

      The first filter you are using just translates the graphic so the
sensitive region of the circle is not really what's displayed on the screen.

      Now, being awared of how nodeHitAt is working right now, if this is
really an issue for you, I would suggest to submit us a patch that provides
a new method such as nodeHitAt that takes filter, clip, mask... into account
(basically, using the same idea than getPrimitiveBounds compared to
getBounds).

      Then I am willing to rename the current nodeHitAt to
primitiveNodeHitAt (or equivalent) and add your new method as nodeHitAt).

      Thierry.

      Thank you at first, you let me see how nodeHitAt is working.
      I am not master at batik, I think, I don't have a clue to make
"nodeHitAt" take those into account..
      However, To feOffset only, If we regist the invAffine of
AffineRable8Bit as a new member of ShapeNode when SvgFeOffsetBridge is
working, We can transform the input point by invAffine in "nodeHitAt". How
do you think about?

      Now, The batik browser can't deal with the mouse event,
      I expect some master can make "nodeHitAt" take all of those into
account.

      Ma zhenduo

Re: problem about "nodeHitAt"

Posted by ma zhenduo <ma...@yahoo.com>.
There are some problem about "nodeHitAt".
     When the filter ( <filter id="f1"><feOffset dx="50" dy="50"
/></filter>) is appled on the shape
        ( <circle cx="85"  cy="135" r="50" filter="url(#f1)" />),
        I can't find it by calling "nodeHitAt(rootGraphicsNode)".
        But another filter
            ( <filter id="f1"><feSpecularLighting in="FillPaint"
in2="SourceAlpha" lighting-color="blue" result="specOut">
                    <fePointLight/>
              </feSpecularLighting>
              <feComposite in="specOut" in2="SourceAlpha" operator="in"
result="specOut"/>filter>
            ) is no problem.

    thanks in advance

    The nodeHitAt method is using the GraphicsNode's raw geometry to
determine whether or not it contains the (x, y) coordinate .  That means
that any filter, mask or clip is taken into account (similar to
getPrimitiveBounds).

    The first filter you are using just translates the graphic so the
sensitive region of the circle is not really what's displayed on the screen.

    Now, being awared of how nodeHitAt is working right now, if this is
really an issue for you, I would suggest to submit us a patch that provides
a new method such as nodeHitAt that takes filter, clip, mask... into account
(basically, using the same idea than getPrimitiveBounds compared to
getBounds).

    Then I am willing to rename the current nodeHitAt to primitiveNodeHitAt
(or equivalent) and add your new method as nodeHitAt).

    Thierry.

    Thank you at first, you let me see how nodeHitAt is working.
    I am not master at batik, I think, I don't have a clue to make
"nodeHitAt" take those into account..
    However, To feOffset only, If we regist the invAffine of AffineRable8Bit
as a new member of ShapeNode when SvgFeOffsetBridge is working, We can
transform the input point by invAffine in "nodeHitAt". How do you think
about?

    Now, The batik browser can't deal with the mouse event,
    I expect some master can make "nodeHitAt" take all of those into
account.

    Ma zhenduo

RE: problem about "nodeHitAt"

Posted by Thierry Kormann <tk...@ilog.fr>.
  -----Original Message-----
  From: ma zhenduo [mailto:mazd_work@yahoo.com]
  Sent: Saturday, March 16, 2002 2:19 AM
  To: Batik Users
  Subject: problem about "nodeHitAt"


  There are some problem about "nodeHitAt".
   When the filter ( <filter id="f1"><feOffset dx="50" dy="50" /></filter>)
is appled on the shape
      ( <circle cx="85"  cy="135" r="50" filter="url(#f1)" />),
      I can't find it by calling "nodeHitAt(rootGraphicsNode)".
      But another filter
          ( <filter id="f1"><feSpecularLighting in="FillPaint"
in2="SourceAlpha" lighting-color="blue" result="specOut">
                  <fePointLight/>
            </feSpecularLighting>
            <feComposite in="specOut" in2="SourceAlpha" operator="in"
result="specOut"/>filter>
          ) is no problem.

  thanks in advance

  The nodeHitAt method is using the GraphicsNode's raw geometry to determine
whether or not it contains the (x, y) coordinate .  That means that any
filter, mask or clip is taken into account (similar to getPrimitiveBounds).

  The first filter you are using just translates the graphic so the
sensitive region of the circle is not really what's displayed on the screen.

  Now, being awared of how nodeHitAt is working right now, if this is really
an issue for you, I would suggest to submit us a patch that provides a new
method such as nodeHitAt that takes filter, clip, mask... into account
(basically, using the same idea than getPrimitiveBounds compared to
getBounds).

  Then I am willing to rename the current nodeHitAt to primitiveNodeHitAt
(or equivalent) and add your new method as nodeHitAt).

  Thierry.