summaryrefslogtreecommitdiff
path: root/Pb_Api/ImGradient
diff options
context:
space:
mode:
Diffstat (limited to 'Pb_Api/ImGradient')
-rw-r--r--Pb_Api/ImGradient/Params.py45
-rw-r--r--Pb_Api/ImGradient/__init__.py13
-rw-r--r--Pb_Api/ImGradient/options.py83
3 files changed, 0 insertions, 141 deletions
diff --git a/Pb_Api/ImGradient/Params.py b/Pb_Api/ImGradient/Params.py
deleted file mode 100644
index 10d98d5..0000000
--- a/Pb_Api/ImGradient/Params.py
+++ /dev/null
@@ -1,45 +0,0 @@
-import re, random
-from Pb_Api.Params import Pb_Api_Params
-from Pb_Api.Param import Pb_Api_Param
-from Pb_Api.Param.Option import Pb_Api_Param_Option
-from Pb_Api.Param.Options import Pb_Api_Param_Options
-from Pb_Api.Param.Username import Pb_Api_Param_Username
-from Pb_Api.Param.Image_Url import Pb_Api_Param_Image_Url
-from Pb_Api.Param.MultiSelect import Pb_Api_Param_MultiSelect
-from Pb_Api.Param.NumberRange import Pb_Api_Param_NumberRange
-from Pb_Api.Param.Color import Pb_Api_Param_Color
-
-from Pb_Api.ImGradient.options import *
-
-
-
-class ImGradient_Params(Pb_Api_Params):
- def __init__(self):
- self.params = [
- Pb_Api_Param_Username(name="username", required=0),
- Pb_Api_Param_NumberRange(name="width", required=1, options=width_options, min=100, max=800),
- Pb_Api_Param_NumberRange(name="height", required=1, options=height_options, min=100, max=800),
- Pb_Api_Param_Color(name="color1", required=1, options=color1_options),
- Pb_Api_Param_Color(name="color2", required=1, options=color2_options),
- Pb_Api_Param_MultiSelect(name="filetype", required=0, options=filetype_options),
- Pb_Api_Param_MultiSelect(name="gradienttype", required=1, options=gradienttype_options),
- Pb_Api_Param_MultiSelect(name="halftone", required=0, options=halftone_options),
- Pb_Api_Param_MultiSelect(name="bevel", required=0, options=bevel_options),
-
- Pb_Api_Param_NumberRange(name="stripenumber", required=0, options=stripenumber_options, min=0, max=400),
- Pb_Api_Param_NumberRange(name="stripeintensity", required=0, options=stripeintensity_options, min=0, max=5000),
-
- Pb_Api_Param_NumberRange(name="blurriness", required=0, options=blurriness_options, min=0, max=200),
-# Pb_Api_Param_NumberRange(name="contrast", required=0, options=contrast_options, min=0, max=200),
- Pb_Api_Param_NumberRange(name="brightness", required=0, options=brightness_options, min=0, max=200),
- Pb_Api_Param_NumberRange(name="saturation", required=0, options=saturation_options, min=0, max=200),
- Pb_Api_Param_NumberRange(name="hue", required=0, options=hue_options, min=0, max=200),
-
- Pb_Api_Param_NumberRange(name="percentbeveled", required=0, options=percentbeveled_options, min=0, max=100),
- Pb_Api_Param_NumberRange(name="rotate", required=0, options=rotate_options, min=0, max=360),
- Pb_Api_Param_NumberRange(name="tilt", required=0, options=tilt_options, min=0, max=360),
-
-
- Pb_Api_Param_MultiSelect(name="flop", required=0, options=flop_options),
- Pb_Api_Param_MultiSelect(name="flip", required=0, options=flip_options),
- ]
diff --git a/Pb_Api/ImGradient/__init__.py b/Pb_Api/ImGradient/__init__.py
deleted file mode 100644
index 1f90bbe..0000000
--- a/Pb_Api/ImGradient/__init__.py
+++ /dev/null
@@ -1,13 +0,0 @@
-#!/usr/bin/python2.7
-from Pb_Api import Pb_Api
-from Pb_Api.ImGradient.Params import ImGradient_Params
-from config import IMGRADIENT_URL
-
-class Pb_Api_ImGradient(Pb_Api):
- def __init__(self):
- self.url = IMGRADIENT_URL
- def params_init(self):
- new_params = ImGradient_Params()
- #new_params = self.get_from_server()
- new_params.api = self
- return new_params
diff --git a/Pb_Api/ImGradient/options.py b/Pb_Api/ImGradient/options.py
deleted file mode 100644
index a6ad88c..0000000
--- a/Pb_Api/ImGradient/options.py
+++ /dev/null
@@ -1,83 +0,0 @@
-from Pb_Api.Param.Options import Pb_Api_Param_Options
-width_options = Pb_Api_Param_Options.from_dict(
- { "value" : 400, "weight" : 1 },
- { "value" : 600, "weight" : 1 },
-)
-height_options = Pb_Api_Param_Options.from_dict(
- { "value" : 400, "weight" : 1 },
- { "value" : 600, "weight" : 1 },
-)
-color1_options = Pb_Api_Param_Options.from_dict(
- { "value" : "black", "weight" : 1 },
- { "value" : "white", "weight" : 2 },
-)
-color2_options = Pb_Api_Param_Options.from_dict(
- { "value" : "black", "weight" : 2 },
- { "value" : "white", "weight" : 1 },
-)
-stripes_options = Pb_Api_Param_Options.from_dict(
- {"value":"true", "weight": 1},
- {"value":"false", "weight": 1},
-)
-stripenumber_options = Pb_Api_Param_Options.from_dict(
- {"value":1, "weight": 50},
- {"value":2, "weight": 50},
-)
-# contrast_options = \
-stripeintensity_options = \
- brightness_options = \
- saturation_options = \
- hue_options = \
- Pb_Api_Param_Options.from_dict(
- {"value": "", "weight": 300},
-)
-halftone_options = Pb_Api_Param_Options.from_dict(
- { "value" : "checkeredfade", "weight": 1 },
- { "value" : "etchedtransition", "weight": 1 },
- { "value" : "bendaydots", "weight": 1 },
- { "value" : "smallerdots1", "weight": 1 },
- { "value" : "smallerdots2", "weight": 1 },
- { "value" : "flatstripes", "weight": 1 },
-)
-bevel_options = Pb_Api_Param_Options.from_dict(
- { "value" : "", "weight" : 4 },
- { "value" : "flatout", "weight" : 1 },
- { "value" : "flatinner", "weight" : 1 },
- { "value" : "evenlyframed", "weight" : 1 },
- { "value" : "biginner", "weight" : 1 },
- { "value" : "bigouter", "weight" : 1 },
- { "value" : "dramaticflatout", "weight" : 1 },
- { "value" : "dramaticflatinner", "weight" : 1 },
-)
-
-blurriness_options = \
- percentbeveled_options = Pb_Api_Param_Options.from_dict(
- { "value" : "", "weight": 4 },
-)
-rotate_options = \
- tilt_options = Pb_Api_Param_Options.from_dict(
- {"value":"", "weight": 9},
- {"value":90, "weight": 2},
- {"value":180, "weight": 2},
- {"value":270, "weight": 2},
-)
-flop_options = flip_options = Pb_Api_Param_Options.from_dict(
- {"value":"", "weight": 1},
- {"value":"true", "weight": 1},
-)
-
-filetype_options = Pb_Api_Param_Options.from_dict(
- {"value":"png", "weight": 5},
- {"value":"jpg", "weight": 2},
- {"value":"gif", "weight": 2},
-)
-gradienttype_options = Pb_Api_Param_Options.from_dict(
- { "value" : "canvas", "weight" : 1 },
- { "value" : "gradient", "weight" : 3 },
- { "value" : "radial", "weight" : 1 },
- { "value" : "colorspace", "weight" : 1 },
- { "value" : "plasmawash", "weight" : 1 },
- { "value" : "gradientwash", "weight" : 1 },
- { "value" : "mirrored", "weight" : 1 },
- { "value" : "noise", "weight" : 1 },
-)