Commit 3361ed6d authored by 张博's avatar 张博

选择点闪烁

parent 1a4d9ff1
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
delayTime: 10 // 屏保出现时间(单位:秒) 10s delayTime: 10 // 屏保出现时间(单位:秒) 10s
}, },
//三维模型配置 yinan 沂南站 shm 上海庙站 sn 苏南 hainan 海南站 //三维模型配置 yinan 沂南站 shm 上海庙站 sn 苏南 hainan 海南站
view3dFile:'/mods/components/3dviewConvertor/threeres/models/shm/index_dev.json', view3dFile:'/mods/components/3dviewConvertor/threeres/models/yinan/index.json',
} }
} }
}; };
......
{ {
"sceneName": "station-shanghai-temple", "sceneName": "station-shanghai-temple",
"basePath": "/threeres/models/shm/", "basePath": "/mods/components/3dviewConvertor/threeres/models/shm/",
"models": [ "models": [
{ "objName": "ground.obj", "mtlName": "ground.mtl", "modelLevel": "Park" }, { "objName": "ground.obj", "mtlName": "ground.mtl", "modelLevel": "Park" },
{ "objName": "ji1diduanfatingshi.obj", "mtlName": "ji1diduanfatingshi.mtl", "modelLevel": "Building", "foreignKey": "valve-hall_01" }, { "objName": "ji1diduanfatingshi.obj", "mtlName": "ji1diduanfatingshi.mtl", "modelLevel": "Building", "foreignKey": "valve-hall_01" },
......
...@@ -61,9 +61,11 @@ export default function marker3DFactory(WrappedComponent = 'div', options) { ...@@ -61,9 +61,11 @@ export default function marker3DFactory(WrappedComponent = 'div', options) {
componentWillReceiveProps = nextProps => { componentWillReceiveProps = nextProps => {
if (nextProps.isEditMode) { if (nextProps.isEditMode) {
this.markersCache.eachValue(obj => { this.markersCache.eachValue(obj => {
// this.setTopCardConf(obj, obj.extData);
if (nextProps.selectPoints.type === obj.extData.type && nextProps.selectPoints.id === obj.extData.id) { if (nextProps.selectPoints.type === obj.extData.type && nextProps.selectPoints.id === obj.extData.id) {
this.setTwinkleConf(obj); this.selectTwinkleConf(obj,1,'#FF0000');
} else {
this.selectTwinkleConf(obj,null,null);
} }
}); });
} }
...@@ -126,6 +128,18 @@ export default function marker3DFactory(WrappedComponent = 'div', options) { ...@@ -126,6 +128,18 @@ export default function marker3DFactory(WrappedComponent = 'div', options) {
pulsePeriod: pulsePeriod.toFixed(2) pulsePeriod: pulsePeriod.toFixed(2)
}); });
}; };
selectTwinkleConf = (obj, mark,selectColor)=> {
let pulsePeriod = mark;
let color = selectColor;
if (!obj.baseObjHelper.outlineHelper) {
obj.baseObjHelper.setOutlineHelper(this.outlineHelper);
}
obj.baseObjHelper.style.outlineColor = color;
pulsePeriod &&
obj.baseObjHelper.outlineHelper.setConfig({
pulsePeriod: pulsePeriod.toFixed(2)
});
};
setTopCardConf = (obj, extData) => { setTopCardConf = (obj, extData) => {
const { title, name } = extData; const { title, name } = extData;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment