facetype.js icon indicating copy to clipboard operation
facetype.js copied to clipboard

no "unitsPerEm"

Open kelvinwop opened this issue 1 year ago • 2 comments

18dbc473-e0ee-4a46-be7d-32356ec82272:35 Failure loading font http://localhost:3000/fonts/RobotoMonoBold.json; trying fallback TypeError: Cannot read properties of undefined (reading 'unitsPerEm')

kelvinwop avatar Feb 06 '24 08:02 kelvinwop

same issue

isaackogan avatar Oct 25 '24 00:10 isaackogan

If you are using r3f, its no need to convert to json type font, you can use ttf or other file type. for example:

      <Text font={'/fonts/PangMenZhengDaoBiaoTiTiMianFeiBan-2.ttf'} rotation={[-Math.PI / 3, 0, 0  ]} position={[PLANE_WIDTH / 2 - 20 , PHYS_Y + 2, PLANE_HEIGHT / 2 - 5 ]} fontSize={5} color="#fff">123</Text>

siadou avatar Nov 21 '24 05:11 siadou