Different result in Scripting |Run Scripts than run from CTB

Things you’d like to miss in the future...
Forum rules
You might want to read this if you're looking for priority service

:info: Please Include The Following Information
1) Your XYplorer Version (e.g., v28.00.0801)
2) Your Windows Version (e.g., Win 11)
3) Your Screen Scaling Percentage (e.g., 125%).

:info: Use Your Profile Or Signature
We strongly recommend adding your Windows Version and Screen Scaling Percentage to the Location field in your Profile or to your Signature. That way, you only have to type them once, and we won't have to search for that vital information.

:info: How To Attach Images
When attaching an Image, please use the Attachment tab at the bottom of your post and click "Add files".
admin
Site Admin
Posts: 67283
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Different result in Scripting |Run Scripts than run from

Post by admin »

klownboy wrote:Don, are those the same values you came out with for the image I sent? I can't ask anyone else since they don't have the picture. So why would the codec affect the script running in one situation and not the other?
Yes.

Why does the impossible happen? Don't know. :)

klownboy
Posts: 4481
Joined: 28 Feb 2012 19:27
Location: Windows 11, 25H2 Build 26200.8737 at 100% 2560x1440

Re: Different result in Scripting |Run Scripts than run from

Post by klownboy »

Thanks Don, good to know I'm back to getting the same values I had previously and they're the same as yours. I may mention the issue to the author of FastPicureViewer Pro Codec Pack especially since their own viewer doesn't show the image correctly (i.e., their EXIF auto-rotation for this case is incorrect). I wish they would break free the option for EXIF rotation from the decoder itself.

admin
Site Admin
Posts: 67283
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Different result in Scripting |Run Scripts than run from

Post by admin »

It does not explain the difference in script context, does it?

klownboy
Posts: 4481
Joined: 28 Feb 2012 19:27
Location: Windows 11, 25H2 Build 26200.8737 at 100% 2560x1440

Re: Different result in Scripting |Run Scripts than run from

Post by klownboy »

When you say "script context", I assume you mean the behavior/result I experienced that was different in the "Run Scripts" verses the script ran from a CTB. No it doesn't and to be honest that's quite strange. :eh:

admin
Site Admin
Posts: 67283
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Different result in Scripting |Run Scripts than run from

Post by admin »

Yep, that's what I meant. Looking at the source code there simply cannot be any difference (and there is not here). Fascinating.

bdeshi
Posts: 4256
Joined: 12 Mar 2014 17:27
Location: Asteroid B-612
Contact:

Re: Different result in Scripting |Run Scripts than run from

Post by bdeshi »

admin wrote:It does not explain the difference in script context, does it?
Maybe that software has some kind of caching mechanism. Running the script second time on the same file(s) gets orientation info from that cache where it was stored incorrectly (quote below) during first run of script... this theory could've been tested by running the script twice from the same "entry point" (Runscript|ctb)
klownboy wrote:having the Jpeg decoder installed also removed the "Orientation" value for that particular photograph which was "Rotate 270 degrees".
Icon Names | Onyx | Undocumented Commands | xypcre
[ this user is asleep ]

klownboy
Posts: 4481
Joined: 28 Feb 2012 19:27
Location: Windows 11, 25H2 Build 26200.8737 at 100% 2560x1440

Re: Different result in Scripting |Run Scripts than run from

Post by klownboy »

SammaySarkar wrote:Maybe that software has some kind of caching mechanism...
I did run the scripts on not only on that file but other similar files repeatedly from both Run scripts and CTB and never saw any change. It was always consistent results, if you want to call it that, from Run scripts it showed the actual proper portrait dimensions 2592x3888 and ran form CTB always 3888x2592. Now that I've uninstalled that particular codec for JPEG decoding with EXIF rotation, the values are reversed (landscape) but at least they are consistent to both methods and evidently the same as Don's results. And now I can continue updating my Photo Cropper script http://www.xyplorer.com/xyfc/viewtopic. ... per#p78430 I may poke around the FastPictureViewer forum and possibly write to the developer. Thanks.

This quote from the site might have something to do with it.
The FastPictureViewer Codec Pack includes a faster JPEG codec that performs automatic rotation of thumbnails and previews in Windows Explorer, according to EXIF information. We make Windows "EXIF orientation-aware".
I noticed that it does come in 32 and 64 bit flavors hopefully that has nothing to do with it. I know I installed the 64 from here FastPictureViewer Codec Pack

Post Reply