I’m on mobile too, I’ll post a code example later.
GraphicsDeviceManager has an event PreparingDeviceSettings that is raised whenever a GraphicsDevice is created or when ApplyChanges is called on the GDM. The event argument contains a GraphicsDeviceInformation instance which has a PresentationParameters property. Basically the event allows you to modify the PresentationParameters before they’re passed to the GraphicsDevice. So you can use that to set the MS count.
I’m in favor of replacing the PreferMultisampling property in GDM with a MultisampleCount property though.
Sample code:
GraphicsDeviceManager graphics;
public Game1()
{
graphics = new GraphicsDeviceManager(this);
graphics.PreparingDeviceSettings += SetMultiSampling;
}
private void SetMultiSampling(object sender, PreparingDeviceSettingsEventArgs e)
{
var pp = e.GraphicsDeviceInformation.PresentationParameters;
pp.MultiSampleCount = 4;
}