A simple way to edit images #7
|
|
@ -6,7 +6,6 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"image"
|
"image"
|
||||||
"image/color"
|
"image/color"
|
||||||
"log"
|
|
||||||
"os"
|
"os"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
|
|
||||||
|
|
@ -80,8 +79,6 @@ func (s *Service) reprocess(ctx context.Context, session *models.ImageEditSessio
|
||||||
img = imageImageSource{resImg}
|
img = imageImageSource{resImg}
|
||||||
}
|
}
|
||||||
|
|
||||||
log.Printf("result of processed image: %T", img)
|
|
||||||
|
|
||||||
return img, nil
|
return img, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -105,10 +102,6 @@ func (s *Service) processImage(ctx context.Context, srcImg image.Image, processo
|
||||||
defer f.Close()
|
defer f.Close()
|
||||||
|
|
||||||
return imaging.Decode(f)
|
return imaging.Decode(f)
|
||||||
//case "shadow":
|
|
||||||
// shadow := makeBoxShadow(srcImg, color.Black, 4, 10, 0)
|
|
||||||
// composit := imaging.OverlayCenter(shadow, srcImg, 1.0)
|
|
||||||
// return composit, nil
|
|
||||||
}
|
}
|
||||||
|
|
||||||
proc, ok := processors[processor.Type]
|
proc, ok := processors[processor.Type]
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue