I i want to apply a custom text like a "grid" to a Plane Entity in RealityKit but I can't find the updated solution. so far I have try this code:
func createBoard() {
let planeMesh = MeshResource.generatePlane(width: 1,
height: 1,
cornerRadius: 0.2)
var myMaterial = SimpleMaterial()
myMaterial.baseColor = try! .texture(.load(named: "texture.png"))
//'baseColor' was deprecated in iOS 15.0: use `color` property instead
myMaterial.metallic = MaterialScalarParameter(floatLiteral: 0.5)
myMaterial.roughness = MaterialScalarParameter(floatLiteral: 0.5)
myMaterial.tintColor = UIColor.blue
//'tintColor' was deprecated in iOS 15.0: use `color` property instead
let modelEntity = ModelEntity(mesh: planeMesh, materials: [myMaterial])
}
But I'm getting the warning that base color and tintcolor are deprecated on iOS 15, I can't find the way to correct this issue.
Thanks for the help.