You will just have to call get_children() for each gallery:
$images = array();
foreach ( $gallery_posts as $gallery ) {
$images = array_merge( $images, get_children(
'post_parent' => $gallery->ID,
...
) );
}
You will just have to call get_children() for each gallery:
$images = array();
foreach ( $gallery_posts as $gallery ) {
$images = array_merge( $images, get_children(
'post_parent' => $gallery->ID,
...
) );
}