Merge pull request #495 from tomaka/fix-multisampling

Makes sure that the pixel format has the same multisampling settings as the requirements
This commit is contained in:
tomaka 2015-06-23 16:46:49 +02:00
commit 717ea3d5ba

View file

@ -398,8 +398,15 @@ impl<'a> BuilderAttribs<'a> {
continue;
}
if self.multisampling.is_some() && format.multisampling.is_none() {
continue;
if let Some(req_ms) = self.multisampling {
match format.multisampling {
Some(val) if val >= req_ms => (),
_ => continue
}
} else {
if format.multisampling.is_some() {
continue;
}
}
if let Some(srgb) = self.srgb {