Skip to content

Commit

Permalink
Added README.md files for browsing image directory
Browse files Browse the repository at this point in the history
  • Loading branch information
OneEyeMaker committed Jul 6, 2022
1 parent c4ac9de commit 1f53562
Show file tree
Hide file tree
Showing 4 changed files with 346 additions and 1 deletion.
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Then this mosaic can be painted with any color or gradient.
Next code creates logo of this project (the one you can see above).

```rust
use palette::{Gradient, LinSrgb};
use palette::LinSrgb;
use starry_mosaic::{coloring_method::RadialGradient, Mosaic, MosaicBuilder, Vector};

let mosaic = MosaicBuilder::default()
Expand Down Expand Up @@ -55,3 +55,8 @@ let mosaic_image = mosaic.draw(RadialGradient::new(
let save_result = mosaic_image.save("target/logo.png");
assert!(save_result.is_ok());
```

## More images

To see more images visit [`images` directory](https://github.com/OneEyeMaker/starry_mosaic/tree/master/images/README.md)
in repository of this project.
13 changes: 13 additions & 0 deletions images/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Images

This directory contains example images generated using this library.

For ease of searching for mosaic images each directory contains `README.md` file.

* [Logo](logo.png) of the project.
* [starry_mosaic](starry_mosaic/README.md) - contains mosaic images
created using `starry_mosaic::StarryMosaic` (or `starry_mosaic::MosaicBuilder::build_star`);
these images are based on [Voronoi diagram](https://en.wikipedia.org/wiki/Voronoi_diagram).
* [polygonal_mosaic](polygonal_mosaic/README.md) - contains mosaic images
created using `starry_mosaic::PolygonalMosaic` (or `starry_mosaic::MosaicBuilder::build_polygon`);
such images are based on [Delaunay triangulation](https://en.wikipedia.org/wiki/Delaunay_triangulation).
164 changes: 164 additions & 0 deletions images/polygonal_mosaic/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,164 @@
<style>
img {
width: 40%;
}
</style>

# Polygonal Mosaic images

All images in this directory (and subdirectories) are created using `starry_mosaic::PolygonalMosaic` and
based on [Delaunay triangulation](https://en.wikipedia.org/wiki/Delaunay_triangulation).

Every mosaic image can be generated using different mosaic shapes (`starry_mosaic::mosaic_shape::MosaicShape`)
and painted with various coloring methods (`starry_mosaic::coloring_method::ColoringMethod`).
This page illustrates just few of these.

## Single colored

Mosaics are painted with single color to create images below.
This library supports many color types provided by `palette` crate.

*Why images are blue? Just because I like this color!*

### With shape of regular polygon

Mosaic shape used to generate images in this section is based on regular polygon.
See `starry_mosaic::mosaic_shape::RegularPolygon` for more details.

[![Polygonal single colored mosaic image with shape of regular polygon](single_colored/regular_polygon_5.png)](single_colored/regular_polygon_5.png)
[![Polygonal single colored mosaic image with shape of regular polygon](single_colored/regular_polygon_6.png)](single_colored/regular_polygon_6.png)
[![Polygonal single colored mosaic image with shape of regular polygon](single_colored/regular_polygon_7.png)](single_colored/regular_polygon_7.png)
[![Polygonal single colored mosaic image with shape of regular polygon](single_colored/regular_polygon_8.png)](single_colored/regular_polygon_8.png)
[![Polygonal single colored mosaic image with shape of regular polygon](single_colored/regular_polygon_12.png)](single_colored/regular_polygon_12.png)
[![Polygonal single colored mosaic image with shape of regular polygon](single_colored/regular_polygon_13.png)](single_colored/regular_polygon_13.png)
[![Polygonal single colored mosaic image with shape of regular polygon](single_colored/regular_polygon_15.png)](single_colored/regular_polygon_15.png)
[![Polygonal single colored mosaic image with shape of regular polygon](single_colored/regular_polygon_16.png)](single_colored/regular_polygon_16.png)
[![Polygonal single colored mosaic image with shape of regular polygon](single_colored/regular_polygon_23.png)](single_colored/regular_polygon_23.png)
[![Polygonal single colored mosaic image with shape of regular polygon](single_colored/regular_polygon_24.png)](single_colored/regular_polygon_24.png)

### With shape of polygonal star

Shape of mosaic used to generate images in this section is based on polygonal star.
See `starry_mosaic::mosaic_shape::PolygonalStar` for more details.

[![Polygonal single colored mosaic image with shape of polygonal star](single_colored/polygonal_star_5.png)](single_colored/polygonal_star_5.png)
[![Polygonal single colored mosaic image with shape of polygonal star](single_colored/polygonal_star_6.png)](single_colored/polygonal_star_6.png)
[![Polygonal single colored mosaic image with shape of polygonal star](single_colored/polygonal_star_7.png)](single_colored/polygonal_star_7.png)
[![Polygonal single colored mosaic image with shape of polygonal star](single_colored/polygonal_star_8.png)](single_colored/polygonal_star_8.png)
[![Polygonal single colored mosaic image with shape of polygonal star](single_colored/polygonal_star_12.png)](single_colored/polygonal_star_12.png)
[![Polygonal single colored mosaic image with shape of polygonal star](single_colored/polygonal_star_13.png)](single_colored/polygonal_star_13.png)
[![Polygonal single colored mosaic image with shape of polygonal star](single_colored/polygonal_star_15.png)](single_colored/polygonal_star_15.png)
[![Polygonal single colored mosaic image with shape of polygonal star](single_colored/polygonal_star_16.png)](single_colored/polygonal_star_16.png)
[![Polygonal single colored mosaic image with shape of polygonal star](single_colored/polygonal_star_23.png)](single_colored/polygonal_star_23.png)
[![Polygonal single colored mosaic image with shape of polygonal star](single_colored/polygonal_star_24.png)](single_colored/polygonal_star_24.png)

## Linear gradient

Mosaics are painted with linear gradient (`starry_mosaic::coloring_method::LinearGradient`)
to create images below.

### With shape of regular polygon

Mosaic shape used to generate images in this section is based on regular polygon.
See `starry_mosaic::mosaic_shape::RegularPolygon` for more details.

[![Polygonal linear gradient mosaic image with shape of regular polygon](linear_gradient/regular_polygon_5.png)](linear_gradient/regular_polygon_5.png)
[![Polygonal linear gradient mosaic image with shape of regular polygon](linear_gradient/regular_polygon_6.png)](linear_gradient/regular_polygon_6.png)
[![Polygonal linear gradient mosaic image with shape of regular polygon](linear_gradient/regular_polygon_7.png)](linear_gradient/regular_polygon_7.png)
[![Polygonal linear gradient mosaic image with shape of regular polygon](linear_gradient/regular_polygon_8.png)](linear_gradient/regular_polygon_8.png)
[![Polygonal linear gradient mosaic image with shape of regular polygon](linear_gradient/regular_polygon_12.png)](linear_gradient/regular_polygon_12.png)
[![Polygonal linear gradient mosaic image with shape of regular polygon](linear_gradient/regular_polygon_13.png)](linear_gradient/regular_polygon_13.png)
[![Polygonal linear gradient mosaic image with shape of regular polygon](linear_gradient/regular_polygon_15.png)](linear_gradient/regular_polygon_15.png)
[![Polygonal linear gradient mosaic image with shape of regular polygon](linear_gradient/regular_polygon_16.png)](linear_gradient/regular_polygon_16.png)
[![Polygonal linear gradient mosaic image with shape of regular polygon](linear_gradient/regular_polygon_23.png)](linear_gradient/regular_polygon_23.png)
[![Polygonal linear gradient mosaic image with shape of regular polygon](linear_gradient/regular_polygon_24.png)](linear_gradient/regular_polygon_24.png)

### With shape of polygonal star

Shape of mosaic used to generate images in this section is based on polygonal star.
See `starry_mosaic::mosaic_shape::PolygonalStar` for more details.

[![Polygonal linear gradient mosaic image with shape of polygonal star](linear_gradient/polygonal_star_5.png)](linear_gradient/polygonal_star_5.png)
[![Polygonal linear gradient mosaic image with shape of polygonal star](linear_gradient/polygonal_star_6.png)](linear_gradient/polygonal_star_6.png)
[![Polygonal linear gradient mosaic image with shape of polygonal star](linear_gradient/polygonal_star_7.png)](linear_gradient/polygonal_star_7.png)
[![Polygonal linear gradient mosaic image with shape of polygonal star](linear_gradient/polygonal_star_8.png)](linear_gradient/polygonal_star_8.png)
[![Polygonal linear gradient mosaic image with shape of polygonal star](linear_gradient/polygonal_star_12.png)](linear_gradient/polygonal_star_12.png)
[![Polygonal linear gradient mosaic image with shape of polygonal star](linear_gradient/polygonal_star_13.png)](linear_gradient/polygonal_star_13.png)
[![Polygonal linear gradient mosaic image with shape of polygonal star](linear_gradient/polygonal_star_15.png)](linear_gradient/polygonal_star_15.png)
[![Polygonal linear gradient mosaic image with shape of polygonal star](linear_gradient/polygonal_star_16.png)](linear_gradient/polygonal_star_16.png)
[![Polygonal linear gradient mosaic image with shape of polygonal star](linear_gradient/polygonal_star_23.png)](linear_gradient/polygonal_star_23.png)
[![Polygonal linear gradient mosaic image with shape of polygonal star](linear_gradient/polygonal_star_24.png)](linear_gradient/polygonal_star_24.png)

## Radial gradient

Mosaics are painted with radial gradient (`starry_mosaic::coloring_method::RadialGradient`)
to create images below.

### With shape of regular polygon

Mosaic shape used to generate images in this section is based on regular polygon.
See `starry_mosaic::mosaic_shape::RegularPolygon` for more details.

[![Polygonal radial gradient mosaic image with shape of regular polygon](radial_gradient/regular_polygon_5.png)](radial_gradient/regular_polygon_5.png)
[![Polygonal radial gradient mosaic image with shape of regular polygon](radial_gradient/regular_polygon_6.png)](radial_gradient/regular_polygon_6.png)
[![Polygonal radial gradient mosaic image with shape of regular polygon](radial_gradient/regular_polygon_7.png)](radial_gradient/regular_polygon_7.png)
[![Polygonal radial gradient mosaic image with shape of regular polygon](radial_gradient/regular_polygon_8.png)](radial_gradient/regular_polygon_8.png)
[![Polygonal radial gradient mosaic image with shape of regular polygon](radial_gradient/regular_polygon_12.png)](radial_gradient/regular_polygon_12.png)
[![Polygonal radial gradient mosaic image with shape of regular polygon](radial_gradient/regular_polygon_13.png)](radial_gradient/regular_polygon_13.png)
[![Polygonal radial gradient mosaic image with shape of regular polygon](radial_gradient/regular_polygon_15.png)](radial_gradient/regular_polygon_15.png)
[![Polygonal radial gradient mosaic image with shape of regular polygon](radial_gradient/regular_polygon_16.png)](radial_gradient/regular_polygon_16.png)
[![Polygonal radial gradient mosaic image with shape of regular polygon](radial_gradient/regular_polygon_23.png)](radial_gradient/regular_polygon_23.png)
[![Polygonal radial gradient mosaic image with shape of regular polygon](radial_gradient/regular_polygon_24.png)](radial_gradient/regular_polygon_24.png)

### With shape of polygonal star

Shape of mosaic used to generate images in this section is based on polygonal star.
See `starry_mosaic::mosaic_shape::PolygonalStar` for more details.

[![Polygonal radial gradient mosaic image with shape of polygonal star](radial_gradient/polygonal_star_5.png)](radial_gradient/polygonal_star_5.png)
[![Polygonal radial gradient mosaic image with shape of polygonal star](radial_gradient/polygonal_star_6.png)](radial_gradient/polygonal_star_6.png)
[![Polygonal radial gradient mosaic image with shape of polygonal star](radial_gradient/polygonal_star_7.png)](radial_gradient/polygonal_star_7.png)
[![Polygonal radial gradient mosaic image with shape of polygonal star](radial_gradient/polygonal_star_8.png)](radial_gradient/polygonal_star_8.png)
[![Polygonal radial gradient mosaic image with shape of polygonal star](radial_gradient/polygonal_star_12.png)](radial_gradient/polygonal_star_12.png)
[![Polygonal radial gradient mosaic image with shape of polygonal star](radial_gradient/polygonal_star_13.png)](radial_gradient/polygonal_star_13.png)
[![Polygonal radial gradient mosaic image with shape of polygonal star](radial_gradient/polygonal_star_15.png)](radial_gradient/polygonal_star_15.png)
[![Polygonal radial gradient mosaic image with shape of polygonal star](radial_gradient/polygonal_star_16.png)](radial_gradient/polygonal_star_16.png)
[![Polygonal radial gradient mosaic image with shape of polygonal star](radial_gradient/polygonal_star_23.png)](radial_gradient/polygonal_star_23.png)
[![Polygonal radial gradient mosaic image with shape of polygonal star](radial_gradient/polygonal_star_24.png)](radial_gradient/polygonal_star_24.png)

## Conic gradient

Mosaics are painted with conic gradient (`starry_mosaic::coloring_method::ConicGradient`)
to create images below.

### With shape of regular polygon

Mosaic shape used to generate images in this section is based on regular polygon.
See `starry_mosaic::mosaic_shape::RegularPolygon` for more details.

[![Polygonal conic gradient mosaic image with shape of regular polygon](conic_gradient/regular_polygon_5.png)](conic_gradient/regular_polygon_5.png)
[![Polygonal conic gradient mosaic image with shape of regular polygon](conic_gradient/regular_polygon_6.png)](conic_gradient/regular_polygon_6.png)
[![Polygonal conic gradient mosaic image with shape of regular polygon](conic_gradient/regular_polygon_7.png)](conic_gradient/regular_polygon_7.png)
[![Polygonal conic gradient mosaic image with shape of regular polygon](conic_gradient/regular_polygon_8.png)](conic_gradient/regular_polygon_8.png)
[![Polygonal conic gradient mosaic image with shape of regular polygon](conic_gradient/regular_polygon_12.png)](conic_gradient/regular_polygon_12.png)
[![Polygonal conic gradient mosaic image with shape of regular polygon](conic_gradient/regular_polygon_13.png)](conic_gradient/regular_polygon_13.png)
[![Polygonal conic gradient mosaic image with shape of regular polygon](conic_gradient/regular_polygon_15.png)](conic_gradient/regular_polygon_15.png)
[![Polygonal conic gradient mosaic image with shape of regular polygon](conic_gradient/regular_polygon_16.png)](conic_gradient/regular_polygon_16.png)
[![Polygonal conic gradient mosaic image with shape of regular polygon](conic_gradient/regular_polygon_23.png)](conic_gradient/regular_polygon_23.png)
[![Polygonal conic gradient mosaic image with shape of regular polygon](conic_gradient/regular_polygon_24.png)](conic_gradient/regular_polygon_24.png)

### With shape of polygonal star

Shape of mosaic used to generate images in this section is based on polygonal star.
See `starry_mosaic::mosaic_shape::PolygonalStar` for more details.

[![Polygonal conic gradient mosaic image with shape of polygonal star](conic_gradient/polygonal_star_5.png)](conic_gradient/polygonal_star_5.png)
[![Polygonal conic gradient mosaic image with shape of polygonal star](conic_gradient/polygonal_star_6.png)](conic_gradient/polygonal_star_6.png)
[![Polygonal conic gradient mosaic image with shape of polygonal star](conic_gradient/polygonal_star_7.png)](conic_gradient/polygonal_star_7.png)
[![Polygonal conic gradient mosaic image with shape of polygonal star](conic_gradient/polygonal_star_8.png)](conic_gradient/polygonal_star_8.png)
[![Polygonal conic gradient mosaic image with shape of polygonal star](conic_gradient/polygonal_star_12.png)](conic_gradient/polygonal_star_12.png)
[![Polygonal conic gradient mosaic image with shape of polygonal star](conic_gradient/polygonal_star_13.png)](conic_gradient/polygonal_star_13.png)
[![Polygonal conic gradient mosaic image with shape of polygonal star](conic_gradient/polygonal_star_15.png)](conic_gradient/polygonal_star_15.png)
[![Polygonal conic gradient mosaic image with shape of polygonal star](conic_gradient/polygonal_star_16.png)](conic_gradient/polygonal_star_16.png)
[![Polygonal conic gradient mosaic image with shape of polygonal star](conic_gradient/polygonal_star_23.png)](conic_gradient/polygonal_star_23.png)
[![Polygonal conic gradient mosaic image with shape of polygonal star](conic_gradient/polygonal_star_24.png)](conic_gradient/polygonal_star_24.png)
Loading

0 comments on commit 1f53562

Please sign in to comment.