A transparent polymer rod containing a dopant with high refractive index was prepared by bulk-radical polymerization. The rod was then placed under compressed carbon dioxide during specific time. Carbon dioxide easily diffused within the rod on account of its good permeability and selectively extracted the dopant out of the rod. Accordingly, a graded-dopant concentration was generated within the rod.