Files
__mahjong/components/render/ios/renderAux.swift
T
2026-10-28 17:10:05 +03:00

13 lines
343 B
Swift

import UIKit
func renderDraw(_ vm: RenderVM) {
raybriRender(vm.pixelSize[0], vm.pixelSize[1])
}
func renderPixelSize(_ view: UIView) -> [Int32] {
let scale = view.contentScaleFactor
let w = Int32(max(1, (view.bounds.width * scale).rounded()))
let h = Int32(max(1, (view.bounds.height * scale).rounded()))
return [w, h]
}