Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Create strip from image sequence

Participant ,
Oct 02, 2008 Oct 02, 2008
I need a script or action, or droplet or something that will take a folder of images and create One Image strip from it. Basically I have animations I have rendered out as frames that I need to put in a game. The game needs the images in one file with all the images side by side (or on top of each other I think) The frames are all one size (but different for each sequence) It takes about 4 hours for me to do this now. And then if it has to change it's four more hours...

Any thoughts idease or techniques?

C
TOPICS
Actions and scripting
21.1K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe
New Here ,
Feb 05, 2009 Feb 05, 2009
The recursive function is working great though... it seems to chew through the whole directory structure of nested folders. This is more power than I need even now, as I only needed one subfolder level, but this should be useful to other people too...

just need to move the output files up one level in the dir structure and we are golden!
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Valorous Hero ,
Feb 05, 2009 Feb 05, 2009
Seeing as it is a sorted list of foldernames it should be the top level folder, doesn't it work like that for you?
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 05, 2009 Feb 05, 2009
Yes I have:

Parent (SelectedFolder)
sub1
sub2
sub3

etc.

It is putting all output files into sub1.

I would like them all in Parent for my purposes.

(though for deep recusion, your first method may be best, and safest. i.e. put the output file in the containing source subfolder...)
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 05, 2009 Feb 05, 2009
BTW, you could also maybe try another method to retain relative PNG position:

1 add alpha chanel
2 select all of alpha chanel
3 fill
4 process
5 delete alpha chanel

this should allow vert or hor strips, as well as arrays, whereas my suggested method requires editing for hor, and will not work with arrays...

I think the above should work... i have not tested it, as I now have what I need for my purposes...
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Valorous Hero ,
Feb 05, 2009 Feb 05, 2009
Mmmm if you change that line to;
saveFile = new File(imageFolder+'/'+saveFile+'.png');
then that is the selected folder, hopefully.
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 05, 2009 Feb 05, 2009
yup. perfect!!!!!!

Thank you so much!
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 05, 2009 Feb 05, 2009
It will now go though an infinitely deep folder structure, and output all resulting files to the top level of that selected structure....

very nice.
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Valorous Hero ,
Feb 05, 2009 Feb 05, 2009
We got there in the end.
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jun 08, 2010 Jun 08, 2010
LATEST

"

app.preferences.rulerUnits = Units.PIXELS;
app.preferences.typeUnits = TypeUnits.PIXELS;
selectedFolder = Folder.selectDialog( "Please select input folder");
var fileList = selectedFolder.getFiles();
for(var aFile = 0; aFile<fileList.length;aFile++) {
     var file = fileList[aFile];
     if(file instanceof File && file.name.match(/\.(jpg|tif|gif|png)$/i)){
          open(file);
          var Width =activeDocument.width.value;
          var Height =activeDocument.height.value;
          activeDocument.resizeCanvas(Width+2, Height, AnchorPosition.MIDDLECENTER);
          var Width =activeDocument.width.value;
          var Height =activeDocument.height.value;
          var fillColor = new SolidColor;
          fillColor.rgb.hexValue = '000000';
          activeDocument.selection.select([[0,0],[1,0],[1,Height],[0,Height]], SelectionType.REPLACE, 0, false);
          activeDocument.selection.fill(fillColor, ColorBlendMode.NORMAL, 100, false );
          activeDocument.selection.deselect();
          activeDocument.selection.select([[(Width-1),0],[Width,0],[Width,Height],[(Width-1),Height]], SelectionType.REPLACE, 0, false);
          activeDocument.selection.fill(fillColor, ColorBlendMode.NORMAL, 100, false );
          activeDocument.selection.deselect();
          if(documents.length > 1){
               activeDocument.selection.selectAll();
               activeDocument.selection.copy();
               activeDocument.close(SaveOptions.DONOTSAVECHANGES);
               activeDocument = documents[0];
               app.activeDocument.resizeCanvas(app.activeDocument.width,app.activeDocument.height+Height, AnchorPosition.TOPCENTER);
               activeDocument.paste();
               activeDocument.selection.selectAll();
               align('AdBt');
               app.activeDocument.selection.deselect();
               activeDocument.mergeVisibleLayers();
          }
    }else{
         continue;
    }
}
var Width =activeDocument.width.value;
var Height =activeDocument.height.value;
activeDocument.resizeCanvas(Width-2, Height, AnchorPosition.MIDDLECENTER);
function align(method) {
    var desc = new ActionDescriptor();
    var ref = new ActionReference();
    ref.putEnumerated( charIDToTypeID( "Lyr " ), charIDToTypeID( "Ordn" ), charIDToTypeID( "Trgt" ) );
    desc.putReference( charIDToTypeID( "null" ), ref );
    desc.putEnumerated( charIDToTypeID( "Usng" ), charIDToTypeID( "ADSt" ), charIDToTypeID( method ) );
    executeAction( charIDToTypeID( "Algn" ), desc, DialogModes.NO );
};

"

is what andrew means.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines