SetAlphaChannel[color]
color に完全な不透明度を加える.
SetAlphaChannel[color,a]
color に不透明度を a を加える.
SetAlphaChannel[image,…]
image にアルファチャンネルを加える.
SetAlphaChannel[video,…]
video のフレームにアルファチャンネルを加える.
SetAlphaChannel
SetAlphaChannel[color]
color に完全な不透明度を加える.
SetAlphaChannel[color,a]
color に不透明度を a を加える.
SetAlphaChannel[image,…]
image にアルファチャンネルを加える.
SetAlphaChannel[video,…]
video のフレームにアルファチャンネルを加える.
詳細
- SetAlphaChannelは,全画素に固定の不透明度を使うか全画素に不透明度を含む画像を使うかして,アルファチャンネルがある画像を返す.アルファチャンネルは,主に関心領域のハイライトまたは画像のマスキングに使われる.
- SetAlphaChannel[image]はSetAlphaChannel[image,1]に等しい.
- SetAlphaChannel[image,a]の a はスカラー値または image と次元が等しい画像でよい.
- 色または画像に不透明度を設定するときは,既存の不透明度特性は無視される.
- SetAlphaChannelは任意の有効な色指示子および有効な色空間の2Dまたは3Dの画像でよい.つまり,ColorSpaceオプションの任意の設定値(Automatic以外)でよい.
例題
すべて開く すべて閉じる例 (2)
スコープ (8)
SetAlphaChannel[[image]]ImageChannels[%]SetAlphaChannel[[image], 0.5]SetAlphaChannel[[image], [image]]SetAlphaChannel[[image], [image]]SetAlphaChannel[[image], [image]]グラフィックスオブジェクトを使ってアルファチャンネルを指定する:
SetAlphaChannel[[image], Graphics[{Gray, Disk[]}]]SetAlphaChannel[[image], [image]]out = SetAlphaChannel[Video["ExampleData/fish.mp4"], [image]];
VideoExtractFrames[out, .1]アプリケーション (4)
i = [image];
bg = Binarize[i, .05]SetAlphaChannel[i, bg]i = [image];SetAlphaChannel[i, ChanVeseBinarize[i, "TargetColor" -> Blue]]i = [image];b = DeleteBorderComponents[Binarize[i, {0, .8}]]foreground = FillingTransform@SelectComponents[b, #Holes == 1&]SetAlphaChannel[i, foreground + .2]RGB画像のアルファチャンネルをそのブルーチャンネルのネガになるように設定する:
i = [image];SetAlphaChannel[i, ColorNegate[Last[ColorSeparate[i]]]]特性と関係 (1)
インタラクティブな例題 (1)
DynamicModule[{pt = {61, 61}},
LocatorPane[Dynamic[pt],
Dynamic@SetAlphaChannel[[image], Image[Graphics[{GrayLevel[1], Rectangle[Floor[pt - 30], Floor[pt] + 30]}, PlotRange -> {{1, 120}, {1, 120}}, Background -> GrayLevel[0.3]], ImageSize -> {120, 120}]], {{30, 30}, {90, 90}}]]関連するガイド
-
▪
- 色の処理 ▪
- 基本的な画像の操作 ▪
- 画像計算機能の更新履歴 ▪
- 色 ▪
- 画像の処理と解析 ▪
- 動画計算機能の更新履歴
テキスト
Wolfram Research (2010), SetAlphaChannel, Wolfram言語関数, https://reference.wolfram.com/language/ref/SetAlphaChannel.html (2022年に更新).
CMS
Wolfram Language. 2010. "SetAlphaChannel." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2022. https://reference.wolfram.com/language/ref/SetAlphaChannel.html.
APA
Wolfram Language. (2010). SetAlphaChannel. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/SetAlphaChannel.html
BibTeX
@misc{reference.wolfram_2026_setalphachannel, author="Wolfram Research", title="{SetAlphaChannel}", year="2022", howpublished="\url{https://reference.wolfram.com/language/ref/SetAlphaChannel.html}", note=[Accessed: 03-November-2026]}
BibLaTeX
@online{reference.wolfram_2026_setalphachannel, organization={Wolfram Research}, title={SetAlphaChannel}, year={2022}, url={https://reference.wolfram.com/language/ref/SetAlphaChannel.html}, note=[Accessed: 03-November-2026]}