Browse Source

fix author

master
独行之狼 4 years ago
parent
commit
815a064f41
  1. BIN
      fr-plugin-imageProcess-1.0/fr-plugin-imageProcess-1.0.jar
  2. 18
      fr-plugin-imageProcess-1.0/plugin.xml
  3. BIN
      install/fr-plugin-imageProcess-1.0.zip
  4. 2
      src/main/java/com/fr/plugin/image/process/FRImageAdjustRGB.java
  5. 2
      src/main/java/com/fr/plugin/image/process/FRImageChrome.java
  6. 2
      src/main/java/com/fr/plugin/image/process/FRImageColorGain.java
  7. 2
      src/main/java/com/fr/plugin/image/process/FRImageColorInvert.java
  8. 2
      src/main/java/com/fr/plugin/image/process/FRImageColorLevel.java
  9. 2
      src/main/java/com/fr/plugin/image/process/FRImageContrast.java
  10. 2
      src/main/java/com/fr/plugin/image/process/FRImageCrystallize.java
  11. 2
      src/main/java/com/fr/plugin/image/process/FRImageDiffusionDither.java
  12. 2
      src/main/java/com/fr/plugin/image/process/FRImageDissolve.java
  13. 2
      src/main/java/com/fr/plugin/image/process/FRImageEmboss.java
  14. 2
      src/main/java/com/fr/plugin/image/process/FRImageExposure.java
  15. 2
      src/main/java/com/fr/plugin/image/process/FRImageFlare.java
  16. 2
      src/main/java/com/fr/plugin/image/process/FRImageFromText.java
  17. 2
      src/main/java/com/fr/plugin/image/process/FRImageGamma.java
  18. 2
      src/main/java/com/fr/plugin/image/process/FRImageGaussianBlur.java
  19. 2
      src/main/java/com/fr/plugin/image/process/FRImageGlow.java
  20. 2
      src/main/java/com/fr/plugin/image/process/FRImageGrayScale.java
  21. 2
      src/main/java/com/fr/plugin/image/process/FRImageMixChannel.java
  22. 2
      src/main/java/com/fr/plugin/image/process/FRImageMosaic.java
  23. 2
      src/main/java/com/fr/plugin/image/process/FRImageOil.java
  24. 2
      src/main/java/com/fr/plugin/image/process/FRImagePosterize.java
  25. 2
      src/main/java/com/fr/plugin/image/process/FRImageReScale.java
  26. 2
      src/main/java/com/fr/plugin/image/process/FRImageScaleRotate.java
  27. 2
      src/main/java/com/fr/plugin/image/process/FRImageSize.java
  28. 2
      src/main/java/com/fr/plugin/image/process/FRImageSolar.java
  29. 2
      src/main/java/com/fr/plugin/image/process/FRImageSparkle.java
  30. 2
      src/main/java/com/fr/plugin/image/process/FRImageStamp.java
  31. 2
      src/main/java/com/fr/plugin/image/process/FRImageTransparency.java
  32. 2
      src/main/java/com/fr/plugin/image/process/FRImageWaterMark.java
  33. 2
      src/main/java/com/fr/plugin/image/process/FRImageWeave.java
  34. 5
      src/main/java/com/fr/plugin/image/process/FunctionConstants.java

BIN
fr-plugin-imageProcess-1.0/fr-plugin-imageProcess-1.0.jar

Binary file not shown.

18
fr-plugin-imageProcess-1.0/plugin.xml

@ -0,0 +1,18 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><plugin>
<id>com.fr.plugin.function.image.process</id>
<name><![CDATA[图像处理函数]]></name>
<active>yes</active>
<version>1.0</version>
<env-version>10.0</env-version>
<jartime>2018-07-31</jartime>
<vendor>all100</vendor>
<description><![CDATA[一组图像处理函数]]></description>
<change-notes><![CDATA[
[2021-3-6]初始化插件。<br/>
]]></change-notes>
<extra-core>
<LocaleFinder class="com.fr.plugin.image.process.MyLocaleFinder"/>
<FunctionGroup class="com.fr.plugin.image.process.ImageProcessFunction" />
</extra-core>
<function-recorder class="com.fr.plugin.image.process.FRImageContrast"/>
</plugin>

