fixed opacity
diff --git a/player/index.html b/player/index.html
index 0375fc1..93d5e65 100644
--- a/player/index.html
+++ b/player/index.html
@@ -36,6 +36,6 @@
<!-- endbuild -->
</head>
<body style="background-color:#fff; margin: 0px;height: 100%; font-family: sans-serif;font-size: 10px">
-<div style="width:500px;height:500px;background-color:#000;display:inline-block" class="bodymovin" data-bm-path="exports/ninja" data-bm-type="svg" data-bm-loop="true" data-bm-prerender="true"></div>
+<div style="width:500px;height:500px;background-color:#000;display:inline-block" class="bodymovin" data-bm-path="exports/letters/full" data-bm-type="svg" data-bm-loop="true" data-bm-prerender="true"></div>
</body>
</html>
diff --git a/player/js/animation/AnimationItem.js b/player/js/animation/AnimationItem.js
index f74bc9a..37d7467 100644
--- a/player/js/animation/AnimationItem.js
+++ b/player/js/animation/AnimationItem.js
@@ -124,8 +124,8 @@
this.totalFrames = this.animationData.animation.totalFrames;
this.frameRate = this.animationData.animation.frameRate;
this.firstFrame = Math.round(this.animationData.animation.ff*this.frameRate);
- this.firstFrame = 23;
- this.totalFrames = 1;
+ /*this.firstFrame = 23;
+ this.totalFrames = 1;*/
this.frameMult = this.animationData.animation.frameRate / 1000;
dataManager.completeData(this.animationData);
this.renderer.buildItems(this.animationData.animation.layers);
diff --git a/player/js/elements/ShapeItemElement.js b/player/js/elements/ShapeItemElement.js
index 0c44ac0..0a2cbe3 100644
--- a/player/js/elements/ShapeItemElement.js
+++ b/player/js/elements/ShapeItemElement.js
@@ -141,9 +141,9 @@
this.renderRect(items[i],data[i],num,groupTransform);
}
}else if(items[i].ty == 'fl'){
- this.renderFill(items[i],data[i],num);
+ this.renderFill(items[i],data[i],num,groupTransform);
}else if(items[i].ty == 'st'){
- this.renderStroke(items[i],data[i],num);
+ this.renderStroke(items[i],data[i],num,groupTransform);
}else if(items[i].ty == 'gr'){
this.renderShape(num,groupTransform,items[i].it,data[i].it);
}else if(items[i].ty == 'tm'){
@@ -191,13 +191,13 @@
}
};
-ShapeItemElement.prototype.renderFill = function(styleData,viewData,num){
+ShapeItemElement.prototype.renderFill = function(styleData,viewData,num,groupTransform){
var fillData = styleData.renderedData[num];
var styleElem = viewData.style;
if(!viewData.renderedFrames[this.globalData.frameNum]){
viewData.renderedFrames[this.globalData.frameNum] = {
c: fillData.color,
- o: fillData.opacity
+ o: fillData.opacity*groupTransform.opacity
}
}
@@ -214,13 +214,13 @@
viewData.lastData.o = o;
};
-ShapeItemElement.prototype.renderStroke = function(styleData,viewData,num){
+ShapeItemElement.prototype.renderStroke = function(styleData,viewData,num,groupTransform){
var fillData = styleData.renderedData[num];
var styleElem = viewData.style;
if(!viewData.renderedFrames[this.globalData.frameNum]){
viewData.renderedFrames[this.globalData.frameNum] = {
c: fillData.color,
- o: fillData.opacity,
+ o: fillData.opacity*groupTransform.opacity,
w: fillData.width
};
if(fillData.dashes){