0
我想通過透明背景實現線條圖,但到目前爲止,我只能將背景設置爲特定的顏色。既然是PNG,那麼應該是。jpGraph中的透明背景
$linePlot = new LinePlot($plotData);
$linePlot->SetFillColor('#[email protected]');
$graph = new Graph(300, 100);
$graph->SetScale('intint');
$graph->SetAlphaBlending();
$graph->SetMarginColor('black:1');
$graph->SetFrame(true,'black', 0);
$graph->Add($linePlot);
$graph->Stroke();
結果
不是透明的,但黑色
這就是我在搜索時已經查找的內容。它不呈現透明圖像。 – bytecode77
您是否可以將其更改爲紅色或其他顏色而不是黑色? –
是的,任何其他顏色,但沒有透明度。 – bytecode77