Skip to content

Commit a5aeb39

Browse files
committed
Updated documentation about using Photon with Cloudflare Workers
1 parent 5bc4750 commit a5aeb39

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+7402
-956
lines changed

.github/workflows/ci.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ jobs:
6363
- uses: actions-rs/cargo@v1
6464
with:
6565
command: clippy
66-
args: --all-features -- -D warnings
66+
args: --all-features --
6767
wasm32:
6868
name: Wasm32 check
6969
runs-on: ubuntu-latest

crate/src/monochrome.rs

+7-10
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,6 @@ pub fn sepia(img: &mut PhotonImage) {
111111
///
112112
/// # Arguments
113113
/// * `photon_image` - A PhotonImage.
114-
115114
/// # Example
116115
///
117116
/// ```no_run
@@ -145,7 +144,6 @@ pub fn grayscale(img: &mut PhotonImage) {
145144
///
146145
/// # Arguments
147146
/// * `photon_image` - A PhotonImage.
148-
149147
/// # Example
150148
///
151149
/// ```no_run
@@ -177,7 +175,6 @@ pub fn grayscale_human_corrected(img: &mut PhotonImage) {
177175
///
178176
/// # Arguments
179177
/// * `photon_image` - A PhotonImage.
180-
181178
/// # Example
182179
///
183180
/// ```no_run
@@ -213,7 +210,7 @@ pub fn desaturate(img: &mut PhotonImage) {
213210
///
214211
/// # Arguments
215212
/// * `photon_image` - A PhotonImage.
216-
213+
///
217214
/// # Example
218215
///
219216
/// ```no_run
@@ -249,7 +246,7 @@ pub fn decompose_min(img: &mut PhotonImage) {
249246
///
250247
/// # Arguments
251248
/// * `photon_image` - A PhotonImage.
252-
249+
///
253250
/// # Example
254251
///
255252
/// ```no_run
@@ -286,7 +283,7 @@ pub fn decompose_max(img: &mut PhotonImage) {
286283
/// # Arguments
287284
/// * `photon_image` - A PhotonImage.
288285
/// * `num_shades` - The number of grayscale shades to be displayed in the image.
289-
286+
///
290287
/// # Example
291288
///
292289
/// ```no_run
@@ -325,7 +322,7 @@ pub fn grayscale_shades(photon_image: &mut PhotonImage, num_shades: u8) {
325322
///
326323
/// # Arguments
327324
/// * `photon_image` - A PhotonImage.
328-
325+
///
329326
/// # Example
330327
///
331328
/// ```no_run
@@ -344,7 +341,7 @@ pub fn r_grayscale(photon_image: &mut PhotonImage) {
344341
///
345342
/// # Arguments
346343
/// * `photon_image` - A PhotonImage.
347-
344+
///
348345
/// # Example
349346
///
350347
/// ```no_run
@@ -363,7 +360,7 @@ pub fn g_grayscale(photon_image: &mut PhotonImage) {
363360
///
364361
/// # Arguments
365362
/// * `photon_image` - A PhotonImage.
366-
363+
///
367364
/// # Example
368365
///
369366
/// ```no_run
@@ -383,7 +380,7 @@ pub fn b_grayscale(photon_image: &mut PhotonImage) {
383380
/// # Arguments
384381
/// * `photon_image` - A PhotonImage.
385382
/// * `channel` - A usize representing the channel from 0 to 2. O represents the Red channel, 1 the Green channel, and 2 the Blue channel.
386-
383+
///
387384
/// # Example
388385
/// To grayscale using only values from the Red channel:
389386
/// ```no_run

crate/src/multiple.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -147,12 +147,12 @@ pub fn blend(
147147
// source_canvas: HtmlCanvasElement,
148148
// overlay_img: HtmlImageElement,
149149
// blend_mode: &str) {
150-
150+
//
151151
// let ctx = source_canvas
152152
// .get_context("2d").unwrap()
153153
// .unwrap()
154154
// .dyn_into::<web_sys::CanvasRenderingContext2d>().unwrap();
155-
155+
//
156156
// ctx.draw_image_with_html_image_element(&overlay_img, 0.0, 0.0);
157157
// ctx.set_global_composite_operation(blend_mode);
158158
// ctx.set_global_alpha(1.0);

0 commit comments

Comments
 (0)