raw.js 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. import {Booth} from './booth'
  2. //计算点位分布
  3. let calcuSpread = (start, end, other=[], getRid=[] ) => {
  4. let arr = [];
  5. for (let i = 0; i <= end - start; i++) {
  6. if (!(getRid.indexOf(start + i)>-1)) {
  7. arr.push(start + i);
  8. }
  9. }
  10. return arr.concat(other);
  11. };
  12. //展区
  13. let region = [
  14. {
  15. id: "1",
  16. name: "综合展区",
  17. theme: "rgba(179, 104, 216, 1)",
  18. company: Booth.find(item=>item.id=='1').company, //综合展区ID
  19. spread: calcuSpread(0, 57,[344],[]),
  20. firstView: {
  21. panoId: "0",
  22. panoQuaternion: {
  23. x: 0.004201298516425423,
  24. y: 0.6983405631424313,
  25. z: -0.004099157345704842,
  26. w: 0.7157415805989583
  27. },
  28. },
  29. },
  30. {
  31. id: "2",
  32. name: "地方展区",
  33. theme: "rgba(187, 39, 39, 1)", //主题颜色
  34. company: Booth.find(item=>item.id=='2').company, //地方展区id
  35. spread: calcuSpread(58, 282,[],[254,257,258]),
  36. firstView: {
  37. panoId: "4",
  38. panoQuaternion: {
  39. x: -0.016484962519480128,
  40. y:0.7083437993857234,
  41. z: 0.016551859736091593,
  42. w: 0.7054809155529423
  43. },
  44. },
  45. },
  46. {
  47. id: "3",
  48. name: "互联网企业展区",
  49. theme: "rgba(113, 200, 82, 1)",
  50. company: Booth.find(item=>item.id=='3').company, //互联网企业ID
  51. spread: calcuSpread(283, 392,[254,257,258],[344]),
  52. firstView: {
  53. panoId: "47",
  54. panoQuaternion: {
  55. x:0.0008521342062728275,
  56. y:0.7237583641229127,
  57. z:-0.000893757162925398,
  58. w:0.6900523954291632
  59. },
  60. },
  61. }
  62. ];
  63. export { region };