|
From: Bruce S. <Bru...@nc...> - 2008-12-09 17:00:17
|
I wasn't even aware of there being routines in Visual 3 called
scene.show() and scene.hide(). I can't find them mentioned in the Visual
3 documentation. Where are they discussed?
The documented way to hide and show a window is by setting scene.visible.
I can't reproduce any errors with picking an object. The following
routine correctly picks the appropriate object, no matter how I rotate
the scene:
b = box(pos=(-1,0,0))
c = cylinder(pos=(1,0,0), axis=(0,1,0))
d = pyramid()
while 1:
if scene.mouse.clicked:
click = scene.mouse.getclick()
print click.pick
Please post a complete routine that fails, since I can't see any failure.
One way to keep both Visual 3 and Visual 5 around on Windows is to
install Python 2.4 and Visual 3 for it, in parallel to Python 2.5 with
Visual 5. There aren't sizable differences between Visual 3 for Python
2.4 and Python 2.5.
Alternatively, save the relevant contents of
c:\Python25\Lib\site-packages (for Visual 3, numeric and numarray and
Numeric.pth and visual; for Visual 5, numpy and
numpy-1.2.1-py2.5.egg-info and visual). Then just swap them in or out.
Bruce Sherwood
Stef Mientki wrote:
> thanks for the great job Bruce.
>
> A few problems:
> - left-mouse click only seems to work on a box. When you click on
> "nothing" it returns None. When you click on something like a cylinder,
> you get a box returned, probably the box under the cyclinder, tested with
> if scene.mouse.clicked :
> click = scene.mouse.getclick ()
> print 'click',click.pick
> - scene.show is not available (I only read that scene.cursor.visible was
> not available) and
> because I embed VPython, I also can't close my program, because
> scene.hide doesn't work.
>
> btw,
> when you want / need to go back from VPython 5 to VPython 3,
> what's the best way to achieve that ?
> Or is it even better to make a copy of Python, before installing VPython 5 ?
>
> cheers,
> Stef
>
> Bruce Sherwood wrote:
>> At vpython.org there is now available the Visual 5.0 release candidate
>> for Windows, Intel Mac 10.5, and Linux. A version for PowerPC Mac is
>> forthcoming. The Mac version does not use X11 nor depend on Fink.
>>
>> This new version has been tested against a sizable suite of existing
>> programs, but it is likely that wider use will identify bugs to be
>> fixed, so please report problems you may encounter.
>>
>> There remains a major component to be completed, which David Scherer is
>> working on. There are various significant problems with IDLE, with
>> particularly serious issues on the Mac (in fact, the MacPython IDLE has
>> major mouse handling problems, which you can sometimes overcome by
>> clicking in the title bar, and it doesn't even offer a configuration
>> menu option for IDLE). If you find problems with IDLE, as you will at
>> the very least on the Mac, you need not report them, as this is being
>> worked on.
>>
>> Visual 5.0 was created by David Scherer and Bruce Sherwood. Jonathan
>> Brandmeyer provided support in Visual 4beta for opacity, local lighting,
>> and textures, and made some important architectural changes, but had to
>> stop work on the project before it was completed. Further development
>> has led to API changes which are incompatible with the Visual 4beta
>> release, so this release is called version 5 instead of 4.
>>
>> The late Arthur Siegel implemented dependence on the currently supported
>> numpy library in place of Numeric, which is no longer supported. Hugh
>> Fisher provided a big start on the native-mode Mac version. Michael
>> Temkine fixed some bugs and implemented keyboard handling for Windows.
>>
>> Previous to Visual 4beta, Jonathan Brandmeyer made several major
>> contributions to Visual 3, including changing the connection between
>> Python and C++ from CXX, which was no longer supported, to the Boost C++
>> libraries, and implementing auto-configurable installations for Linux.
>>
>> ------------------------------------------------------------------------------
>> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
>> The future of the web can't happen without you. Join us at MIX09 to help
>> pave the way to the Next Web now. Learn more and register at
>> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
>> _______________________________________________
>> Visualpython-users mailing list
>> Vis...@li...
>> https://lists.sourceforge.net/lists/listinfo/visualpython-users
>>
>>
>>
>
>
> Het UMC St Radboud staat geregistreerd bij de Kamer van Koophandel in het handelsregister onder nummer 41055629.
> The Radboud University Nijmegen Medical Centre is listed in the Commercial Register of the Chamber of Commerce under file number 41055629.
>
>
>
> ------------------------------------------------------------------------------
> SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
> The future of the web can't happen without you. Join us at MIX09 to help
> pave the way to the Next Web now. Learn more and register at
> http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
> _______________________________________________
> Visualpython-users mailing list
> Vis...@li...
> https://lists.sourceforge.net/lists/listinfo/visualpython-users
|