Skip to content

Commit

Permalink
Fix: paste image get blank image issue (windows)
Browse files Browse the repository at this point in the history
  • Loading branch information
mazhibin committed Jan 23, 2019
1 parent 62661f8 commit 19e5ff5
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Change Log

## 1.0.4 (January 23, 2018)

- Fix: paste image get blank image issue (windows)

## 1.0.3 (November 28, 2018)

- Fix: paste translucent image get background issue (windows)
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "vscode-paste-image",
"displayName": "Paste Image",
"description": "paste image from clipboard directly",
"version": "1.0.3",
"version": "1.0.4",
"publisher": "mushan",
"author": {
"name": "mushan",
Expand Down
2 changes: 1 addition & 1 deletion res/pc.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ if (-not $imagePath) {
Exit 1
}

$fcb = new-object Windows.Media.Imaging.FormatConvertedBitmap($img, [Windows.Media.PixelFormats]::Rgba64, $null, 0)
$fcb = new-object Windows.Media.Imaging.FormatConvertedBitmap($img, [Windows.Media.PixelFormats]::Rgb24, $null, 0)
$stream = [IO.File]::Open($imagePath, "OpenOrCreate")
$encoder = New-Object Windows.Media.Imaging.PngBitmapEncoder
$encoder.Frames.Add([Windows.Media.Imaging.BitmapFrame]::Create($fcb)) | out-null
Expand Down

0 comments on commit 19e5ff5

Please sign in to comment.