Skip to content

Commit

Permalink
set bitmap immutable
Browse files Browse the repository at this point in the history
  • Loading branch information
Brooooooklyn committed Aug 15, 2024
1 parent 2d9efd9 commit 8ca3a9e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions skia-c/skia_c.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1511,9 +1511,11 @@ extern "C"
canvas->setMatrix(matrix);
auto image = SkImages::RasterFromBitmap(*bitmap);
canvas->drawImage(image, 0, 0);
oriented_bitmap->setImmutable();
bitmap_info->bitmap = reinterpret_cast<skiac_bitmap *>(oriented_bitmap);
delete bitmap;
} else {
bitmap->setImmutable();
bitmap_info->bitmap = reinterpret_cast<skiac_bitmap *>(bitmap);
}
bitmap_info->width = width;
Expand Down

0 comments on commit 8ca3a9e

Please sign in to comment.