473,785 Members | 2,209 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

interactive graphics?

I'm intrigued by the pedagogical possibilities of those Java applets where you
can manipulate an image by mouse-dragging. Is there any prospect of doing
something similar with Python? And if so, where might one start?
Jul 18 '05 #1
4 2294
Elaine Jackson wrote:
I'm intrigued by the pedagogical possibilities of those Java applets where you
can manipulate an image by mouse-dragging. Is there any prospect of doing
something similar with Python? And if so, where might one start?


Quite vague.
Although, you might want to take a look at PyGame www.pygame.org
and also the turtle module: http://docs.python.org/lib/module-turtle.html

--Irmen
Jul 18 '05 #2
If your platform is Windows you might also want to
take a look at:

http://www.onlamp.com/pub/a/python/e...t20/index.html

HTH,
Larry Bates
Syscon, inc.

"Elaine Jackson" <el************ ***@home.com> wrote in message
news:4egNc.1158 64$Mr4.37857@pd 7tw1no...
I'm intrigued by the pedagogical possibilities of those Java applets where you can manipulate an image by mouse-dragging. Is there any prospect of doing
something similar with Python? And if so, where might one start?

Jul 18 '05 #3
Elaine Jackson wrote:
I'm intrigued by the pedagogical possibilities of those Java applets where you
can manipulate an image by mouse-dragging. Is there any prospect of doing
something similar with Python? And if so, where might one start?


Do you mean like an applet that lets you draw? Or an applet that takes
a pre-existing image and you can alter it (like make it fuzzy or draw
over it)? Or an applet that lets you add shapes and move them around?

There isn't as much on the Python side as Java, but you can do all these
in Python.

If you are using Windows, I would recommend starting off by trying out
wxPython (http://www.wxpython.org/) and running the demo.

If you are wanting to do something like a drawing or image altering
application, see in addition to the demo:
http://wiki.wxpython.org/index.cgi/WorkingWithImages
http://www.pythonware.com/products/pil/

If you are wanting something that can do interactive structured
graphics, where you can add shapes and drag them around, see for
example: http://bellsouthpwp.net/p/r/prochak/pyxel.html

And also check out http://pygame.org/ and http://www.nongnu.org/pygsear/
Jul 18 '05 #4
On Mon, 26 Jul 2004 23:13:04 GMT, "Elaine Jackson"
<el************ ***@home.com> wrote:
I'm intrigued by the pedagogical possibilities of those Java applets where you
can manipulate an image by mouse-dragging. Is there any prospect of doing
something similar with Python? And if so, where might one start?

www.vpython.org

The demos should give you a good idea of some of the possiblities.
Its pedagogical possibilities are being well explored in the physics
classroom, but there are many other ways to go with it.

My own effort is PyGeo, which is a geometry laboratory using Vpython
as the rendering backend. It is in the class of "dynamic geometry"
applications. Except, as opposed to the others of which I am aware,
it lives in a spacial, rather than flat world. Oh, and its in Python.

http://home.netcom.com/~ajs

There are parts of its architecture I think are cool.

Except that its mouse functioning is broken by the brand new VPython
release (which is the first Boost based release). I suspected the
new VPython might break PyGeo, so was holding off on a new release
until the VPython release. Now I have no excuse.

Art
Jul 18 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

20
2453
by: Joe | last post by:
When you run "python -i scriptname.py" after the script completes you left at the interactive command prompt. Is there a way to have this occur from a running program? In other words can I just run scriptname.py (NOT python -i scriptname.py) and inside of scriptname.py I decide that I want to fall back to the interactive prompt? I've searched and so far the only thing I've come up with is to use pdb, but
5
1830
by: Eckhoff, Michael A | last post by:
Hello, I failed to locate a list for pygtk, so I thought I'd ask my question here. Is it possible to write CGI scripts that bring up a GUI (as in GTK+, QT, Tk, ...) or an openGL display that is windowed inside a web browser? The answer would seem to me to be no, since the client could be Windows or Linux. I'd like to
2
7813
by: Charles Krug | last post by:
List: I'm trying to us pylab to see what I'm doing with some DSP algorithms, in case my posts about convolution and ffts weren't giving it away. I've been using pylab's plot function, but I'm finding it a bit cumbersome. It works, but if I switch from the interactive window to the plot window and back, the plot window gets trashed.
2
2013
by: WJ | last post by:
I have three ASPX pages: 1. "WebForm1.aspx" is interactive, responsible for calling a web site (https://www.payMe.com) with $$$. It is working fine. 2. "WebForm2.aspx" is non-interactive, a listener in my site to capture a "STATUS_CD" returned by www.payMe.com. It is working fine. 3. "WebForm3.aspx" is interactive page, responsibe to display the STATUS CODE "POSTED" by "WebForm2.aspx". 4. My goal is to use "WebForm2.aspx" to call...
6
1867
by: Brian Henry | last post by:
Hello, I am trying to make a user control that is interactive. What I am doing is drawing a set of bars on a control similar to a gantt chart and allowing a user to place the mouse over them to see a tool tip, or if you click on them to open a form associated with data tied behind them. What I can't figure out how to do (I have been looking at a few very complex examples and it's hard to pull out how they did it) is how do you create a...
3
4612
by: Lubomir | last post by:
Hi, I read that interactive windows services will not be allowed to run under Wista. I would like to ask what exactly is the interactive service. It is supposed to be a service that communicates with desktop. What about the following scenario: A service will create a thread. This thread will create and run an UI Windows application that manages task bar and so on on a desktop. This application will communicate with the service: a/ by...
1
2272
by: pool | last post by:
This has probably been asked before, but I cannot seem to find what i need with the searches I have tried. I am trying to learn C# for a project at work that I will probably be moving on to. I am trying to figure out to create a form which will interact with a graphics. In other words, I would like to create a form with buttons and other components on it, and have events from that form cause stuff to be drawn (lines, arcs, etc) in...
2
2188
by: sydneytroz | last post by:
I am writing a program to simulate a double displacement reaction getting to equilibrium, but I am having some trouble graphing the particles' concentrations. It seems that it's only possible to pan and zoom the graph once the program exits (when running it from IDLE), but I don't want to have to kill the sim every time I want to view the graph (besides, when I do, the graph window dissappears). The following code contains all the graphing...
3
1995
by: Bob | last post by:
Hello, I was hoping someone could help me with what I think should be a relatively easy code question, but I can't seem to find what I'm looking for. I put together a screen shot of what I'm looking for at this link: http://www.slocountywineries.com/test_map.jpg
0
9646
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9483
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10346
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10157
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8982
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6742
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5386
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5514
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4055
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.