This is Interesting: Free Magazines for Graphics designers and webmasters  


Home > Archive > PainShop Pro Scripting > June 2006 > SmartPhotoFix





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author SmartPhotoFix
Rick Thornquist

2006-06-27, 9:08 pm

All -

I'm trying to use SmartPhotoFix is a script and it's not working for me.=
=

I hope somebody can help me here.

I generated a script using the script recorder. I brought up the Smart =
=

Photo Fix dialog, changed some settings, and then clicked OK. The probl=
em =

is when I execute the script it doesn't recognize the settings that I =

changed - it just reverts to the defaults. The settings are in the =

script, they are just not taking. I've used other functions in the same=
=

way, resize for example, and it takes the settings. Smart Photo Fix =

doesn't seem to want to do it.

Here's the script that was generated:

from PSPApp import *

def ScriptProperties():
return {
'Author': u'',
'Copyright': u'',
'Description': u'',
'Host': u'Paint Shop Pro X',
'Host Version': u'10.02'
}

def Do(Environment):
# EnableOptimizedScriptUndo
App.Do( Environment, 'EnableOptimizedScriptUndo', {
'GeneralSettings': {
'ExecutionMode': App.Constants.ExecutionMode.Default,
'AutoActionMode': App.Constants.AutoActionMode.Match,
'Version': ((10,0,2),1)
}
})

# SmartPhotoFix
App.Do( Environment, 'SmartPhotoFix', {
'UseGreyBalance': False,
'GreyBalanceSampleList': [
],
'BlackPoint': 1,
'WhitePoint': 91,
'Highlights': -15,
'Brightness': 30,
'Shadows': 15,
'Saturation': -15,
'Sharpness': 75,
'GeneralSettings': {
'ExecutionMode': App.Constants.ExecutionMode.Default,
'AutoActionMode': App.Constants.AutoActionMode.Match,
'Version': ((10,0,2),1)
}
})

If someone could tell me what I'm doing wrong, I'd appreciate it!

- Rick
Spandex Rutabaga

2006-06-27, 9:08 pm

Rick Thornquist wrote:
>
> All -
>
> I'm trying to use SmartPhotoFix is a script and it's not working for me.
> I hope somebody can help me here.
>
> I generated a script using the script recorder. I brought up the Smart
> Photo Fix dialog, changed some settings, and then clicked OK. The problem
> is when I execute the script it doesn't recognize the settings that I
> changed - it just reverts to the defaults. The settings are in the
> script, they are just not taking. I've used other functions in the same
> way, resize for example, and it takes the settings. Smart Photo Fix
> doesn't seem to want to do it.


> If someone could tell me what I'm doing wrong, I'd appreciate it!


Perhaps you aren't doing anything wrong. It's possible that the
"smart" part of Smart Photo Fix is that it always knows better
than you what you want and picks settings somehow adapted to the
image. I don't have PSP X so I can't check anything. However, did
you have Advance Options checked when you recorded the script? (I
can't see a command parameter that would correspond to this checkbox
though.) One other thing. In my newsreader the script you posted
shows an italicized closing square bracket on the line after the
one with GreyBalanceSampleList.
Rick Thornquist

2006-06-27, 9:08 pm

On Thu, 15 Jun 2006 12:14:52 -0700, Joske <j.backer@home.nl> wrote:

> The trick would be to connect the names above to those in the Smart
> Photo Fix dialog, and then manually edit those numbers behind them
> in your script. I think Sharpness is easy, that has to be Focus.
> Same for Shadows, Highlights, and Saturation, they have the same
> names as in the dialog.
>
> So if you want Saturation to be 10, just type 10 in the place where
> it now says 15 in your script.
>
> Joske


Joske -

I have changed the numbers already - the numbers in the script are what =
I =

want them to be. The problem is that if I run the script the numbers in=
=

the script don't get used in the function - it uses it's own numbers.

I tried changing the ExecutionMode to Interactive and the numbers in the=
=

script don't populate the dialog box. I tried the same thing with Resiz=
e =

and the numbers in the script DO go into the dialog box. For some reaso=
n, =

it doesn't happen in SmartPhotoFix.

- Rick
Joske

2006-06-27, 9:08 pm

Spandex Rutabaga wrote:
> Rick Thornquist wrote:


[color=darkred]
[color=darkred]
[color=darkred]
[color=darkred]
> Perhaps you aren't doing anything wrong. It's possible that the
> "smart" part of Smart Photo Fix is that it always knows better
> than you what you want and picks settings somehow adapted to the
> image. I don't have PSP X so I can't check anything. However, did
> you have Advance Options checked when you recorded the script? (I
> can't see a command parameter that would correspond to this
> checkbox though.)


Yes, I canceled my initial idea because of course the SPF will
sample... and that will be different for each photo so it will
sample (and come up with different settings) no matter what. I tried
doing it in two steps, the first resetting the SPF to default and
the second really running it, but that doesn't help - with or
without advanced settings.

Joske


Rick Thornquist

2006-06-27, 9:08 pm

On Thu, 15 Jun 2006 12:16:32 -0700, Spandex Rutabaga =

<SpRu@agabatur.xednaps> wrote:

> Perhaps you aren't doing anything wrong. It's possible that the
> "smart" part of Smart Photo Fix is that it always knows better
> than you what you want and picks settings somehow adapted to the
> image. I don't have PSP X so I can't check anything. However, did
> you have Advance Options checked when you recorded the script? (I
> can't see a command parameter that would correspond to this checkbox
> though.)


