(a) This section applies to the following:
(1) criminal or civil court proceedings relating to an offense under:
(A) Section 21.02, 21.11, 21.15, 22.011, 22.012, or 22.021, Penal Code;
(B) Section 20A.02(a)(3), (4), (7), or (8), Penal Code; or
(C) Section 20A.03, Penal Code, if the offense is based partly or wholly on conduct that constitutes an offense described by Paragraph (B); and
(2) court proceedings relating to:
(A) a protective order under Chapter 7B, Code of Criminal Procedure;
(B) a magistrate's order for emergency protection issued under Article 17.292, Code of Criminal Procedure;
(C) a protective order issued under Section 6.504, Family Code; or
(D) a protective order issued under Chapter 85, Family Code.
(b) A court may not allow the electronic transmission or broadcasting of court proceedings described by Subsection (a) in which evidence or testimony is offered that depicts or describes acts of a sexual nature unless the court provides notice to and receives express consent for the transmission or broadcasting from:
(1) the victim or the parent, conservator, or guardian of the victim, as applicable;
(2) the attorney representing the state; and
(3) the defendant.