not quite sure if i completly understand what you are trying to do, but from what i gather.......
in photoshop i would go to: Select/Color Range and then click on the colors you either want to keep or get rid of, play with the "fuzziness" untill you get as smoove of lines as you can.
once done with that you should see the color you chose highlighted with the dotted line. Either delete the unwanted part or copy the wanted part and your done!
TIP: if you selected the opposite of what you wanted you can hit ctrl+i and it will invert the selection
Hope that helps. If im way off post a pic and tell me what you want it to look like and i will see what i can do