I'm not using the Advanced Options so that's why I didn't check the box.=
=

The Advanced Options check box doesn't actually have a command parameter=
=

because all the box does is show or hide some additional parameters in t=
he =

dialog box (these additional parameters are the UseGreyBalance, =

GreyBalanceSampleList, BlackPoint, WhitePoint parameters, which are in t=
he =

script).

Just in case I tried checking the box and it generated exactly the same =
=

script as before.

> One other thing. In my newsreader the script you posted
> shows an italicized closing square bracket on the line after the
> one with GreyBalanceSampleList.


Strange, it doesn't show up for me. The text in my editor and elsewhere=
=

isn't italicized.

- Rick
Joske

2006-06-27, 9:08 pm

Rick Thornquist wrote:
> Joske wrote:


[color=darkred]
[color=darkred]
> I have changed the numbers already - the numbers in the script
> are what I want them to be. The problem is that if I run the
> script the numbers in the script don't get used in the function -
> it uses it's own numbers.


> I tried changing the ExecutionMode to Interactive and the numbers
> in the script don't populate the dialog box. I tried the same
> thing with Resize and the numbers in the script DO go into the
> dialog box. For some reason, it doesn't happen in SmartPhotoFix.


See my reply to Spandex. I don't think this will work. I just looked
at the original (it's in Paint Shop Pro
X\Scripts-Restricted\File-Open) and cannot divine any further
knowledge from it at this short notice. You could rename it (and
move it) and then experiment with its settings yourself, though I
don't see what good this would do.

Joske



Joske

2006-06-27, 9:08 pm

underprocessable
JoeB

2006-06-27, 9:08 pm

"Rick Thornquist" <rickthornquist@XXXXXXXXXX> wrote in
news:op.ta7crienafmftc@dellxps600.vc.shawcable.net:

> On Thu, 15 Jun 2006 12:16:32 -0700, Spandex Rutabaga
> <SpRu@agabatur.xednaps> wrote:
>


>
> Strange, it doesn't show up for me. The text in my editor and
> elsewhere isn't italicized.
>
> - Rick


Not necessarily strange, as newsreaders don't always render things
correctly. It shows up fine in my newsreader, and in any event the
script will contain what you see in your text editor, so it isn't
anything to be concerned about.

Regards,

JoeB
JoeB

2006-06-27, 9:08 pm

"Joske" <j.backer@home.nl> wrote in news:4491de99_2@cnews:

> Rick Thornquist wrote:
>
>
> I created a preset in SPF and then recorded a script using the
> preset. I have no idea how, but as you can tell by the combined
> screenshots, using a preset does influence the outcome. Maybe
> someone can shed some light on the Preset, which is also a script
> and can be found in your Presets folder.
>
> Anyway, it gave me this idea which I hope is correct: you can run
> this preset script on an image - it should be possible to edit it
> and put in in your regular Scripts-Restricted folder.
>
> Joske


While I'm not the OP, I've been following the thread just as a
learning experience and gotta say that you did great work coming up
with that idea!

Regards,

JoeB
Spandex Rutabaga

2006-06-27, 9:08 pm

Rick Thornquist wrote:

> I tried changing the ExecutionMode to Interactive and the numbers in the
> script don't populate the dialog box.


It's because it's "smart" and doesn't listen to "insufficiently
smart" users :)

> I tried the same thing with Resize
> and the numbers in the script DO go into the dialog box.


It's because it is an ordinary command and isn't "smart".

> For some reason,
> it doesn't happen in SmartPhotoFix.


Use Joske's idea of loading a saved preset with the numbers you
want. I wish I had been "smart" enough to think of that but I was
"insufficiently smart" :) Other adaptive filters such as Digital
Camera Noise Removal have a checkbox (Camera Preset) to determine
whether a preset runs adaptively or not. Apparently SPF runs
adaptively from a script and non-adaptively from a preset (even
though a preset is a kind of script :)
Rick Thornquist

2006-06-27, 9:08 pm

On Thu, 15 Jun 2006 15:31:07 -0700, Joske <j.backer@home.nl> wrote:

> Anyway, it gave me this idea which I hope is correct: you can run
> this preset script on an image - it should be possible to edit it
> and put in in your regular Scripts-Restricted folder.


I tried creating a preset and checked out the script it created - it's =

pretty much the same as the script I created by changing the parameters.=
=

Then I recorded a script and selected the preset. Tt just save the =

parameters - it doesn't save the fact that I used a preset.

I'm not quite sure what you mean. Do you mean calling the preset script=
=

from my own script? How would I do that?

- Rick




Joske

2006-06-27, 9:08 pm

underprocessable
Rick Thornquist

2006-06-27, 9:08 pm

On Fri, 16 Jun 2006 08:35:20 -0700, Joske <j.backer@home.nl> wrote:

Joske -

> If I were you, I would record as many of the steps in PSF as you can =


> find in other (older) tools instead.


A very good idea! Thanks for the tip.

I hope Corel is listening to this and offers up a fix for the Smart Phot=
o =

Fix problem .

- Rick
Spandex Rutabaga

2006-06-27, 9:08 pm

Rick Thornquist wrote:

> I hope Corel is listening to this and offers up a fix for the Smart Photo
> Fix problem .


They aren't. You might get them to pay heed if you use the E-mail
Corel link here http://support.corel.com.
Sponsored Links


Copyright 2003 - 2009 forum4designers.com  Software forum  Computer Hardware reviews