BIN
install/fr-plugin-imageProcess-1.0.zip

Binary file not shown.

2
src/main/java/com/fr/plugin/image/process/FRImageAdjustRGB.java

@ -18,7 +18,7 @@ public class FRImageAdjustRGB extends AbstractFunction {
@Override
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageAdjustRGB", source = Original.PLUGIN)
public Object run(Object[] args) throws FormulaException {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes=FunctionConstants.CheckArgs(args,4);

2
src/main/java/com/fr/plugin/image/process/FRImageChrome.java

@ -16,7 +16,7 @@ import java.awt.image.BufferedImage;
public class FRImageChrome extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageChrome", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 6);

2
src/main/java/com/fr/plugin/image/process/FRImageColorGain.java

@ -16,7 +16,7 @@ import java.awt.image.BufferedImage;
public class FRImageColorGain extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageColorGain", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 3);

2
src/main/java/com/fr/plugin/image/process/FRImageColorInvert.java

@ -16,7 +16,7 @@ import java.awt.image.BufferedImage;
public class FRImageColorInvert extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageColorInvert", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 1);

2
src/main/java/com/fr/plugin/image/process/FRImageColorLevel.java

@ -16,7 +16,7 @@ import java.awt.image.BufferedImage;
public class FRImageColorLevel extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageColorLevel", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 5);

2
src/main/java/com/fr/plugin/image/process/FRImageContrast.java

@ -17,7 +17,7 @@ public class FRImageContrast extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageContrast", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 3);

2
src/main/java/com/fr/plugin/image/process/FRImageCrystallize.java

@ -16,7 +16,7 @@ import java.awt.image.BufferedImage;
public class FRImageCrystallize extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageCrystallize", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 6);

2
src/main/java/com/fr/plugin/image/process/FRImageDiffusionDither.java

@ -18,7 +18,7 @@ public class FRImageDiffusionDither extends AbstractFunction {
@Override
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageDiffusionDither", source = Original.PLUGIN)
public Object run(Object[] args) throws FormulaException {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes=FunctionConstants.CheckArgs(args,4);

2
src/main/java/com/fr/plugin/image/process/FRImageDissolve.java

@ -16,7 +16,7 @@ import java.awt.image.BufferedImage;
public class FRImageDissolve extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageDissolve", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 3);

2
src/main/java/com/fr/plugin/image/process/FRImageEmboss.java

@ -16,7 +16,7 @@ import java.awt.image.BufferedImage;
public class FRImageEmboss extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageEmboss", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 5);

2
src/main/java/com/fr/plugin/image/process/FRImageExposure.java

@ -18,7 +18,7 @@ public class FRImageExposure extends AbstractFunction {
@Override
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageExposure", source = Original.PLUGIN)
public Object run(Object[] args) throws FormulaException {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}

2
src/main/java/com/fr/plugin/image/process/FRImageFlare.java

@ -20,7 +20,7 @@ public class FRImageFlare extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageFlare", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 9);

2
src/main/java/com/fr/plugin/image/process/FRImageFromText.java

@ -19,7 +19,7 @@ public class FRImageFromText extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageFromText", source = Original.PLUGIN)
@Override
public Object run(Object[] args) throws FormulaException {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String text = args[0].toString();

2
src/main/java/com/fr/plugin/image/process/FRImageGamma.java

@ -16,7 +16,7 @@ import java.awt.image.BufferedImage;
public class FRImageGamma extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageGamma", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 2);

2
src/main/java/com/fr/plugin/image/process/FRImageGaussianBlur.java

@ -17,7 +17,7 @@ public class FRImageGaussianBlur extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageTritone", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 2);

2
src/main/java/com/fr/plugin/image/process/FRImageGlow.java

@ -17,7 +17,7 @@ public class FRImageGlow extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageGlow", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 3);

2
src/main/java/com/fr/plugin/image/process/FRImageGrayScale.java

@ -16,7 +16,7 @@ import java.awt.image.BufferedImage;
public class FRImageGrayScale extends AbstractFunction {
@Focus(id =FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageGrayScale", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 1);

2
src/main/java/com/fr/plugin/image/process/FRImageMixChannel.java

@ -16,7 +16,7 @@ import java.awt.image.BufferedImage;
public class FRImageMixChannel extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageMixChannel", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 7);

2
src/main/java/com/fr/plugin/image/process/FRImageMosaic.java

@ -17,7 +17,7 @@ public class FRImageMosaic extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageMosaic", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 2);

2
src/main/java/com/fr/plugin/image/process/FRImageOil.java

@ -17,7 +17,7 @@ public class FRImageOil extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageOil", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 3);

2
src/main/java/com/fr/plugin/image/process/FRImagePosterize.java

@ -17,7 +17,7 @@ public class FRImagePosterize extends AbstractFunction {
@Focus(id =FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImagePosterize", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 2);

2
src/main/java/com/fr/plugin/image/process/FRImageReScale.java

@ -17,7 +17,7 @@ public class FRImageReScale extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageReScale", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 2);

2
src/main/java/com/fr/plugin/image/process/FRImageScaleRotate.java

@ -20,7 +20,7 @@ public class FRImageScaleRotate extends AbstractFunction {
@Override
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageScaleRotate", source = Original.PLUGIN)
public Object run(Object[] args) throws FormulaException {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}

2
src/main/java/com/fr/plugin/image/process/FRImageSize.java

@ -19,7 +19,7 @@ public class FRImageSize extends AbstractFunction {
@Override
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageSize", source = Original.PLUGIN)
public Object run(Object[] args) throws FormulaException {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}

2
src/main/java/com/fr/plugin/image/process/FRImageSolar.java

@ -16,7 +16,7 @@ import java.awt.image.BufferedImage;
public class FRImageSolar extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageSolar", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 1);

2
src/main/java/com/fr/plugin/image/process/FRImageSparkle.java

@ -16,7 +16,7 @@ import java.awt.image.BufferedImage;
public class FRImageSparkle extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageSparkle", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 4);

2
src/main/java/com/fr/plugin/image/process/FRImageStamp.java

@ -16,7 +16,7 @@ import java.awt.image.BufferedImage;
public class FRImageStamp extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageStamp", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 4);

2
src/main/java/com/fr/plugin/image/process/FRImageTransparency.java

@ -16,7 +16,7 @@ import java.awt.image.BufferedImage;
public class FRImageTransparency extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageTransparency", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 2);

2
src/main/java/com/fr/plugin/image/process/FRImageWaterMark.java

@ -20,7 +20,7 @@ public class FRImageWaterMark extends AbstractFunction {
@Override
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageWaterMark", source = Original.PLUGIN)
public Object run(Object[] args) throws FormulaException {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}

2
src/main/java/com/fr/plugin/image/process/FRImageWeave.java

@ -16,7 +16,7 @@ import java.awt.image.BufferedImage;
public class FRImageWeave extends AbstractFunction {
@Focus(id = FunctionConstants.PLUGIN_ID, text = "Plugin-Test_Function_FRImageWeave", source = Original.PLUGIN)
public Object run(Object[] args) {
if (!PluginContexts.currentContext().isAvailable()) {
if(!FunctionConstants.author()){
return FunctionConstants.AUTHOR_ERROR;
}
String checkRes = FunctionConstants.CheckArgs(args, 5);

5
src/main/java/com/fr/plugin/image/process/FunctionConstants.java

@ -1,5 +1,6 @@
package com.fr.plugin.image.process;
import com.fr.plugin.context.PluginContexts;
import com.fr.stable.ArrayUtils;
import javax.imageio.ImageIO;
import java.awt.*;
@ -14,6 +15,10 @@ public class FunctionConstants {
static final String PLUGIN_ID = "com.fr.plugin.function.image.process";
static final String AUTHOR_ERROR=i18nText("Plugin.Function.ImagProcess_AUTHOR_ERROR");
static final String CHECK_PASS=i18nText("Plugin.Function.ImagProcess_CHECK_PASS");
static final boolean author() {
return PluginContexts.currentContext().isAvailable();
}
static BufferedImage readImage(Object file) {
BufferedImage res;
if(file instanceof BufferedImage){

Loading…
Cancel
Save