How to vary post loop results layout and resume?

  1. How do I get a WP_Query object containing the next five posts? :
// $query is the original WP_Query object.

$five_posts = new WP_Query();
$five_posts->posts = array_slice(
                            $query->posts, 
                            $query->current_position, 
                            $query->current_position + 5
                        );

  1. How do I then elegantly resume the standard-layout loop output at the right place? :
/* Sum the count of all the posts you displayed with your showcase function. 

In this case they were 5, so by setting the current position to 18, the next loop iteration will 
display the post 19. */


$query->current_post += 5;
  1. How do I do this at regular intervals?:
$simple_posts_layout = 12;
$showcase_posts_layout = 5;

foreach(array_chunk($query->posts, $single_posts_layout + $showcase_posts_layout) as $chunk){
   foreach($chunk as $key => $post){
       if($key == $simple_posts_layout - 1){
           display_showcase_posts($five_posts);
           $query->current_position += $showcase_posts_layout;
           break;
       }
      $posts->the_post();
      // ... the rest of your template.
   }
}

I haven’t tested the code so there might be errors, but something like this should work.