Heh, I wish I could say I had implemented elaborate code that could tell
whether the mouse was on a Segment or not, but I haven't.

You can see the behavior yourself in my program called G-Wizard.  Give it
your name and email to download:

http://www.cnccookbook.com/CCGWizardEBeta.html

You will see the grid created by Away3D off on the right.  Start spinning
the mouse wheel to zoom.  You will get zoomed in close enough to be able to
put the pointer right on a line pretty soon.  At that point you will see if
you are on a line, all mouse wheel events are ignored, but off the line they
work fine.

BTW, hold down right mouse and drag to rotate the perspective.  That too
fails if your mouse pointer sits on a line.

Odd, no?  But something with the intelligence to know I am on that line has
to be eating those events.  FWIW, the Flex object containing all this is
a Canvas.

Cheers,

BW

On Mon, Feb 28, 2011 at 1:38 PM, Fabrice3D <[email protected]> wrote:

> mouse wheel just need a stage. So I do not see 1, 2, 3 why it doesn't work
> for you.
>
> Just looked at Prefab code again: I make a sprite class, that holds the
> view. and simply
> addEventListener(MouseEvent.MOUSE_WHEEL, onWheel); to this class.
> I have no conflict at all with other mouseEvents & mouse3DEvents.
>
> Fabrice
>
>
>  On Feb 28, 2011, at 7:53 PM, Bob Warfield wrote:
>
>  Fabrice:
>
> I tried adding mouse wheel event listeners to both the Mesh and Segment
> objects:
>
>            mesh.addEventListener(MouseEvent.MOUSE_WHEEL, onMouseWheel);
>
> It didn't help.  As mentioned, I already had handlers on the stage, View,
> and Scene.
>
> I don't use any sprites, however the Mesh objects are set to "ownCanvas =
> true".  Does that jog loose an idea of what I can change?  FWIW, setting it
> to "false" doesn't help at all.
>
> I have set mouseEnabled = false for the Mesh objects, the View and the
> Scene.  It isn't available on the Segments.  Didn't seem to matter though.
>
> I've certainly seen demos where mouse wheel zooming works just fine with
> the cursor hot spot on a line, so not sure what could be going wrong.  I
> could certainly add a transparent layer to catch the event, but I really
> prefer not to as eventually I want to be able to handle mouse events down on
> these objects.
>
> Any other thoughts would be much appreciated.
>
> Best,
>
> BW
>
>
>
>
> On Sun, Feb 27, 2011 at 2:34 PM, Fabrice3D <[email protected]> wrote:
>
>> add a layer above for wheel?
>> tho I have mouse wheel in Prefab, and no issues while on segments.
>> do you use sprites, or own canvas? mouse.enable them false?
>>
>> Fabrice
>>
>> On Feb 27, 2011, at 11:17 PM, BobWarfield wrote:
>>
>> > Seeing some odd behavior.  I have a CAD/CAM application using G-
>> > Wizard.  Drawings have a background grid for reference.  At this
>> > point, the only Away3D objects I am creating are wireframes.  They're
>> > Segments added to Meshes.
>> >
>> > I have added event listeners to the stage, View, and Scene (the latter
>> > two out of desperation, didn't notice a change) for the
>> > MouseEvent.MOUSE_WHEEL.
>> >
>> > It works great if the mouse pointer is not on any of the Segments, but
>> > if the hot spot is on a Segment, the event listener never hears that
>> > MOUSE_WHEEL.
>> >
>> > How do I get around this?
>> >
>> > Cheers,
>> >
>> > BW
>>
>>
>
>

Reply via email to