convert selected poly into alpha to control mixture of a mix node

in edit mode , i want to select some random polygons/faces. in node editor (texture editing), how can i convert these selected polys/faces into mask, to feed into ‘fac’ parameter of a mix node ? or in other word, to convert selected polys to alpha to control the mixture of a mix node.

Use vertex colors. Select the polys you want, then enter vertex paint mode. Press M to utilize your selection from edit mode, then shift K to fill those faces with your current brush color (White). Ctrl I to invert face selection, change brush color to something else (Black) and shift K to fill those.

Then simply use the vertex colors in the node editor. Cycles will have the vert colors accessible as the top menu option in Inputs. BI will have the vert colors attached to the Geometry node, under Inputs.

Great !!! it works perfectly. Thanks a lot.