Compare commits

...

12 Commits

Author SHA1 Message Date
Takashi Sakai 772297abd0 release v2.3.2 2018-05-21 15:13:20 +09:00
Takashi Sakai b4cb57e097 update change log 2018-05-21 15:13:19 +09:00
Takashi Sakai 923f74d047 Update release script (use 5.5.0p4 to export package) 2018-05-21 15:09:56 +09:00
Takashi Sakai be90296be7 Add UNITY_STANDALONE_WIN symbol 2018-05-19 13:48:31 +09:00
Takashi Sakai e6027fbec2 Fixed #65 : UIEffectCapturedImage: When iteration count is even. the result image is flipped vertically (other method) 2018-05-19 13:23:29 +09:00
Takashi Sakai 72e2149f70 Revert "Fixed: UIEffectCapturedImage: When iteration count is even. the result image is flipped vertically (on Windows) #62"
This reverts commit 9d911eb581.
2018-05-19 12:12:43 +09:00
Takashi Sakai 8490d11762 Update README.md 2018-05-11 20:39:13 +09:00
Takashi Sakai ed3fce5fa5 release v2.3.1 2018-05-10 12:44:18 +09:00
Takashi Sakai 4bbe569248 update change log 2018-05-10 12:44:18 +09:00
Takashi Sakai 9d911eb581 Fixed: UIEffectCapturedImage: When iteration count is even. the result image is flipped vertically (on Windows) #62 2018-05-10 12:34:39 +09:00
Takashi Sakai bc87c42cdd Remove docs dir 2018-05-08 21:19:12 +09:00
Takashi Sakai 972235ec44 Update readme 2018-05-08 21:10:44 +09:00
21 changed files with 43 additions and 184 deletions
+19
View File
@@ -142,6 +142,22 @@ namespace Coffee.UIExtensions
// When not displaying, clear vertex.
if (texture == null || effectColor.a < 1 / 255f || canvasRenderer.GetAlpha() < 1 / 255f)
vh.Clear();
#if UNITY_STANDALONE_WIN
else if(_capturedIterations % 2 == 0)
{
Debug.Log(iterations);
base.OnPopulateMesh(vh);
int count = vh.currentVertCount;
UIVertex vt = UIVertex.simpleVert;
Vector2 one = Vector2.one;
for (int i = 0; i < count; i++)
{
vh.PopulateUIVertex(ref vt, i);
vt.uv0 = new Vector2(vt.uv0.x, 1-vt.uv0.y);
vh.SetUIVertex(vt, i);
}
}
#endif
else
base.OnPopulateMesh(vh);
}
@@ -249,6 +265,7 @@ namespace Coffee.UIExtensions
{
_buffer.Blit(s_CopyId, rtId);
_buffer.ReleaseTemporaryRT(s_CopyId);
_capturedIterations = 1;
}
// Blit with effect.
else
@@ -275,6 +292,7 @@ namespace Coffee.UIExtensions
{
_buffer.ReleaseTemporaryRT(s_EffectId2);
}
_capturedIterations = m_Iterations;
}
}
@@ -311,6 +329,7 @@ namespace Coffee.UIExtensions
RenderTexture _rt;
RenderTexture _rtToRelease;
CommandBuffer _buffer;
int _capturedIterations = 1;
static int s_CopyId;
static int s_EffectId1;
+16
View File
@@ -1,5 +1,21 @@
# Changelog
## [v2.3.2](https://github.com/mob-sakai/UIEffect/tree/v2.3.2) (2018-05-21)
[Full Changelog](https://github.com/mob-sakai/UIEffect/compare/v2.3.1...v2.3.2)
**Closed issues:**
- Fixed: UIEffectCapturedImage: When iteration count is even. the result image is flipped vertically \(other method\) [\#65](https://github.com/mob-sakai/UIEffect/issues/65)
## [v2.3.1](https://github.com/mob-sakai/UIEffect/tree/v2.3.1) (2018-05-10)
[Full Changelog](https://github.com/mob-sakai/UIEffect/compare/v2.3.0...v2.3.1)
**Fixed bugs:**
- UIEffectCapturedImage: When iteration count is even. the result image is flipped vertically \(on Windows\) [\#62](https://github.com/mob-sakai/UIEffect/issues/62)
## [v2.3.0](https://github.com/mob-sakai/UIEffect/tree/v2.3.0) (2018-05-08)
[Full Changelog](https://github.com/mob-sakai/UIEffect/compare/v2.2.0...v2.3.0)
+6 -1
View File
@@ -4,7 +4,7 @@ UIEffect
UIEffect is an effect component for uGUI in Unity.
Let's decorate your UI with effects!
[![](https://img.shields.io/github/release/mob-sakai/UIEffect.svg?label=latest%20version)](https://github.com/mob-sakai/UIEffect/release)
[![](https://img.shields.io/github/release/mob-sakai/UIEffect.svg?label=latest%20version)](https://github.com/mob-sakai/UIEffect/releases)
[![](https://img.shields.io/github/release-date/mob-sakai/UIEffect.svg)](https://github.com/mob-sakai/UIEffect/releases)
![](https://img.shields.io/badge/requirement-Unity%205.5%2B-green.svg)
[![](https://img.shields.io/github/license/mob-sakai/UIEffect.svg)](https://github.com/mob-sakai/UIEffect/blob/master/LICENSE.txt)
@@ -20,6 +20,9 @@ Let's decorate your UI with effects!
<br><br><br><br>
## Description
### New feature in v2.3.0!
![v2.3.0](https://user-images.githubusercontent.com/12690315/39756239-bf546ae6-5303-11e8-964a-38aed7ea6096.gif)
### Supports following effects!
![image](https://user-images.githubusercontent.com/12690315/35077815-5ff8094e-fc42-11e7-92dd-99916c9f9da7.png)
@@ -48,6 +51,7 @@ Let's decorate your UI with effects!
* Diagonal
* Shiny
* Dissolve
* Flip horizontal/vertical
### Easy to control effect parameters!
@@ -76,6 +80,7 @@ Merged from [ShinyEffectForUGUI](https://github.com/mob-sakai/ShinyEffectForUGUI
* UIDissolve: Dissolve effect WITHOUT material instancing. This will suppress extra draw calls and improve performance.
Merged from [DissolveEffectForUGUI](https://github.com/mob-sakai/DissolveEffectForUGUI).
![demo](https://user-images.githubusercontent.com/12690315/39131616-dcf7ea60-474a-11e8-8e20-f9e5bd8b3f5c.gif)
* UIFlip: Flip horizontal/vertical.
File diff suppressed because one or more lines are too long
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.8 KiB

-122
View File
@@ -1,122 +0,0 @@
function UnityProgress (dom) {
this.progress = 0.0;
this.message = "";
this.dom = dom;
var parent = dom.parentNode;
var background = document.createElement("div");
background.style.background = Module["backgroundColor"] ? Module["backgroundColor"] : "#4D4D4D";
background.style.position = "absolute";
background.style.overflow = "hidden";
parent.appendChild(background);
this.background = background;
if (Module["backgroundImage"])
{
var backgroundImg = document.createElement("img");
backgroundImg.src = Module["backgroundImage"];
backgroundImg.style.position = "absolute";
backgroundImg.style.width = "100%";
backgroundImg.style.height = "auto";
backgroundImg.style.top = "50%";
backgroundImg.style.transform = "translate(0, -50%)";
background.appendChild(backgroundImg);
}
var logoImage = document.createElement("img");
var splashStyle = Module["splashStyle"] ? Module["splashStyle"] : "Light";
logoImage.src = "TemplateData/Logo." + splashStyle + ".png";
logoImage.style.position = "absolute";
parent.appendChild(logoImage);
this.logoImage = logoImage;
var progressFrame = document.createElement("img");
progressFrame.src = "TemplateData/ProgressFrame." + splashStyle + ".png";
progressFrame.style.position = "absolute";
parent.appendChild(progressFrame);
this.progressFrame = progressFrame;
var progressBar = document.createElement("div");
progressBar.style.position = "absolute";
progressBar.style.overflow = "hidden";
parent.appendChild(progressBar);
this.progressBar = progressBar;
var progressBarImg = document.createElement("img");
progressBarImg.src = "TemplateData/ProgressBar." + splashStyle + ".png";
progressBarImg.style.position = "absolute";
progressBar.appendChild(progressBarImg);
this.progressBarImg = progressBarImg;
var messageArea = document.createElement("p");
messageArea.style.position = "absolute";
parent.appendChild(messageArea);
this.messageArea = messageArea;
this.SetProgress = function (progress) {
if (this.progress < progress)
this.progress = progress;
this.messageArea.style.display = "none";
this.progressFrame.style.display = "inline";
this.progressBar.style.display = "inline";
this.Update();
}
this.SetMessage = function (message) {
this.message = message;
this.background.style.display = "inline";
this.logoImage.style.display = "inline";
this.progressFrame.style.display = "none";
this.progressBar.style.display = "none";
this.Update();
}
this.Clear = function() {
this.background.style.display = "none";
this.logoImage.style.display = "none";
this.progressFrame.style.display = "none";
this.progressBar.style.display = "none";
}
this.Update = function() {
this.background.style.top = this.dom.offsetTop + 'px';
this.background.style.left = this.dom.offsetLeft + 'px';
this.background.style.width = this.dom.offsetWidth + 'px';
this.background.style.height = this.dom.offsetHeight + 'px';
var logoImg = new Image();
logoImg.src = this.logoImage.src;
var progressFrameImg = new Image();
progressFrameImg.src = this.progressFrame.src;
this.logoImage.style.top = this.dom.offsetTop + (this.dom.offsetHeight * 0.5 - logoImg.height * 0.5) + 'px';
this.logoImage.style.left = this.dom.offsetLeft + (this.dom.offsetWidth * 0.5 - logoImg.width * 0.5) + 'px';
this.logoImage.style.width = logoImg.width+'px';
this.logoImage.style.height = logoImg.height+'px';
this.progressFrame.style.top = this.dom.offsetTop + (this.dom.offsetHeight * 0.5 + logoImg.height * 0.5 + 10) + 'px';
this.progressFrame.style.left = this.dom.offsetLeft + (this.dom.offsetWidth * 0.5 - progressFrameImg.width * 0.5) + 'px';
this.progressFrame.width = progressFrameImg.width;
this.progressFrame.height = progressFrameImg.height;
this.progressBarImg.style.top = '0px';
this.progressBarImg.style.left = '0px';
this.progressBarImg.width = progressFrameImg.width;
this.progressBarImg.height = progressFrameImg.height;
this.progressBar.style.top = this.progressFrame.style.top;
this.progressBar.style.left = this.progressFrame.style.left;
this.progressBar.style.width = (progressFrameImg.width * this.progress) + 'px';
this.progressBar.style.height = progressFrameImg.height + 'px';
this.messageArea.style.top = this.progressFrame.style.top;
this.messageArea.style.left = 0;
this.messageArea.style.width = '100%';
this.messageArea.style.textAlign = 'center';
this.messageArea.innerHTML = this.message;
}
this.Update ();
}
Binary file not shown.

Before

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.9 KiB

-22
View File
@@ -1,22 +0,0 @@
/****************************************
==== RESETS
****************************************/
html,body,div,canvas { margin: 0; padding: 0; }
::-moz-selection { color: #333; text-shadow: none; }
::selection { color: #333; text-shadow: none; }
.clear:after { visibility: hidden; display: block; font-size: 0; content: " "; clear: both; height: 0; }
.clear { display: inline-table; clear: both; }
/* Hides from IE-mac \*/ * html .clear { height: 1%; } .clear { display: block; } /* End hide from IE-mac */
/****************************************
==== LAYOUT
****************************************/
html, body { width: 100%; height: 100%; font-family: Helvetica, Verdana, Arial, sans-serif; }
div.logo { width: 204px; height: 38px; float: left; background: url(logo.png) 0 0 no-repeat; position: relative; z-index: 10; }
div.title { height: 38px; line-height: 38px; padding: 0 10px; margin: 0 1px 0 0; float: right; color: #333; text-align: right; font-size: 18px; position: relative; z-index: 10; }
.template-wrap { position: absolute; top: 50%; left: 50%; -webkit-transform: translate(-50%, -50%); transform: translate(-50%, -50%); }
.template-wrap canvas { margin: 0 0 10px 0; position: relative; z-index: 9; box-shadow: 0 10px 30px rgba(0,0,0,0.2); -moz-box-shadow: 0 10px 30px rgba(0,0,0,0.2); }
.fullscreen { float: right; position: relative; z-index: 10; }
-35
View File
@@ -1,35 +0,0 @@
<!doctype html>
<html lang="en-us">
<head>
<meta charset="utf-8">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Unity WebGL Player | UIEffect</title>
<link rel="stylesheet" href="TemplateData/style.css">
<link rel="shortcut icon" href="TemplateData/favicon.ico" />
<script src="TemplateData/UnityProgress.js"></script>
</head>
<body class="template">
<div class="template-wrap clear">
<canvas class="emscripten" id="canvas" oncontextmenu="event.preventDefault()" height="600px" width="960px"></canvas>
<br>
<div class="logo"></div>
<div class="fullscreen"><img src="TemplateData/fullscreen.png" width="38" height="38" alt="Fullscreen" title="Fullscreen" onclick="SetFullscreen(1);" /></div>
<div class="title">UIEffect</div>
</div>
<script type='text/javascript'>
var Module = {
TOTAL_MEMORY: 268435456,
errorhandler: null, // arguments: err, url, line. This function must return 'true' if the error is handled, otherwise 'false'
compatibilitycheck: null,
backgroundColor: "#222C36",
splashStyle: "Light",
dataUrl: "Release/build.data",
codeUrl: "Release/build.js",
asmUrl: "Release/build.asm.js",
memUrl: "Release/build.mem",
};
</script>
<script src="Release/UnityLoader.js"></script>
</body>
</html>
+2 -2
View File
@@ -1,11 +1,11 @@
{
"name": "UIEffect",
"version": "2.3.0",
"version": "2.3.2",
"repository": {
"type": "git",
"url": "git+https://github.com/mob-sakai/UIEffect.git"
},
"src": "Assets/UIEffect",
"unity": "/Applications/Unity2017.1.0p5/Unity2017.1.0p5.app/Contents/MacOS/Unity",
"unity": "/Applications/Unity/Hub/Editor/5.5.0p4/Unity.app/Contents/MacOS/Unity",
"license": "MIT"
}