Skip to content
Permalink
Browse files

Fix trailing whitespace.

Every editor these days seems to trim trailing whitespace, which makes for noisy diffs when old files are changed. So let's just trim it all once and for all. This might mess with merges, sorry Meridian, I suggest doing the same on your fork.
  • Loading branch information
SupSuper committed Jan 15, 2019
1 parent 687cc75 commit 4251ab7c88bc2cc7952c5cb6d559a97e588f6e0e
Showing with 1,208 additions and 1,211 deletions.
  1. +1 βˆ’3 .astylerc
  2. +4 βˆ’4 CHANGELOG.txt
  3. +1 βˆ’1 bin/common/Language/en-GB.yml
  4. +1 βˆ’1 bin/common/Language/en-US.yml
  5. +5 βˆ’5 bin/common/Shaders/5xBR_Rounded.OpenGL.shader
  6. +5 βˆ’5 bin/common/Shaders/5xBR_Semi-Rounded.OpenGL.shader
  7. +5 βˆ’5 bin/common/Shaders/5xBR_Squared.OpenGL.shader
  8. +9 βˆ’9 bin/common/Shaders/HQ2x.OpenGL.shader
  9. +12 βˆ’12 bin/common/Shaders/Openxcom.OpenGL.shader
  10. +53 βˆ’53 bin/common/Shaders/SABR-XCOMified.OpenGL.shader
  11. +2 βˆ’2 bin/common/Shaders/Scale2x.OpenGL.shader
  12. +3 βˆ’3 bin/common/Shaders/Scale4xHQ.OpenGL.shader
  13. +1 βˆ’1 bin/common/Shaders/heavybloom.OpenGL.shader
  14. +1 βˆ’1 bin/common/Shaders/scanline-3x.OpenGL.shader
  15. +1 βˆ’1 bin/common/Shaders/scanline-4x.OpenGL.shader
  16. +1 βˆ’1 bin/common/Shaders/simplebloom.OpenGL.shader
  17. +1 βˆ’1 bin/common/SoldierName/Belgium.nam
  18. +1 βˆ’1 bin/common/SoldierName/German.nam
  19. +1 βˆ’1 bin/common/SoldierName/Irish.nam
  20. +1 βˆ’1 bin/common/SoldierName/Polish.nam
  21. +2 βˆ’2 bin/common/SoldierName/Polynesia.nam
  22. +1 βˆ’1 bin/common/SoldierName/Russian.nam
  23. +3 βˆ’3 bin/common/SoldierName/Swedish.nam
  24. +1 βˆ’1 bin/standard/xcom1/Resources/Weapons/license.txt
  25. +2 βˆ’2 bin/standard/xcom1/alienDeployments.rul
  26. +1 βˆ’1 bin/standard/xcom1/alienMissions.rul
  27. +1 βˆ’1 bin/standard/xcom1/interfaces.rul
  28. +1 βˆ’1 bin/standard/xcom1/items.rul
  29. +1 βˆ’1 bin/standard/xcom1/regions.rul
  30. +1 βˆ’1 bin/standard/xcom1/units.rul
  31. +1 βˆ’1 bin/standard/xcom2/Language/en-GB.yml
  32. +1 βˆ’1 bin/standard/xcom2/Language/en-US.yml
  33. +1 βˆ’1 bin/standard/xcom2/Resources/Weapons/license.txt
  34. +137 βˆ’137 bin/standard/xcom2/alienDeployments.rul
  35. +1 βˆ’1 bin/standard/xcom2/alienMissions.rul
  36. +1 βˆ’1 bin/standard/xcom2/alienRaces.rul
  37. +3 βˆ’3 bin/standard/xcom2/converter.rul
  38. +1 βˆ’1 bin/standard/xcom2/cutscenes.rul
  39. +5 βˆ’5 bin/standard/xcom2/interfaces.rul
  40. +1 βˆ’1 bin/standard/xcom2/items.rul
  41. +110 βˆ’110 bin/standard/xcom2/manufacture.rul
  42. +11 βˆ’12 bin/standard/xcom2/missionScripts.rul
  43. +1 βˆ’1 bin/standard/xcom2/soldiers.rul
  44. +3 βˆ’3 bin/standard/xcom2/vars.rul
  45. +19 βˆ’19 cmake/modules/FindSDL2.cmake
  46. +8 βˆ’8 cmake/modules/FindSDL_gfx.cmake
  47. +5 βˆ’5 cmake/modules/FindYaml_cpp.cmake
  48. +76 βˆ’76 cmake/modules/NSIS.template.in
  49. +58 βˆ’58 docs/Doxyfile.in
  50. +5 βˆ’5 docs/openxcom.6.xml
  51. +4 βˆ’4 install/opensuse/openxcom.spec
  52. +83 βˆ’83 install/win/installer.nsi
  53. +1 βˆ’1 src/Basescape/CraftSoldiersState.cpp
  54. +1 βˆ’1 src/Basescape/SellState.cpp
  55. +2 βˆ’2 src/Basescape/SoldierDiaryMissionState.cpp
  56. +4 βˆ’4 src/Basescape/SoldierDiaryOverviewState.cpp
  57. +3 βˆ’3 src/Basescape/SoldierDiaryPerformanceState.cpp
  58. +1 βˆ’1 src/Basescape/SoldierInfoState.cpp
  59. +1 βˆ’1 src/Basescape/TransferItemsState.cpp
  60. +18 βˆ’18 src/Battlescape/AIModule.cpp
  61. +2 βˆ’2 src/Battlescape/AliensCrashState.cpp
  62. +6 βˆ’6 src/Battlescape/BattlescapeGame.cpp
  63. +5 βˆ’5 src/Battlescape/BattlescapeGenerator.cpp
  64. +9 βˆ’9 src/Battlescape/BattlescapeState.cpp
  65. +6 βˆ’6 src/Battlescape/CommendationLateState.cpp
  66. +9 βˆ’9 src/Battlescape/DebriefingState.cpp
  67. +1 βˆ’1 src/Battlescape/DebriefingState.h
  68. +3 βˆ’3 src/Battlescape/Map.cpp
  69. +1 βˆ’1 src/Battlescape/MedikitState.cpp
  70. +6 βˆ’6 src/Battlescape/MeleeAttackBState.cpp
  71. +1 βˆ’1 src/Battlescape/MiniMapState.cpp
  72. +1 βˆ’1 src/Battlescape/Pathfinding.cpp
  73. +7 βˆ’7 src/Battlescape/Projectile.cpp
  74. +4 βˆ’4 src/Battlescape/ProjectileFlyBState.cpp
  75. +1 βˆ’1 src/Battlescape/PsiAttackBState.cpp
  76. +5 βˆ’5 src/Battlescape/TileEngine.cpp
  77. +1 βˆ’1 src/Battlescape/UnitDieBState.cpp
  78. +4 βˆ’4 src/Battlescape/UnitFallBState.cpp
  79. +2 βˆ’2 src/Battlescape/UnitPanicBState.cpp
  80. +7 βˆ’7 src/Battlescape/UnitSprite.cpp
  81. +2 βˆ’2 src/Battlescape/UnitWalkBState.cpp
  82. +7 βˆ’7 src/Engine/Adlib/adlplayer.cpp
  83. +3 βˆ’3 src/Engine/CrossPlatform.cpp
  84. +3 βˆ’3 src/Engine/FastLineClip.cpp
  85. +2 βˆ’2 src/Engine/FileMap.cpp
  86. +23 βˆ’23 src/Engine/FlcPlayer.cpp
  87. +1 βˆ’1 src/Engine/FlcPlayer.h
  88. +1 βˆ’1 src/Engine/Font.cpp
  89. +11 βˆ’11 src/Engine/GraphSubset.h
  90. +1 βˆ’1 src/Engine/Logger.h
  91. +1 βˆ’1 src/Engine/OpenGL.cpp
  92. +3 βˆ’3 src/Engine/Options.cpp
  93. +1 βˆ’1 src/Engine/Palette.cpp
  94. +1 βˆ’1 src/Engine/Scalers/scale2x.cpp
  95. +1 βˆ’1 src/Engine/Scalers/scale3x.cpp
  96. +6 βˆ’6 src/Engine/Screen.cpp
  97. +7 βˆ’7 src/Engine/ShaderDraw.h
  98. +104 βˆ’104 src/Engine/ShaderDrawHelper.h
  99. +21 βˆ’21 src/Engine/ShaderRepeat.h
  100. +1 βˆ’1 src/Engine/SurfaceSet.cpp
  101. +4 βˆ’4 src/Engine/Timer.cpp
  102. +1 βˆ’1 src/Engine/Timer.h
  103. +39 βˆ’39 src/Engine/Zoom.cpp
  104. +1 βˆ’1 src/Geoscape/BuildNewBaseState.cpp
  105. +1 βˆ’1 src/Geoscape/DogfightState.cpp
  106. +1 βˆ’1 src/Geoscape/GeoscapeState.cpp
  107. +1 βˆ’1 src/Geoscape/NewPossibleResearchState.cpp
  108. +1 βˆ’1 src/Interface/BattlescapeButton.h
  109. +1 βˆ’1 src/Interface/ScrollBar.cpp
  110. +1 βˆ’1 src/Interface/Slider.h
  111. +4 βˆ’4 src/Makefile.gcc-pch
  112. +1 βˆ’1 src/Menu/ConfirmLoadState.h
  113. +1 βˆ’1 src/Menu/CutsceneState.cpp
  114. +1 βˆ’1 src/Menu/ListLoadState.cpp
  115. +1 βˆ’1 src/Menu/LoadGameState.cpp
  116. +2 βˆ’2 src/Menu/OptionsAdvancedState.cpp
  117. +2 βˆ’2 src/Menu/OptionsBattlescapeState.cpp
  118. +1 βˆ’1 src/Menu/OptionsControlsState.cpp
  119. +2 βˆ’2 src/Menu/OptionsGeoscapeState.cpp
  120. +1 βˆ’1 src/Menu/OptionsModsState.cpp
  121. +15 βˆ’15 src/Menu/OptionsVideoState.cpp
  122. +1 βˆ’1 src/Menu/StartState.cpp
  123. +1 βˆ’1 src/Menu/StatisticsState.cpp
  124. +1 βˆ’1 src/Menu/VideoState.cpp
  125. +1 βˆ’1 src/Mod/AlienDeployment.cpp
  126. +1 βˆ’1 src/Mod/ArticleDefinition.cpp
  127. +1 βˆ’1 src/Mod/City.h
  128. +2 βˆ’2 src/Mod/MapScript.cpp
  129. +3 βˆ’3 src/Mod/Mod.cpp
  130. +2 βˆ’2 src/Mod/RuleGlobe.cpp
  131. +1 βˆ’1 src/Mod/RuleMissionScript.h
  132. +1 βˆ’1 src/Mod/RuleMusic.cpp
  133. +1 βˆ’1 src/Mod/RuleVideo.cpp
  134. +1 βˆ’1 src/Mod/SoundDefinition.cpp
  135. +11 βˆ’11 src/Mod/StatString.h
  136. +3 βˆ’3 src/OpenXcom.rc
  137. +1 βˆ’1 src/Savegame/AlienBase.h
  138. +1 βˆ’1 src/Savegame/BattleUnit.cpp
  139. +1 βˆ’1 src/Savegame/Country.cpp
  140. +3 βˆ’3 src/Savegame/CraftWeaponProjectile.cpp
  141. +1 βˆ’1 src/Savegame/CraftWeaponProjectile.h
  142. +1 βˆ’1 src/Savegame/MovingTarget.cpp
  143. +1 βˆ’1 src/Savegame/Node.h
  144. +1 βˆ’1 src/Savegame/SaveConverter.cpp
  145. +1 βˆ’1 src/Savegame/SavedBattleGame.cpp
  146. +1 βˆ’1 src/Savegame/SavedGame.cpp
  147. +1 βˆ’1 src/Savegame/Soldier.h
  148. +53 βˆ’53 src/Savegame/SoldierDiary.cpp
  149. +1 βˆ’1 src/Savegame/Tile.h
  150. +1 βˆ’1 src/Savegame/Ufo.cpp
  151. +2 βˆ’2 src/Ufopaedia/ArticleStateTFTDArmor.cpp
  152. +1 βˆ’1 src/Ufopaedia/ArticleStateTFTDCraftWeapon.cpp
  153. +1 βˆ’1 src/Ufopaedia/ArticleStateTFTDFacility.cpp
  154. +1 βˆ’1 src/Ufopaedia/ArticleStateTFTDItem.cpp
  155. +1 βˆ’1 src/Ufopaedia/ArticleStateTFTDUso.cpp
  156. +8 βˆ’8 src/Ufopaedia/ArticleStateTFTDVehicle.cpp
  157. +10 βˆ’10 src/Ufopaedia/ArticleStateVehicle.cpp
  158. +1 βˆ’1 src/Ufopaedia/UfopaediaSelectState.cpp
  159. +2 βˆ’2 src/Ufopaedia/UfopaediaStartState.cpp
  160. +15 βˆ’15 src/apple/SDLMain.m
  161. +14 βˆ’14 src/dirent.h
  162. +1 βˆ’1 src/resource.h
