Compare commits
20 Commits
0.0.3
...
a8f46113d4
Author | SHA1 | Date | |
---|---|---|---|
a8f46113d4 | |||
99736f114d | |||
4d1a008106 | |||
9318cbca4e | |||
a162f345c4 | |||
1af4afc7c6 | |||
a3efe939e8 | |||
5daee1a01a | |||
2d5d305528 | |||
8da46c0511 | |||
75b5d7708c | |||
5b2177a795 | |||
8cb33dca5f | |||
ae2e0af18a | |||
2ac5a3d4f0 | |||
5f78a1afde | |||
ef5cf78a03 | |||
b60e62af70 | |||
3e59fe1462 | |||
4b4bf5ed65 |
@@ -1,19 +1,60 @@
|
||||
using Cryville.Common.Font;
|
||||
using Cryville.Common.Logging;
|
||||
using Cryville.Common.Unity.UI;
|
||||
using Cryville.Culture;
|
||||
using System;
|
||||
using System.Globalization;
|
||||
using System.IO;
|
||||
using System.Text;
|
||||
using System.Xml;
|
||||
using System.Xml.Linq;
|
||||
using UnityEngine;
|
||||
using Logger = Cryville.Common.Logging.Logger;
|
||||
|
||||
namespace Cryville.EEW.Unity {
|
||||
class App {
|
||||
public static string AppDataPath { get; private set; }
|
||||
|
||||
public static Logger MainLogger { get; private set; }
|
||||
static FileStream _logFileStream;
|
||||
static StreamLoggerListener _logWriter;
|
||||
|
||||
static bool _init;
|
||||
public static void Init() {
|
||||
if (_init) return;
|
||||
_init = true;
|
||||
|
||||
AppDataPath = Application.persistentDataPath;
|
||||
|
||||
var logPath = Directory.CreateDirectory(Path.Combine(AppDataPath, "logs"));
|
||||
_logFileStream = new FileStream(
|
||||
Path.Combine(
|
||||
logPath.FullName,
|
||||
string.Format(
|
||||
CultureInfo.InvariantCulture,
|
||||
"{0}.log",
|
||||
DateTimeOffset.UtcNow.ToString("yyyyMMddHHmmssfff", CultureInfo.InvariantCulture)
|
||||
)
|
||||
),
|
||||
FileMode.Create, FileAccess.Write, FileShare.Read
|
||||
);
|
||||
_logWriter = new StreamLoggerListener(_logFileStream) { AutoFlush = true };
|
||||
MainLogger = new Logger();
|
||||
var listener = new InstantLoggerListener();
|
||||
listener.Log += MainLogger.Log;
|
||||
MainLogger.AddListener(_logWriter);
|
||||
Application.logMessageReceivedThreaded += OnInternalLog;
|
||||
|
||||
MainLogger.Log(1, "App", null, "App Version: {0}", Application.version);
|
||||
MainLogger.Log(1, "App", null, "Unity Version: {0}", Application.unityVersion);
|
||||
MainLogger.Log(1, "App", null, "Operating System: {0}, Unity = {1}, Family = {2}", Environment.OSVersion, SystemInfo.operatingSystem, SystemInfo.operatingSystemFamily);
|
||||
MainLogger.Log(1, "App", null, "Platform: Build = {0}, Unity = {1}", PlatformConfig.Name, Application.platform);
|
||||
MainLogger.Log(1, "App", null, "Culture: {0}, UI = {1}, Unity = {2}", SharedCultures.CurrentCulture, SharedCultures.CurrentUICulture, Application.systemLanguage);
|
||||
MainLogger.Log(1, "App", null, "Device: Model = {0}, Type = {1}", SystemInfo.deviceModel, SystemInfo.deviceType);
|
||||
MainLogger.Log(1, "App", null, "Graphics: Name = {0}, Type = {1}, Vendor = {2}, Version = {3}", SystemInfo.graphicsDeviceName, SystemInfo.graphicsDeviceType, SystemInfo.graphicsDeviceVendor, SystemInfo.graphicsDeviceVersion);
|
||||
MainLogger.Log(1, "App", null, "Processor: Count = {0}, Frequency = {1}MHz, Type = {2}", SystemInfo.processorCount, SystemInfo.processorFrequency, SystemInfo.processorType);
|
||||
|
||||
MainLogger.Log(1, "App", null, "Initializing font manager");
|
||||
foreach (var res in Resources.LoadAll<TextAsset>("cldr/common/validity")) {
|
||||
IdValidity.Load(LoadXmlDocument(res));
|
||||
}
|
||||
@@ -25,7 +66,10 @@ namespace Cryville.EEW.Unity {
|
||||
};
|
||||
TMPLocalizedText.DefaultShader = Resources.Load<Shader>(PlatformConfig.TextShader);
|
||||
|
||||
MainLogger.Log(1, "App", null, "Loading config");
|
||||
SharedSettings.Instance.Init();
|
||||
|
||||
MainLogger.Log(1, "App", null, "Initialized");
|
||||
}
|
||||
|
||||
static readonly Encoding _encoding = new UTF8Encoding(false, true);
|
||||
@@ -40,5 +84,16 @@ namespace Cryville.EEW.Unity {
|
||||
using var reader = XmlReader.Create(stream, _xmlSettings);
|
||||
return XDocument.Load(reader);
|
||||
}
|
||||
|
||||
static void OnInternalLog(string condition, string stackTrace, LogType type) {
|
||||
var l = type switch {
|
||||
LogType.Log => 1,
|
||||
LogType.Assert => 2,
|
||||
LogType.Warning => 3,
|
||||
LogType.Error or LogType.Exception => 4,
|
||||
_ => 1,
|
||||
};
|
||||
MainLogger.Log(l, "Internal", null, "{0}\n{1}", condition, stackTrace);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -1,3 +1,3 @@
|
||||
using System.Reflection;
|
||||
|
||||
[assembly: AssemblyVersion("0.0.3")]
|
||||
[assembly: AssemblyVersion("0.0.7")]
|
||||
|
@@ -1,5 +1,9 @@
|
||||
using Cryville.EEW.Core;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.Globalization;
|
||||
using System.Text.Json;
|
||||
using System.Text.Json.Serialization;
|
||||
|
||||
namespace Cryville.EEW.Unity {
|
||||
@@ -8,11 +12,18 @@ namespace Cryville.EEW.Unity {
|
||||
float SeverityColorMappingLuminanceMultiplier,
|
||||
bool UseContinuousColor,
|
||||
string ColorScheme,
|
||||
string LocationNamer,
|
||||
|
||||
string OverrideTimeZone,
|
||||
bool DoDisplayTimeZone,
|
||||
bool DoSwitchBackToHistory,
|
||||
|
||||
string NowcastWarningDelayTolerance,
|
||||
|
||||
string OverrideDisplayCulture,
|
||||
IReadOnlyCollection<TTSCultureConfig> TTSCultures,
|
||||
bool DoIgnoreLanguageVariant,
|
||||
|
||||
IReadOnlyCollection<EventSourceConfig> EventSources
|
||||
) {
|
||||
public static Config Default => new(
|
||||
@@ -20,11 +31,18 @@ namespace Cryville.EEW.Unity {
|
||||
1f,
|
||||
false,
|
||||
"Default",
|
||||
"FERegionLong",
|
||||
|
||||
null,
|
||||
true,
|
||||
true,
|
||||
|
||||
"1:00:00",
|
||||
|
||||
"",
|
||||
new List<TTSCultureConfig> { new(SharedCultures.CurrentUICulture) },
|
||||
true,
|
||||
|
||||
new List<EventSourceConfig> {
|
||||
new JMAAtomEventSourceConfig(Array.Empty<string>()),
|
||||
new UpdateCheckerEventSourceConfig(),
|
||||
@@ -37,6 +55,7 @@ namespace Cryville.EEW.Unity {
|
||||
[JsonDerivedType(typeof(BMKGOpenDataEventSourceConfig), "BMKGOpenData")]
|
||||
[JsonDerivedType(typeof(CWAOpenDataEventSourceConfig), "CWAOpenData")]
|
||||
[JsonDerivedType(typeof(EMSCRealTimeEventSourceConfig), "EMSCRealTime")]
|
||||
[JsonDerivedType(typeof(GeoNetEventSourceConfig), "GeoNet")]
|
||||
[JsonDerivedType(typeof(GlobalQuakeServerEventSourceConfig), "GlobalQuakeServer")]
|
||||
[JsonDerivedType(typeof(GlobalQuakeServer15EventSourceConfig), "GlobalQuakeServer15")]
|
||||
[JsonDerivedType(typeof(JMAAtomEventSourceConfig), "JMAAtom")]
|
||||
@@ -48,15 +67,30 @@ namespace Cryville.EEW.Unity {
|
||||
record BMKGOpenDataEventSourceConfig([property: JsonRequired] string[] Subtypes) : EventSourceConfig;
|
||||
record CWAOpenDataEventSourceConfig([property: JsonRequired] string Subtype, [property: JsonRequired] string Token) : EventSourceConfig;
|
||||
record EMSCRealTimeEventSourceConfig() : EventSourceConfig;
|
||||
record GeoNetEventSourceConfig(int MinimumMMI = 3, bool DoGetFullHistory = false, bool DoGetStrongMotionInfo = true) : EventSourceConfig;
|
||||
record GlobalQuakeServerEventSourceConfig([property: JsonRequired] string Host, int Port = 38000) : EventSourceConfig;
|
||||
record GlobalQuakeServer15EventSourceConfig(string Host, int Port = 38000) : GlobalQuakeServerEventSourceConfig(Host, Port);
|
||||
record JMAAtomEventSourceConfig(IReadOnlyCollection<string> Filter = null, bool IsFilterWhitelist = false) : EventSourceConfig;
|
||||
record NOAAEventSourceConfig([property: JsonRequired] string Subtype) : EventSourceConfig;
|
||||
record UpdateCheckerEventSourceConfig : EventSourceConfig;
|
||||
record USGSQuakeMLEventSourceConfig([property: JsonRequired] string Subtype) : EventSourceConfig;
|
||||
record WolfxEventSourceConfig(IReadOnlyCollection<string> Filter = null, bool IsFilterWhitelist = false) : EventSourceConfig;
|
||||
record WolfxEventSourceConfig(IReadOnlyCollection<string> Filter = null, bool IsFilterWhitelist = false, bool UseRawCENCLocationName = false) : EventSourceConfig;
|
||||
|
||||
[JsonSerializable(typeof(Config))]
|
||||
[JsonSourceGenerationOptions(WriteIndented = true)]
|
||||
[JsonSourceGenerationOptions(Converters = new Type[] { typeof(CultureInfoConverter) }, WriteIndented = true)]
|
||||
sealed partial class ConfigSerializationContext : JsonSerializerContext { }
|
||||
|
||||
sealed class CultureInfoConverter : JsonConverter<CultureInfo> {
|
||||
public override CultureInfo Read(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options) {
|
||||
Debug.Assert(typeToConvert == typeof(CultureInfo));
|
||||
var value = reader.GetString();
|
||||
if (value == null) return CultureInfo.InvariantCulture;
|
||||
if (value == "") return SharedCultures.CurrentUICulture;
|
||||
return SharedCultures.Get(value);
|
||||
}
|
||||
|
||||
public override void Write(Utf8JsonWriter writer, CultureInfo value, JsonSerializerOptions options) {
|
||||
writer.WriteStringValue(value.Name);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -3,6 +3,7 @@
|
||||
"rootNamespace": "",
|
||||
"references": [
|
||||
"GUID:b92f9c7ac10b1c04e86fc48210f62ab1",
|
||||
"GUID:1e0937e40dadba24a97b7342c4559580",
|
||||
"GUID:e5b7e7f40a80a814ba706299d68f9213",
|
||||
"GUID:da293eebbcb9a4947a212534c52d1a32"
|
||||
],
|
||||
|
@@ -17,19 +17,24 @@ namespace Cryville.EEW.Unity.Map {
|
||||
GameObject m_prefabTile;
|
||||
[SerializeField]
|
||||
GameObject m_prefabBitmapHolder;
|
||||
[SerializeField]
|
||||
int m_maxMapTileZoom = 10;
|
||||
[SerializeField]
|
||||
bool m_isEditor;
|
||||
|
||||
readonly MapTileCacheManager _tiles = new();
|
||||
MapTileCacheManager _tiles;
|
||||
float _elementLayerZ;
|
||||
|
||||
void Start() {
|
||||
_camera = GetComponent<Camera>();
|
||||
_tiles = m_isEditor ? new EditorMapTileCacheManager() : new MapTileCacheManager();
|
||||
_tiles.ExtraCachedZoomLevel = 20;
|
||||
_tiles.Parent = m_layerTile;
|
||||
_tiles.PrefabTile = m_prefabTile;
|
||||
_tiles.PrefabBitmapHolder = m_prefabBitmapHolder;
|
||||
_tiles.CacheDir = Application.temporaryCachePath;
|
||||
_camera.orthographicSize = 0.5f / MathF.Max(1, (float)_camera.pixelWidth / _camera.pixelHeight);
|
||||
_elementLayerZ = m_layerElement.transform.position.z;
|
||||
if (m_layerElement != null) _elementLayerZ = m_layerElement.transform.position.z;
|
||||
_mapElementUpdated = true;
|
||||
}
|
||||
void OnDestroy() {
|
||||
@@ -74,7 +79,7 @@ namespace Cryville.EEW.Unity.Map {
|
||||
}
|
||||
}
|
||||
void ZoomToMapElement() {
|
||||
var aabb = m_layerElement.AABB;
|
||||
var aabb = m_layerElement != null ? m_layerElement.AABB : null;
|
||||
if (aabb is not RectangleF b) return;
|
||||
if (b.Width * _camera.pixelHeight < _camera.pixelWidth * b.Height)
|
||||
Scale = b.Height;
|
||||
@@ -97,26 +102,30 @@ namespace Cryville.EEW.Unity.Map {
|
||||
transform.localPosition = new(nx, Math.Clamp(transform.position.y, h / 2 - 1, -h / 2), -20);
|
||||
|
||||
var bounds = new Bounds((Vector2)transform.position, new Vector2(w, h));
|
||||
int zoom = Math.Clamp((int)Math.Log(vz / 256, 2) + 1, 0, 10);
|
||||
int zoom = Math.Clamp((int)Math.Log(vz / 256, 2) + 1, 0, m_maxMapTileZoom);
|
||||
int zoomScale = 1 << zoom;
|
||||
_tiles.MoveTo(
|
||||
new(Mathf.FloorToInt(bounds.min.x * zoomScale), Mathf.FloorToInt(-bounds.max.y * zoomScale), zoom),
|
||||
new(Mathf.CeilToInt(bounds.max.x * zoomScale), Mathf.CeilToInt(-bounds.min.y * zoomScale), zoom)
|
||||
);
|
||||
|
||||
m_layerElement.Scale = h;
|
||||
m_layerElementSub.Scale = h;
|
||||
if (m_layerElement != null) {
|
||||
m_layerElement.Scale = h;
|
||||
}
|
||||
if (m_layerElementSub != null) {
|
||||
m_layerElementSub.Scale = h;
|
||||
|
||||
if (nx - w / 2 < 0) {
|
||||
m_layerElementSub.gameObject.SetActive(true);
|
||||
m_layerElementSub.transform.localPosition = new(-1, 0, _elementLayerZ);
|
||||
}
|
||||
else if (nx + w / 2 > 1) {
|
||||
m_layerElementSub.gameObject.SetActive(true);
|
||||
m_layerElementSub.transform.localPosition = new(1, 0, _elementLayerZ);
|
||||
}
|
||||
else {
|
||||
m_layerElementSub.gameObject.SetActive(false);
|
||||
if (nx - w / 2 < 0) {
|
||||
m_layerElementSub.gameObject.SetActive(true);
|
||||
m_layerElementSub.transform.localPosition = new(-1, 0, _elementLayerZ);
|
||||
}
|
||||
else if (nx + w / 2 > 1) {
|
||||
m_layerElementSub.gameObject.SetActive(true);
|
||||
m_layerElementSub.transform.localPosition = new(1, 0, _elementLayerZ);
|
||||
}
|
||||
else {
|
||||
m_layerElementSub.gameObject.SetActive(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
15
Assets/Cryville.EEW.Unity/Map/EditorMapTileCacheManager.cs
Normal file
15
Assets/Cryville.EEW.Unity/Map/EditorMapTileCacheManager.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
using Cryville.EEW.Core.Map;
|
||||
using System.IO;
|
||||
using UnityEngine;
|
||||
|
||||
namespace Cryville.EEW.Unity.Map {
|
||||
sealed class EditorMapTileCacheManager : MapTileCacheManager {
|
||||
protected override MapTileBitmapHolder CreateBitmapHolder(MapTileIndex index) => new(
|
||||
index,
|
||||
GameObject.Instantiate(PrefabBitmapHolder, Parent, false),
|
||||
new($"https://tile.openstreetmap.org/{index.Z}/{index.NX}/{index.NY}.png")
|
||||
);
|
||||
|
||||
protected override string GetCacheFilePath(MapTileIndex index) => Path.Combine(CacheDir, $"map_editor/{index.Z}/{index.NX}/{index.NY}");
|
||||
}
|
||||
}
|
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 478198b8ecc0082449fa3f68795174a9
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@@ -2,6 +2,7 @@ using Cryville.EEW.BMKGOpenData.Map;
|
||||
using Cryville.EEW.Core;
|
||||
using Cryville.EEW.CWAOpenData.Map;
|
||||
using Cryville.EEW.EMSC.Map;
|
||||
using Cryville.EEW.GeoNet.Map;
|
||||
using Cryville.EEW.GlobalQuake.Map;
|
||||
using Cryville.EEW.JMAAtom.Map;
|
||||
using Cryville.EEW.Map;
|
||||
@@ -135,6 +136,9 @@ namespace Cryville.EEW.Unity.Map {
|
||||
new CWATsunamiMapGenerator(),
|
||||
new EMSCRealTimeEventMapGenerator(),
|
||||
new FujianEEWMapGenerator(),
|
||||
new GeoNetQuakeHistoryMapGenerator(),
|
||||
new GeoNetQuakeMapGenerator(),
|
||||
new GeoNetStrongMapGenerator(),
|
||||
new GlobalQuakeMapViewGenerator(),
|
||||
new JMAAtomMapGenerator(),
|
||||
new JMAEEWMapGenerator(),
|
||||
|
@@ -7,10 +7,12 @@ using UnityEngine;
|
||||
|
||||
namespace Cryville.EEW.Unity.Map {
|
||||
sealed class MapTileBitmapHolder : Core.Map.MapTileBitmapHolder {
|
||||
MapTileBitmapHolderBehaviour _behaviour;
|
||||
readonly MapTileBitmapHolderBehaviour _behaviour;
|
||||
readonly Uri _uri;
|
||||
|
||||
public MapTileBitmapHolder(MapTileIndex index, GameObject gameObject) : base(index) {
|
||||
public MapTileBitmapHolder(MapTileIndex index, GameObject gameObject, Uri uri) : base(index) {
|
||||
_behaviour = gameObject.GetComponent<MapTileBitmapHolderBehaviour>();
|
||||
_uri = uri;
|
||||
}
|
||||
|
||||
protected override void Dispose(bool disposing) {
|
||||
@@ -20,8 +22,7 @@ namespace Cryville.EEW.Unity.Map {
|
||||
}
|
||||
}
|
||||
|
||||
protected override Uri GetUri() =>
|
||||
new($"https://server.arcgisonline.com/ArcGIS/rest/services/Ocean/World_Ocean_Base/MapServer/tile/{Index.Z}/{Index.NY}/{Index.NX}");
|
||||
protected override Uri GetUri() => _uri;
|
||||
|
||||
protected override Task LoadBitmap(FileInfo file, CancellationToken cancellationToken) {
|
||||
_behaviour.Load(file);
|
||||
|
@@ -40,18 +40,18 @@ namespace Cryville.EEW.Unity.Map {
|
||||
_req.SendWebRequest();
|
||||
}
|
||||
catch (Exception ex) {
|
||||
Debug.LogException(ex);
|
||||
App.MainLogger.Log(4, "Map", null, "An error occurred when loading map tile {0}: {1}", _localFile, ex);
|
||||
}
|
||||
_isReady = false;
|
||||
}
|
||||
if (_req == null || !_req.isDone) return;
|
||||
if (_texHandler.isDone) {
|
||||
if (_texHandler.isDone && _texHandler.texture != null) {
|
||||
_tex = _texHandler.texture;
|
||||
_tex.wrapMode = TextureWrapMode.Clamp;
|
||||
_sprite = Sprite.Create(_tex, new Rect(0, 0, _tex.width, _tex.height), Vector2.zero, _tex.height, 0, SpriteMeshType.FullRect, Vector4.zero, false);
|
||||
}
|
||||
else {
|
||||
Debug.LogError(_req.error);
|
||||
App.MainLogger.Log(4, "Map", null, "An error occurred when loading map tile {0}: {1}", _localFile, _texHandler.error);
|
||||
_localFile.Delete();
|
||||
}
|
||||
_req.Dispose();
|
||||
|
@@ -4,7 +4,7 @@ using System.IO;
|
||||
using UnityEngine;
|
||||
|
||||
namespace Cryville.EEW.Unity.Map {
|
||||
sealed class MapTileCacheManager : MapTileCacheManager<MapTileBitmapHolder> {
|
||||
class MapTileCacheManager : MapTileCacheManager<MapTileBitmapHolder> {
|
||||
public GameObject PrefabTile { get; set; }
|
||||
public GameObject PrefabBitmapHolder { get; set; }
|
||||
|
||||
@@ -12,8 +12,12 @@ namespace Cryville.EEW.Unity.Map {
|
||||
|
||||
public string CacheDir { get; set; }
|
||||
|
||||
protected override MapTileBitmapHolder CreateBitmapHolder(MapTileIndex index) => new(index, GameObject.Instantiate(PrefabBitmapHolder, Parent, false));
|
||||
|
||||
protected override MapTileBitmapHolder CreateBitmapHolder(MapTileIndex index) => new(
|
||||
index,
|
||||
GameObject.Instantiate(PrefabBitmapHolder, Parent, false),
|
||||
new($"https://server.arcgisonline.com/ArcGIS/rest/services/Ocean/World_Ocean_Base/MapServer/tile/{index.Z}/{index.NY}/{index.NX}")
|
||||
);
|
||||
|
||||
protected override string GetCacheFilePath(MapTileIndex index) => Path.Combine(CacheDir, $"map/{index.Z}/{index.NX}/{index.NY}");
|
||||
|
||||
readonly Dictionary<MapTile<MapTileBitmapHolder>, MapTile> _map = new();
|
||||
|
219
Assets/Cryville.EEW.Unity/Map/RegionEditor.cs
Normal file
219
Assets/Cryville.EEW.Unity/Map/RegionEditor.cs
Normal file
@@ -0,0 +1,219 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Globalization;
|
||||
using System.IO;
|
||||
using System.Text.Json;
|
||||
using System.Text.Json.Serialization;
|
||||
using TMPro;
|
||||
using UnityEngine;
|
||||
|
||||
namespace Cryville.EEW.Unity.Map {
|
||||
sealed class RegionEditor : MonoBehaviour {
|
||||
QuadTreeNode _root;
|
||||
|
||||
[SerializeField] CameraController m_cameraController;
|
||||
[SerializeField] GameObject m_regionViewPrefab;
|
||||
|
||||
[SerializeField] TMP_Text m_textSelectedInfo;
|
||||
[SerializeField] TMP_Text m_textHoveredInfo;
|
||||
[SerializeField] TMP_InputField m_inputId;
|
||||
|
||||
readonly Dictionary<QuadTreeNode, RegionView> _map = new();
|
||||
|
||||
void Start() {
|
||||
var file = new FileInfo(Path.Combine(Application.persistentDataPath, "regions.json"));
|
||||
if (file.Exists) {
|
||||
using var stream = file.OpenRead();
|
||||
_root = JsonSerializer.Deserialize<QuadTreeNode>(stream);
|
||||
}
|
||||
else {
|
||||
_root = NewNode();
|
||||
}
|
||||
BuildView(_root);
|
||||
}
|
||||
|
||||
public void Save() {
|
||||
var file = new FileInfo(Path.Combine(Application.persistentDataPath, "regions.json"));
|
||||
using var stream = file.Open(FileMode.Create);
|
||||
JsonSerializer.Serialize(stream, _root);
|
||||
}
|
||||
|
||||
void BuildView(QuadTreeNode node) {
|
||||
var view = Instantiate(m_regionViewPrefab, transform, false).GetComponent<RegionView>();
|
||||
view.Init(node.X, node.Y, node.Z);
|
||||
view.Id = node.Data.Id;
|
||||
view.IsLeaf = node.Children == null;
|
||||
_map.Add(node, view);
|
||||
BuildChildViews(node);
|
||||
}
|
||||
|
||||
void BuildChildViews(QuadTreeNode node) {
|
||||
if (node.Children == null) return;
|
||||
foreach (var child in node.Children) {
|
||||
BuildView(child);
|
||||
}
|
||||
}
|
||||
|
||||
void DestroyChildViews(QuadTreeNode node) {
|
||||
if (node.Children == null) return;
|
||||
foreach (var child in node.Children) {
|
||||
Destroy(_map[child].gameObject);
|
||||
_map.Remove(child);
|
||||
}
|
||||
}
|
||||
|
||||
QuadTreeNode _hoveredNode;
|
||||
QuadTreeNode _selectedNode;
|
||||
Vector3? _ppos;
|
||||
void Update() {
|
||||
var pos = Camera.main.ScreenToWorldPoint(Input.mousePosition);
|
||||
pos.y += 1;
|
||||
var hoveredNode = _root.Get(pos);
|
||||
if (hoveredNode != _hoveredNode) {
|
||||
HoverNode(hoveredNode);
|
||||
}
|
||||
if (Input.GetMouseButtonDown(0)) {
|
||||
_ppos = Input.mousePosition;
|
||||
}
|
||||
if (Input.GetMouseButton(0) && _ppos is Vector3 pos0) {
|
||||
if (Input.mousePosition != pos0) {
|
||||
_ppos = null;
|
||||
}
|
||||
}
|
||||
if (hoveredNode == null) return;
|
||||
if (Input.GetMouseButtonUp(0) && _ppos != null) {
|
||||
SelectNode(hoveredNode);
|
||||
_ppos = null;
|
||||
}
|
||||
if (m_inputId.isFocused)
|
||||
return;
|
||||
if (Input.GetKeyUp(KeyCode.A)) {
|
||||
MergeNode(hoveredNode);
|
||||
}
|
||||
if (Input.GetKeyUp(KeyCode.S)) {
|
||||
SplitNode(hoveredNode);
|
||||
}
|
||||
if (Input.GetKeyUp(KeyCode.C)) {
|
||||
m_inputId.text = hoveredNode.Data.Id;
|
||||
}
|
||||
if (Input.GetKeyUp(KeyCode.V)) {
|
||||
hoveredNode.Data.Id = m_inputId.text;
|
||||
_map[hoveredNode].Id = hoveredNode.Data.Id;
|
||||
}
|
||||
}
|
||||
void HoverNode(QuadTreeNode node) {
|
||||
if (_hoveredNode != null) {
|
||||
_map[_hoveredNode].IsHovered = false;
|
||||
}
|
||||
_hoveredNode = node;
|
||||
if (_hoveredNode != null) {
|
||||
_map[_hoveredNode].IsHovered = true;
|
||||
m_textHoveredInfo.text = string.Format(CultureInfo.InvariantCulture, "<Hovered>\nZ: {2}, XY: ({0}, {1})\nD: {3}", node.X, node.Y, node.Z, node.Data.Id);
|
||||
}
|
||||
else {
|
||||
m_textHoveredInfo.text = "";
|
||||
}
|
||||
}
|
||||
void SelectNode(QuadTreeNode node) {
|
||||
if (_selectedNode != null) {
|
||||
_map[_selectedNode].IsSelected = false;
|
||||
}
|
||||
_selectedNode = node;
|
||||
if (_selectedNode != null) {
|
||||
_map[_selectedNode].IsSelected = true;
|
||||
m_textSelectedInfo.text = string.Format(CultureInfo.InvariantCulture, "<Selected>\nZ: {2}, XY: ({0}, {1})\nD: {3}", node.X, node.Y, node.Z, node.Data.Id);
|
||||
}
|
||||
else {
|
||||
m_textSelectedInfo.text = "";
|
||||
}
|
||||
}
|
||||
void MergeNode(QuadTreeNode node) {
|
||||
var parent = node.Parent;
|
||||
if (parent == null)
|
||||
return;
|
||||
DestroyChildViews(parent);
|
||||
_map[parent].IsLeaf = true;
|
||||
parent.Merge();
|
||||
_hoveredNode = null;
|
||||
if (_selectedNode != null && !_map.ContainsKey(_selectedNode)) {
|
||||
_selectedNode = null;
|
||||
}
|
||||
}
|
||||
void SplitNode(QuadTreeNode node) {
|
||||
node.Split();
|
||||
_map[node].IsLeaf = false;
|
||||
BuildChildViews(node);
|
||||
}
|
||||
|
||||
static QuadTreeNode NewNode() => new() { Data = new("") };
|
||||
|
||||
sealed class QuadTreeNode {
|
||||
QuadTreeNode[] m_children;
|
||||
public QuadTreeNode[] Children {
|
||||
get => m_children;
|
||||
set {
|
||||
if (m_children != null) {
|
||||
foreach (var child in m_children) {
|
||||
child.DetachFromParent();
|
||||
}
|
||||
}
|
||||
m_children = value;
|
||||
UpdateChildren();
|
||||
}
|
||||
}
|
||||
QuadTreeNode m_parent;
|
||||
[JsonIgnore] public QuadTreeNode Parent => m_parent;
|
||||
void AttachToParent(QuadTreeNode parent, int index) {
|
||||
if (m_parent != null && m_parent != parent)
|
||||
throw new InvalidOperationException("Node already in a tree.");
|
||||
m_parent = parent;
|
||||
X = (parent.X << 1) | (index is 0 or 3 ? 1 : 0);
|
||||
Y = (parent.Y << 1) | (index is 0 or 1 ? 1 : 0);
|
||||
Z = parent.Z + 1;
|
||||
UpdateChildren();
|
||||
}
|
||||
void DetachFromParent() => m_parent = null;
|
||||
void UpdateChildren() {
|
||||
if (m_children != null) {
|
||||
for (int i = 0; i < m_children.Length; i++) {
|
||||
m_children[i].AttachToParent(this, i);
|
||||
}
|
||||
}
|
||||
}
|
||||
[JsonIgnore] public int X { get; private set; }
|
||||
[JsonIgnore] public int Y { get; private set; }
|
||||
[JsonIgnore] public int Z { get; private set; }
|
||||
public RegionData Data { get; set; }
|
||||
|
||||
public QuadTreeNode Get(Vector2 pos) {
|
||||
if ((pos.x is < 0 or >= 1) || (pos.y is < 0 or >= 1))
|
||||
return null;
|
||||
if (m_children == null)
|
||||
return this;
|
||||
Vector2 subPos = pos * 2;
|
||||
subPos.x %= 1;
|
||||
subPos.y %= 1;
|
||||
return pos.x >= 0.5f
|
||||
? (pos.y >= 0.5f ? m_children[0] : m_children[3]).Get(subPos)
|
||||
: (pos.y >= 0.5f ? m_children[1] : m_children[2]).Get(subPos);
|
||||
}
|
||||
|
||||
public void Merge() {
|
||||
Children = null;
|
||||
}
|
||||
|
||||
public void Split() {
|
||||
Children = new QuadTreeNode[] {
|
||||
new() { Data = Data.Copy() },
|
||||
new() { Data = Data.Copy() },
|
||||
new() { Data = Data.Copy() },
|
||||
new() { Data = Data.Copy() },
|
||||
};
|
||||
}
|
||||
}
|
||||
sealed record RegionData(string Id) {
|
||||
public string Id { get; set; } = Id;
|
||||
public RegionData Copy() => (RegionData)MemberwiseClone();
|
||||
}
|
||||
}
|
||||
}
|
11
Assets/Cryville.EEW.Unity/Map/RegionEditor.cs.meta
Normal file
11
Assets/Cryville.EEW.Unity/Map/RegionEditor.cs.meta
Normal file
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: fd7b70d11ebfe324e830806e394cc334
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
68
Assets/Cryville.EEW.Unity/Map/RegionView.cs
Normal file
68
Assets/Cryville.EEW.Unity/Map/RegionView.cs
Normal file
@@ -0,0 +1,68 @@
|
||||
using UnityEngine;
|
||||
|
||||
namespace Cryville.EEW.Unity.Map {
|
||||
sealed class RegionView : MonoBehaviour {
|
||||
[SerializeField]
|
||||
SpriteRenderer m_spriteRenderer;
|
||||
|
||||
Color _color;
|
||||
|
||||
bool m_isHovered;
|
||||
public bool IsHovered {
|
||||
get => m_isHovered;
|
||||
set {
|
||||
m_isHovered = value;
|
||||
UpdateColor();
|
||||
}
|
||||
}
|
||||
|
||||
bool m_isSelected;
|
||||
public bool IsSelected {
|
||||
get => m_isSelected;
|
||||
set {
|
||||
m_isSelected = value;
|
||||
UpdateColor();
|
||||
}
|
||||
}
|
||||
|
||||
bool m_isLeaf = true;
|
||||
public bool IsLeaf {
|
||||
get => m_isLeaf;
|
||||
set {
|
||||
m_isLeaf = value;
|
||||
UpdateColor();
|
||||
}
|
||||
}
|
||||
|
||||
string m_id;
|
||||
public string Id {
|
||||
get => m_id;
|
||||
set {
|
||||
m_id = value;
|
||||
unchecked {
|
||||
uint hash = (uint)value.GetHashCode();
|
||||
_color = Color.HSVToRGB(((hash >> 24) ^ ((hash >> 16) & 0xff) ^ ((hash >> 8) & 0xff) ^ (hash & 0xff)) / (float)0xff, 1, 1);
|
||||
}
|
||||
UpdateColor();
|
||||
}
|
||||
}
|
||||
|
||||
public void Init(int x, int y, int z) {
|
||||
float scale = 1f / (1 << z);
|
||||
transform.localScale = new Vector3(scale, scale, 1);
|
||||
transform.localPosition = new Vector3(x * scale, y * scale - 1, -1 - z / 100f);
|
||||
}
|
||||
|
||||
void UpdateColor() {
|
||||
if (!m_isLeaf)
|
||||
_color.a = 0.0f;
|
||||
else if (m_isSelected)
|
||||
_color.a = 0.6f;
|
||||
else if (m_isHovered)
|
||||
_color.a = 0.4f;
|
||||
else
|
||||
_color.a = 0.2f;
|
||||
m_spriteRenderer.color = _color;
|
||||
}
|
||||
}
|
||||
}
|
11
Assets/Cryville.EEW.Unity/Map/RegionView.cs.meta
Normal file
11
Assets/Cryville.EEW.Unity/Map/RegionView.cs.meta
Normal file
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: c57a0e86eb63b6048ba265e9d98e84f6
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@@ -1,4 +1,5 @@
|
||||
using Cryville.EEW.Colors;
|
||||
using Cryville.EEW.Core;
|
||||
using Cryville.EEW.Core.Colors;
|
||||
using Cryville.EEW.FERegion;
|
||||
using Cryville.EEW.Map;
|
||||
@@ -25,8 +26,23 @@ namespace Cryville.EEW.Unity {
|
||||
public IColorScheme ColorScheme { get; private set; } = new SeverityBasedColorScheme(DefaultSeverityScheme.Instance, DefaultSeverityColorMapping.Instance);
|
||||
public ISubColorScheme BorderColorScheme { get; private set; } = new WrappedColorScheme(new SeverityBasedColorScheme(DefaultSeverityScheme.Instance, DefaultSeverityColorMapping.SecondaryInstance));
|
||||
public ISubColorScheme TextColorScheme { get; private set; } = new DefaultTextColorScheme(Color.White, Color.Black);
|
||||
public ILocationConverter LocationConverter => new FERegionLongConverter(); // TODO TTS
|
||||
public TimeSpan NowcastWarningDelayTolerance => TimeSpan.FromMinutes(60); // TODO TTS
|
||||
public TimeSpan NowcastWarningDelayTolerance { get; private set; } = TimeSpan.FromMinutes(60);
|
||||
|
||||
public CultureInfo RVMCulture { get; private set; } = SharedCultures.CurrentUICulture;
|
||||
readonly int _infoLocationSpecificity = 3;
|
||||
readonly int _ttsLocationSpecificity = 3;
|
||||
readonly LocationNamer _locationNamer = new() { Namer = new FERegionLongNamer() };
|
||||
public bool NameLocation(double lat, double lon, CultureInfo localCulture, ref CultureInfo targetCulture, out string name, out int specificity) {
|
||||
specificity = _ttsLocationSpecificity;
|
||||
return _locationNamer.Name(lat, lon, localCulture, ref targetCulture, out name, ref specificity);
|
||||
}
|
||||
public bool NameLocation(double lat, double lon, CultureInfo localCulture, ref CultureInfo targetCulture, out string name) {
|
||||
int specificity = _infoLocationSpecificity;
|
||||
return _locationNamer.Name(lat, lon, localCulture, ref targetCulture, out name, ref specificity);
|
||||
}
|
||||
|
||||
public IReadOnlyCollection<TTSCultureConfig> TTSCultures { get; private set; }
|
||||
public bool DoIgnoreLanguageVariant { get; private set; }
|
||||
|
||||
public TimeZoneInfo OverrideTimeZone { get; private set; }
|
||||
public bool DoDisplayTimeZone { get; private set; } = true;
|
||||
@@ -101,9 +117,20 @@ namespace Cryville.EEW.Unity {
|
||||
"SREV" => new DefaultTextColorScheme(Color.White, Color.FromArgb(28, 28, 28), 0.555f),
|
||||
_ => new DefaultTextColorScheme(Color.White, Color.Black),
|
||||
};
|
||||
_locationNamer.Namer = config.LocationNamer switch {
|
||||
"FERegionShort" => new FERegionShortNamer(),
|
||||
_ => new FERegionLongNamer(),
|
||||
};
|
||||
if (config.NowcastWarningDelayTolerance is string nowcastWarningDelayTolerance)
|
||||
NowcastWarningDelayTolerance = TimeSpan.Parse(nowcastWarningDelayTolerance, CultureInfo.InvariantCulture);
|
||||
OverrideTimeZone = ParseTimeZone(config.OverrideTimeZone);
|
||||
DoDisplayTimeZone = config.DoDisplayTimeZone;
|
||||
DoSwitchBackToHistory = config.DoSwitchBackToHistory;
|
||||
RVMCulture = config.OverrideDisplayCulture is string rvmCulture
|
||||
? (string.IsNullOrEmpty(rvmCulture) ? SharedCultures.CurrentUICulture : SharedCultures.Get(rvmCulture))
|
||||
: CultureInfo.InvariantCulture;
|
||||
TTSCultures = config.TTSCultures ?? new List<TTSCultureConfig> { new(CultureInfo.InvariantCulture) };
|
||||
DoIgnoreLanguageVariant = config.DoIgnoreLanguageVariant;
|
||||
EventSources = config.EventSources;
|
||||
}
|
||||
|
||||
|
@@ -5,7 +5,7 @@ using System.IO;
|
||||
using UnityEngine;
|
||||
|
||||
namespace Cryville.EEW.Unity {
|
||||
class SoundPlayer : Core.SoundPlayer {
|
||||
class SoundPlayer : Core.Audio.SoundPlayer {
|
||||
public SoundPlayer() : base(GetEngineList(), AudioUsage.NotificationEvent) { }
|
||||
static List<Type> GetEngineList() => new() {
|
||||
typeof(Audio.Wasapi.MMDeviceEnumeratorWrapper),
|
||||
@@ -13,6 +13,7 @@ namespace Cryville.EEW.Unity {
|
||||
};
|
||||
|
||||
protected override Stream Open(string path) {
|
||||
App.MainLogger.Log(0, "Audio", null, "Opening audio file {0}", path);
|
||||
path = Path.Combine(Application.streamingAssetsPath, "Sounds", path + ".ogg");
|
||||
if (!File.Exists(path)) return null;
|
||||
return new FileStream(path, FileMode.Open, FileAccess.Read);
|
||||
|
@@ -1,25 +1,53 @@
|
||||
using SpeechLib;
|
||||
using System;
|
||||
using System.Globalization;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Cryville.EEW.Unity {
|
||||
class TTSWorker : Core.TTSWorker {
|
||||
public TTSWorker() : base(CreateSoundPlayer()) { }
|
||||
class TTSWorker : Core.Audio.TTSWorker {
|
||||
readonly ISpVoice _voice;
|
||||
|
||||
public TTSWorker() : base(CreateSoundPlayer()) {
|
||||
App.MainLogger.Log(1, "Audio", null, "Initializing TTS worker");
|
||||
try {
|
||||
_voice = new SpVoiceClass();
|
||||
}
|
||||
catch { }
|
||||
}
|
||||
|
||||
static SoundPlayer CreateSoundPlayer() {
|
||||
App.MainLogger.Log(1, "Audio", null, "Creating sound player");
|
||||
try {
|
||||
return new SoundPlayer();
|
||||
}
|
||||
catch (InvalidOperationException) {
|
||||
catch (InvalidOperationException ex) {
|
||||
App.MainLogger.Log(3, "Audio", null, "An error occurred when creating sound player: {0}", ex);
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
protected override bool IsSpeaking() => false;
|
||||
protected override bool IsSpeaking() {
|
||||
if (_voice == null) return false;
|
||||
_voice.GetStatus(out var status, out _);
|
||||
return (status.dwRunningState & (uint)SpeechRunState.SRSEIsSpeaking) != 0;
|
||||
}
|
||||
|
||||
protected override Task Speak(CultureInfo culture, string content, CancellationToken cancellationToken) => Task.CompletedTask;
|
||||
protected override Task Speak(CultureInfo culture, string content, CancellationToken cancellationToken) {
|
||||
if (_voice == null) return Task.CompletedTask;
|
||||
_voice.Speak(
|
||||
string.Format(CultureInfo.InvariantCulture, "<LANG LANGID=\"{0:x}\">{1}</LANG>", culture.LCID, content),
|
||||
(uint)(SpeechVoiceSpeakFlags.SVSFlagsAsync | SpeechVoiceSpeakFlags.SVSFPurgeBeforeSpeak),
|
||||
out _
|
||||
);
|
||||
App.MainLogger.Log(0, "Audio", null, "TTS ({0}): {1}", culture, content);
|
||||
return Task.CompletedTask;
|
||||
}
|
||||
|
||||
protected override void StopCurrent() { }
|
||||
protected override void StopCurrent() {
|
||||
if (_voice == null) return;
|
||||
App.MainLogger.Log(0, "Audio", null, "TTS stopping current");
|
||||
_voice.Skip("SENTENCE", int.MaxValue, out _);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -23,6 +23,7 @@ namespace Cryville.EEW.Unity.UI {
|
||||
child.SetViewModel(e);
|
||||
child.transform.SetParent(m_listView, false);
|
||||
_displayingViews.Add(child);
|
||||
OnDisplayingViewsChanged();
|
||||
|
||||
SwitchTo(_displayingReports.Count - 1);
|
||||
|
||||
@@ -37,6 +38,7 @@ namespace Cryville.EEW.Unity.UI {
|
||||
child.SetParent(null, false);
|
||||
Destroy(child.gameObject);
|
||||
_displayingViews.RemoveAt(index);
|
||||
OnDisplayingViewsChanged();
|
||||
|
||||
if (_displayingReports.Count == 0) {
|
||||
m_currentView.gameObject.SetActive(false);
|
||||
@@ -49,6 +51,14 @@ namespace Cryville.EEW.Unity.UI {
|
||||
|
||||
if (_displayingReports.Count <= 1) m_listView.gameObject.SetActive(false);
|
||||
}
|
||||
void OnDisplayingViewsChanged() {
|
||||
_maxBaseDuration = 1;
|
||||
foreach (var e in _displayingReports) {
|
||||
float duration = GetBaseDuration(e);
|
||||
if (duration > _maxBaseDuration)
|
||||
_maxBaseDuration = duration;
|
||||
}
|
||||
}
|
||||
|
||||
void Awake() {
|
||||
if (Instance != null) {
|
||||
@@ -63,6 +73,7 @@ namespace Cryville.EEW.Unity.UI {
|
||||
|
||||
int _index = -1;
|
||||
float _tickDown;
|
||||
float _maxBaseDuration;
|
||||
void Update() {
|
||||
if (_displayingReports.Count == 0) return;
|
||||
_tickDown -= Time.deltaTime;
|
||||
@@ -77,12 +88,15 @@ namespace Cryville.EEW.Unity.UI {
|
||||
_index = index;
|
||||
var e = _displayingReports[index];
|
||||
m_currentView.SetViewModel(e, true);
|
||||
var keyProp = e.Properties.FirstOrDefault();
|
||||
_displayingViews[_index].SetCurrent(true);
|
||||
_tickDown = MathF.Exp(Math.Max(-1f, keyProp?.Severity ?? -1f) + 1);
|
||||
_tickDown = GetBaseDuration(e) / Math.Min(_maxBaseDuration, 4) * 4;
|
||||
m_currentView.gameObject.SetActive(true);
|
||||
Worker.Instance.SetCurrent(e);
|
||||
}
|
||||
static float GetBaseDuration(ReportViewModel e) {
|
||||
return MathF.Exp(Math.Max(-1f, e.Properties.FirstOrDefault()?.Severity ?? -1f) + 1);
|
||||
}
|
||||
|
||||
public void OnItemClicked(ReportViewModel viewModel) {
|
||||
int index = _displayingReports.IndexOf(viewModel);
|
||||
if (index == -1) return;
|
||||
|
@@ -12,8 +12,8 @@ namespace Cryville.EEW.Unity.UI {
|
||||
_textView = GetComponent<TMP_Text>();
|
||||
}
|
||||
|
||||
StringBuilder _sb = new();
|
||||
char[] _buffer = new char[256];
|
||||
readonly StringBuilder _sb = new();
|
||||
readonly char[] _buffer = new char[256];
|
||||
void Update() {
|
||||
_sb.Clear();
|
||||
_sb.AppendFormat(
|
||||
|
@@ -5,6 +5,8 @@ using Cryville.EEW.CWAOpenData;
|
||||
using Cryville.EEW.CWAOpenData.Model;
|
||||
using Cryville.EEW.CWAOpenData.TTS;
|
||||
using Cryville.EEW.EMSC;
|
||||
using Cryville.EEW.GeoNet;
|
||||
using Cryville.EEW.GeoNet.TTS;
|
||||
using Cryville.EEW.GlobalQuake;
|
||||
using Cryville.EEW.JMAAtom;
|
||||
using Cryville.EEW.JMAAtom.TTS;
|
||||
@@ -58,16 +60,21 @@ namespace Cryville.EEW.Unity {
|
||||
}
|
||||
|
||||
void Start() {
|
||||
App.MainLogger.Log(1, "App", null, "Initializing localized resources manager");
|
||||
LocalizedResources.Init(new LocalizedResourcesManager());
|
||||
RegisterViewModelGenerators(_worker);
|
||||
RegisterTTSMessageGenerators(_worker);
|
||||
BuildWorkers();
|
||||
_worker.RVMGeneratorContext = SharedSettings.Instance;
|
||||
_worker.TTSMessageGeneratorContext = SharedSettings.Instance;
|
||||
_worker.RVMCulture = SharedSettings.Instance.RVMCulture;
|
||||
_worker.SetTTSCultures(SharedSettings.Instance.TTSCultures ?? new TTSCultureConfig[0]);
|
||||
_worker.IgnoreLanguageVariant = SharedSettings.Instance.DoIgnoreLanguageVariant;
|
||||
_ongoingReportManager.Changed += OnOngoingReported;
|
||||
_worker.Reported += OnReported;
|
||||
_grouper.GroupUpdated += OnGroupUpdated;
|
||||
_grouper.GroupRemoved += OnGroupRemoved;
|
||||
App.MainLogger.Log(1, "App", null, "Worker ready");
|
||||
Task.Run(() => GatewayVerify(_cancellationTokenSource.Token)).ContinueWith(task => {
|
||||
if (task.IsFaulted) {
|
||||
OnReported(this, new() { Title = task.Exception.Message });
|
||||
@@ -87,15 +94,19 @@ namespace Cryville.EEW.Unity {
|
||||
_ongoingReportManager.Dispose();
|
||||
}
|
||||
|
||||
static void RegisterViewModelGenerators(CoreWorker worker) {
|
||||
CENCEarthquakeRVMGenerator _cencEarthquakeRVMGenerator;
|
||||
void RegisterViewModelGenerators(CoreWorker worker) {
|
||||
worker.RegisterViewModelGenerator(new BMKGEarthquakeRVMGenerator());
|
||||
worker.RegisterViewModelGenerator(new CENCEarthquakeRVMGenerator());
|
||||
worker.RegisterViewModelGenerator(_cencEarthquakeRVMGenerator = new CENCEarthquakeRVMGenerator());
|
||||
worker.RegisterViewModelGenerator(new CENCEEWRVMGenerator());
|
||||
worker.RegisterViewModelGenerator(new CWAEarthquakeRVMGenerator());
|
||||
worker.RegisterViewModelGenerator(new CWAEEWRVMGenerator());
|
||||
worker.RegisterViewModelGenerator(new CWATsunamiRVMGenerator());
|
||||
worker.RegisterViewModelGenerator(new EMSCRealTimeEventRVMGenerator());
|
||||
worker.RegisterViewModelGenerator(new FujianEEWRVMGenerator());
|
||||
worker.RegisterViewModelGenerator(new GeoNetQuakeHistoryRVMGenerator());
|
||||
worker.RegisterViewModelGenerator(new GeoNetQuakeRVMGenerator());
|
||||
worker.RegisterViewModelGenerator(new GeoNetStrongRVMGenerator());
|
||||
worker.RegisterViewModelGenerator(new GlobalQuakeRVMGenerator());
|
||||
worker.RegisterViewModelGenerator(new JMAAtomRVMGenerator());
|
||||
worker.RegisterViewModelGenerator(new JMAEEWRVMGenerator());
|
||||
@@ -104,14 +115,18 @@ namespace Cryville.EEW.Unity {
|
||||
worker.RegisterViewModelGenerator(new SichuanEEWRVMGenerator());
|
||||
worker.RegisterViewModelGenerator(new VersionRVMGenerator());
|
||||
}
|
||||
static void RegisterTTSMessageGenerators(CoreWorker worker) {
|
||||
CENCEarthquakeTTSMessageGenerator _cencEarthquakeTTSMessageGenerator;
|
||||
void RegisterTTSMessageGenerators(CoreWorker worker) {
|
||||
worker.RegisterTTSMessageGenerator(new BMKGEarthquakeTTSMessageGenerator());
|
||||
worker.RegisterTTSMessageGenerator(new CENCEarthquakeTTSMessageGenerator());
|
||||
worker.RegisterTTSMessageGenerator(_cencEarthquakeTTSMessageGenerator = new CENCEarthquakeTTSMessageGenerator());
|
||||
worker.RegisterTTSMessageGenerator(new CENCEEWTTSMessageGenerator());
|
||||
worker.RegisterTTSMessageGenerator(new CWAEarthquakeTTSMessageGenerator());
|
||||
worker.RegisterTTSMessageGenerator(new CWAEEWTTSMessageGenerator());
|
||||
worker.RegisterTTSMessageGenerator(new CWATsunamiTTSMessageGenerator());
|
||||
worker.RegisterTTSMessageGenerator(new FujianEEWTTSMessageGenerator());
|
||||
worker.RegisterTTSMessageGenerator(new GeoNetQuakeHistoryTTSMessageGenerator());
|
||||
worker.RegisterTTSMessageGenerator(new GeoNetQuakeTTSMessageGenerator());
|
||||
worker.RegisterTTSMessageGenerator(new GeoNetStrongTTSMessageGenerator());
|
||||
worker.RegisterTTSMessageGenerator(new JMAAtomTTSMessageGenerator());
|
||||
worker.RegisterTTSMessageGenerator(new JMAEEWTTSMessageGenerator());
|
||||
worker.RegisterTTSMessageGenerator(new NOAATTSMessageGenerator());
|
||||
@@ -120,6 +135,7 @@ namespace Cryville.EEW.Unity {
|
||||
|
||||
bool _verified;
|
||||
void BuildWorkers() {
|
||||
App.MainLogger.Log(1, "App", null, "Building workers");
|
||||
#if UNITY_EDITOR
|
||||
_worker.AddWorker(new WolfxWorker(new Uri("ws://localhost:9995/wolfx")));
|
||||
_worker.AddWorker(new JMAAtomWorker(new Uri("http://localhost:9095/eqvol.xml")));
|
||||
@@ -129,30 +145,31 @@ namespace Cryville.EEW.Unity {
|
||||
BMKGOpenDataWorker bmkgWorker = new(new Uri("http://localhost:9095/autogempa.json"));
|
||||
bmkgWorker.SetDataUris(new Uri[] { new("http://localhost:9095/gempadirasakan.json") });
|
||||
_worker.AddWorker(bmkgWorker);
|
||||
_worker.AddWorker(new NOAAAtomWorker(new("http://localhost:9095/PAAQAtom.xml")));
|
||||
_worker.AddWorker(new NOAAAtomWorker(new("http://localhost:9095/PAAQAtom.xml"), forceHttps: false));
|
||||
_worker.AddWorker(new UpdateCheckerWorker(typeof(Worker).Assembly.GetName().Version?.ToString(3) ?? "", "unity"));
|
||||
#else
|
||||
foreach (var source in SharedSettings.Instance.EventSources) {
|
||||
_worker.AddWorker(source switch {
|
||||
BMKGOpenDataEventSourceConfig bmkgOpenData => BuildBMKGOpenDataWorkerUris(new BMKGOpenDataWorker(new("https://data.bmkg.go.id/DataMKG/TEWS/autogempa.json")), bmkgOpenData),
|
||||
BMKGOpenDataEventSourceConfig bmkgOpenData => BuildBMKGOpenDataWorkerUris(new(new("https://data.bmkg.go.id/DataMKG/TEWS/autogempa.json")), bmkgOpenData),
|
||||
CWAOpenDataEventSourceConfig cwaOpenData => cwaOpenData.Subtype switch {
|
||||
"E-A0014-001" => new CWAReportWorker<Tsunami>(new Uri("https://opendata.cwa.gov.tw/api/v1/rest/datastore/E-A0014-001"), cwaOpenData.Token, 1440, 17280),
|
||||
"E-A0015-001" => new CWAReportWorker<Earthquake>(new Uri("https://opendata.cwa.gov.tw/api/v1/rest/datastore/E-A0015-001"), cwaOpenData.Token),
|
||||
"E-A0016-001" => new CWAReportWorker<Earthquake>(new Uri("https://opendata.cwa.gov.tw/api/v1/rest/datastore/E-A0016-001"), cwaOpenData.Token),
|
||||
"E-A0014-001" => new CWAReportWorker<Tsunami>(new("https://opendata.cwa.gov.tw/api/v1/rest/datastore/E-A0014-001"), cwaOpenData.Token, 1440, 17280),
|
||||
"E-A0015-001" => new CWAReportWorker<Earthquake>(new("https://opendata.cwa.gov.tw/api/v1/rest/datastore/E-A0015-001"), cwaOpenData.Token),
|
||||
"E-A0016-001" => new CWAReportWorker<Earthquake>(new("https://opendata.cwa.gov.tw/api/v1/rest/datastore/E-A0016-001"), cwaOpenData.Token),
|
||||
_ => throw new InvalidOperationException("Unknown CWA open data sub-type."),
|
||||
},
|
||||
EMSCRealTimeEventSourceConfig => new EMSCRealTimeWorker(new("wss://www.seismicportal.eu/standing_order/websocket")),
|
||||
GeoNetEventSourceConfig geoNet => BuildGeoNetWorker(new(new("https://api.geonet.org.nz/quake"), new("https://api.geonet.org.nz/quake/history/index"), new("https://api.geonet.org.nz/intensity/strong/processed/index")), geoNet),
|
||||
GlobalQuakeServer15EventSourceConfig gq => new GlobalQuakeWorker15(gq.Host, gq.Port),
|
||||
GlobalQuakeServerEventSourceConfig gq => new GlobalQuakeWorker(gq.Host, gq.Port),
|
||||
JMAAtomEventSourceConfig jmaAtom => BuildJMAAtomWorkerFilter(new JMAAtomWorker(new("https://www.data.jma.go.jp/developer/xml/feed/eqvol.xml")), jmaAtom),
|
||||
JMAAtomEventSourceConfig jmaAtom => BuildJMAAtomWorkerFilter(new(new("https://www.data.jma.go.jp/developer/xml/feed/eqvol.xml")), jmaAtom),
|
||||
NOAAEventSourceConfig noaaAtom => noaaAtom.Subtype switch {
|
||||
"PAAQ" => new NOAAAtomWorker(new("https://www.tsunami.gov/events/xml/PAAQAtom.xml"), new("https://www.tsunami.gov/"), new("/php/esri.php?e=t", UriKind.Relative), "PAAQ"),
|
||||
"PHEB" => new NOAAAtomWorker(new("https://www.tsunami.gov/events/xml/PHEBAtom.xml"), new("https://www.tsunami.gov/"), new("/php/esri.php?e=t", UriKind.Relative), "PHEB"),
|
||||
_ => throw new InvalidOperationException("Unknown NOAA sub-type."),
|
||||
},
|
||||
UpdateCheckerEventSourceConfig => new UpdateCheckerWorker(typeof(Worker).Assembly.GetName().Version?.ToString(3) ?? "", "unity"),
|
||||
USGSQuakeMLEventSourceConfig usgsQuakeML => BuildUSGSQuakeMLWorkerUri(new USGSQuakeMLWorker(new Uri("https://earthquake.usgs.gov/earthquakes/feed/v1.0/quakeml.php")), usgsQuakeML),
|
||||
WolfxEventSourceConfig wolfx => BuildWolfxWorkerFilter(new WolfxWorker(new Uri("wss://ws-api.wolfx.jp/all_eew")), wolfx),
|
||||
USGSQuakeMLEventSourceConfig usgsQuakeML => BuildUSGSQuakeMLWorkerUri(new USGSQuakeMLWorker(new("https://earthquake.usgs.gov/earthquakes/feed/v1.0/quakeml.php")), usgsQuakeML),
|
||||
WolfxEventSourceConfig wolfx => BuildWolfxWorkerFilter(new WolfxWorker(new("wss://ws-api.wolfx.jp/all_eew")), wolfx),
|
||||
_ => throw new InvalidOperationException("Unknown event source type."),
|
||||
});
|
||||
}
|
||||
@@ -163,7 +180,7 @@ namespace Cryville.EEW.Unity {
|
||||
worker.IsFilterWhitelist = config.IsFilterWhitelist;
|
||||
return worker;
|
||||
}
|
||||
static WolfxWorker BuildWolfxWorkerFilter(WolfxWorker worker, WolfxEventSourceConfig config) {
|
||||
WolfxWorker BuildWolfxWorkerFilter(WolfxWorker worker, WolfxEventSourceConfig config) {
|
||||
if (config.Filter != null) worker.SetFilter(config.Filter.Select(i => i switch {
|
||||
"cenc_eew" => typeof(CENCEEW),
|
||||
"cenc_eqlist" => typeof(WolfxEarthquakeList<CENCEarthquake>),
|
||||
@@ -174,12 +191,23 @@ namespace Cryville.EEW.Unity {
|
||||
_ => throw new InvalidOperationException("Unknown Wolfx event type."),
|
||||
}));
|
||||
worker.IsFilterWhitelist = config.IsFilterWhitelist;
|
||||
|
||||
_cencEarthquakeRVMGenerator.UseRawLocationName
|
||||
= _cencEarthquakeTTSMessageGenerator.UseRawLocationName
|
||||
= config.UseRawCENCLocationName;
|
||||
|
||||
return worker;
|
||||
}
|
||||
static BMKGOpenDataWorker BuildBMKGOpenDataWorkerUris(BMKGOpenDataWorker worker, BMKGOpenDataEventSourceConfig config) {
|
||||
worker.SetDataUris(config.Subtypes.Select(i => new Uri(string.Format(CultureInfo.InvariantCulture, "https://data.bmkg.go.id/DataMKG/TEWS/{0}.json", i))));
|
||||
return worker;
|
||||
}
|
||||
static GeoNetWorker BuildGeoNetWorker(GeoNetWorker worker, GeoNetEventSourceConfig pref) {
|
||||
worker.MinimumMMI = pref.MinimumMMI;
|
||||
worker.DoGetFullHistory = pref.DoGetFullHistory;
|
||||
worker.DoGetStrongMotionInfo = pref.DoGetStrongMotionInfo;
|
||||
return worker;
|
||||
}
|
||||
static USGSQuakeMLWorker BuildUSGSQuakeMLWorkerUri(USGSQuakeMLWorker worker, USGSQuakeMLEventSourceConfig config) {
|
||||
worker.SetFeedRelativeUri(new(string.Format(CultureInfo.InvariantCulture, "/earthquakes/feed/v1.0/summary/{0}.quakeml", config.Subtype), UriKind.Relative));
|
||||
return worker;
|
||||
@@ -190,7 +218,7 @@ namespace Cryville.EEW.Unity {
|
||||
ReportViewModel _latestHistoryReport;
|
||||
void OnReported(object sender, ReportViewModel e) {
|
||||
if (e.Model is Exception && e.Model is not SourceWorkerNetworkException)
|
||||
Debug.LogError(e);
|
||||
App.MainLogger.Log(4, "Map", null, "Received an error from {0}: {1}", sender.GetType(), e.Model);
|
||||
_grouper.Report(e);
|
||||
_ongoingReportManager.Report(e);
|
||||
_uiActionQueue.Enqueue(() => {
|
||||
|
Binary file not shown.
BIN
Assets/Plugins/Cryville.Common.Logging.dll
Normal file
BIN
Assets/Plugins/Cryville.Common.Logging.dll
Normal file
Binary file not shown.
33
Assets/Plugins/Cryville.Common.Logging.dll.meta
Normal file
33
Assets/Plugins/Cryville.Common.Logging.dll.meta
Normal file
@@ -0,0 +1,33 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 7aa0c56ccfdaf9443b58f26bf40eed01
|
||||
PluginImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
iconMap: {}
|
||||
executionOrder: {}
|
||||
defineConstraints: []
|
||||
isPreloaded: 0
|
||||
isOverridable: 0
|
||||
isExplicitlyReferenced: 0
|
||||
validateReferences: 1
|
||||
platformData:
|
||||
- first:
|
||||
Any:
|
||||
second:
|
||||
enabled: 1
|
||||
settings: {}
|
||||
- first:
|
||||
Editor: Editor
|
||||
second:
|
||||
enabled: 0
|
||||
settings:
|
||||
DefaultValueInitialized: true
|
||||
- first:
|
||||
Windows Store Apps: WindowsStoreApps
|
||||
second:
|
||||
enabled: 0
|
||||
settings:
|
||||
CPU: AnyCPU
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
185
Assets/Plugins/Cryville.Common.Logging.xml
Normal file
185
Assets/Plugins/Cryville.Common.Logging.xml
Normal file
@@ -0,0 +1,185 @@
|
||||
<?xml version="1.0"?>
|
||||
<doc>
|
||||
<assembly>
|
||||
<name>Cryville.Common.Logging</name>
|
||||
</assembly>
|
||||
<members>
|
||||
<member name="T:Cryville.Common.Logging.Logger">
|
||||
<summary>
|
||||
A logger.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.Logger.AddListener(Cryville.Common.Logging.LoggerListener)">
|
||||
<summary>
|
||||
Attaches a listener to the logger.
|
||||
</summary>
|
||||
<param name="listener">The logger listener.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.Logger.RemoveListener(Cryville.Common.Logging.LoggerListener)">
|
||||
<summary>
|
||||
Detaches a listener from the logger.
|
||||
</summary>
|
||||
<param name="listener">The logger listener.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.Logger.Log(System.Int32,System.String,System.String,System.Object[])">
|
||||
<summary>
|
||||
Logs to the logger.
|
||||
</summary>
|
||||
<param name="level">The severity level.</param>
|
||||
<param name="category">The category.</param>
|
||||
<param name="format">The format string.</param>
|
||||
<param name="args">The arguments for formatting.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.Logger.Log(System.Int32,System.String,System.IFormatProvider,System.String,System.Object[])">
|
||||
<summary>
|
||||
Logs to the logger.
|
||||
</summary>
|
||||
<param name="level">The severity level.</param>
|
||||
<param name="category">The category.</param>
|
||||
<param name="provider">The format provider.</param>
|
||||
<param name="format">The format string.</param>
|
||||
<param name="args">The arguments for formatting.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.Logger.Log(System.Int32,System.String,System.String)">
|
||||
<summary>
|
||||
Logs to the logger.
|
||||
</summary>
|
||||
<param name="level">The severity level.</param>
|
||||
<param name="category">The category.</param>
|
||||
<param name="message">The message.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.Logger.Log(System.Int32,System.String,System.Char[])">
|
||||
<summary>
|
||||
Logs to the logger.
|
||||
</summary>
|
||||
<param name="level">The severity level.</param>
|
||||
<param name="category">The category.</param>
|
||||
<param name="message">An array of <see cref="T:System.Char" /> containing the message.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.Logger.Log(System.Int32,System.String,System.Char[],System.Int32,System.Int32)">
|
||||
<summary>
|
||||
Logs to the logger.
|
||||
</summary>
|
||||
<param name="level">The severity level.</param>
|
||||
<param name="category">The category.</param>
|
||||
<param name="message">An array of <see cref="T:System.Char" /> containing the message.</param>
|
||||
<param name="index">A zero-based index of the first character of the message within <paramref name="message" />.</param>
|
||||
<param name="length">The length of the message.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.Logger.Log(System.Int32,System.String,System.Char*,System.Int32)">
|
||||
<summary>
|
||||
Logs to the logger.
|
||||
</summary>
|
||||
<param name="level">The severity level.</param>
|
||||
<param name="category">The category.</param>
|
||||
<param name="message">A pointer to the first character of the message.</param>
|
||||
<param name="length">The length of the message.</param>
|
||||
</member>
|
||||
<member name="T:Cryville.Common.Logging.LoggerListener">
|
||||
<summary>
|
||||
A logger listener.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.LoggerListener.Dispose(System.Boolean)">
|
||||
<summary>
|
||||
Closes the logger listener and cleans up all the resources.
|
||||
</summary>
|
||||
<param name="disposing">Whether to clean up managed resources.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.LoggerListener.Dispose">
|
||||
<summary>
|
||||
Closes the logger listener.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.LoggerListener.OnLog(System.Int32,System.String,System.String)">
|
||||
<summary>
|
||||
Handles an incoming log.
|
||||
</summary>
|
||||
<param name="level">The severity level.</param>
|
||||
<param name="category">The category.</param>
|
||||
<param name="message">The message.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.LoggerListener.OnLog(System.Int32,System.String,System.Char[],System.Int32,System.Int32)">
|
||||
<summary>
|
||||
Handles an incoming log.
|
||||
</summary>
|
||||
<param name="level">The severity level.</param>
|
||||
<param name="category">The category.</param>
|
||||
<param name="message">An array of <see cref="T:System.Char" /> containing the message.</param>
|
||||
<param name="index">A zero-based index of the first character of the message within <paramref name="message" />.</param>
|
||||
<param name="length">The length of the message.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.LoggerListener.OnLog(System.Int32,System.String,System.Char*,System.Int32)">
|
||||
<summary>
|
||||
Handles an incoming log.
|
||||
</summary>
|
||||
<param name="level">The severity level.</param>
|
||||
<param name="category">The category.</param>
|
||||
<param name="message">A pointer to the first character of the message.</param>
|
||||
<param name="length">The length of the message.</param>
|
||||
</member>
|
||||
<member name="T:Cryville.Common.Logging.InstantLoggerListener">
|
||||
<summary>
|
||||
A <see cref="T:Cryville.Common.Logging.LoggerListener" /> that calls a callback function on log.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="E:Cryville.Common.Logging.InstantLoggerListener.Log">
|
||||
<summary>
|
||||
Occurs when a log is logged to the logger.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.InstantLoggerListener.OnLog(System.Int32,System.String,System.String)">
|
||||
<inheritdoc />
|
||||
</member>
|
||||
<member name="T:Cryville.Common.Logging.BufferedLoggerListener">
|
||||
<summary>
|
||||
A <see cref="T:Cryville.Common.Logging.LoggerListener" /> that buffers the logs for enumeration.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.BufferedLoggerListener.OnLog(System.Int32,System.String,System.String)">
|
||||
<inheritdoc />
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.BufferedLoggerListener.Enumerate(Cryville.Common.Logging.LogHandler)">
|
||||
<summary>
|
||||
Enumerates the buffered logs.
|
||||
</summary>
|
||||
<param name="callback">The callback function to receive the logs.</param>
|
||||
</member>
|
||||
<member name="T:Cryville.Common.Logging.StreamLoggerListener">
|
||||
<summary>
|
||||
A <see cref="T:Cryville.Common.Logging.LoggerListener" /> that writes logs into a stream.
|
||||
</summary>
|
||||
<param name="stream">The stream.</param>
|
||||
<param name="encoding">The encoding.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.StreamLoggerListener.#ctor(System.IO.Stream,System.Text.Encoding)">
|
||||
<summary>
|
||||
A <see cref="T:Cryville.Common.Logging.LoggerListener" /> that writes logs into a stream.
|
||||
</summary>
|
||||
<param name="stream">The stream.</param>
|
||||
<param name="encoding">The encoding.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.StreamLoggerListener.#ctor(System.IO.Stream)">
|
||||
<summary>
|
||||
Creates an instance of the <see cref="T:Cryville.Common.Logging.StreamLoggerListener" /> class.
|
||||
</summary>
|
||||
<param name="stream">The stream.</param>
|
||||
</member>
|
||||
<member name="P:Cryville.Common.Logging.StreamLoggerListener.AutoFlush">
|
||||
<summary>
|
||||
Whether to flush the stream every time a log is written.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Cryville.Common.Logging.StreamLoggerListener.OnLog(System.Int32,System.String,System.String)">
|
||||
<inheritdoc />
|
||||
</member>
|
||||
<member name="T:Cryville.Common.Logging.LogHandler">
|
||||
<summary>
|
||||
Represents the method that will handle a log.
|
||||
</summary>
|
||||
<param name="level">The severity level.</param>
|
||||
<param name="category">The category.</param>
|
||||
<param name="message">The message.</param>
|
||||
</member>
|
||||
</members>
|
||||
</doc>
|
7
Assets/Plugins/Cryville.Common.Logging.xml.meta
Normal file
7
Assets/Plugins/Cryville.Common.Logging.xml.meta
Normal file
@@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 72ded0675457e0348809193a9c1092b5
|
||||
TextScriptImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Assets/Plugins/Cryville.EEW.CENCStrongGroundMotion.Map.dll
Normal file
BIN
Assets/Plugins/Cryville.EEW.CENCStrongGroundMotion.Map.dll
Normal file
Binary file not shown.
@@ -0,0 +1,33 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 550171b48a648b34e9ce5f1aba6244f1
|
||||
PluginImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
iconMap: {}
|
||||
executionOrder: {}
|
||||
defineConstraints: []
|
||||
isPreloaded: 0
|
||||
isOverridable: 0
|
||||
isExplicitlyReferenced: 0
|
||||
validateReferences: 1
|
||||
platformData:
|
||||
- first:
|
||||
Any:
|
||||
second:
|
||||
enabled: 1
|
||||
settings: {}
|
||||
- first:
|
||||
Editor: Editor
|
||||
second:
|
||||
enabled: 0
|
||||
settings:
|
||||
DefaultValueInitialized: true
|
||||
- first:
|
||||
Windows Store Apps: WindowsStoreApps
|
||||
second:
|
||||
enabled: 0
|
||||
settings:
|
||||
CPU: AnyCPU
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Plugins/Cryville.EEW.CENCStrongGroundMotion.dll
Normal file
BIN
Assets/Plugins/Cryville.EEW.CENCStrongGroundMotion.dll
Normal file
Binary file not shown.
33
Assets/Plugins/Cryville.EEW.CENCStrongGroundMotion.dll.meta
Normal file
33
Assets/Plugins/Cryville.EEW.CENCStrongGroundMotion.dll.meta
Normal file
@@ -0,0 +1,33 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 0f848a4ea2f35e7449e584beee48c659
|
||||
PluginImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
iconMap: {}
|
||||
executionOrder: {}
|
||||
defineConstraints: []
|
||||
isPreloaded: 0
|
||||
isOverridable: 0
|
||||
isExplicitlyReferenced: 0
|
||||
validateReferences: 1
|
||||
platformData:
|
||||
- first:
|
||||
Any:
|
||||
second:
|
||||
enabled: 1
|
||||
settings: {}
|
||||
- first:
|
||||
Editor: Editor
|
||||
second:
|
||||
enabled: 0
|
||||
settings:
|
||||
DefaultValueInitialized: true
|
||||
- first:
|
||||
Windows Store Apps: WindowsStoreApps
|
||||
second:
|
||||
enabled: 0
|
||||
settings:
|
||||
CPU: AnyCPU
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Assets/Plugins/Cryville.EEW.GeoNet.Map.dll
Normal file
BIN
Assets/Plugins/Cryville.EEW.GeoNet.Map.dll
Normal file
Binary file not shown.
33
Assets/Plugins/Cryville.EEW.GeoNet.Map.dll.meta
Normal file
33
Assets/Plugins/Cryville.EEW.GeoNet.Map.dll.meta
Normal file
@@ -0,0 +1,33 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 9add703a85e306e41a5f1f424b9e5980
|
||||
PluginImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
iconMap: {}
|
||||
executionOrder: {}
|
||||
defineConstraints: []
|
||||
isPreloaded: 0
|
||||
isOverridable: 0
|
||||
isExplicitlyReferenced: 0
|
||||
validateReferences: 1
|
||||
platformData:
|
||||
- first:
|
||||
Any:
|
||||
second:
|
||||
enabled: 1
|
||||
settings: {}
|
||||
- first:
|
||||
Editor: Editor
|
||||
second:
|
||||
enabled: 0
|
||||
settings:
|
||||
DefaultValueInitialized: true
|
||||
- first:
|
||||
Windows Store Apps: WindowsStoreApps
|
||||
second:
|
||||
enabled: 0
|
||||
settings:
|
||||
CPU: AnyCPU
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Plugins/Cryville.EEW.GeoNet.TTS.dll
Normal file
BIN
Assets/Plugins/Cryville.EEW.GeoNet.TTS.dll
Normal file
Binary file not shown.
33
Assets/Plugins/Cryville.EEW.GeoNet.TTS.dll.meta
Normal file
33
Assets/Plugins/Cryville.EEW.GeoNet.TTS.dll.meta
Normal file
@@ -0,0 +1,33 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 1fa7d6d104052f447b49fc53f65d55cd
|
||||
PluginImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
iconMap: {}
|
||||
executionOrder: {}
|
||||
defineConstraints: []
|
||||
isPreloaded: 0
|
||||
isOverridable: 0
|
||||
isExplicitlyReferenced: 0
|
||||
validateReferences: 1
|
||||
platformData:
|
||||
- first:
|
||||
Any:
|
||||
second:
|
||||
enabled: 1
|
||||
settings: {}
|
||||
- first:
|
||||
Editor: Editor
|
||||
second:
|
||||
enabled: 0
|
||||
settings:
|
||||
DefaultValueInitialized: true
|
||||
- first:
|
||||
Windows Store Apps: WindowsStoreApps
|
||||
second:
|
||||
enabled: 0
|
||||
settings:
|
||||
CPU: AnyCPU
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Plugins/Cryville.EEW.GeoNet.dll
Normal file
BIN
Assets/Plugins/Cryville.EEW.GeoNet.dll
Normal file
Binary file not shown.
33
Assets/Plugins/Cryville.EEW.GeoNet.dll.meta
Normal file
33
Assets/Plugins/Cryville.EEW.GeoNet.dll.meta
Normal file
@@ -0,0 +1,33 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 590f9955e3e1e36458e2f7b807a05188
|
||||
PluginImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
iconMap: {}
|
||||
executionOrder: {}
|
||||
defineConstraints: []
|
||||
isPreloaded: 0
|
||||
isOverridable: 0
|
||||
isExplicitlyReferenced: 0
|
||||
validateReferences: 1
|
||||
platformData:
|
||||
- first:
|
||||
Any:
|
||||
second:
|
||||
enabled: 1
|
||||
settings: {}
|
||||
- first:
|
||||
Editor: Editor
|
||||
second:
|
||||
enabled: 0
|
||||
settings:
|
||||
DefaultValueInitialized: true
|
||||
- first:
|
||||
Windows Store Apps: WindowsStoreApps
|
||||
second:
|
||||
enabled: 0
|
||||
settings:
|
||||
CPU: AnyCPU
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -14,10 +14,10 @@
|
||||
The shared instance of the <see cref="T:Cryville.EEW.TTS.EmptyTTSMessageGeneratorContext" /> class.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.TTS.EmptyTTSMessageGeneratorContext.LocationConverter">
|
||||
<member name="P:Cryville.EEW.TTS.EmptyTTSMessageGeneratorContext.NowcastWarningDelayTolerance">
|
||||
<inheritdoc />
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.TTS.EmptyTTSMessageGeneratorContext.NowcastWarningDelayTolerance">
|
||||
<member name="M:Cryville.EEW.TTS.EmptyTTSMessageGeneratorContext.NameLocation(System.Double,System.Double,System.Globalization.CultureInfo,System.Globalization.CultureInfo@,System.String@)">
|
||||
<inheritdoc />
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.TTS.ITTSMessageGeneratorContext">
|
||||
@@ -25,16 +25,22 @@
|
||||
Represents a context used in TTS message generators.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.TTS.ITTSMessageGeneratorContext.LocationConverter">
|
||||
<summary>
|
||||
The location converter.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.TTS.ITTSMessageGeneratorContext.NowcastWarningDelayTolerance">
|
||||
<summary>
|
||||
The delay tolerance before a nowcast warning event cannot trigger sounds and TTS.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.TTS.ITTSMessageGeneratorContext.NameLocation(System.Double,System.Double,System.Globalization.CultureInfo,System.Globalization.CultureInfo@,System.String@)">
|
||||
<summary>
|
||||
Names a location in a culture.
|
||||
</summary>
|
||||
<param name="lat">The latitude of the location.</param>
|
||||
<param name="lon">The longitude of the location.</param>
|
||||
<param name="localCulture">The local culture supported by the event itself.</param>
|
||||
<param name="targetCulture">The target culture of the location name. When the method returns, set to the actual culture of the location name.</param>
|
||||
<param name="name">The location name.</param>
|
||||
<returns>Whether the name is given by the context. <see langword="false" /> if the generator should provide a local name instead.</returns>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.TTS.TTSEntry">
|
||||
<summary>
|
||||
Represents an entry sent to a TTS worker.
|
||||
@@ -101,7 +107,7 @@
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.TTS.TTSEntry.IssueTime">
|
||||
<summary>
|
||||
The time when the entry is created.
|
||||
The time when the entry is created in UTC.
|
||||
</summary>
|
||||
</member>
|
||||
</members>
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -30,17 +30,17 @@
|
||||
<param name="amount">The amount of phase to increment.</param>
|
||||
<returns>The next delay value.</returns>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.EmptyLocationConverter">
|
||||
<member name="T:Cryville.EEW.EmptyLocationNamer">
|
||||
<summary>
|
||||
An empty <see cref="T:Cryville.EEW.ILocationConverter" />.
|
||||
An empty <see cref="T:Cryville.EEW.ILocationNamer" />.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.EmptyLocationConverter.Instance">
|
||||
<member name="P:Cryville.EEW.EmptyLocationNamer.Instance">
|
||||
<summary>
|
||||
The shared instance of the <see cref="T:Cryville.EEW.EmptyLocationConverter" /> class.
|
||||
The shared instance of the <see cref="T:Cryville.EEW.EmptyLocationNamer" /> class.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.EmptyLocationConverter.Convert(Cryville.EEW.INamedLocation,System.Globalization.CultureInfo@)">
|
||||
<member name="M:Cryville.EEW.EmptyLocationNamer.Name(System.Double,System.Double,System.Globalization.CultureInfo@,System.Int32@)">
|
||||
<inheritdoc />
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.GeoUtils">
|
||||
@@ -76,6 +76,20 @@
|
||||
The shared instance of the <see cref="T:Cryville.EEW.Heartbeat" /> class.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.HttpExtensions">
|
||||
<summary>
|
||||
Provides a set of <see langword="static" /> methods related to HTTP.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.HttpExtensions.EnsureNonErrorStatusCode(System.Net.Http.HttpResponseMessage)">
|
||||
<summary>
|
||||
Throws an exception if the HTTP response has a client error status code (400~499) or a server error status code (500~599).
|
||||
</summary>
|
||||
<param name="response">The response message.</param>
|
||||
<returns>The response message if there is no error.</returns>
|
||||
<exception cref="T:System.InvalidOperationException">The response has a client error status code (400~499).</exception>
|
||||
<exception cref="T:System.Net.Http.HttpRequestException">The response has a server error status code (500~599).</exception>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.HttpPullWorker">
|
||||
<summary>
|
||||
A source worker that pulls events with HTTP GET requests.
|
||||
@@ -117,6 +131,34 @@
|
||||
<returns>The task.</returns>
|
||||
<exception cref="T:System.InvalidOperationException">The server responses with an unhandled status code.</exception>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.HttpPullWorker.HandleRawResponse(System.Net.Http.HttpResponseMessage,System.Threading.CancellationToken)">
|
||||
<summary>
|
||||
Handles a raw response message.
|
||||
</summary>
|
||||
<param name="response">The response message.</param>
|
||||
<param name="cancellationToken">A cancellation token.</param>
|
||||
<returns>A task.</returns>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.HttpPullWorker.TryGetAsync(System.Uri,System.Threading.CancellationToken,System.Boolean,System.Int32)">
|
||||
<summary>
|
||||
Try to send a GET request to the specified URI.
|
||||
</summary>
|
||||
<param name="uri">The URI.</param>
|
||||
<param name="cancellationToken">The cancellation token.</param>
|
||||
<param name="retryOnErrorStatusCode">Whether to retry if the server responses with an error status code.</param>
|
||||
<param name="retries">Times to retry before the request fails.</param>
|
||||
<returns>The response message, or <see langword="null" /> if the request fails.</returns>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.HttpPullWorker.TrySendAsync(System.Func{System.Net.Http.HttpRequestMessage},System.Threading.CancellationToken,System.Boolean,System.Int32)">
|
||||
<summary>
|
||||
Try to send a request to the specified URI.
|
||||
</summary>
|
||||
<param name="msgFactory">A function that creates the request message.</param>
|
||||
<param name="cancellationToken">The cancellation token.</param>
|
||||
<param name="retryOnErrorStatusCode">Whether to retry if the server responses with an error status code.</param>
|
||||
<param name="retries">Times to retry before the request fails.</param>
|
||||
<returns>The response message, or <see langword="null" /> if the request fails.</returns>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.HttpPullWorker.GetUri">
|
||||
<summary>
|
||||
Gets the URI of the next request, usually based on <see cref="P:Cryville.EEW.HttpPullWorker.BaseUri" />.
|
||||
@@ -128,7 +170,7 @@
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.HttpPullWorker.AfterHandled(System.Threading.CancellationToken)">
|
||||
<summary>
|
||||
Called when a response is handled successfully, or when the server reponses with No Content (204) or Not Modified (304).
|
||||
Called when a response is handled successfully, or when the server responses with a non-error status code (100~399).
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.HttpPullWorker.Handle(System.IO.Stream,System.Net.Http.Headers.HttpResponseHeaders,System.Threading.CancellationToken)">
|
||||
@@ -213,18 +255,20 @@
|
||||
<param name="culture">The preferred culture of the generated object. When the method returns, set to the actual culture of the generated object.</param>
|
||||
<returns>The generated object.</returns>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.ILocationConverter">
|
||||
<member name="T:Cryville.EEW.ILocationNamer">
|
||||
<summary>
|
||||
Represents a converter that converts a named location to a name in a specified culture.
|
||||
Represents a namer that names a location in a specified culture.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.ILocationConverter.Convert(Cryville.EEW.INamedLocation,System.Globalization.CultureInfo@)">
|
||||
<member name="M:Cryville.EEW.ILocationNamer.Name(System.Double,System.Double,System.Globalization.CultureInfo@,System.Int32@)">
|
||||
<summary>
|
||||
Converts a named location to a name in a specified culture.
|
||||
Names a location in a specified culture.
|
||||
</summary>
|
||||
<param name="location">The named location.</param>
|
||||
<param name="lat">The latitude.</param>
|
||||
<param name="lon">The longitude.</param>
|
||||
<param name="culture">The preferred culture of the name. When the method returns, set to the actual culture of the name.</param>
|
||||
<returns>The converted name.</returns>
|
||||
<param name="specificity">The preferred specificity of the name. When the method returns, set to the actual specificity of the name.</param>
|
||||
<returns>The name.</returns>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.ISourceWorker">
|
||||
<summary>
|
||||
@@ -349,6 +393,16 @@
|
||||
<returns>The string of the specified name in the resource.</returns>
|
||||
<exception cref="T:System.Collections.Generic.KeyNotFoundException">The string of the specified name is not found.</exception>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.MessageStringSetExtensions.GetStringOrDefault(Cryville.EEW.IMessageStringSet,System.String,System.String)">
|
||||
<summary>
|
||||
Gets a string in the string set, or a default string in the string set if not found.
|
||||
</summary>
|
||||
<param name="set">The string set.</param>
|
||||
<param name="name">The name of the string.</param>
|
||||
<param name="defaultName">The name of the default string.</param>
|
||||
<returns>The string of the specified name in the resource, or the default string of the specified default name in the string set if not found.</returns>
|
||||
<exception cref="T:System.Collections.Generic.KeyNotFoundException">The default string of the specified default name is not found.</exception>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.MessageStringSetExtensions.GetStringSetRequired(Cryville.EEW.IMessageStringSet,System.String)">
|
||||
<summary>
|
||||
Gets a string set in the string set.
|
||||
@@ -537,6 +591,61 @@
|
||||
<member name="P:Cryville.EEW.Models.GeoJSON.Feature.Properties">
|
||||
<summary>The properties of the feature.</summary>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.Models.GeoJSON.Feature`1">
|
||||
<summary>
|
||||
Represents a spatially bounded thing.
|
||||
</summary>
|
||||
<typeparam name="T">The type of the properties.</typeparam>
|
||||
<param name="Id">A JSON string or number representing the commonly used identifier of the feature.</param>
|
||||
<param name="Geometry">The geometry of the feature.</param>
|
||||
<param name="Properties">The properties of the feature.</param>
|
||||
<param name="BoundingBox">The bounding box.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.Models.GeoJSON.Feature`1.#ctor(System.Text.Json.JsonElement,Cryville.EEW.Models.GeoJSON.Geometry,`0,System.Double[])">
|
||||
<summary>
|
||||
Represents a spatially bounded thing.
|
||||
</summary>
|
||||
<typeparam name="T">The type of the properties.</typeparam>
|
||||
<param name="Id">A JSON string or number representing the commonly used identifier of the feature.</param>
|
||||
<param name="Geometry">The geometry of the feature.</param>
|
||||
<param name="Properties">The properties of the feature.</param>
|
||||
<param name="BoundingBox">The bounding box.</param>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.Models.GeoJSON.Feature`1.Id">
|
||||
<summary>A JSON string or number representing the commonly used identifier of the feature.</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.Models.GeoJSON.Feature`1.Geometry">
|
||||
<summary>The geometry of the feature.</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.Models.GeoJSON.Feature`1.Properties">
|
||||
<summary>The properties of the feature.</summary>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.Models.GeoJSON.IFeature`1">
|
||||
<summary>
|
||||
Represents a spatially bounded thing.
|
||||
</summary>
|
||||
<typeparam name="T">The type of the properties.</typeparam>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.Models.GeoJSON.IFeature`1.Id">
|
||||
<summary>
|
||||
A JSON string or number representing the commonly used identifier of the feature.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.Models.GeoJSON.IFeature`1.Geometry">
|
||||
<summary>
|
||||
The geometry of the feature.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.Models.GeoJSON.IFeature`1.Properties">
|
||||
<summary>
|
||||
The properties of the feature.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.Models.GeoJSON.IFeature`1.BoundingBox">
|
||||
<summary>
|
||||
The bounding box.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.Models.GeoJSON.FeatureCollection">
|
||||
<summary>
|
||||
Represents a feature collection.
|
||||
@@ -554,6 +663,25 @@
|
||||
<member name="P:Cryville.EEW.Models.GeoJSON.FeatureCollection.Features">
|
||||
<summary>The features.</summary>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.Models.GeoJSON.FeatureCollection`1">
|
||||
<summary>
|
||||
Represents a feature collection.
|
||||
</summary>
|
||||
<typeparam name="T">The type of the properties of the features.</typeparam>
|
||||
<param name="Features">The features.</param>
|
||||
<param name="BoundingBox">The bounding box.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.Models.GeoJSON.FeatureCollection`1.#ctor(Cryville.EEW.Models.GeoJSON.Feature{`0}[],System.Double[])">
|
||||
<summary>
|
||||
Represents a feature collection.
|
||||
</summary>
|
||||
<typeparam name="T">The type of the properties of the features.</typeparam>
|
||||
<param name="Features">The features.</param>
|
||||
<param name="BoundingBox">The bounding box.</param>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.Models.GeoJSON.FeatureCollection`1.Features">
|
||||
<summary>The features.</summary>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.Models.GeoJSON.GeoJSONObject">
|
||||
<summary>
|
||||
A Geometry, Feature, or collection of Features.
|
||||
@@ -960,61 +1088,6 @@
|
||||
</summary>
|
||||
<param name="value">An instance of the <see cref="T:Cryville.EEW.Models.XmlSerializedDateTimeOffset" /> struct.</param>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.INamedLocation">
|
||||
<summary>
|
||||
Represents a named location.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.INamedLocation.Name">
|
||||
<summary>
|
||||
The source name of the location.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.INamedLocation.Culture">
|
||||
<summary>
|
||||
The source culture of <see cref="P:Cryville.EEW.INamedLocation.Name" />.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.INamedLocation.Latitude">
|
||||
<summary>
|
||||
The latitude of the location.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.INamedLocation.Longitude">
|
||||
<summary>
|
||||
The longitude of the location.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.NamedLocation">
|
||||
<summary>
|
||||
Represents a named location.
|
||||
</summary>
|
||||
<param name="Name">The source name of the location.</param>
|
||||
<param name="Culture">The source culture of <paramref name="Name" />.</param>
|
||||
<param name="Latitude">The latitude of the location.</param>
|
||||
<param name="Longitude">The longitude of the location.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.NamedLocation.#ctor(System.String,System.Globalization.CultureInfo,System.Double,System.Double)">
|
||||
<summary>
|
||||
Represents a named location.
|
||||
</summary>
|
||||
<param name="Name">The source name of the location.</param>
|
||||
<param name="Culture">The source culture of <paramref name="Name" />.</param>
|
||||
<param name="Latitude">The latitude of the location.</param>
|
||||
<param name="Longitude">The longitude of the location.</param>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.NamedLocation.Name">
|
||||
<summary>The source name of the location.</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.NamedLocation.Culture">
|
||||
<summary>The source culture of <paramref name="Name" />.</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.NamedLocation.Latitude">
|
||||
<summary>The latitude of the location.</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.NamedLocation.Longitude">
|
||||
<summary>The longitude of the location.</summary>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.NonstandardDateTimeJsonConverter">
|
||||
<summary>
|
||||
Converts instances of the <see cref="T:System.DateTime" /> struct to or from JSON.
|
||||
@@ -1026,6 +1099,37 @@
|
||||
<member name="M:Cryville.EEW.NonstandardDateTimeJsonConverter.Write(System.Text.Json.Utf8JsonWriter,System.DateTime,System.Text.Json.JsonSerializerOptions)">
|
||||
<inheritdoc />
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.ProgressiveDelay">
|
||||
<summary>
|
||||
A helper class that produces progressive delay.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.ProgressiveDelay.CurrentDelay">
|
||||
<summary>
|
||||
The delay to next tick.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.ProgressiveDelay.#ctor(System.Double,System.Double,System.Double)">
|
||||
<summary>
|
||||
Creates an instance of the <see cref="T:Cryville.EEW.ProgressiveDelay" /> class.
|
||||
</summary>
|
||||
<param name="baseDelay">The minimum delay.</param>
|
||||
<param name="maxDelay">The maximum delay.</param>
|
||||
<param name="delayMultiplier">The multiplier between adjacent delay values.</param>
|
||||
<exception cref="T:System.ArgumentOutOfRangeException"><paramref name="baseDelay" /> is negative or zero. -or- <paramref name="maxDelay" /> is negative or zero. -or- <paramref name="delayMultiplier" /> is less than or equal to 1.</exception>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.ProgressiveDelay.Step(System.Double)">
|
||||
<summary>
|
||||
Decrements the current delay and ticks if the delay has run over.
|
||||
</summary>
|
||||
<param name="amount">The amount of delay to decrement.</param>
|
||||
<returns>Whether to tick.</returns>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.ProgressiveDelay.Reset">
|
||||
<summary>
|
||||
Resets to the base delay.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.Report.EmptyRVMGeneratorContext">
|
||||
<summary>
|
||||
An empty <see cref="T:Cryville.EEW.Report.IRVMGeneratorContext" />.
|
||||
@@ -1039,7 +1143,7 @@
|
||||
<member name="P:Cryville.EEW.Report.EmptyRVMGeneratorContext.SeverityScheme">
|
||||
<inheritdoc />
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.Report.EmptyRVMGeneratorContext.LocationConverter">
|
||||
<member name="M:Cryville.EEW.Report.EmptyRVMGeneratorContext.NameLocation(System.Double,System.Double,System.Globalization.CultureInfo,System.Globalization.CultureInfo@,System.String@,System.Int32@)">
|
||||
<inheritdoc />
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.Report.EmptySeverityScheme">
|
||||
@@ -1061,7 +1165,7 @@
|
||||
</summary>
|
||||
<param name="Latitude">The latitude of the hypocenter.</param>
|
||||
<param name="Longitude">The longitude of the hypocenter.</param>
|
||||
<param name="DateTime">The origin date time.</param>
|
||||
<param name="DateTime">The origin date time in UTC.</param>
|
||||
<param name="Magnitude">The magnitude.</param>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.Report.HypocenterGroupKey.#ctor(System.Double,System.Double,System.DateTime,System.Double)">
|
||||
@@ -1070,7 +1174,7 @@
|
||||
</summary>
|
||||
<param name="Latitude">The latitude of the hypocenter.</param>
|
||||
<param name="Longitude">The longitude of the hypocenter.</param>
|
||||
<param name="DateTime">The origin date time.</param>
|
||||
<param name="DateTime">The origin date time in UTC.</param>
|
||||
<param name="Magnitude">The magnitude.</param>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.Report.HypocenterGroupKey.Latitude">
|
||||
@@ -1080,7 +1184,7 @@
|
||||
<summary>The longitude of the hypocenter.</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.Report.HypocenterGroupKey.DateTime">
|
||||
<summary>The origin date time.</summary>
|
||||
<summary>The origin date time in UTC.</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.Report.HypocenterGroupKey.Magnitude">
|
||||
<summary>The magnitude.</summary>
|
||||
@@ -1192,10 +1296,34 @@
|
||||
The severity scheme.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.Report.IRVMGeneratorContext.LocationConverter">
|
||||
<member name="M:Cryville.EEW.Report.IRVMGeneratorContext.NameLocation(System.Double,System.Double,System.Globalization.CultureInfo,System.Globalization.CultureInfo@,System.String@,System.Int32@)">
|
||||
<summary>
|
||||
The location converter.
|
||||
Names a location in a culture.
|
||||
</summary>
|
||||
<param name="lat">The latitude of the location.</param>
|
||||
<param name="lon">The longitude of the location.</param>
|
||||
<param name="localCulture">The local culture supported by the event itself.</param>
|
||||
<param name="targetCulture">The target culture of the location name. When the method returns, set to the actual culture of the location name.</param>
|
||||
<param name="name">The location name.</param>
|
||||
<param name="specificity">The location specificity. See <see cref="P:Cryville.EEW.Report.ReportViewModel.LocationSpecificity" />.</param>
|
||||
<returns>Whether the name is given by the context. <see langword="false" /> if the generator should provide a local name instead.</returns>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.Report.RVMGeneratorContextExtensions">
|
||||
<summary>
|
||||
Provides a set of <see langword="static" /> methods related to <see cref="T:Cryville.EEW.Report.IRVMGeneratorContext" />.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.Report.RVMGeneratorContextExtensions.NameLocationTo(Cryville.EEW.Report.IRVMGeneratorContext,Cryville.EEW.Report.ReportViewModel,System.Double,System.Double,System.Globalization.CultureInfo,System.Globalization.CultureInfo)">
|
||||
<summary>
|
||||
Names a location in a culture and sets the result to a report view model.
|
||||
</summary>
|
||||
<param name="context">The context.</param>
|
||||
<param name="e">The report view model.</param>
|
||||
<param name="lat">The latitude of the location.</param>
|
||||
<param name="lon">The longitude of the location.</param>
|
||||
<param name="localCulture">The local culture supported by the event itself.</param>
|
||||
<param name="targetCulture">The target culture of the location name. When the method returns, set to the actual culture of the location name.</param>
|
||||
<returns>Whether the name is given by the context. <see langword="false" /> if the generator should provide a local name instead.</returns>
|
||||
</member>
|
||||
<member name="T:Cryville.EEW.Report.ISeverityScheme">
|
||||
<summary>
|
||||
@@ -1336,11 +1464,6 @@
|
||||
<see cref="P:Cryville.EEW.Report.ReportViewModel.InvalidatedTime" /> converted to UTC.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.Report.ReportViewModel.IssueTime">
|
||||
<summary>
|
||||
The time when the report is issued, in the time zone indicated by <see cref="P:Cryville.EEW.Report.ReportViewModel.TimeZone" />.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:Cryville.EEW.Report.ReportViewModel.UtcIssueTime">
|
||||
<summary>
|
||||
The time when the report is issued, in UTC.
|
||||
@@ -1464,14 +1587,6 @@
|
||||
The parent type.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.Report.ReportViewModelPropertyType.#ctor(System.String,Cryville.EEW.Report.ReportViewModelPropertyType)">
|
||||
<summary>
|
||||
Creates an instance of the <see cref="T:Cryville.EEW.Report.ReportViewModelPropertyType" /> class.
|
||||
</summary>
|
||||
<param name="name">The name of the type.</param>
|
||||
<param name="parent">The parent type.</param>
|
||||
<exception cref="T:System.ArgumentException"><paramref name="name" /> contains the sub-type delimiter <c>:</c>.</exception>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.Report.ReportViewModelPropertyType.OfSubtype(System.String)">
|
||||
<summary>
|
||||
Creates a sub-type from this type.
|
||||
@@ -1482,6 +1597,14 @@
|
||||
<member name="M:Cryville.EEW.Report.ReportViewModelPropertyType.ToString">
|
||||
<inheritdoc/>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.Report.ReportViewModelPropertyType.Of(System.String,Cryville.EEW.Report.ReportViewModelPropertyType)">
|
||||
<summary>
|
||||
Gets an instance of the <see cref="T:Cryville.EEW.Report.ReportViewModelPropertyType" /> class.
|
||||
</summary>
|
||||
<param name="name">The name of the type.</param>
|
||||
<param name="parent">The parent type.</param>
|
||||
<exception cref="T:System.ArgumentException"><paramref name="name" /> contains the sub-type delimiter <c>:</c>.</exception>
|
||||
</member>
|
||||
<member name="M:Cryville.EEW.Report.ReportViewModelPropertyType.FromString(System.String)">
|
||||
<summary>
|
||||
Creates a report view model property type from a string.
|
||||
|
Binary file not shown.
@@ -1,5 +1,5 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 04c265355b02a924eb0c82f0d1be0676
|
||||
guid: 33ce0e71590119e4f803932e358b4593
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
@@ -0,0 +1,102 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace SpeechLib {
|
||||
/// <summary>Marshals the COM <see langword="IEnumVARIANT" /> interface to the .NET Framework <see cref="T:System.Collections.IEnumerator" /> interface, and vice versa.</summary>
|
||||
public class EnumeratorToEnumVariantMarshaler : ICustomMarshaler {
|
||||
[ComImport]
|
||||
[Guid("00020404-0000-0000-C000-000000000046")]
|
||||
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
|
||||
private interface IEnumVARIANT {
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Next(int celt, [MarshalAs(UnmanagedType.Struct)] out object rgvar, out uint pceltFetched);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Skip(uint celt);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Reset();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
IEnumVARIANT Clone();
|
||||
}
|
||||
|
||||
private class VARIANTEnumerator : IEnumerator {
|
||||
private IEnumVARIANT com_enum;
|
||||
|
||||
private object current;
|
||||
|
||||
public object Current => current;
|
||||
|
||||
public VARIANTEnumerator(IEnumVARIANT com_enum) {
|
||||
this.com_enum = com_enum;
|
||||
}
|
||||
|
||||
public bool MoveNext() {
|
||||
uint pceltFetched = 0u;
|
||||
com_enum.Next(1, out var rgvar, out pceltFetched);
|
||||
if (pceltFetched == 0) {
|
||||
return false;
|
||||
}
|
||||
current = rgvar;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void Reset() {
|
||||
com_enum.Reset();
|
||||
}
|
||||
}
|
||||
|
||||
private static EnumeratorToEnumVariantMarshaler instance;
|
||||
|
||||
/// <summary>Performs necessary cleanup of the managed data when it is no longer needed.</summary>
|
||||
/// <param name="pManagedObj">The managed object to be destroyed.</param>
|
||||
public void CleanUpManagedData(object pManagedObj) {
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
/// <summary>Performs necessary cleanup of the unmanaged data when it is no longer needed.</summary>
|
||||
/// <param name="pNativeData">A pointer to the unmanaged data to be destroyed.</param>
|
||||
public void CleanUpNativeData(IntPtr pNativeData) {
|
||||
Marshal.Release(pNativeData);
|
||||
}
|
||||
|
||||
/// <summary>Returns an instance of the custom marshaler.</summary>
|
||||
/// <param name="pstrCookie">String "cookie" parameter that can be used by the custom marshaler.</param>
|
||||
/// <returns>An instance of the custom marshaler.</returns>
|
||||
public static ICustomMarshaler GetInstance(string pstrCookie) {
|
||||
if (instance == null) {
|
||||
instance = new EnumeratorToEnumVariantMarshaler();
|
||||
}
|
||||
return instance;
|
||||
}
|
||||
|
||||
/// <summary>Returns the size in bytes of the unmanaged data to be marshaled.</summary>
|
||||
/// <returns>-1 to indicate the type this marshaler handles is not a value type.</returns>
|
||||
public int GetNativeDataSize() {
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
/// <summary>Marshals an object from managed code to unmanaged code.</summary>
|
||||
/// <param name="pManagedObj">The managed object to be converted.</param>
|
||||
/// <returns>A pointer to the unmanaged object.</returns>
|
||||
/// <exception cref="T:System.ArgumentNullException">
|
||||
/// <paramref name="pManagedObj" /> is <see langword="null" />.</exception>
|
||||
public IntPtr MarshalManagedToNative(object pManagedObj) {
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
/// <summary>Marshals an object from unmanaged code to managed code.</summary>
|
||||
/// <param name="pNativeData">A pointer to the unmanaged object to be converted.</param>
|
||||
/// <returns>A managed object.</returns>
|
||||
/// <exception cref="T:System.ArgumentNullException">
|
||||
/// <paramref name="pNativeData" /> is <see langword="null" />.</exception>
|
||||
/// <exception cref="T:System.InvalidCastException">The unmanaged object that <paramref name="pNativeData" /> points to could not be converted.</exception>
|
||||
public object MarshalNativeToManaged(IntPtr pNativeData) {
|
||||
return new VARIANTEnumerator((IEnumVARIANT)Marshal.GetObjectForIUnknown(pNativeData));
|
||||
}
|
||||
}
|
||||
}
|
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 57f24b2017eba4d4eb634cf86ae099af
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@@ -0,0 +1,29 @@
|
||||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace SpeechLib {
|
||||
[ComImport]
|
||||
[InterfaceType(1)]
|
||||
[Guid("06B64F9E-7FDA-11D2-B4F2-00C04F797396")]
|
||||
[TypeLibType(512)]
|
||||
public interface IEnumSpObjectTokens {
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Next([In] uint celt, [MarshalAs(UnmanagedType.Interface)] out ISpObjectToken pelt, out uint pceltFetched);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Skip([In] uint celt);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Reset();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Clone([MarshalAs(UnmanagedType.Interface)] out SpMMAudioEnum ppEnum);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Item([In] uint Index, [MarshalAs(UnmanagedType.Interface)] out ISpObjectToken ppToken);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetCount(out uint pCount);
|
||||
}
|
||||
}
|
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b8d9b83debeb9c244a52757c270bd3ff
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
47
Assets/Plugins/Windows/Interop.SpeechLib/ISpDataKey.cs
Normal file
47
Assets/Plugins/Windows/Interop.SpeechLib/ISpDataKey.cs
Normal file
@@ -0,0 +1,47 @@
|
||||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace SpeechLib {
|
||||
[ComImport]
|
||||
[TypeLibType(512)]
|
||||
[Guid("14056581-E16C-11D2-BB90-00C04F8EE6C0")]
|
||||
[InterfaceType(1)]
|
||||
public interface ISpDataKey {
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetData([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [In] uint cbData, [In] ref byte pData);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetData([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [In] ref uint pcbData, out byte pData);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetStringValue([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [In][MarshalAs(UnmanagedType.LPWStr)] string pszValue);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetStringValue([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [MarshalAs(UnmanagedType.LPWStr)] out string ppszValue);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetDWORD([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [In] uint dwValue);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetDWORD([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, out uint pdwValue);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void OpenKey([In][MarshalAs(UnmanagedType.LPWStr)] string pszSubKeyName, [MarshalAs(UnmanagedType.Interface)] out ISpDataKey ppSubKey);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void CreateKey([In][MarshalAs(UnmanagedType.LPWStr)] string pszSubKey, [MarshalAs(UnmanagedType.Interface)] out ISpDataKey ppSubKey);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void DeleteKey([In][MarshalAs(UnmanagedType.LPWStr)] string pszSubKey);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void DeleteValue([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void EnumKeys([In] uint Index, [MarshalAs(UnmanagedType.LPWStr)] out string ppszSubKeyName);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void EnumValues([In] uint Index, [MarshalAs(UnmanagedType.LPWStr)] out string ppszValueName);
|
||||
}
|
||||
}
|
11
Assets/Plugins/Windows/Interop.SpeechLib/ISpDataKey.cs.meta
Normal file
11
Assets/Plugins/Windows/Interop.SpeechLib/ISpDataKey.cs.meta
Normal file
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 53c599adb0888ca488c429446e094a6e
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
41
Assets/Plugins/Windows/Interop.SpeechLib/ISpEventSource.cs
Normal file
41
Assets/Plugins/Windows/Interop.SpeechLib/ISpEventSource.cs
Normal file
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace SpeechLib {
|
||||
[ComImport]
|
||||
[InterfaceType(1)]
|
||||
[Guid("BE7A9CCE-5F9E-11D2-960F-00C04F8EE628")]
|
||||
[TypeLibType(512)]
|
||||
public interface ISpEventSource : ISpNotifySource {
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetNotifySink([In][MarshalAs(UnmanagedType.Interface)] ISpNotifySink pNotifySink);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetNotifyWindowMessage([In][ComAliasName("SpeechLib.wireHWND")] ref _RemotableHandle hWnd, [In] uint Msg, [In][ComAliasName("SpeechLib.UINT_PTR")] ulong wParam, [In][ComAliasName("SpeechLib.LONG_PTR")] long lParam);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetNotifyCallbackFunction([In] ref IntPtr pfnCallback, [In][ComAliasName("SpeechLib.UINT_PTR")] ulong wParam, [In][ComAliasName("SpeechLib.LONG_PTR")] long lParam);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetNotifyCallbackInterface([In] ref IntPtr pSpCallback, [In][ComAliasName("SpeechLib.UINT_PTR")] ulong wParam, [In][ComAliasName("SpeechLib.LONG_PTR")] long lParam);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetNotifyWin32Event();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void WaitForNotifyEvent([In] uint dwMilliseconds);
|
||||
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new IntPtr GetNotifyEventHandle();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetInterest([In] ulong ullEventInterest, [In] ulong ullQueuedInterest);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetEvents([In] uint ulCount, out SPEVENT pEventArray, out uint pulFetched);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetInfo(out SPEVENTSOURCEINFO pInfo);
|
||||
}
|
||||
}
|
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 956b9cc3f6ea4e848971f63146675fca
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
14
Assets/Plugins/Windows/Interop.SpeechLib/ISpNotifySink.cs
Normal file
14
Assets/Plugins/Windows/Interop.SpeechLib/ISpNotifySink.cs
Normal file
@@ -0,0 +1,14 @@
|
||||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace SpeechLib {
|
||||
[ComImport]
|
||||
[TypeLibType(512)]
|
||||
[Guid("259684DC-37C3-11D2-9603-00C04F8EE628")]
|
||||
[InterfaceType(1)]
|
||||
public interface ISpNotifySink {
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Notify();
|
||||
}
|
||||
}
|
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: a8f6204837b45824b8513ceb242f9ec1
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
32
Assets/Plugins/Windows/Interop.SpeechLib/ISpNotifySource.cs
Normal file
32
Assets/Plugins/Windows/Interop.SpeechLib/ISpNotifySource.cs
Normal file
@@ -0,0 +1,32 @@
|
||||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace SpeechLib {
|
||||
[ComImport]
|
||||
[TypeLibType(512)]
|
||||
[InterfaceType(1)]
|
||||
[Guid("5EFF4AEF-8487-11D2-961C-00C04F8EE628")]
|
||||
public interface ISpNotifySource {
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetNotifySink([In][MarshalAs(UnmanagedType.Interface)] ISpNotifySink pNotifySink);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetNotifyWindowMessage([In][ComAliasName("SpeechLib.wireHWND")] ref _RemotableHandle hWnd, [In] uint Msg, [In][ComAliasName("SpeechLib.UINT_PTR")] ulong wParam, [In][ComAliasName("SpeechLib.LONG_PTR")] long lParam);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetNotifyCallbackFunction([In] ref IntPtr pfnCallback, [In][ComAliasName("SpeechLib.UINT_PTR")] ulong wParam, [In][ComAliasName("SpeechLib.LONG_PTR")] long lParam);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetNotifyCallbackInterface([In] ref IntPtr pSpCallback, [In][ComAliasName("SpeechLib.UINT_PTR")] ulong wParam, [In][ComAliasName("SpeechLib.LONG_PTR")] long lParam);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetNotifyWin32Event();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void WaitForNotifyEvent([In] uint dwMilliseconds);
|
||||
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
IntPtr GetNotifyEventHandle();
|
||||
}
|
||||
}
|
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: dc0e801e79d02c0419ef4ce756d894e8
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
77
Assets/Plugins/Windows/Interop.SpeechLib/ISpObjectToken.cs
Normal file
77
Assets/Plugins/Windows/Interop.SpeechLib/ISpObjectToken.cs
Normal file
@@ -0,0 +1,77 @@
|
||||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace SpeechLib {
|
||||
[ComImport]
|
||||
[Guid("14056589-E16C-11D2-BB90-00C04F8EE6C0")]
|
||||
[TypeLibType(512)]
|
||||
[InterfaceType(1)]
|
||||
public interface ISpObjectToken : ISpDataKey {
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetData([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [In] uint cbData, [In] ref byte pData);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void GetData([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [In] ref uint pcbData, out byte pData);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetStringValue([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [In][MarshalAs(UnmanagedType.LPWStr)] string pszValue);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void GetStringValue([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [MarshalAs(UnmanagedType.LPWStr)] out string ppszValue);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetDWORD([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [In] uint dwValue);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void GetDWORD([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, out uint pdwValue);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void OpenKey([In][MarshalAs(UnmanagedType.LPWStr)] string pszSubKeyName, [MarshalAs(UnmanagedType.Interface)] out ISpDataKey ppSubKey);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void CreateKey([In][MarshalAs(UnmanagedType.LPWStr)] string pszSubKey, [MarshalAs(UnmanagedType.Interface)] out ISpDataKey ppSubKey);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void DeleteKey([In][MarshalAs(UnmanagedType.LPWStr)] string pszSubKey);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void DeleteValue([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void EnumKeys([In] uint Index, [MarshalAs(UnmanagedType.LPWStr)] out string ppszSubKeyName);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void EnumValues([In] uint Index, [MarshalAs(UnmanagedType.LPWStr)] out string ppszValueName);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetId([MarshalAs(UnmanagedType.LPWStr)] string pszCategoryId, [In][MarshalAs(UnmanagedType.LPWStr)] string pszTokenId, [In] int fCreateIfNotExist);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetId([MarshalAs(UnmanagedType.LPWStr)] out string ppszCoMemTokenId);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetCategory([MarshalAs(UnmanagedType.Interface)] out ISpObjectTokenCategory ppTokenCategory);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void CreateInstance([In][MarshalAs(UnmanagedType.IUnknown)] object pUnkOuter, [In] uint dwClsContext, [In] ref Guid riid, out IntPtr ppvObject);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetStorageFileName([In] ref Guid clsidCaller, [In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [In][MarshalAs(UnmanagedType.LPWStr)] string pszFileNameSpecifier, [In] uint nFolder, [MarshalAs(UnmanagedType.LPWStr)] out string ppszFilePath);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void RemoveStorageFileName([In] ref Guid clsidCaller, [In][MarshalAs(UnmanagedType.LPWStr)] string pszKeyName, [In] int fDeleteFile);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Remove(ref Guid pclsidCaller);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void IsUISupported([In][MarshalAs(UnmanagedType.LPWStr)] string pszTypeOfUI, [In] IntPtr pvExtraData, [In] uint cbExtraData, [In][MarshalAs(UnmanagedType.IUnknown)] object punkObject, out int pfSupported);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void DisplayUI([In][ComAliasName("SpeechLib.wireHWND")] ref _RemotableHandle hWndParent, [In][MarshalAs(UnmanagedType.LPWStr)] string pszTitle, [In][MarshalAs(UnmanagedType.LPWStr)] string pszTypeOfUI, [In] IntPtr pvExtraData, [In] uint cbExtraData, [In][MarshalAs(UnmanagedType.IUnknown)] object punkObject);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void MatchesAttributes([In][MarshalAs(UnmanagedType.LPWStr)] string pszAttributes, out int pfMatches);
|
||||
}
|
||||
}
|
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 9dbe636fbecc6d246ac06f0111e1b644
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@@ -0,0 +1,65 @@
|
||||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace SpeechLib {
|
||||
[ComImport]
|
||||
[Guid("2D3D3845-39AF-4850-BBF9-40B49780011D")]
|
||||
[TypeLibType(512)]
|
||||
[InterfaceType(1)]
|
||||
public interface ISpObjectTokenCategory : ISpDataKey {
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetData([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [In] uint cbData, [In] ref byte pData);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void GetData([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [In] ref uint pcbData, out byte pData);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetStringValue([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [In][MarshalAs(UnmanagedType.LPWStr)] string pszValue);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void GetStringValue([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [MarshalAs(UnmanagedType.LPWStr)] out string ppszValue);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetDWORD([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, [In] uint dwValue);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void GetDWORD([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName, out uint pdwValue);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void OpenKey([In][MarshalAs(UnmanagedType.LPWStr)] string pszSubKeyName, [MarshalAs(UnmanagedType.Interface)] out ISpDataKey ppSubKey);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void CreateKey([In][MarshalAs(UnmanagedType.LPWStr)] string pszSubKey, [MarshalAs(UnmanagedType.Interface)] out ISpDataKey ppSubKey);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void DeleteKey([In][MarshalAs(UnmanagedType.LPWStr)] string pszSubKey);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void DeleteValue([In][MarshalAs(UnmanagedType.LPWStr)] string pszValueName);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void EnumKeys([In] uint Index, [MarshalAs(UnmanagedType.LPWStr)] out string ppszSubKeyName);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void EnumValues([In] uint Index, [MarshalAs(UnmanagedType.LPWStr)] out string ppszValueName);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetId([In][MarshalAs(UnmanagedType.LPWStr)] string pszCategoryId, [In] int fCreateIfNotExist);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetId([MarshalAs(UnmanagedType.LPWStr)] out string ppszCoMemCategoryId);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetDataKey([In] SPDATAKEYLOCATION spdkl, [MarshalAs(UnmanagedType.Interface)] out ISpDataKey ppDataKey);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void EnumTokens([In][MarshalAs(UnmanagedType.LPWStr)] string pzsReqAttribs, [In][MarshalAs(UnmanagedType.LPWStr)] string pszOptAttribs, [MarshalAs(UnmanagedType.Interface)] out SpMMAudioEnum ppEnum);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetDefaultTokenId([In][MarshalAs(UnmanagedType.LPWStr)] string pszTokenId);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetDefaultTokenId([MarshalAs(UnmanagedType.LPWStr)] out string ppszCoMemTokenId);
|
||||
}
|
||||
}
|
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 15623e252a155a848a97cf37f60268e8
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@@ -0,0 +1,17 @@
|
||||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace SpeechLib {
|
||||
[ComImport]
|
||||
[TypeLibType(512)]
|
||||
[InterfaceType(1)]
|
||||
[Guid("B2745EFD-42CE-48CA-81F1-A96E02538A90")]
|
||||
public interface ISpPhoneticAlphabetSelection {
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void IsAlphabetUPS(out int pfIsUPS);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetAlphabetToUPS([In] int fForceUPS);
|
||||
}
|
||||
}
|
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: d029aee7bdb974547abcc71e4b1d5c0e
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
49
Assets/Plugins/Windows/Interop.SpeechLib/ISpStreamFormat.cs
Normal file
49
Assets/Plugins/Windows/Interop.SpeechLib/ISpStreamFormat.cs
Normal file
@@ -0,0 +1,49 @@
|
||||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.InteropServices.ComTypes;
|
||||
|
||||
namespace SpeechLib {
|
||||
[ComImport]
|
||||
[ComConversionLoss]
|
||||
[InterfaceType(1)]
|
||||
[Guid("BED530BE-2606-4F4D-A1C0-54C5CDA5566F")]
|
||||
[TypeLibType(512)]
|
||||
public interface ISpStreamFormat : IStream {
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void RemoteRead(out byte pv, [In] uint cb, out uint pcbRead);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void RemoteWrite([In] ref byte pv, [In] uint cb, out uint pcbWritten);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void RemoteSeek([In] _LARGE_INTEGER dlibMove, [In] uint dwOrigin, out _ULARGE_INTEGER plibNewPosition);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetSize([In] _ULARGE_INTEGER libNewSize);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void RemoteCopyTo([In][MarshalAs(UnmanagedType.Interface)] IStream pstm, [In] _ULARGE_INTEGER cb, out _ULARGE_INTEGER pcbRead, out _ULARGE_INTEGER pcbWritten);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Commit([In] uint grfCommitFlags);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void Revert();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void LockRegion([In] _ULARGE_INTEGER libOffset, [In] _ULARGE_INTEGER cb, [In] uint dwLockType);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void UnlockRegion([In] _ULARGE_INTEGER libOffset, [In] _ULARGE_INTEGER cb, [In] uint dwLockType);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Stat(out tagSTATSTG pstatstg, [In] uint grfStatFlag);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void Clone([MarshalAs(UnmanagedType.Interface)] out IStream ppstm);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetFormat([In] ref Guid pguidFormatId, [Out] IntPtr ppCoMemWaveFormatEx);
|
||||
}
|
||||
}
|
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 3757bf8ef8a3f324896a9d3712a52c0d
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
117
Assets/Plugins/Windows/Interop.SpeechLib/ISpVoice.cs
Normal file
117
Assets/Plugins/Windows/Interop.SpeechLib/ISpVoice.cs
Normal file
@@ -0,0 +1,117 @@
|
||||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.InteropServices.ComTypes;
|
||||
|
||||
namespace SpeechLib {
|
||||
[ComImport]
|
||||
[InterfaceType(1)]
|
||||
[Guid("6C44DF74-72B9-4992-A1EC-EF996E0422D4")]
|
||||
[TypeLibType(512)]
|
||||
public interface ISpVoice : ISpEventSource {
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetNotifySink([In][MarshalAs(UnmanagedType.Interface)] ISpNotifySink pNotifySink);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetNotifyWindowMessage([In][ComAliasName("SpeechLib.wireHWND")] ref _RemotableHandle hWnd, [In] uint Msg, [In][ComAliasName("SpeechLib.UINT_PTR")] ulong wParam, [In][ComAliasName("SpeechLib.LONG_PTR")] long lParam);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetNotifyCallbackFunction([In] ref IntPtr pfnCallback, [In][ComAliasName("SpeechLib.UINT_PTR")] ulong wParam, [In][ComAliasName("SpeechLib.LONG_PTR")] long lParam);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetNotifyCallbackInterface([In] ref IntPtr pSpCallback, [In][ComAliasName("SpeechLib.UINT_PTR")] ulong wParam, [In][ComAliasName("SpeechLib.LONG_PTR")] long lParam);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetNotifyWin32Event();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void WaitForNotifyEvent([In] uint dwMilliseconds);
|
||||
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new IntPtr GetNotifyEventHandle();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void SetInterest([In] ulong ullEventInterest, [In] ulong ullQueuedInterest);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void GetEvents([In] uint ulCount, out SPEVENT pEventArray, out uint pulFetched);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
new void GetInfo(out SPEVENTSOURCEINFO pInfo);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetOutput([In][MarshalAs(UnmanagedType.IUnknown)] object pUnkOutput, [In] int fAllowFormatChanges);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetOutputObjectToken([MarshalAs(UnmanagedType.Interface)] out ISpObjectToken ppObjectToken);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetOutputStream([MarshalAs(UnmanagedType.Interface)] out ISpStreamFormat ppStream);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Pause();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Resume();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetVoice([In][MarshalAs(UnmanagedType.Interface)] ISpObjectToken pToken);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetVoice([MarshalAs(UnmanagedType.Interface)] out ISpObjectToken ppToken);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Speak([In][MarshalAs(UnmanagedType.LPWStr)] string pwcs, [In] uint dwFlags, out uint pulStreamNumber);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SpeakStream([In][MarshalAs(UnmanagedType.Interface)] IStream pStream, [In] uint dwFlags, out uint pulStreamNumber);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetStatus(out SPVOICESTATUS pStatus, [MarshalAs(UnmanagedType.LPWStr)] out string ppszLastBookmark);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void Skip([In][MarshalAs(UnmanagedType.LPWStr)] string pItemType, [In] int lNumItems, out uint pulNumSkipped);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetPriority([In] SPVPRIORITY ePriority);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetPriority(out SPVPRIORITY pePriority);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetAlertBoundary([In] SPEVENTENUM eBoundary);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetAlertBoundary(out SPEVENTENUM peBoundary);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetRate([In] int RateAdjust);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetRate(out int pRateAdjust);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetVolume([In] ushort usVolume);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetVolume(out ushort pusVolume);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void WaitUntilDone([In] uint msTimeout);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void SetSyncSpeakTimeout([In] uint msTimeout);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void GetSyncSpeakTimeout(out uint pmsTimeout);
|
||||
|
||||
[MethodImpl(MethodImplOptions.PreserveSig | MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
IntPtr SpeakCompleteEvent();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void IsUISupported([In][MarshalAs(UnmanagedType.LPWStr)] string pszTypeOfUI, [In] IntPtr pvExtraData, [In] uint cbExtraData, out int pfSupported);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
void DisplayUI([In][ComAliasName("SpeechLib.wireHWND")] ref _RemotableHandle hWndParent, [In][MarshalAs(UnmanagedType.LPWStr)] string pszTitle, [In][MarshalAs(UnmanagedType.LPWStr)] string pszTypeOfUI, [In] IntPtr pvExtraData, [In] uint cbExtraData);
|
||||
}
|
||||
}
|
11
Assets/Plugins/Windows/Interop.SpeechLib/ISpVoice.cs.meta
Normal file
11
Assets/Plugins/Windows/Interop.SpeechLib/ISpVoice.cs.meta
Normal file
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 272a8c831aaf44a4d94da0a8f2f29199
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@@ -0,0 +1,47 @@
|
||||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace SpeechLib {
|
||||
[ComImport]
|
||||
[TypeLibType(4160)]
|
||||
[Guid("E6E9C590-3E18-40E3-8299-061F98BDE7C7")]
|
||||
public interface ISpeechAudioFormat {
|
||||
[DispId(1)]
|
||||
SpeechAudioFormatType Type {
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
[param: In]
|
||||
set;
|
||||
}
|
||||
|
||||
[DispId(2)]
|
||||
string Guid {
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
[TypeLibFunc(64)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
[TypeLibFunc(64)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.BStr)]
|
||||
set;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
[TypeLibFunc(64)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
SpWaveFormatEx GetWaveFormatEx();
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[TypeLibFunc(64)]
|
||||
void SetWaveFormatEx([In][MarshalAs(UnmanagedType.Interface)] SpWaveFormatEx SpeechWaveFormatEx);
|
||||
}
|
||||
}
|
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 0121f963d2ad3124f93d8b901dea2ef2
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@@ -0,0 +1,36 @@
|
||||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace SpeechLib {
|
||||
[ComImport]
|
||||
[TypeLibType(4160)]
|
||||
[Guid("6450336F-7D49-4CED-8097-49D6DEE37294")]
|
||||
public interface ISpeechBaseStream {
|
||||
[DispId(1)]
|
||||
SpAudioFormat Format {
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
get;
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
[param: In]
|
||||
[param: MarshalAs(UnmanagedType.Interface)]
|
||||
set;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
int Read([MarshalAs(UnmanagedType.Struct)] out object Buffer, [In] int NumberOfBytes);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
int Write([In][MarshalAs(UnmanagedType.Struct)] object Buffer);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.Struct)]
|
||||
object Seek([In][MarshalAs(UnmanagedType.Struct)] object Position, [In] SpeechStreamSeekPositionType Origin = SpeechStreamSeekPositionType.SSSPTRelativeToStart);
|
||||
}
|
||||
}
|
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b47a20305f9457d4a9178de9ed11508a
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
64
Assets/Plugins/Windows/Interop.SpeechLib/ISpeechDataKey.cs
Normal file
64
Assets/Plugins/Windows/Interop.SpeechLib/ISpeechDataKey.cs
Normal file
@@ -0,0 +1,64 @@
|
||||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace SpeechLib {
|
||||
[ComImport]
|
||||
[TypeLibType(4160)]
|
||||
[Guid("CE17C09B-4EFA-44D5-A4C9-59D9585AB0CD")]
|
||||
public interface ISpeechDataKey {
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(1)]
|
||||
void SetBinaryValue([In][MarshalAs(UnmanagedType.BStr)] string ValueName, [In][MarshalAs(UnmanagedType.Struct)] object Value);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(2)]
|
||||
[return: MarshalAs(UnmanagedType.Struct)]
|
||||
object GetBinaryValue([In][MarshalAs(UnmanagedType.BStr)] string ValueName);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(3)]
|
||||
void SetStringValue([In][MarshalAs(UnmanagedType.BStr)] string ValueName, [In][MarshalAs(UnmanagedType.BStr)] string Value);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(4)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
string GetStringValue([In][MarshalAs(UnmanagedType.BStr)] string ValueName);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(5)]
|
||||
void SetLongValue([In][MarshalAs(UnmanagedType.BStr)] string ValueName, [In] int Value);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(6)]
|
||||
int GetLongValue([In][MarshalAs(UnmanagedType.BStr)] string ValueName);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(7)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
ISpeechDataKey OpenKey([In][MarshalAs(UnmanagedType.BStr)] string SubKeyName);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(8)]
|
||||
[return: MarshalAs(UnmanagedType.Interface)]
|
||||
ISpeechDataKey CreateKey([In][MarshalAs(UnmanagedType.BStr)] string SubKeyName);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(9)]
|
||||
void DeleteKey([In][MarshalAs(UnmanagedType.BStr)] string SubKeyName);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(10)]
|
||||
void DeleteValue([In][MarshalAs(UnmanagedType.BStr)] string ValueName);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(11)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
string EnumKeys([In] int Index);
|
||||
|
||||
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
|
||||
[DispId(12)]
|
||||
[return: MarshalAs(UnmanagedType.BStr)]
|
||||
string EnumValues([In] int Index);
|
||||
}
|
||||
}
|
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 67d9e05beeee4594688ea5fff1341d30
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user