mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-05-13 08:26:56 +00:00
...
This commit is contained in:
parent
a0f6152aee
commit
c48ed15007
1 changed files with 2 additions and 2 deletions
|
|
@ -17,9 +17,9 @@ var _ = fmt.Print
|
|||
|
||||
func encode_rgba(output io.Writer, img image.Image) (err error) {
|
||||
var final_img *image.NRGBA
|
||||
switch img.(type) {
|
||||
switch ti := img.(type) {
|
||||
case *image.NRGBA:
|
||||
final_img = img.(*image.NRGBA)
|
||||
final_img = ti
|
||||
default:
|
||||
b := img.Bounds()
|
||||
final_img = image.NewNRGBA(image.Rect(0, 0, b.Dx(), b.Dy()))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue