mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-04-21 21:05:50 +12:00
use proper primitive types
This commit is contained in:
parent
b220c163e3
commit
a08d61ad46
2 changed files with 14 additions and 1 deletions
|
@ -97,4 +97,17 @@ inline MTL::StencilOperation toMTLStencilOperation(u8 op) {
|
|||
return MTL::StencilOperationKeep;
|
||||
}
|
||||
|
||||
inline MTL::PrimitiveType toMTLPrimitiveType(PrimType primType) {
|
||||
switch (primType) {
|
||||
case PrimType::TriangleList: return MTL::PrimitiveTypeTriangle;
|
||||
case PrimType::TriangleStrip: return MTL::PrimitiveTypeTriangleStrip;
|
||||
case PrimType::TriangleFan:
|
||||
Helpers::warn("Triangle fans are not supported on Metal, using triangles instead");
|
||||
return MTL::PrimitiveTypeTriangle;
|
||||
case PrimType::GeometryPrimitive:
|
||||
Helpers::warn("Geometry primitives are not yet, using triangles instead");
|
||||
return MTL::PrimitiveTypeTriangle;
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace PICA
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue