Use texture painting to determine transparent areas
Here's an examples using the painted texture to control the mix between diffuse and transparent shaders on a plane. Areas painted in white will be opaque, black will be transparent.



If you are getting the opposite effect switch the transparent and diffuse nodes. Or add a Color>Invert node between the texture and the Fac input fot the Mix Shader node so that the black areas are opaque and white becomes transparent.

Note that this texture painting controls the transparency only. The texture for the difuse shader has to be a different texture (or image), plugged to the color socket of the shader.



If you are going to paint directly on the 3D viewport make sure that you select the correct paint slot.