It is currently Tue Jul 02, 2024 2:59 am


All times are UTC - 5 hours [ DST ]



Post new topic Reply to topic  [ 45 posts ]  Go to page Previous  1, 2, 3  Next
Author Message
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Mon Mar 07, 2011 1:31 pm  (#21) 
Offline
GimpChat Member
User avatar

Joined: May 16, 2010
Posts: 14709
Location: USA
That's a good idea Mahvin.

_________________
Image
Edmund Burke nailed it when he said, "The only thing necessary for the triumph of evil is for good men to do nothing."


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Mon Mar 07, 2011 5:50 pm  (#22) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 12531
OK Rod. I don't have GIMP Portable. Did consolidate all the dlls and the Python script into it's own directory and tried to double-click on the Python script, but get a quick DOS menu then it disappears. I'm downloading GIMP Portable just in case it requires that too. I'll edit this (or add) if success or failure afterwards (only getting 70K/s download speed so it's taking a few more minutes then I would like). :)

edit:

I didn't realize you still had to install GIMP Portable before you can use it. I'll just stick with the GIMP launch thingy that I did when I started this thread. :)

edit:

OK; Kevin's version does work and can be called in GIMP with all the caveats that Rod mentioned. Still cool though. Thanks Kevin. :)

_________________
Lyle

Psalm 109:8

Image


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Mon Mar 07, 2011 6:37 pm  (#23) 
Offline
GimpChat Member
User avatar

Joined: May 16, 2010
Posts: 14709
Location: USA
You shouldn't need gimp portable, as i do not have it.
If it is opening a quick dos window and closing again it means you don't have all the required dll files in the folder with the python file.Are you sure you placed all the dll's i posted earlier in there?

_________________
Image
Edmund Burke nailed it when he said, "The only thing necessary for the triumph of evil is for good men to do nothing."


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Mon Mar 07, 2011 6:42 pm  (#24) 
Offline
Global Moderator
User avatar

Joined: Oct 06, 2010
Posts: 4050
It runs pretty good in Linux as a standalone, the only problem I have is the random button doesn't seem to work (all the time). This is the error:

/home/mahvin/Ghost Diagram/ghost-diagrams-0.8.py:1050: DeprecationWarning: catching of string exceptions is deprecated
  except "repeat":
Traceback (most recent call last):
  File "/home/mahvin/Ghost Diagram/ghost-diagrams-0.8.py", line 613, in <lambda>
    random_button.connect('clicked', lambda widget: self.random())
  File "/home/mahvin/Ghost Diagram/ghost-diagrams-0.8.py", line 1047, in random
    if a in all and b not in all: raise "repeat"
TypeError: exceptions must be old-style classes or derived from BaseException, not str


A couple of new interesting presets to add to your list:

"'212121', ' 1 2 '",
"'F Aa ', 'c Aa '",

_________________
"In order to attain the impossible, one must attempt the absurd."
~ Miguel de Cervantes


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Mon Mar 07, 2011 7:53 pm  (#25) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 12531
Rod wrote:
You shouldn't need gimp portable, as i do not have it.
If it is opening a quick dos window and closing again it means you don't have all the required dll files in the folder with the python file.Are you sure you placed all the dll's i posted earlier in there?


I triple checked Rod. No problem anyway since Kevin's edit works. I just wish it would output seamless textures but too chicken (and lazy) to email Paul (busy he must be) to add that capability. :)

_________________
Lyle

Psalm 109:8

Image


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Mon Mar 07, 2011 8:18 pm  (#26) 
Offline
Global Moderator
User avatar

Joined: Oct 06, 2010
Posts: 4050
I emailed him, (never hurts to ask).

_________________
"In order to attain the impossible, one must attempt the absurd."
~ Miguel de Cervantes


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Tue Mar 08, 2011 4:46 pm  (#27) 
Offline
GimpChat Member
User avatar

Joined: May 16, 2010
Posts: 14709
Location: USA
No it doesn't! :)

_________________
Image
Edmund Burke nailed it when he said, "The only thing necessary for the triumph of evil is for good men to do nothing."


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Wed Mar 09, 2011 8:42 am  (#28) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 12531
Sorry for opening this up again. lol

Just found another cool preset ('cCc C '). Even harder to make it seamless (but I did). Of course I used the Python version since I like the inside line effect. Then the hard part (made it seamless). Click on the image for it's Deviant (yup; another SSP; lol). :)

Image

edit:

Also another (yes, it's seamless. It's based on 'aA aA '); decided to host this one here, but still an SSP. ;)

:)


Attachments:
lattice.png
lattice.png [ 33.71 KiB | Viewed 2018 times ]

_________________
Lyle

Psalm 109:8

Image
Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Thu Mar 10, 2011 1:15 am  (#29) 
Offline
Global Moderator
User avatar

Joined: Oct 06, 2010
Posts: 4050
I don't know why, but presets I find in the javascript version don't play nice in the Python version. How weird is that?

_________________
"In order to attain the impossible, one must attempt the absurd."
~ Miguel de Cervantes


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Thu Mar 10, 2011 1:30 am  (#30) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 12531
Yeah; and you get different results. I think, based on reading the 70MByte thesis he posted, that the XHTML version is closest to what he wanted the result to be. :)

_________________
Lyle

Psalm 109:8

Image


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Thu Mar 10, 2011 1:40 am  (#31) 
Offline
Global Moderator
User avatar

Joined: Oct 06, 2010
Posts: 4050
Right, and it looks better, but without the knots (which I personally prefer).

_________________
"In order to attain the impossible, one must attempt the absurd."
~ Miguel de Cervantes


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Fri Mar 11, 2011 1:48 am  (#32) 
Offline
Global Moderator
User avatar

Joined: Oct 06, 2010
Posts: 4050
I don't know if any of you have paid much attention to the ability to change the colors of your ghost diagrams. It works best by placing your hexadecimal code directly before a ', see the example below:

Take this:

'1B1B', 'a A ', ' bA ', 'ab B'

and do this:

'1B1B/#fff', 'a A /#fff', ' bA /#000', 'ab B/#fff'

Note: you can use the html notation of any 6 alphanumeric (#e4d56b), for colors. The above example is just the short version for black and white, but you can use html notation. Just make sure the "/#000 immediately precedes the CLOSING ' I tried using it before the opening ' and it doesn't work.

_________________
"In order to attain the impossible, one must attempt the absurd."
~ Miguel de Cervantes


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Fri Mar 11, 2011 2:07 am  (#33) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 12531
Cool; works for the python script but not the XHTML for whatever reason. :)

_________________
Lyle

Psalm 109:8

Image


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Fri Mar 11, 2011 2:22 am  (#34) 
Offline
Global Moderator
User avatar

Joined: Oct 06, 2010
Posts: 4050
If there are any differences in presets on the javascript version, just copy and paste the preset into the python version and then change the colors. I haven't really looked to see if any were different on the separate versions.

You can even declare grids, borders, and thicknesses (I got some pretty cool grids from this):

grid=0, border=0, thickness=0.3

_________________
"In order to attain the impossible, one must attempt the absurd."
~ Miguel de Cervantes


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Fri Mar 11, 2011 3:59 am  (#35) 
Offline
GimpChat Member

Joined: Apr 12, 2010
Posts: 5870
mahvin wrote:
Word to the wise:

Instead of saving the javascript version as a desktop link (that may one day disappear from the internet) save it as a file. But make sure you save the "entire content" of the xhtml (do not save it as a link). And do not save the file just by clicking "save file as", as sometimes it fails to associate the web content according to the actual source information in the xhtml, and running it sometimes will fail. Instead, (using Firefox: recommended) open the source page, select Edit - All, then save the copy of the source to your folder (you can keep the same name for it, if you want). And now you will have a standalone javascript version to use and not have to worry about the website going down or going away.



this is a good tip and not only for this app

_________________
My 3D Gallery on Deviantart http://photocomix2.deviantart.com/
Main gallery http://www.flickriver.com/photos/photocomix-mandala/
Mandala and simmetry http://www.flickriver.com/photos/photocomix_mandala/

Image

Mrs Wilbress


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Fri Mar 11, 2011 11:24 am  (#36) 
Offline
GimpChat Member
User avatar

Joined: May 16, 2010
Posts: 14709
Location: USA
Thanks Mahvin for the tips.

_________________
Image
Edmund Burke nailed it when he said, "The only thing necessary for the triumph of evil is for good men to do nothing."


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Sat Mar 12, 2011 12:57 am  (#37) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 12531
OK Rod. I had a few minutes so I went looked at the issue again. I first copied the python script in the GIMP bin folder and low and behold, it worked great. I decided to do pretty much what you did and found the files needed and I needed more files then you did for whatever reason. Now I wonder if I can give the save as svg option as opposed to save as PNG. Might take a look at the code and replace the libpng with the libsvg and see what happens. Not sure if it is as easy as this though. :)


Attachments:
whatineeded.png
whatineeded.png [ 77.45 KiB | Viewed 1870 times ]

_________________
Lyle

Psalm 109:8

Image
Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Sat Mar 12, 2011 1:09 am  (#38) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 12531
Well I tried to copy both libsvg.dll and librsvg-2-2.dll after replacing all the png entries with svg entries in the python script, but I get this error. Guess I'm SOL. lol

:)


Attachments:
sol.png
sol.png [ 42.63 KiB | Viewed 1869 times ]

_________________
Lyle

Psalm 109:8

Image
Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Sat Mar 12, 2011 1:51 am  (#39) 
Offline
Global Moderator
User avatar

Joined: Oct 06, 2010
Posts: 4050
This build of gdk-pixbuf does not support saving the image format, svg

We need the svg-gdk-pixbuf-loader version, but I am not sure how to implement that into this python file.

I am tempted to call up the "export as svg" plug-in and see what happens.

_________________
"In order to attain the impossible, one must attempt the absurd."
~ Miguel de Cervantes


Top
 Post subject: Re: Ghost Diagrams Python Script.
PostPosted: Sat Mar 12, 2011 1:58 am  (#40) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 12531
Again, hacker I'm not and am not aware of all the "skin a cat" methods, but if you do get it to work Mahvin, I would appreciate it if you share. At least I now can run it without GIMP (Rod told how; weird I had to add the additional files for mine to work). :)

_________________
Lyle

Psalm 109:8

Image


Top
Post new topic Reply to topic  [ 45 posts ]  Go to page Previous  1, 2, 3  Next

All times are UTC - 5 hours [ DST ]


   Similar Topics   Replies 
No new posts Just brainstorm with diagrams and hack it out

5

No new posts .py script not showing under Python-Fu

3

No new posts Attachment(s) My first Python Script for Gimp

7

No new posts Attachment(s) Learning to do first Python script

6

No new posts Does anyone have script fu and python plugins that work on 2.99.19?

1



* Login  



Powered by phpBB3 © phpBB Group