title: Extract Object properties for use in an array
body: <p>I have a JSON string with some values that I unserialized into an object (STDClass/Object).</p>
  
  <p>There are a couple of values in it, but I have to extract exactly 8 of those values into an multidimensional array. This snippet shows the values I'm after as they existed in the JSON:</p>
  
  <pre><code>"picture1":"path/to/image/picture1.jpg"
  "picture1_color":"#000000"
  "picture2":"path/to/image/picture2.jpg"
  "picture2_color":"#111111"
  "picture3":"path/to/image/picture3.jpg"
  "picture3_color":"#222222"
  "picture4":"path/to/image/picture4.jpg"
  "picture4_color":"#333333"
  </code></pre>
  
  <p>I want to extract these values and put them into an array like this:</p>
  
  <pre><code>Array
  (
      [0] =&gt; Array
          (
              [picture] =&gt; path/to/image/picture1.jpg
              [color] =&gt; #000000
          )
  
      [1] =&gt; Array
          (
              [picture] =&gt; path/to/image/picture2.jpg
              [color] =&gt; #111111
          )
  
  and so forth
  
  
  )
  </code></pre>
  
  <p>Is this doable programmatically or do I just need to do it by hand?</p>