@@ -3,7 +3,5 @@ indent=tab
pad-oper
pad-header
unpad-paren
fill-empty-lines
add-brackets
align-pointer=name
mode=c
mode=c
@@ -81,7 +81,7 @@ New features:
- Added right-click on soldier in Craft screen to show their stats.
- Ufopaedia now shows armor damage and stat modifiers.
- New Advanced-Option: View soldier's Psi-Strength after the appropriate research has been completed.*

Battlescape:
- Inventory: Ctrl-click an item to attempt to swap it between the ground and your soldier's inventory.
- Inventory: Added ability to define paper dolls for non-player units.
@@ -143,7 +143,7 @@ Bugfixes:
- Palette system overhauled to prevent windows changing colours incorrectly.
- Fixed various bugs with Unicode handling in paths and strings.
- Fixed various UI bugs on tablets.

Geoscape:
- X-Com now correctly pays their first month's rent and maintenance in advance.
- To avoid lawsuits, sacked soldiers no longer take their armour with them.
@@ -163,7 +163,7 @@ Bugfixes:
- Fix the council congratulating XCom on a job well done as they cancel the project.
- Downed UFOs will use appropriate behaviour after XCom dusts off.
- Alien mission timers fixed.

Battlescape:
- Fixes to various UFOpaedia articles.
- Loading saved games now correctly preserves the difficulty adjustments to alien stats.
@@ -551,7 +551,7 @@ New features:
- Support for user soldier name pools.
- Various new options (see docs).
- Debug mode.

