Jump to content
You must now use your email address to sign in [click for more info] ×

Search the Community

Showing results for tags '1000 x 1000'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Affinity Support
    • News and Information
    • Frequently Asked Questions
    • Affinity Support & Questions
    • Feedback & Suggestions
  • Learn and Share
    • Tutorials (Serif and Customer Created Tutorials)
    • Share your work
    • Resources
  • Bug Reporting
    • V2 Bugs found on macOS
    • V2 Bugs found on Windows
    • V2 Bugs found on iPad
    • Reports of Bugs in Affinity Version 1 applications
  • Beta Software Forums
    • 2.4 New Features and Improvements
    • Other New Bugs and Issues in the Betas
    • Beta Software Program Members Area
    • [ARCHIVE] Reports from earlier Affinity betas

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


Location


Interests


Member Title

Found 1 result

  1. Good Morning All! I am currently attempting to find a replacement for Adobe Fireworks as the business I'm employed by would like to move away from the costs involved with Adobe. We have narrowed it down to Affinity Photo as a necessity to have for the batch function but also a luxury to have the Photoshop capabilities to use on the rare occasion. We had some custom scripts written which we imported into Fireworks. I cannot get the same end result with solely the batch process function within Affinity. Below is the script contents that were written for us for Fireworks. Is it possible to automate this inside Affinity? Essentially we want the option point the batch tool to the files to resize multiple photo file formats into 1000 x 1000 72dpi. For example, If the image is 1000 x 500 before batching, we want the batch program to fill out to 1000 x 1000 with the colour white. We no longer require "makeResize" and only "makeLarge" within the script. var theDoc = fw.getDocumentDOM().filePathForRevert; var origFile = Files.getDirectory(theDoc) + '/' + Files.getFilename(theDoc) var newFile = 'file:///C|/batched/'+Files.getFilename(theDoc, true) makeLarge() makeResize(227, 227, '_m') makeResize(75, 75, '_s') makeResize(40, 40, '_t') Files.deleteFileIfExisting(origFile) function makeLarge() { var oldHeight = fw.getDocumentDOM().height; var oldWidth = fw.getDocumentDOM().width; if (oldHeight > oldWidth) { newWidth = 1000 var temp = oldHeight/newWidth newHeight = oldHeight/temp newWidth = oldWidth/temp } else { newHeight = 1000 var temp = oldWidth/newHeight newWidth = oldWidth/temp newHeight = oldHeight/temp } fw.getDocumentDOM().setDocumentImageSize({left:0, top:0, right:newWidth, bottom:newHeight}, {pixelsPerUnit:72, units:"inch"}, true); fw.getDocumentDOM().setDocumentCanvasSize({left:0, top:0, right:1000, bottom:1000}, true); fw.getDocumentDOM().setDocumentCanvasColor("#ffffff", true); fw.getDocumentDOM().selectAll(); fw.getDocumentDOM().align('center vertical', 'true') fw.getDocumentDOM().align('center horizontal', 'true') var theDoc = fw.getDocumentDOM().filePathForRevert; var theFolder = Files.getDirectory(theDoc) var theFilename = Files.getFilename(theDoc, true) var fullPath = theFolder + '/' + theFilename var theExtension = Files.getExtension(theDoc) fw.exportDocumentAs(null, newFile+'_l', ({applyScale:false, colorMode:"24 bit",exportFormat:"JPEG",jpegQuality:80,jpegSmoothness:0,jpegSubsampling:0,name:"JPEG - Better Quality",numEntiresRequested:0,percentScale:"100",useScale:true,xSize:0,ySize:0})) } function makeResize(height, width, ext) { fw.getDocumentDOM().setDocumentImageSize({left:0, top:0, right:height, bottom:width}, {pixelsPerUnit:72, units:"inch"}, true); fw.getDocumentDOM().setDocumentCanvasSize({left:0, top:0, right:height, bottom:width}, true); fw.getDocumentDOM().setDocumentCanvasColor("#ffffff", true); fw.getDocumentDOM().selectAll(); fw.getDocumentDOM().align('center vertical', 'true') fw.getDocumentDOM().align('center horizontal', 'true') var theDoc = fw.getDocumentDOM().filePathForRevert; var theFolder = Files.getDirectory(theDoc) var theFilename = Files.getFilename(theDoc, true) var fullPath = theFolder + '/' + theFilename var theExtension = Files.getExtension(theDoc) fw.exportDocumentAs(null, newFile+ext, ({applyScale:false, colorMode:"24 bit",exportFormat:"JPEG",jpegQuality:80,jpegSmoothness:0,jpegSubsampling:0,name:"JPEG - Better Quality",numEntiresRequested:0,percentScale:"100",useScale:true,xSize:0,ySize:0})) } Convert for Web.jsf
×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.