using System.Collections.Generic;
using UnityEngine;
public class DataConfig : MonoBehaviour
{
}
public class objectData
{
public Vector3 pos;
public Vector3 rot;
public Vector3 scale;
}
public enum MaterialType
{
None,
Image,
Video,
Model,
Text,
Image_Video_Text,
Model_Text,
LocaImage,
Vuforia,
}
public enum SpoitType
{
Null,
ShanXin,
PingZiXing,
BingLie,
LunBo,
}
public enum SceneType
{
Vuforial,
PointCloud,
}
public class ObjectTransform
{
public Vector3 startPos { get; set; }
public Vector3 startRot { get; set; }
public Vector3 startScale { get; set; }
public Vector3 nowPos { get; set; }
public Vector3 nowRot { get; set; }
public Vector3 nowScale { get; set; }
public void SetStartValue(Vector3 _startPos, Vector3 _StartRot, Vector3 _startScale)
{
startPos = _startPos;
nowPos = _startPos;
startRot = _StartRot;
nowRot = _StartRot;
startScale = _startScale;
nowScale = _startScale;
}
public void SavePos(Vector3 _startPos, Vector3 _StartRot, Vector3 _startScale)
{
nowPos = _startPos;
nowRot = _StartRot;
nowScale = _startScale;
}
}
///
/// 锚点属性
///
public class Anchor
{
public int id { get; set; }
public bool select { get; set; }
public string pictureName { get; set; }
public ObjectTransform objectTransform { get; set; }
public AnchorPos picturePosition { get; set; }
public string pictureUrl { get; set; }
// public string localloadPath { get; set; }
public Anchor()
{
select = false;
objectTransform = new ObjectTransform();
}
}
///
/// 景点坐标以及触发器坐标和范围
///
public class AnchorPos
{
///
/// 景点所在X | Y轴坐标
///
public double pointRelativeX { get; set; }
public double pointRelativeY { get; set; }
///
/// 景点矩形区域宽高
///
public double areaRelativeW { get; set; }
public double areaRelativeH { get; set; }
///
/// 景点矩形区域所在X Y轴坐标
///
public double areaRelativeX { get; set; }
public double areaRelativeY { get; set; }
}
///
/// 景点坐标以及触发器坐标和范围
///
public class SpoitPos
{
///
/// 景点所在X | Y轴坐标
///
public double pointRelativeX { get; set; }
public double pointRelativeY { get; set; }
///
/// 景点矩形区域宽高
///
public double areaRelativeW { get; set; }
public double areaRelativeH { get; set; }
///
/// 景点矩形区域所在X Y轴坐标
///
public double areaRelativeX { get; set; }
public double areaRelativeY { get; set; }
}
///
/// 单个素材属性
///
public class MaterialObjValue
{
public string uid { get; set; }
//素材名称
public string name { get; set; }
///
/// 素材类型
///
public string type { get; set; }
///
/// 文本内容
///
public string textContent { get; set; }
///
/// 文字位置(如果类型不为文字 则为NULL)
///
public string textPosition { get; set; }
///
/// 文本框背景
///
public string TextBJ { get; set; }
///
/// 下载地址
///
public string DownloadPath { get; set; }
///
/// 本地保存地址
///
public string localSavePath { get; set; }
///
/// 素材位置信息
/// 文字传递的是方位,其余类型场地为空值
///
public ObjectTransform ObjectTransform { get; set; }
}
///
/// 景点下素材组合
///
public class MaterialObl
{
///
/// 主键id
///
public int id { get; set; }
///
/// 是否设置过素材
///
public bool select { get; set; }
///
/// 素材名称
///
public string name { get; set; }
///
/// 素材类型 1图片 2视频 3模型 4文字 5图片+文字/视频+文字 6模型+文字
///
public int type { get; set; }
///
/// 描述
///
public string describe { get; set; }
///
/// 素材json数组
///
public List materialList { get; set; }
///
/// 素材图标(缩略图)
///
public string icon { get; set; }
///
/// 更新时间
///
public int updateTime { get; set; }
///
/// 素材坐标
/// 网页端传递的数据为空
///
public ObjectTransform objectTransform { get; set; }
///
/// 用户ID
///
public int userId { get; set; }
///
/// 排版
/// 1-单排平铺,2-单排扇形,3-双排平铺,4-双排扇形,5-巨幕
///
public string typesetting;
public MaterialObl()
{
select = false;
materialList = new List();
objectTransform = new ObjectTransform();
}
}
///
/// 景点属性
///
public class SpoitValue
{
///
/// 景点ID
///
public int id;
///
/// 场景id
///
public int projectId;
///
/// 景点名称
///
public string name { get; set; }
///
/// 景点和触发范围信息
///
public List SpoitTransform { get; set; }
//坐标 旋转 尺寸 如果没有数据的话默认为NULL
public ObjectTransform spoitTf { get; set; }
///
/// 更新时间
///
public int updateTime { get; set; }
///
/// 素材
///
public List material { get; set; }
///
/// 景点和触发范围信息
///
public SpoitPos position { get; set; }
///
/// 景点和触发范围信息
///
public SpoitPos triggerRange { get; set; }
}
public class SpoitValueDetail
{
///
/// 景点ID
///
public int id;
///
/// 场景id
///
public int projectId;
///
/// 景点名称
///
public string name { get; set; }
///
/// 景点和触发范围信息
///
public List position { get; set; }
///
/// 景点和触发范围信息
///
public SpoitPos triggerRange { get; set; }
///
/// 景点素材父物体坐标 旋转 尺寸 如果没有数据的话默认为NULL
///
public ObjectTransform spoitTf { get; set; }
///
/// 更新时间
///
public int updateTime { get; set; }
///
/// 素材
///
public List material { get; set; }
}
///
/// 整个场景属性
///
public class SceneValue
{
public int id { get; set; }
///
/// 场景名称
///
public string name { get; set; }
///
/// 场景照片
///
public string image { get; set; }
///
/// 更新时间
///
public long updateTime { get; set; }
///
/// 景点信息
///
public List listSpoit { get; set; }
///
/// 场景-地图
/// url
///
public string map { get; set; }
///
/// 场景-沙盘
/// url
///
public string sandTable { get; set; }
///
/// 线路
///
public List navLines { get; set; }
public List backgroundImages;
///
/// 场景真实长宽
///
public float length { get; set; }
public float width { get; set; }
///
/// 锚点Vuforia 数据
///
public string vuforiaXML { get; set; }
public string vuforiaDat { get; set; }
///
/// 锚点列表
///
public List listPicture { get; set; }
}
public class BdImage
{
public string base64;
}
#region 路线
public class NavLinesItem
{
///
/// 更新时间
///
public long updateTime { get; set; }
///
/// 图片高度
///
public double realityHeight { get; set; }
///
/// 图片宽度
///
public double realityWidth { get; set; }
///
/// 路线的虚拟导游信息 : 1 导游A, 2 导游B, 3 不使用虚拟导游
///
public int guideMod { get; set; }
///
/// 路线样式风格 : 1 样式1, 2 样式2, 3 样式3
///
public int routerMod { get; set; }
///
/// 路线名称
///
public string name { get; set; }
///
/// 起点(x1,y1)
///
public double x1 { get; set; }
///
/// 起点(x1,y1)
///
public double y1 { get; set; }
///
/// 终点(x2, y2)
///
public double x2 { get; set; }
///
///终点(x2, y2)
///
public double y2 { get; set; }
///
/// 路径线段
///
public List lines { get; set; }
}
public class line
{
///
/// 起点(x1,y1)
///
public double x1 { get; set; }
///
/// 起点(x1,y1)
///
public double y1 { get; set; }
///
/// 终点(x2, y2)
///
public double x2 { get; set; }
///
///终点(x2, y2)
///
public double y2 { get; set; }
// 以下为路线段的私有信息
public string _groups { get; set; }
public string _id { get; set; }
public int _index { get; set; }
public string _name { get; set; }
public string _type { get; set; }
}
#endregion