getFbxVersion function

dynamic getFbxVersion(
  1. dynamic text
)

Implementation

getFbxVersion( text ) {

	var versionRegExp = RegExp(r"FBXVersion: (\d+)");
	var match = versionRegExp.firstMatch(text);

	if ( versionRegExp.hasMatch(text) ) {

		var version = int.parse( match!.group(1)! );
		return version;

	}

	throw( 'THREE.FBXLoader: Cannot find the version number for the file given.' );

}