We compute the prompt photon production by gluon fusion and the v2 harmonic coefficient for a the magnetized medium created in heavy-ion collisions. Our calculation is based in the existence of very intense magnetic fields at the early times of the collisions which varies from 1 to 3 times pion mass squared, and open new channels to the photon production. Our calculation take into account several parameters which are relevant to the description of the experimental transverse momentum distribution, and elliptic flow for RHIC and LHC energies. Also, the high occupation number for gluons and the saturation scale are included as well as the flux velocity and geometrical factors. The results are compared with data from PHENIX, and recent hidrodynamical models.