Of course it’s possible - here’s a quick example
// This is a stand-in for your small bitmap you want to position
// using an 8x8 pixel yellow square for testing purposes
var smallBmp:BitmapData = new BitmapData(8, 8, true, 0xFFFF00FF);
// Define the size of the individual frames
var frameWidth:int = 64, frameHeight:int = 64;
// Number of frames
var numFrames:int = 10;
// Number of little objects per frame
var itemsPerFrame:int = 8;
// Create stage bitmap
var largeBmp:BitmapData = new BitmapData(numFrames * frameWidth, frameHeight, true, 0);
// Some variables
var iFrame:int; // current frame index
var iItem:int; // current item index
// For each frame...
for (iFrame = 0; iFrame < numFrames; iFrame++) {
// For each item to place
for (iItem = 0; iItem < numItems; iItem++) {
// We're going to select the x and y positions randomly among the available space
// but bias the y positions based on frame index
FP.point.x = FP.rand(frameWidth - itemWidth) + frameWidth * iFrame;
FP.point.y = (iFrame * itemHeight / (numFrames-1)) + FP.random * FP.random * FP.random * frameHeight;
FP.point.y = FP.clamp(FP.point.y, 0, frameHeight - itemHeight);
// Stick the small bitmap inside the frame
largeBmp.copyPixels(smallBmp, smallBmp.rect, FP.point);
}
}
// All the frames are generated, we can create a spritemap
var spritemap:Spritemap = new Spritemap(largeBmp, frameWidth, frameHeight);
// do something with the spritemap