Bugfixes:
- Two duplicating ammo bugs.
- Wrong rocket launcher hand sprite.
@@ -308,7 +308,7 @@ en-GB:
STR_MOUSEWHEEL_SPEED_DESC: "Adjusts the number of lines scrolled in lists with each increment of the mouse wheel."
STR_DISABLED: "Disabled"
STR_MAXIMIZE_INFO_SCREENS: "Maximize info screens"
STR_MAXIMIZE_INFO_SCREENS_DESC: "Inventory and various other screens will be displayed at full screen, regardless of scale settings."
STR_MAXIMIZE_INFO_SCREENS_DESC: "Inventory and various other screens will be displayed at full screen, regardless of scale settings."
STR_DIARY: "DIARY"
STR_KILLED: "KILLED"
STR_STUNNED: "STUNNED"
@@ -308,7 +308,7 @@ en-US:
STR_MOUSEWHEEL_SPEED_DESC: "Adjusts the number of lines scrolled in lists with each increment of the mouse wheel."
STR_DISABLED: "Disabled"
STR_MAXIMIZE_INFO_SCREENS: "Maximize info screens"
STR_MAXIMIZE_INFO_SCREENS_DESC: "Inventory and various other screens will be displayed at full screen, regardless of scale settings."
STR_MAXIMIZE_INFO_SCREENS_DESC: "Inventory and various other screens will be displayed at full screen, regardless of scale settings."
STR_DIARY: "DIARY"
STR_KILLED: "KILLED"
STR_STUNNED: "STUNNED"
@@ -1,6 +1,6 @@
# <!--
# Hyllian's 5xBR v3.7a Shader

