TextureSettings.fromJsonFile constructor

TextureSettings.fromJsonFile(
  1. Map<String, dynamic> json
)

Creates texture settings from a JSON map.

Throws TypeError if required fields are missing or have wrong types.

Implementation

TextureSettings.fromJsonFile(Map<String, dynamic> json)
  : width = _requireInt(json, 'width'),
    height = _requireInt(json, 'height');