You can subscribe to this list here.
2000 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(4) |
Jul
(1) |
Aug
|
Sep
(15) |
Oct
(32) |
Nov
(35) |
Dec
(48) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2001 |
Jan
(46) |
Feb
(22) |
Mar
(65) |
Apr
(49) |
May
(22) |
Jun
(29) |
Jul
(51) |
Aug
(34) |
Sep
(32) |
Oct
(46) |
Nov
(30) |
Dec
(32) |
2002 |
Jan
(48) |
Feb
(4) |
Mar
(20) |
Apr
(28) |
May
(13) |
Jun
(34) |
Jul
(51) |
Aug
(15) |
Sep
(15) |
Oct
(35) |
Nov
(15) |
Dec
(20) |
2003 |
Jan
(31) |
Feb
(111) |
Mar
(41) |
Apr
(28) |
May
(36) |
Jun
(29) |
Jul
(27) |
Aug
(29) |
Sep
(47) |
Oct
(28) |
Nov
(7) |
Dec
(26) |
2004 |
Jan
(44) |
Feb
(9) |
Mar
(17) |
Apr
(26) |
May
(58) |
Jun
(13) |
Jul
(44) |
Aug
(64) |
Sep
(30) |
Oct
(11) |
Nov
(21) |
Dec
(28) |
2005 |
Jan
(29) |
Feb
(11) |
Mar
(11) |
Apr
(22) |
May
(85) |
Jun
(46) |
Jul
(17) |
Aug
(18) |
Sep
(14) |
Oct
(22) |
Nov
(1) |
Dec
(45) |
2006 |
Jan
(20) |
Feb
(36) |
Mar
(18) |
Apr
(24) |
May
(21) |
Jun
(48) |
Jul
(23) |
Aug
(20) |
Sep
(10) |
Oct
(41) |
Nov
(46) |
Dec
(40) |
2007 |
Jan
(40) |
Feb
(20) |
Mar
(13) |
Apr
(6) |
May
(24) |
Jun
(31) |
Jul
(30) |
Aug
(11) |
Sep
(11) |
Oct
(10) |
Nov
(56) |
Dec
(64) |
2008 |
Jan
(64) |
Feb
(22) |
Mar
(63) |
Apr
(28) |
May
(25) |
Jun
(36) |
Jul
(11) |
Aug
(9) |
Sep
(14) |
Oct
(41) |
Nov
(46) |
Dec
(130) |
2009 |
Jan
(95) |
Feb
(41) |
Mar
(24) |
Apr
(35) |
May
(53) |
Jun
(67) |
Jul
(48) |
Aug
(48) |
Sep
(86) |
Oct
(75) |
Nov
(64) |
Dec
(52) |
2010 |
Jan
(57) |
Feb
(31) |
Mar
(28) |
Apr
(40) |
May
(25) |
Jun
(42) |
Jul
(79) |
Aug
(31) |
Sep
(49) |
Oct
(66) |
Nov
(38) |
Dec
(25) |
2011 |
Jan
(29) |
Feb
(18) |
Mar
(44) |
Apr
(6) |
May
(28) |
Jun
(31) |
Jul
(36) |
Aug
(24) |
Sep
(30) |
Oct
(23) |
Nov
(21) |
Dec
(27) |
2012 |
Jan
(14) |
Feb
(11) |
Mar
(2) |
Apr
(48) |
May
(7) |
Jun
(32) |
Jul
(22) |
Aug
(25) |
Sep
(31) |
Oct
(32) |
Nov
(21) |
Dec
(17) |
2013 |
Jan
(44) |
Feb
(27) |
Mar
(3) |
Apr
(1) |
May
|
Jun
|
Jul
(3) |
Aug
(4) |
Sep
(1) |
Oct
(7) |
Nov
(5) |
Dec
(5) |
2014 |
Jan
|
Feb
|
Mar
|
Apr
(3) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(3) |
Dec
(2) |
2015 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2017 |
Jan
(7) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2019 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Bruce S. <Bru...@nc...> - 2008-09-24 15:34:05
|
Here's the crucial statement from the Visual help description of the faces object (choose "Visual" on the Help menu in IDLE): If you don't specify normals at the vertices, the face is illuminated only by "ambient" light. Because you had set the background color to white, the parallelogram looked completely black but was actually colored, but only dimly, due solely to ambient light. Here is a version of your parallelogram routine which constructs the necessary normals: def parallelogram(v1,v2,v3,trianglecolor): c = color.hsv_to_rgb(trianglecolor) n = norm(cross(v2-v1,v3-v1)) triangle1=faces(pos=[v1,v2,v3],normal=n,color=c) triangle2=faces(pos=[v2,v2+v3-v1,v3],normal=n,color=c) triangle3=faces(pos=[v2,v1,v3],normal=-n,color=c) triangle4=faces(pos=[v2+v3-v1,v2,v3],normal=-n,color=c) The information about built-in colors is in the Help; see "Specifying Colors". The module itself has the file name "crayola" but one actually says "color.orange", not "crayola.orange". Bruce Sherwood Poul Riis wrote: > I can't extract from the manual how to control the color of the faces > object. The attached example works, but the rectangle always has the same > color, no matter the trianglecolor parameter. In fact, I would like to > make the back side of the rectangle somewhat darker than the front side - > automatically. > > Btw - where can I find information about crayola colors? > > Yours, > Poul Riis |
From: Poul R. <Pou...@sk...> - 2008-09-24 11:25:47
|
I can't extract from the manual how to control the color of the faces object. The attached example works, but the rectangle always has the same color, no matter the trianglecolor parameter. In fact, I would like to make the back side of the rectangle somewhat darker than the front side - automatically. Btw - where can I find information about crayola colors? Yours, Poul Riis |
From: P. G. C. <ozr...@gm...> - 2008-09-14 16:46:15
|
Hi all. I'm trying to make an vpython scene work as an xscreensaver hack. Everything seemed to be easy, just had to add a line in .xscreensaver like: - "My hack" python /opt/ozp/xss.py & \n\ and use scene.fullscreen=1 in my script. The new hack appears in the list and I can choose it. It is launched after inactivity and my scene looks quite well, but after ~30s it just dissappears. I've read a lot and think the problem can be that the scene should be shown in the root window and not just in a fullscreen window. Now I don't know how to attack the problem. I need help. Any idea? Thank you very much. If someone's interested, here's the script wich I wanted to be a screensaver (it's quite simple but funny): #!/usr/bin/python # -*- coding: utf-8 -*- from visual import * from random import * # Número total de partículas parts=200 # Esta variable nos mostrará una visión objetiva (-1) o subjetiva (1) de la escena visual=1 scene=display() scene.title='Chaothic Knot Conga' scene.autoscale=0 scene.userzoom=0 scene.userspin=0 scene.fullscreen=1 # Paisaje suelo=box(pos=(0,-10,0),color=color.blue,size=(30,0.01,30)) curve(color=color.blue,pos=[(15,10,15),(-15,10,15),(-15,10,-15),(15,10,-15),(15,10,15)]) curve(color=color.blue,pos=[(15,10,15),(15,-10,15)]) curve(color=color.blue,pos=[(-15,10,15),(-15,-10,15)]) curve(color=color.blue,pos=[(-15,10,-15),(-15,-10,-15)]) curve(color=color.blue,pos=[(15,10,-15),(15,-10,-15)]) print windowname # Sólo genera un vector aleatorio def seguidor(): "Genera posiciones aleatoriamente en un cubo de lado 20" return(randint(-10,10),randint(-10,10),randint(-10,10)) seguidores=[] segsvel=[] i=0. while i < parts: "Genera partículas con un gradiente de color" seg=sphere(pos=seguidor(),radius=0.1,color=((parts-i)/parts,1-(parts-i)/parts,0.0)) seguidores.append(seg) vel=vector(seguidor()) segsvel.append(vel) i+=1 dt=1./25. while 1: while mag2(segsvel[parts-1]) > 0.0001: "Mientras no se pare (o casi) la última" rate(25) i=1 while i < parts: "Cada partícula persigue a su predecesora" seguidores[i].pos+=(segsvel[i])*dt segsvel[i]=(seguidores[i-1].pos-seguidores[i].pos)*2 i+=1 if visual == 1: "Perspectiva subjetiva" scene.center=seguidores[parts-1].pos scene.forward=segsvel[parts-1] scene.range=(.5,.5,.5) else: "Perspectiva objetiva" scene.center=(0,0,0) scene.forward=(0,0,-1) scene.range=(10,10,10) if scene.kb.keys: "Cambio de perspectiva" key=scene.kb.getkey() if key=='v': visual=visual*(-1) for i in seguidores: "Recolocación aleatoria de las partículas" i.pos=seguidor() segsvel[parts-1]=vector(1,1,1) -- (^< -- Saludos, nerdigo //'\ V_/_ |
From: Bruce S. <Bru...@nc...> - 2008-09-12 16:32:44
|
I'm assuming that what concerns you is that you don't want the x axis labeled 0, 2, 4 but rather 1, 100, 1e4. visual.graph doesn't provide this capability. Your solution, to use and label the x axis in terms of the log10 of the quantity of interest, is the best you can do, and is indeed a semilog plot of the data. However, notice that visual.graph is simply a Python program, so you could make a copy of it, modify it, and import it instead of visual.graph. The revised version might be of general interest. Bruce Sherwood Gabor Kalman wrote: > In my earlier (9/11/08) "submit" I asked: > "How can one "fool" Vpython to display y=f(log10(x)) as a semi-log > plot?" > > To clarify: > How can I change the "tick-marks" to a log scale? > > see sample program below: > > ************************ > > from visual import * > from visual.graph import * > > > graph1=gdisplay(x=0,y=0, > width=400,height=300,title="semilog",xtitle="f=10^x", > ytitle="y",xmax=4,xmin=1,ymax=500,ymin=0, > foreground=color.black,background=color.white) > plot1 = gvbars(delta=0.5, color=color.green) > > x=[10,100,1000] > y=[400,200,100] > > for i in range(0,3): > plot1.plot(pos=(log10(x[i]),y[i])) |
From: Jose A. M. H <jam...@fd...> - 2008-09-12 15:24:19
|
Is your name really Gabor Kalman ???? What a very filtered name !!!. :-O ----- Original Message ----- From: Gabor Kalman To: Vis...@li... Cc: Bru...@nc... Sent: Friday, September 12, 2008 5:11 PM Subject: [Visualpython-users] Clarifying question regarding semi-log plots In my earlier (9/11/08) "submit" I asked: "How can one "fool" Vpython to display y=f(log10(x)) as a semi-log plot?" To clarify: How can I change the "tick-marks" to a log scale? see sample program below: ************************ from visual import * from visual.graph import * graph1=gdisplay(x=0,y=0, width=400,height=300,title="semilog",xtitle="f=10^x", ytitle="y",xmax=4,xmin=1,ymax=500,ymin=0, foreground=color.black,background=color.white) plot1 = gvbars(delta=0.5, color=color.green) x=[10,100,1000] y=[400,200,100] for i in range(0,3): plot1.plot(pos=(log10(x[i]),y[i])) ------------------------------------------------------------------------------ ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ ------------------------------------------------------------------------------ _______________________________________________ Visualpython-users mailing list Vis...@li... https://lists.sourceforge.net/lists/listinfo/visualpython-users |
From: Gabor K. <Kal...@ms...> - 2008-09-12 15:11:19
|
In my earlier (9/11/08) "submit" I asked: "How can one "fool" Vpython to display y=f(log10(x)) as a semi-log plot?" To clarify: How can I change the "tick-marks" to a log scale? see sample program below: ************************ from visual import * from visual.graph import * graph1=gdisplay(x=0,y=0, width=400,height=300,title="semilog",xtitle="f=10^x", ytitle="y",xmax=4,xmin=1,ymax=500,ymin=0, foreground=color.black,background=color.white) plot1 = gvbars(delta=0.5, color=color.green) x=[10,100,1000] y=[400,200,100] for i in range(0,3): plot1.plot(pos=(log10(x[i]),y[i])) |
From: Gabor K. <Kal...@ms...> - 2008-09-11 12:28:56
|
For semi-log plots: How can one "fool" Vpython to display y=f(log10(x)) ? See sample program below ****** from visual import * from visual.graph import * graph1=gdisplay(x=0,y=0, width=400,height=200,title="FFT",xtitle="n-th", ytitle="ampl",xmax=20,xmin=0,ymax=200,ymin=0, foreground=color.black,background=color.white) plot1 = gvbars(delta=0.5, color=color.green) import numarray.fft.fftpack as fftpack from scipy import * import math npts=4096 #Use some power of 2 t=linspace(0,1,npts+1) dt = (t[-1]-t[0])/(len(t)-1) # Maximum frequency is 1/dt ? fmax = 1/(2*dt) sig=[] for i in range(0,npts+1): if i<0.5*npts: sig.append(100.) else: sig.append(-100) #f1 = 400 #sig=2*sin(2*pi*f1*t)+0.5*sin(2*pi*5*f1*t) ft = fft(sig,n=npts) coeff=pi*2**(log10(npts)/log10(2)-3) mgft=abs(ft)/coeff ) df = fmax/float(npts/2) f=(linspace(0,fmax,0.5*npts+1)) for i in range(1,21): plot1.plot(pos=(f[i],mgft[i])) print "done" |
From: chris l. <chr...@sp...> - 2008-09-09 08:32:20
|
Just for the sake of completeness the link to the POVexport utility in the faq is dead. http://www.vpython.org/FAQ.html Chris |
From: Bruce S. <Bru...@nc...> - 2008-08-31 02:25:59
|
There is now at vpython.org an easy-to-use installer for PowerPC Mac's running OS X 10.5. You may remember that earlier this summer John Armstrong provided an easy-to-use installer for Intel Mac's running OS X 10.5. Bruce Sherwood |
From: Emanuele G. <ema...@gm...> - 2008-08-27 23:44:27
|
In reply to Bruce: It's a pleasure to help! Visual 4 gets a little nearer ;-) In reply to Tyler: see attached the birth of a specialised multiplatform CAD for Fire Dynamics Simulator processor from NIST. My open source pet project, still in its early stages and unreleased. (just run the test.py) Emanuele. |
From: Tyler B. <dan...@li...> - 2008-08-27 22:05:06
|
Why do you want it to have zero thickness anyway? I suspect there's a better way to accomplish whatever effect you were going for. Not that it isn't a bug, of course. Emanuele Gissi wrote: > I am using the packaged VisualPython 3.2.9 on Linux Ubuntu. > I would like to signal this bug. > > Try this: > 8<---------- > from visual import * > b = box() > b.size = (0.,1.,2.) > print "b.size:", b.size > b.size = (3.,1.,2.) > print "b.size:", b.size > 8<---------- > > When the x coordinate of a box size is set to 0, it's impossible to > change it any more. > This does not seem to happen with y and z coordinates. > I lost some nights because of this ;-) > > I circumvented it this way: > > 8<---------- > from visual import * > b = box() > b.size = (1e-6,1.,2.) > print "b.size:", b.size > b.size = (3.,1.,2.) > print "b.size:", b.size > 8<---------- > > Thank you for your attention. > Emanuele Gissi > > > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > > > ------------------------------------------------------------------------ > > _______________________________________________ > Visualpython-users mailing list > Vis...@li... > https://lists.sourceforge.net/lists/listinfo/visualpython-users |
From: Emanuele G. <ema...@gm...> - 2008-08-27 21:54:56
|
I am using the packaged VisualPython 3.2.9 on Linux Ubuntu. I would like to signal this bug. Try this: 8<---------- from visual import * b = box() b.size = (0.,1.,2.) print "b.size:", b.size b.size = (3.,1.,2.) print "b.size:", b.size 8<---------- When the x coordinate of a box size is set to 0, it's impossible to change it any more. This does not seem to happen with y and z coordinates. I lost some nights because of this ;-) I circumvented it this way: 8<---------- from visual import * b = box() b.size = (1e-6,1.,2.) print "b.size:", b.size b.size = (3.,1.,2.) print "b.size:", b.size 8<---------- Thank you for your attention. Emanuele Gissi |
From: Bruce S. <Bru...@nc...> - 2008-08-08 03:10:04
|
Here's a simple example of zooming in without changing the center: from visual import * scene.range = 5 sphere(pos=(-1,0,0), radius=0.5, color=color.red) box(pos=(1,0,0), color=color.cyan) scene.mouse.getclick() scene.range = 3 scene.mouse.getclick() scene.range = 1 I'm not sure I've seen the effect you're referring to about being near the center. Perhaps you should post a specific example. If you do, please strip it down to the simplest test case you can find that illustrates your point. Bruce Sherwood Roberto Aguirre Maturana wrote: > Hi, everybody: > > I am working on an application that uses VPython to navigate around > the spatial data in a way very similar to games like Quake (tm), so > you can fly around using a combination of keys w,a,s,d and changing > the forward direction with the mouse and left button (in a simmilar > way to stonegenhe.py). > > The problem is that the best results are obtained when > scene.mouse.camera is very close to scene.center. But when this > happens the rendering seems to fail, and objects look jagged and in > some cases you can see far objects that should be hidden behind closer > ones. > > Therefore, I have two questions: > > 1. Is there a way to solve the renderig problem on short camera-center > distances? > 2. Is there a code way to move the camera away form the center without > changing the center position itself (that is, emulate the dragging of > left+right button by code)? > > Many thanks in advance. > |
From: Bruce S. <Bru...@nc...> - 2008-08-04 02:12:38
|
For your convenience, here is the note I posted yesterday. The key sentence is, "I can't yet estimate when there will be a real release of Visual 4." Bruce Sherwood ---------------------------------- Here is an important announcement from March 10, a copy of which you'll find in the "Recent developments" section of vpython.org: "A major redesign for Visual-4 Beta is underway. The central goal of the new design is to create an architecture which is more robust, easier to maintain and to extend, and easier to install and to use. The principal architects are David Scherer and Bruce Sherwood. Steve Spicklemire and Ruth Chabay have also been involved in discussions. As a result, a number of changes to the current beta version are likely. Support for textures will change. Rather than creating a texture bitmap, a programmer will be able to specify a material (such as wood). Transparency will be supported. At this point it is unclear exactly what support there will be for bitmapped images; they may be supported only as "decals" which can be applied to flat surfaces. Lighting options may change; it is likely that spotlights will not be supported at first in this version. You can look forward to higher-quality rendering of scenes on computers with modern graphics cards. A Macintosh version which does not require X11 or Fink will be created. Both the Windows version and the Mac version will no longer depend on the large GTK libraries, which will however still be the foundation for Linux." So feel free to play with the beta version, but expect problems, and also expect the details of how to use the new features to change, so don't write lots of code that will need rewriting. Here is a brief update for everyone: Major progress has been made toward improving performance and fixing bugs, and there is now a Carbon-based version for the Mac that does not use X11 or the Fink package manager. None of this is ready for release because 1) there remain some bugs and performance issues and 2) not all changes have been made to the language as discussed above. I can't yet estimate when there will be a real release of Visual 4. Hugh Fisher created a partial implementation of a Carbon-based Mac version of Visual 3 (the older, production version that does not support transparency, etc.). Starting from what Fisher built, David Scherer, assisted by me, created a Carbon-based Mac version of Visual 4. Scherer also made a number of important structural changes to Visual 4, including using a single rendering for all windows rather than separate renderings for each window, thereby making it much easier to apportion time between your Python calculations and the graphics rendering. Scherer also implemented support for unicode text in labels on Windows; new code was necessary after abandoning GTK on Windows. Emanuele Gissi wrote: > Open source software is usually "ready when it's ready...". > > But let me ask this dumb question: > Sourceforge still has the VisualPython 4.beta26 version that was out > in february. > When will the refactored VisualPython 4 version be ready for us hungry > users to test? > > I am looking forward to materials, box with different faces, > transparency, and new frames capabilities... > I suggest the possibility to put pull-down menus and custom buttons > (to build a simple toolbox) on the 3d scene window and not only in a > separate control window. > > Thanks in advance, as usual (Grazie in anticipo, come sempre) > Emanuele > > |
From: Emanuele G. <ema...@gm...> - 2008-08-03 22:48:40
|
Open source software is usually "ready when it's ready...". But let me ask this dumb question: Sourceforge still has the VisualPython 4.beta26 version that was out in february. When will the refactored VisualPython 4 version be ready for us hungry users to test? I am looking forward to materials, box with different faces, transparency, and new frames capabilities... I suggest the possibility to put pull-down menus and custom buttons (to build a simple toolbox) on the 3d scene window and not only in a separate control window. Thanks in advance, as usual (Grazie in anticipo, come sempre) Emanuele |
From: Bruce S. <Bru...@nc...> - 2008-08-03 03:59:14
|
Here is an important announcement from March 10, a copy of which you'll find in the "Recent developments" section of vpython.org: "A major redesign for Visual-4 Beta is underway. The central goal of the new design is to create an architecture which is more robust, easier to maintain and to extend, and easier to install and to use. The principal architects are David Scherer and Bruce Sherwood. Steve Spicklemire and Ruth Chabay have also been involved in discussions. As a result, a number of changes to the current beta version are likely. Support for textures will change. Rather than creating a texture bitmap, a programmer will be able to specify a material (such as wood). Transparency will be supported. At this point it is unclear exactly what support there will be for bitmapped images; they may be supported only as "decals" which can be applied to flat surfaces. Lighting options may change; it is likely that spotlights will not be supported at first in this version. You can look forward to higher-quality rendering of scenes on computers with modern graphics cards. A Macintosh version which does not require X11 or Fink will be created. Both the Windows version and the Mac version will no longer depend on the large GTK libraries, which will however still be the foundation for Linux." So feel free to play with the beta version, but expect problems, and also expect the details of how to use the new features to change, so don't write lots of code that will need rewriting. Here is a brief update for everyone: Major progress has been made toward improving performance and fixing bugs, and there is now a Carbon-based version for the Mac that does not use X11 or the Fink package manager. None of this is ready for release because 1) there remain some bugs and performance issues and 2) not all changes have been made to the language as discussed above. I can't yet estimate when there will be a real release of Visual 4. Hugh Fisher created a partial implementation of a Carbon-based Mac version of Visual 3 (the older, production version that does not support transparency, etc.). Starting from what Fisher built, David Scherer, assisted by me, created a Carbon-based Mac version of Visual 4. Scherer also made a number of important structural changes to Visual 4, including using a single rendering for all windows rather than separate renderings for each window, thereby making it much easier to apportion time between your Python calculations and the graphics rendering. Scherer also implemented support for unicode text in labels on Windows; new code was necessary after abandoning GTK on Windows. Bruce Sherwood CL wrote: > Hi > > I've tried the latest beta version on Windows XP and have some questions. > > The latest version is quite slow on my PC as compared with the 3.2.11, > without using the new features. Any suggestions to make it run faster > or I shall wait for next beta release ? > > Also, I am not able to run texturetest.py and texture_and_lighting.py. > I am able to run hanoi.py and see the base with wood texture. > > vPython is great, especially with the version 4 features ! I would > like to use the version 4 asap. What is the latest progress and > release schedule ? > > > |
From: CL <clc...@gm...> - 2008-08-03 02:26:54
|
Hi I've tried the latest beta version on Windows XP and have some questions. The latest version is quite slow on my PC as compared with the 3.2.11, without using the new features. Any suggestions to make it run faster or I shall wait for next beta release ? Also, I am not able to run texturetest.py and texture_and_lighting.py. I am able to run hanoi.py and see the base with wood texture. vPython is great, especially with the version 4 features ! I would like to use the version 4 asap. What is the latest progress and release schedule ? |
From: Nathan M. <nt...@gm...> - 2008-07-17 16:24:07
|
Problem resolved: I didn't realize that if python is in /usr then I have to use the configure --prefix=/usr option in both the visual compilation AND the gtkglarea-1.2.3 compilation. When I include this flag, visual works wonderfully. A brief synopsis on what it takes to get visual-3.2.9 running on a Scientific Linux 5.1 or 5.2 box follows: Assuming you have root access: Visual requires a number of libraries to run, by trial and error (reading through compilation error logs) the following list seems to suffice: yum install gtk+ gtk+-devel gtk2 gtk2-devel tk tk-devel tkinter Then, download, open and configure gtkglarea-1.2.3 You could probably make it know to visual with a "library/path" shell variable, but I found it easiest to install it in the same tree as python, ie, wget http://www.vpython.org/download/gtkglarea-1.2.3.tar.gz tar zxf gtkglarea-1.2.3.tar.gz cd gtkglarea-1.2.3 ./configure --prefix=/usr * (assuming that pythion is /usr/bin/python)* make make install After this, visual follows the same procedure, wget http://www.vpython.org/download/visual-3.2.9.tar.bz2 tar jxf visual-3.2.9.tar.bz2 tar xf visual-3.2.9.tar.bz2 cd visual-3.2.9 ./configure --prefix=/usr make make install The idle interface is buried inside of /usr and I have trouble remembering the whole path. Instead, I made a simple link inside of my .bashrc login flie, alias idle="/usr/bin/python /usr/lib/python2.4/idlelib/idle.pyw" This took me a while to figure out - perhaps it could be posted on the INSTALL/FAQ? Nathan Moore <nt...@gm...> wrote: > I'm working to get a copy of visual 3.2.9 running on a Scientific Linux 5.2 > box (RHEL 5, compiled from source). The system built normally and I have a > copy of visual installed (I think) but when I run a script which calls > visual, it doesn't run. The error I get in the idle execution window > complains about a missing libgtkgl, > > >>> > > Traceback (most recent call last): > File > "/home/nmoore/ibook_home_dir/nmoore/Desktop/learning_games/lightning/lightning.py", > line 8, in -toplevel- > from visual import * > File "/usr/lib/python2.4/site-packages/visual/__init__.py", line 15, in > -toplevel- > import array_backend > File "/usr/lib/python2.4/site-packages/visual/array_backend.py", line 1, > in -toplevel- > import cvisual > ImportError: libgtkgl.so.5: cannot open shared object file: No such file or > directory > > When I look for this library, it seems to be available, > > [nmoore@pilgrim ~]$ locate libgtkgl > /usr/lib/libgtkglext-x11-1.0.a > /usr/lib/libgtkglext-x11-1.0.so > /usr/lib/libgtkglext-x11-1.0.so.0 > /usr/lib/libgtkglext-x11-1.0.so.0.2.4 > /usr/local/lib/libgtkgl.a > /usr/local/lib/libgtkgl.la > /usr/local/lib/libgtkgl.so > /usr/local/lib/libgtkgl.so.5 > /usr/local/lib/libgtkgl.so.5.0.0 > > Is this an easy thing to fix? When I configured/compiled visual, I used > the config string, > ../visual-3.2.9/configure --prefix=/usr > Should I have specified something else in addition? > > regards, > > Nathan Moore > -- - - - - - - - - - - - - - - - - - - - - - Nathan Moore Assistant Professor, Physics Winona State University AIM: nmoorewsu - - - - - - - - - - - - - - - - - - - - - |
From: Nathan M. <nt...@gm...> - 2008-07-16 20:31:00
|
I'm working to get a copy of visual 3.2.9 running on a Scientific Linux 5.2 box (RHEL 5, compiled from source). The system built normally and I have a copy of visual installed (I think) but when I run a script which calls visual, it doesn't run. The error I get in the idle execution window complains about a missing libgtkgl, >>> Traceback (most recent call last): File "/home/nmoore/ibook_home_dir/nmoore/Desktop/learning_games/lightning/lightning.py", line 8, in -toplevel- from visual import * File "/usr/lib/python2.4/site-packages/visual/__init__.py", line 15, in -toplevel- import array_backend File "/usr/lib/python2.4/site-packages/visual/array_backend.py", line 1, in -toplevel- import cvisual ImportError: libgtkgl.so.5: cannot open shared object file: No such file or directory When I look for this library, it seems to be available, [nmoore@pilgrim ~]$ locate libgtkgl /usr/lib/libgtkglext-x11-1.0.a /usr/lib/libgtkglext-x11-1.0.so /usr/lib/libgtkglext-x11-1.0.so.0 /usr/lib/libgtkglext-x11-1.0.so.0.2.4 /usr/local/lib/libgtkgl.a /usr/local/lib/libgtkgl.la /usr/local/lib/libgtkgl.so /usr/local/lib/libgtkgl.so.5 /usr/local/lib/libgtkgl.so.5.0.0 Is this an easy thing to fix? When I configured/compiled visual, I used the config string, ../visual-3.2.9/configure --prefix=/usr Should I have specified something else in addition? regards, Nathan Moore |
From: Herman, R. <he...@un...> - 2008-07-13 21:40:31
|
Hi, The display attribute was what I needed. I first tried toggling the visible attribute. The bug you mentioned first gave buttons with no text, but further use made the buttons disappear entirely. I ended up using the exit function. I rewrote the control panels as part of functions which could be called to delete one panel and add the other. Toggling this way gave me what I wanted the user to see. Thanks. Russell Herman Editor-in-Chief The Journal of Teaching Effectiveness, http://www.uncw.edu/cte/et/, JE...@un... Center for Teaching Excellence, and Professor Department of Mathematics and Statistics UNC Wilmington, Wilmington, NC 28403 he...@un... -----Original Message----- From: vis...@li... on behalf of Bruce Sherwood Sent: Sun 7/13/2008 3:57 PM To: vis...@li... Subject: Re: [Visualpython-users] Mulitple Control Panels What's missing in the documentation is that a controls window has an attribute "display" which is the display within which those controls are displayed. The following code displays a sphere in an ordinary window plus two controls windows (with no loop to make the controls active). Clicking in the ordinary window makes the second controls window visible, then invisible. from visual.controls import * sphere() c1 = controls(x=500, y=0) toggle() c2 = controls(x=500, y=400) button(text="Press") slider(pos=(-80,-80), axis=(0,100)) scene.mouse.getclick() c2.display.visible = 0 scene.mouse.getclick() c2.display.visible = 1 There is a bug I don't understand. After the second click, which makes the second control panel visible again, the text is missing from the button. If you also want users to be able to kill a controls window without killing the application, you need to say c2.display.exit = 0 # default is 1 (true), which kills the application Bruce Sherwood Herman, Russ wrote: > Hi, > > I have several control panels, but I do not want them showing at the same time. Is there a way to hide them. I tried several display attribute calls but they did not seem to work. Also, if I close one manually, everything closes. > > Thanks > > Russell Herman > > Editor-in-Chief > The Journal of Teaching Effectiveness, > http://www.uncw.edu/cte/et/, JE...@un... > Center for Teaching Excellence, and > > Professor > Department of Mathematics and Statistics > UNC Wilmington, Wilmington, NC 28403 > he...@un... > > ------------------------------------------------------------------------- Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW! Studies have shown that voting for your favorite open source project, along with a healthy diet, reduces your potential for chronic lameness and boredom. Vote Now at http://www.sourceforge.net/community/cca08 _______________________________________________ Visualpython-users mailing list Vis...@li... https://lists.sourceforge.net/lists/listinfo/visualpython-users |
From: Bruce S. <Bru...@nc...> - 2008-07-13 19:57:02
|
What's missing in the documentation is that a controls window has an attribute "display" which is the display within which those controls are displayed. The following code displays a sphere in an ordinary window plus two controls windows (with no loop to make the controls active). Clicking in the ordinary window makes the second controls window visible, then invisible. from visual.controls import * sphere() c1 = controls(x=500, y=0) toggle() c2 = controls(x=500, y=400) button(text="Press") slider(pos=(-80,-80), axis=(0,100)) scene.mouse.getclick() c2.display.visible = 0 scene.mouse.getclick() c2.display.visible = 1 There is a bug I don't understand. After the second click, which makes the second control panel visible again, the text is missing from the button. If you also want users to be able to kill a controls window without killing the application, you need to say c2.display.exit = 0 # default is 1 (true), which kills the application Bruce Sherwood Herman, Russ wrote: > Hi, > > I have several control panels, but I do not want them showing at the same time. Is there a way to hide them. I tried several display attribute calls but they did not seem to work. Also, if I close one manually, everything closes. > > Thanks > > Russell Herman > > Editor-in-Chief > The Journal of Teaching Effectiveness, > http://www.uncw.edu/cte/et/, JE...@un... > Center for Teaching Excellence, and > > Professor > Department of Mathematics and Statistics > UNC Wilmington, Wilmington, NC 28403 > he...@un... > > |
From: Herman, R. <he...@un...> - 2008-07-13 15:48:57
|
Hi, I have several control panels, but I do not want them showing at the same time. Is there a way to hide them. I tried several display attribute calls but they did not seem to work. Also, if I close one manually, everything closes. Thanks Russell Herman Editor-in-Chief The Journal of Teaching Effectiveness, http://www.uncw.edu/cte/et/, JE...@un... Center for Teaching Excellence, and Professor Department of Mathematics and Statistics UNC Wilmington, Wilmington, NC 28403 he...@un... |
From: Bruce S. <Bru...@nc...> - 2008-07-13 13:42:55
|
In the case of spheres this is pretty easy already: if mag(r-c.pos) < c.radius: print "inside". It's certainly more difficult with other objects. What non-sphere objects did you have in mind? Bruce Sherwood Nathan Moore wrote: > I'm playing around with a complicated (boundary) in a Laplace equation > problem, in vpython. It would be nice to know if a point is inside of > another object within the program, ie, > > r=vector(1,1,1) > s=vector(0,0,0) > > c = sphere(pos=(0,0,0),radius=0.75) > > I want to know if r, or s are in the object c. > > I've worked out some functions in longhand, but I figure an included > function might be faster... > > Nathan > |
From: Nathan M. <nt...@gm...> - 2008-07-13 05:01:07
|
I'm playing around with a complicated (boundary) in a Laplace equation problem, in vpython. It would be nice to know if a point is inside of another object within the program, ie, r=vector(1,1,1) s=vector(0,0,0) c = sphere(pos=(0,0,0),radius=0.75) I want to know if r, or s are in the object c. I've worked out some functions in longhand, but I figure an included function might be faster... Nathan |
From: Joel K. <jj...@ya...> - 2008-07-12 21:09:05
|
Bruce Sherwood wrote: >I don't see any reason to translate >working Physlets from Java to Python. >They work fine as they are. It would >be a different matter if one were to >be inspired by a Physlet to do >something new, something for which >VPython was particularly appropriate. I agree that nobody should waste their time on translation if no new value will be added. I think the most obvious kind of change that might be useful is to take a 2D physlet and transform it into a 3D VPython environment. When dealing with the motions of objects, for example, this might increase the educational benefits. Joel |