title: Converting 0xFF to RGB value
body: <p>I have a snippet of code I am using for a Java application, I am trying to replace the hex value of 0xFF which equals blue to a different color preferably represented by an RGB value, is this possible?</p>
  
  <pre><code>void trailBlurEffect(int blendAmount, PGraphics buffer) {
     for (int i = 0, y = 0; y &lt; buffer.height; y++) {
       for (int x = 0; x &lt; buffer.width; x++, i++) {
         buffer.pixels[i] = 0xff000000 | (( buffer.pixels[i]  &amp; 0xFF) * blendAmount) &gt;&gt; 8;
       }
     }
     nodeBuffer.updatePixels();
  }
  </code></pre>
  
  <p>edit: 
  I am trying to write a different color however I am unable to get a result that works, for example by replacing 0xFF(blue) with the hex equivalent of red which is = 0xFF0000 my canvas draws nothing. My code is coming from this example: openprocessing.org/sketch/52388 </p>