# Copyright (C) 2011, 2012 Hyllian/Jararaca - sergiogdb@gmail.com
# Copyright (C) 2012 crazy46guy (GLSL conversion)

@@ -43,7 +43,7 @@ vertex: |
gl_TexCoord[4] = gl_MultiTexCoord0.xxxy + vec4( -dx, 0, dx, dy); // G H I
gl_TexCoord[5] = gl_MultiTexCoord0.xxxy + vec4( -dx, 0, dx, 2.0*dy); // G5 H5 I5
gl_TexCoord[6] = gl_MultiTexCoord0.xyyy + vec4(-2.0*dx, -dy, 0, dy); // A0 D0 G0
gl_TexCoord[7] = gl_MultiTexCoord0.xyyy + vec4( 2.0*dx, -dy, 0, dy); // C4 F4 I4
gl_TexCoord[7] = gl_MultiTexCoord0.xyyy + vec4( 2.0*dx, -dy, 0, dy); // C4 F4 I4
}
fragment: |
uniform sampler2D rubyTexture;
@@ -73,7 +73,7 @@ fragment: |

bvec4 _or_(bvec4 A, bvec4 B) {
return bvec4(A.x || B.x, A.y || B.y, A.z || B.z, A.w || B.w);
}
}

vec4 df(vec4 A, vec4 B) {
return vec4(abs(A - B));
@@ -139,15 +139,15 @@ fragment: |
vec4 Cy = vec4( 2.0, 0.0, -1.0, 0.5 );

// These inequations define the line below which interpolation occurs
bvec4 fx = greaterThan(Ao * fp.y + Bo * fp.x, Co);
bvec4 fx = greaterThan(Ao * fp.y + Bo * fp.x, Co);
bvec4 fx_left = greaterThan(Ax * fp.y + Bx * fp.x, Cx);
bvec4 fx_up = greaterThan(Ay * fp.y + By * fp.x, Cy);

bvec4 interp_restriction_lv1 = _and_( notEqual(e, f), notEqual(e, h) );
bvec4 interp_restriction_lv2_left = _and_( notEqual(e, g), notEqual(d, g) );
bvec4 interp_restriction_lv2_up = _and_( notEqual(e, c), notEqual(b, c) );

bvec4 edr = _and_( lessThan(weighted_distance(e, c, g, i, h5, f4, h, f),
bvec4 edr = _and_( lessThan(weighted_distance(e, c, g, i, h5, f4, h, f),
weighted_distance(h, d, i5, f, i4, b, e, i)), interp_restriction_lv1 );
bvec4 edr_left = _and_( lessThanEqual(coef * df(f, g), df(h, c)), interp_restriction_lv2_left );
bvec4 edr_up = _and_( greaterThanEqual(df(f, g), coef * df(h, c)), interp_restriction_lv2_up );
@@ -1,7 +1,7 @@
# <?xml version="1.0" encoding="UTF-8"?>
# <!--
# Hyllian's 5xBR v3.7b (semi-rounded) Shader

# Copyright (C) 2011, 2012 Hyllian/Jararaca - sergiogdb@gmail.com
# Copyright (C) 2012 crazy46guy (GLSL conversion)

@@ -44,7 +44,7 @@ vertex: |
gl_TexCoord[4] = gl_MultiTexCoord0.xxxy + vec4( -dx, 0, dx, dy); // G H I
gl_TexCoord[5] = gl_MultiTexCoord0.xxxy + vec4( -dx, 0, dx, 2.0*dy); // G5 H5 I5
gl_TexCoord[6] = gl_MultiTexCoord0.xyyy + vec4(-2.0*dx, -dy, 0, dy); // A0 D0 G0
gl_TexCoord[7] = gl_MultiTexCoord0.xyyy + vec4( 2.0*dx, -dy, 0, dy); // C4 F4 I4
gl_TexCoord[7] = gl_MultiTexCoord0.xyyy + vec4( 2.0*dx, -dy, 0, dy); // C4 F4 I4
}
fragment: |
uniform sampler2D rubyTexture;
@@ -76,7 +76,7 @@ fragment: |

bvec4 _or_(bvec4 A, bvec4 B) {
return bvec4(A.x || B.x, A.y || B.y, A.z || B.z, A.w || B.w);
}
}

vec4 df(vec4 A, vec4 B) {
return vec4(abs(A - B));
@@ -146,7 +146,7 @@ fragment: |
vec4 Cy = vec4( 2.0, 0.0, -1.0, 0.5 );

// These inequations define the line below which interpolation occurs
bvec4 fx = greaterThan(Ao * fp.y + Bo * fp.x, Co);
bvec4 fx = greaterThan(Ao * fp.y + Bo * fp.x, Co);
bvec4 fx_left = greaterThan(Ax * fp.y + Bx * fp.x, Cx);
bvec4 fx_up = greaterThan(Ay * fp.y + By * fp.x, Cy);

@@ -159,7 +159,7 @@ fragment: |
bvec4 interp_restriction_lv2_left = _and_( notEqual(e, g), notEqual(d, g) );
bvec4 interp_restriction_lv2_up = _and_( notEqual(e, c), notEqual(b, c) );

bvec4 edr = _and_( lessThan(weighted_distance(e, c, g, i, h5, f4, h, f),
bvec4 edr = _and_( lessThan(weighted_distance(e, c, g, i, h5, f4, h, f),
weighted_distance(h, d, i5, f, i4, b, e, i)), interp_restriction_lv1 );
bvec4 edr_left = _and_( lessThanEqual(coef * df(f, g), df(h, c)), interp_restriction_lv2_left );
bvec4 edr_up = _and_( greaterThanEqual(df(f, g), coef * df(h, c)), interp_restriction_lv2_up );
@@ -1,7 +1,7 @@
# <?xml version="1.0" encoding="UTF-8"?>
# <!--
# Hyllian's 5xBR v3.7c (squared) Shader

# Copyright (C) 2011, 2012 Hyllian/Jararaca - sergiogdb@gmail.com
# Copyright (C) 2012 crazy46guy (GLSL conversion)

@@ -44,7 +44,7 @@ vertex: |
gl_TexCoord[4] = gl_MultiTexCoord0.xxxy + vec4( -dx, 0, dx, dy); // G H I
gl_TexCoord[5] = gl_MultiTexCoord0.xxxy + vec4( -dx, 0, dx, 2.0*dy); // G5 H5 I5
gl_TexCoord[6] = gl_MultiTexCoord0.xyyy + vec4(-2.0*dx, -dy, 0, dy); // A0 D0 G0
gl_TexCoord[7] = gl_MultiTexCoord0.xyyy + vec4( 2.0*dx, -dy, 0, dy); // C4 F4 I4
gl_TexCoord[7] = gl_MultiTexCoord0.xyyy + vec4( 2.0*dx, -dy, 0, dy); // C4 F4 I4
}
fragment: |
uniform sampler2D rubyTexture;
@@ -76,7 +76,7 @@ fragment: |

bvec4 _or_(bvec4 A, bvec4 B) {
return bvec4(A.x || B.x, A.y || B.y, A.z || B.z, A.w || B.w);
}
}

vec4 df(vec4 A, vec4 B) {
return vec4(abs(A - B));
@@ -146,7 +146,7 @@ fragment: |
vec4 Cy = vec4( 2.0, 0.0, -1.0, 0.5 );

// These inequations define the line below which interpolation occurs
bvec4 fx = greaterThan(Ao * fp.y + Bo * fp.x, Co);
bvec4 fx = greaterThan(Ao * fp.y + Bo * fp.x, Co);
bvec4 fx_left = greaterThan(Ax * fp.y + Bx * fp.x, Cx);
bvec4 fx_up = greaterThan(Ay * fp.y + By * fp.x, Cy);

@@ -162,7 +162,7 @@ fragment: |
bvec4 interp_restriction_lv2_left = _and_( notEqual(e, g), notEqual(d, g) );
bvec4 interp_restriction_lv2_up = _and_( notEqual(e, c), notEqual(b, c) );

bvec4 edr = _and_( lessThan(weighted_distance(e, c, g, i, h5, f4, h, f),
bvec4 edr = _and_( lessThan(weighted_distance(e, c, g, i, h5, f4, h, f),
weighted_distance(h, d, i5, f, i4, b, e, i)), interp_restriction_lv1 );
bvec4 edr_left = _and_( lessThanEqual(coef * df(f, g), df(h, c)), interp_restriction_lv2_left );
bvec4 edr_up = _and_( greaterThanEqual(df(f, g), coef * df(h, c)), interp_restriction_lv2_up );
@@ -32,15 +32,15 @@ fragment: |
const float lum_add = 0.25; // effects smoothing

void main() {
vec3 c00 = texture2D(rubyTexture, gl_TexCoord[1].xy).xyz;
vec3 c10 = texture2D(rubyTexture, gl_TexCoord[1].zw).xyz;
vec3 c20 = texture2D(rubyTexture, gl_TexCoord[2].xy).xyz;
vec3 c01 = texture2D(rubyTexture, gl_TexCoord[4].zw).xyz;
vec3 c11 = texture2D(rubyTexture, gl_TexCoord[0].xy).xyz;
vec3 c21 = texture2D(rubyTexture, gl_TexCoord[2].zw).xyz;
vec3 c02 = texture2D(rubyTexture, gl_TexCoord[4].xy).xyz;
vec3 c12 = texture2D(rubyTexture, gl_TexCoord[3].zw).xyz;
vec3 c22 = texture2D(rubyTexture, gl_TexCoord[3].xy).xyz;
vec3 c00 = texture2D(rubyTexture, gl_TexCoord[1].xy).xyz;
vec3 c10 = texture2D(rubyTexture, gl_TexCoord[1].zw).xyz;
vec3 c20 = texture2D(rubyTexture, gl_TexCoord[2].xy).xyz;
vec3 c01 = texture2D(rubyTexture, gl_TexCoord[4].zw).xyz;
vec3 c11 = texture2D(rubyTexture, gl_TexCoord[0].xy).xyz;
vec3 c21 = texture2D(rubyTexture, gl_TexCoord[2].zw).xyz;
vec3 c02 = texture2D(rubyTexture, gl_TexCoord[4].xy).xyz;
vec3 c12 = texture2D(rubyTexture, gl_TexCoord[3].zw).xyz;
vec3 c22 = texture2D(rubyTexture, gl_TexCoord[3].xy).xyz;
vec3 dt = vec3(1.0, 1.0, 1.0);

float md1 = dot(abs(c00 - c22), dt);
@@ -54,17 +54,17 @@ vertex: |
// br = bottom-right vertex //
// bl = bottom-left vertex //
//////////////////////////////////////////////////
const vec2 tr = vec2(x_value,y_value);
const vec2 tr = vec2(x_value,y_value);
const vec2 tl = vec2(-x_value,y_value);
const vec2 br = vec2(x_value,0.0);
const vec2 br = vec2(x_value,0.0);
const vec2 bl = vec2(-x_value,0.0);

////////////////////////////////////////////////////////
//Defines screen position and initial texture coord's.//
////////////////////////////////////////////////////////
gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;
gl_TexCoord[0] = gl_MultiTexCoord0;

//////////////////////////////////////////////////////
//Defines the x-y section of the texture coordinate.//
//////////////////////////////////////////////////////
@@ -74,7 +74,7 @@ vertex: |
gl_TexCoord[4].xy = gl_TexCoord[0].xy + (tl * 0.55);
gl_TexCoord[5].xy = gl_TexCoord[0].xy - tr;
gl_TexCoord[6].xy = gl_TexCoord[0].xy + tr;

//////////////////////////////////////////////////////
//Defines the z-w section of the texture coordinate.//
//////////////////////////////////////////////////////
@@ -110,8 +110,8 @@ fragment: |
// min_weight = minimum filter weight //
//////////////////////////////////////////////////////////////
const float start_weight = 1.04;
const float k = -1.07;
const float max_weight = 0.73;
const float k = -1.07;
const float max_weight = 0.73;
const float min_weight = 0.05;

////////////////////////////////////////////////////////////////////
@@ -142,10 +142,10 @@ fragment: |
//FILTER WEIGHTS: These are the weights which will be used//
//by the filter to produce the intended result. //
////////////////////////////////////////////////////////////
float w1 = min(dot(abs(i2-i4),ref), max(dp(o2),dp(o4)));
float w2 = min(dot(abs(i1-i3),ref), max(dp(o1),dp(o3)));
float w3 = min(dot(abs(i2-i4),ref), max(dp(o2),dp(o4)));
float w4 = min(dot(abs(i1-i3),ref), max(dp(o1),dp(o3)));
float w1 = min(dot(abs(i2-i4),ref), max(dp(o2),dp(o4)));
float w2 = min(dot(abs(i1-i3),ref), max(dp(o1),dp(o3)));
float w3 = min(dot(abs(i2-i4),ref), max(dp(o2),dp(o4)));
float w4 = min(dot(abs(i1-i3),ref), max(dp(o1),dp(o3)));

//////////////////////////////////////////////////////////////////
//Adjusts the weight values, based on the previous dot-products.//
@@ -173,9 +173,9 @@ fragment: |
//Weights w1 to w4 are clamped between the min and the max weight,//
//preventing them from aversely being too high or too low. //
////////////////////////////////////////////////////////////////////
w1 = clamp(w1+start_weight, min_weight, max_weight);
w1 = clamp(w1+start_weight, min_weight, max_weight);
w2 = clamp(w2+start_weight, min_weight, max_weight);
w3 = clamp(w3+start_weight, min_weight, max_weight);
w3 = clamp(w3+start_weight, min_weight, max_weight);
w4 = clamp(w4+start_weight, min_weight, max_weight);

///////////////////////////////////////////////////////////////////////////

0 comments on commit 4251ab7

Please sign in to comment.