Skip to content

Commit

Permalink
→ v0.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
cormullion committed Jul 16, 2023
1 parent f0a6997 commit 8691e86
Show file tree
Hide file tree
Showing 9 changed files with 27,084 additions and 26,607 deletions.
17 changes: 17 additions & 0 deletions .github/workflows/TagBot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: TagBot
on:
issue_comment: # THIS BIT IS NEW
types:
- created
workflow_dispatch:
jobs:
TagBot:
# THIS 'if' LINE IS NEW
if: github.event_name == 'workflow_dispatch' || github.actor == 'JuliaTagBot'
# NOTHING BELOW HAS CHANGED
runs-on: ubuntu-latest
steps:
- uses: JuliaRegistries/TagBot@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
ssh: ${{ secrets.DOCUMENTER_KEY }}
52 changes: 52 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: CI
on:
pull_request:
branches:
- master
push:
branches:
- master
tags: '*'
jobs:
test:
name: Julia ${{ matrix.julia-version }} - ${{ matrix.os }} - ${{ matrix.julia-arch }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
julia-version:
- "1.6"
- "1"
- "nightly"
os:
- ubuntu-latest
- macos-latest
- windows-latest
julia-arch:
- x64
exclude:
- os: macOS-latest
julia-arch: x86

steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@v1
with:
version: ${{ matrix.julia-version }}
arch: ${{ matrix.julia-arch }}
- uses: actions/cache@v1
env:
cache-name: cache-artifacts
with:
path: ~/.julia/artifacts
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
restore-keys: |
${{ runner.os }}-test-${{ env.cache-name }}-
${{ runner.os }}-test-
${{ runner.os }}-
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-runtest@v1
- uses: julia-actions/julia-processcoverage@v1
- uses: codecov/codecov-action@v1
with:
file: lcov.info
37 changes: 0 additions & 37 deletions .travis.yml

This file was deleted.

12 changes: 5 additions & 7 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
name = "Mellan"
uuid = "9395f11c-09ed-45be-886c-23f223b99ebb"
authors = ["cormullion <cormullion@mac.com>"]
version = "0.1.0"
version = "0.2.0"

[deps]
Luxor = "ae8d54c2-7ccd-5906-9d76-62fc9837b5bc"
Colors = "5ae59095-9a9b-59fe-a467-6f913c188581"
FileIO = "5789e2e9-d7fb-5bc7-8068-2c6fae9b9549"
Images = "916415d5-f1e6-5110-898d-aaa5f9f070e0"
QuartzImageIO = "dca85d43-d64c-5e67-8c65-017450d5d020"
ImageMagick = "6218d12a-5da1-5696-b52f-db25d2ecc6d1"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[extras]
Expand All @@ -21,9 +20,8 @@ test = ["Test", "Luxor"]

[compat]
julia = "1"
Luxor = "^2"
Luxor = "^3"
Colors = "0.9.0, 0.10.0, 0.11.0, 0.12.0"
Images = "0.19, 0.20, 0.21, 0.22, 0.23"
ImageMagick = "0.7, 1"
QuartzImageIO = "^0.6"
FileIO = "1.2, 1.3, 1.4"
Images = "0.19, 0.20, 0.21, 0.22, 0.23, 0.24, 0.25"
QuartzImageIO = "0.6, 0.7"
FileIO = "1"
35 changes: 25 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
![travis-img]: https://travis-ci.org/cormullion/Mellan.jl.svg?branch=master
![travis-url]: https://travis-ci.org/cormullion/Mellan.jl

| **Build Status** | **Code Coverage** |
|:-----------------------------------------:|:-------------------------------:|
| [![Build Status][ci-img]][ci-url] | [![][codecov-img]][codecov-url] |
| [![Build Status][appvey-img]][appvey-url] | |

# Mellan

Claude Mellan (1598 to 1688) was a French artist and engraver, remembered today (if at all) only for his virtuosic engravings, in which the image consists of a single spiral groove starting at the centre and winding outwards (like a vinyl record). The different tones are obtained by the slight swelling and shrinking of the line as it proceeds on its spiral outward course. Here's what Leonardo da Vinci's Mona Lisa would have looked like if rendered by Mellan.

![mellanized Mona Lisa](docs/mona.svg)
![mellanized Mona Lisa](images/mona.svg)

Today's computers don't find these images difficult to produce, but the effect is pleasing. This little Julia package will 'Mellanize' images and output a PNG/SVG/PDF file.

Expand All @@ -20,28 +23,28 @@ The image should be square (obviously!), and a JPG or 8 bit PNG.
```
using Mellan
mellanize("Mellan/test/mona.png" output="/tmp/mona.svg")
mellanize("Mellan/test/mona.png", output="/tmp/mona.svg")
```

draws the image above. There are plenty of options to play with:

```
mellanize("Mellan/test/mona.png",
500,
500, # default side length
lineweight = 3,
output = "mona-mellan.svg",
minlineweight = 0.1,
foregroundcolor = "black",
backgroundcolor = "gold2",
foregroundcolor = "black",
backgroundcolor = "gold2",
startradius = 5,
margin = 0,
tightness = 0.5,
chord = 3,
chord = 2,
annotation = true)
```

![another mellanized Mona Lisa](docs/mona-mellan.svg)
![another mellanized Mona Lisa](images/mona-mellan.svg)

Use the `mellanize` function and supply a path name of an image and optionally the required side length. The keyword parameters are all optional, but the ones of interest are:

Expand All @@ -63,7 +66,7 @@ Use the `mellanize` function and supply a path name of an image and optionally t

- chord

the length of each line segment (default 5.0). This is constant for the entire image, although the line width changes. Shorter lines provide more detail.
the length of each line segment (default 2.0). This is constant for the entire image, although the radius changes. Shorter lines provide more detail.

- annotation

Expand All @@ -72,3 +75,15 @@ Use the `mellanize` function and supply a path name of an image and optionally t
- output

the pathname for the output image. If not supplied, the name is constructed with `splitext(imagefile)[1] * "-mellan-$(side).pdf"`.


[pkgeval-link]: http://pkg.julialang.org/?pkg=Mellan

[ci-img]: https://github.com/cormullion/Mellan.jl/workflows/CI/badge.svg
[ci-url]: https://github.com/cormullion/Mellan.jl/actions?query=workflow%3ACI

[appvey-img]: https://ci.appveyor.com/api/projects/status/jfa9e54lv92rqd3m?svg=true
[appvey-url]: https://ci.appveyor.com/project/cormullion/Mellan-jl/branch/master

[codecov-img]: https://codecov.io/gh/cormullion/Mellan.jl/branch/master/graph/badge.svg
[codecov-url]: https://codecov.io/gh/cormullion/Mellan.jl
Loading

0 comments on commit 8691e86

Please sign in to comment.