It is currently Fri Oct 24, 2014 4:27 am


Latest GIMP Scripts & Plug-ins

All times are UTC - 5 hours [ DST ]




Post new topic Reply to topic  [ 274 posts ]  Go to page Previous  1, 2, 3, 4, 5, 6 ... 28  Next
Author Message
 Post subject: Re: XNViewShell
PostPosted: Fri Jan 07, 2011 9:04 pm  (#21) 
Offline
GimpChat Member
User avatar

Joined: Jul 04, 2010
Posts: 1377
Location: Retired Moderator Slowly Returning to the Living.
Let me try this again...

It's no go on Win7 64bit. I don't want to install XnView in the regular "Program Files" directory, as this is reserved for 64 bit programs. I am looking into another option.

_________________
Artists aren't crazy! We're eccentric! ~G.M. Ross

Image

My Sigs = My Photos
Check out my work at http://www.flickr.com/photos/photomastergreg.


Top
 Profile  
 
 Post subject: Re: XNViewShell
PostPosted: Fri Jan 07, 2011 9:06 pm  (#22) 
Offline
GimpChat Member

Joined: Oct 06, 2010
Posts: 2666
PM:

You can change the path in the PY file to suit the installation location. You just need to use double \\ .

I wish I could get it to work in Ubuntu, how sweet that would be.

_________________
You cannot do a kindness too soon because you never know how soon it will be too late.

~Ralph Waldo Emerson


Top
 Profile  
 
 Post subject: Re: XNViewShell
PostPosted: Fri Jan 07, 2011 9:09 pm  (#23) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 6618
OK; The original image as embedded alpha and the result shown is after I ran Cybia's Alphaworks filter and got placed back into GIMP (identical as before running the filter). The second version how it should be. I saved it while still in XNView. I have an idea why this is happening. Maybe if you can figure out how to paste it back in another layer besides the calling layer, you can get the proper result. :)

Attachment:
ducky_fill.png
ducky_fill.png [ 209.71 KiB | Viewed 1863 times ]


Attachments:
gimp-temp-210415.png
gimp-temp-210415.png [ 268.73 KiB | Viewed 1863 times ]

_________________
Lyle

Psalm 109:8

Image
Top
 Profile  
 
 Post subject: Re: XNViewShell
PostPosted: Fri Jan 07, 2011 9:13 pm  (#24) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 6618
Ah; just tried it with a layer that already has transparancy components and the result that comes back is different then if I saved it externally further backing what I think is the problem. :)

What should be the result:

Attachment:
gimp-temp-210418.png
gimp-temp-210418.png [ 338.69 KiB | Viewed 1863 times ]


What comes back inside GIMP:

Attachment:
gimp-temp-210415b.png
gimp-temp-210415b.png [ 317.45 KiB | Viewed 1863 times ]

_________________
Lyle

Psalm 109:8

Image


Top
 Profile  
 
 Post subject: Re: XNViewShell
PostPosted: Fri Jan 07, 2011 9:26 pm  (#25) 
Offline
GimpChat Member

Joined: Oct 06, 2010
Posts: 2666
Rob: I don't know how I missed your post. I thought I was keeping a good eye for any replies and somehow I missed your post. Hmmm... Anyway, thanks for trying. I truly appreciate that.

_________________
You cannot do a kindness too soon because you never know how soon it will be too late.

~Ralph Waldo Emerson


Top
 Profile  
 
 Post subject: Re: XNViewShell
PostPosted: Fri Jan 07, 2011 9:54 pm  (#26) 
Offline
Script Coder
User avatar

Joined: Jul 14, 2010
Posts: 621
mahvin wrote:
Rob: I don't know how I missed your post. I thought I was keeping a good eye for any replies and somehow I missed your post. Hmmm... Anyway, thanks for trying. I truly appreciate that.


OK - I installed wine and xnview and this seems to work:
  # Use temp file names from gimp, it reflects the user's choices in gimp.rc
  # change as indicated if you always want to use the same temp file name
  tempwinfile = "C:\\Windows\\Temp\\tempfile.png"
  tempfilename = "/home/rob/.wine/dosdevices/c:/windows/temp/tempfile.png"

  # !!! Note no run-mode first parameter, and user entered filename is empty string
  pdb.gimp_progress_set_text ("Saving a copy")
  pdb.file_png_save_defaults(tempimage, tempdrawable, tempfilename, tempfilename)

  # Command line - Change to match where you installed XnView
  command = "/usr/bin/wine \"C:\\Program Files\\XnView\\xnview.exe\" \"" + tempwinfile + "\""
  gimp.message(command)
  args = shlex.split(command)


Just replace the bits of the previous version and change your home/rob/ path to yours.

This is necessary to overcome the wine/linux paths.

-Rob A>

_________________
Image
Fantasy Cartography and Mapping by RobA


Top
 Profile  
 
 Post subject: Re: XNViewShell
PostPosted: Fri Jan 07, 2011 10:12 pm  (#27) 
Offline
GimpChat Member

Joined: Oct 06, 2010
Posts: 2666
Results:

Traceback (most recent call last):
File "/usr/lib/gimp/2.0/python/gimpfu.py", line 692, in response
dialog.res = run_script(params)
File "/usr/lib/gimp/2.0/python/gimpfu.py", line 353, in run_script
return apply(function, params)
File "/home/mahvin/.gimp-2.6/plug-ins/XNViewShell.py", line 73, in plugin_main
args = shlex.split(command)
NameError: global name 'shlex' is not defined

_________________
You cannot do a kindness too soon because you never know how soon it will be too late.

~Ralph Waldo Emerson


Top
 Profile  
 
 Post subject: Re: XNViewShell
PostPosted: Fri Jan 07, 2011 10:14 pm  (#28) 
Offline
Script Coder
User avatar

Joined: Jul 14, 2010
Posts: 621
lylejk wrote:
Ah; just tried it with a layer that already has transparancy components and the result that comes back is different then if I saved it externally further backing what I think is the problem. :)


I think I figured it out. It was pasting into the original selection, so if the filter removed alpha, the old image showed through...

Try the attached.


Attachments:
XNViewShell.zip [1.84 KiB]
Downloaded 368 times

_________________
Image
Fantasy Cartography and Mapping by RobA
Top
 Profile  
 
 Post subject: Re: XNViewShell
PostPosted: Fri Jan 07, 2011 10:15 pm  (#29) 
Offline
Script Coder
User avatar

Joined: Jul 14, 2010
Posts: 621
mahvin wrote:
Results:

Traceback (most recent call last):
File "/usr/lib/gimp/2.0/python/gimpfu.py", line 692, in response
dialog.res = run_script(params)
File "/usr/lib/gimp/2.0/python/gimpfu.py", line 353, in run_script
return apply(function, params)
File "/home/mahvin/.gimp-2.6/plug-ins/XNViewShell.py", line 73, in plugin_main
args = shlex.split(command)
NameError: global name 'shlex' is not defined


oops. Forgot. Add a
import shlex

with the other imports

I'm just duffing so I hope this works, at least well enough for you to figure it out.

-Rob A>

_________________
Image
Fantasy Cartography and Mapping by RobA


Top
 Profile  
 
 Post subject: Re: XNViewShell
PostPosted: Fri Jan 07, 2011 10:22 pm  (#30) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 6618
Your new version worked Rob (of course had to change the path back to PF in my case; lol). Thanks a heap. :)

_________________
Lyle

Psalm 109:8

Image


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 274 posts ]  Go to page Previous  1, 2, 3, 4, 5, 6 ... 28  Next

All times are UTC - 5 hours [ DST ]


Who is online

Users browsing this forum: sallyanne and 6 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  

* Login  

* Subscribe to Gimp Chat's RSS Feed    * Subscribe to Gimp Chat's Tutorial Feed    * Subscribe to Gimp Chat's G'MIC Feed


Powered by phpBB3 © phpBB Group