Skip to content

Commit

Permalink
Update PixelCanvas.io API
Browse files Browse the repository at this point in the history
  • Loading branch information
Dadido3 committed Jul 7, 2019
1 parent d8a96e0 commit 59757e4
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions docs/pixelcanvas.io.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,9 +89,9 @@ Palette(15)\R = 130 : Palette(15)\G = 000 : Palette(15)\B = 128

- Download chunk collection (15x15 chunks):

- URL: `https://pixelcanvas.io/api/bigchunk/ccx.ccy.bmp`
- URL: `https://api.pixelcanvas.io/api/bigchunk/ccx.ccy.bmp`
With `ccx` and `ccy` being the offset of the chunk collection.
Example: `https://pixelcanvas.io/api/bigchunk/-10.5.bmp`
Example: `https://api.pixelcanvas.io/api/bigchunk/-10.5.bmp`
Make sure to disable any caching for this request.

- Result: Raw image data, 4 bit per pixel:
Expand Down
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ func init() {
log.Fatalf("Can't get working directory")
}

version, err = semver.NewVersion("0.1.2")
version, err = semver.NewVersion("0.1.3")
if err != nil {
fmt.Println(err.Error())
}
Expand Down
2 changes: 1 addition & 1 deletion pixelcanvas.io.go
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ func newPixelcanvasio() (connection, *canvas) {
startTime := time.Now()
log.Tracef("Download at %v started", cc)

r, err := myClient.Get(fmt.Sprintf("https://pixelcanvas.io/api/bigchunk/%v.%v.bmp", cc.X, cc.Y))
r, err := myClient.Get(fmt.Sprintf("https://api.pixelcanvas.io/api/bigchunk/%v.%v.bmp", cc.X, cc.Y))
if err != nil {
log.Errorf("Can't get bigchunk at %v: %v", cc, err)
return
Expand Down

0 comments on commit 59757e4

Please sign in to comment.