Interesting question, to answer your question in short, many of the seemingly restrictive theocratic laws and dogmatic tendencies we see in contemporary Iran were not a normality in the various post-Islamic entities of Iran. Within Islamic principles, the depiction of the various Prophets, of God, religious entities and the Prophet's descendants or close disciples is often prohibited. However, global Islamic art depicted the human form in full, though subjective and provocative imagery was relevant to individual polities.
The images you have tagged are of Safavid and Qajar era artistic expressions. With the adoption of the Twelver Jafari School of Shia Islam by the Safavid Dynasty (to rival Ottoman Sunni Islam, as the title of Caliph was adopted by the Sultans), a wedge was formed between Iranian dogma and the Sunni standards. Many Imams were depicted in full within frescos, and paintings and textiles.
Within this time period, the gun-powder empires were much more culturally progressive than mainstream outlook credits them. Portrayals of adultery and drinking among other things, were well-established in Safavid Persia. This was also evident in Ottoman Turkey, where pederasty led to the decriminalization of homosexuality in 1858.
From the late 13th century, Persia experienced a rise in a new class of potential nobility that would absorbed a segment of national corruption and administrative control, which was the Mullahs. This class of clergy that adhered to dogmatic rule by using theocratic elements to pressure the monarchy was periodically sustained from the Safavid dynasty, Afsharid, Qajar and the Pahlavi dynasty (despite secularist pressures). Different ideologues of this class held different views on culture, art and tradition. Hardliners did in fact exist, and at times were behind culture-depressions in Persia. Though, for the most part, the nobility class in Iran retained progressive liberties that seem contradictory to contemporary Islam.
The first image is from 1627, Its titled: 'Shah Abbas and his Page Boy' and references Muhammad Qasim’s painting of the Safavid Shah Abbas I . Arguably, the greatest Safavid Shah. He was behind a cultural rejuvenation and the urbanization and development of Esfahan, moving the capital there. In Qasim’s painting, the ruler is depicted with loving sensitivity towards a young cup bearer who offers him wine, a gesture certainly made in privacy.
The second and third photo are of the Qajar era. The third depicts Fath Ali Shah Qajar.
Painted by Mihr 'Ali, one of the great royal painters of the Persian court during the reign of Fath Ali, and is regarded as the most notable Persian portraitist of the early part of this reign. He was also commissioned by the Royal court to paint depictions of the Shahnameh and foreign historic figures.
Traditional Qajar painting was greatly influenced by the Safavid empire. During this time, there was a great deal of European influence on Persian culture, especially in the arts of the royalty and noble classes.
European art was undergoing a period of realism and Qajar art would take a turn with Naser al-din Shah. The European influence is very well evidenced in the prestige of oil painting. Before the appeal to oil paintings, Iranian art was mainly in the form of miniatures.
Qajar art emphasized the suggestive depiction of women. With a gradually increasing Islamic influence, it seems to contradict that view that the women of Qajar Persia are depicted in much art as wearing very little. This is strikingly at odds with the prevalent use of the veil, which by the reign of Ahmad Shah was a broad norm in Persian society.
This would once again be overturned with the Pahlavi reemergence of European elements and Western cultural influences as well as the sequential laws on clothing, such as the "Unveiling Decree" and the "law of dress-codes" involving the introduction of the Pahlavi Hat and later Fedora.
Sources: