The present invention relates to a method of shaping a fibrous material and treatment compositions therefor. The method comprises providing a treatment composition comprising an active agent and a photocatalyst, applying the treatment composition to the fibrous material to form a treated fibrous material, mechanically shaping the treated fibrous material, and exposing the treated fibrous material to electromagnetic radiation. The treatment composition comprises an active agent, wherein the active agent comprises a high-polarity functional group, preferably selected from the group consisting of hydroxyl groups, carboxylic acid groups, and combinations thereof and a photocatalyst.