The soundbar is primarily intended for the TV/projector and is connected via the eARC (enhanced Audio Return Channel), which transmits the sound from the TV to the Sonos Arc Ultra. This means that the DVD/CD player is connected to the TV via HDMI, as is the soundbar.
It would also be possible via an AV receiver (additional device for processing various input sources) if your TV/projector does not support eARC.