FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
gnuplot/demo/argb_hexdata.dem at master · gnuplot/gnuplot · GitHub
gnuplot
gnuplot
Repository navigation
Code
Pull requests
2
(2)
Actions
Security and quality
Insights
Expand file tree
Breadcrumbs
gnuplot
/
demo
/
argb_hexdata.dem
Copy path
More file actions
More file actions
Latest commit
History
History
History
27 lines (22 loc) · 787 Bytes
Breadcrumbs
gnuplot
/
demo
/
argb_hexdata.dem
Copy path
File metadata and controls
27 lines (22 loc) · 787 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#
# test unpacking of integer hex matrix data into an ARGB image
#
$BITS << EOB
0xafffffff 0x3fff0000 0x1f8833aa 0x00ffaa44
0xafff0000 0x3f8833aa 0x1fffaa44 0x00ffffff
0xaf8833aa 0x3fffaa44 0x1f00dddd 0xefffffff
0xafffaa44 0x3fff0000 0x1f8833aa 0x00bb0000
EOB
set pixmap 123 'gradient.png' at screen 0,0 size screen 1,1 behind
set tics 1
unset key
set xrange [-0.5:3.5]; set yrange [-1:3.5]
set title "Alpha+RGB image data loaded from a hexadecimal matrix"
plot 1+2*sin(x*x) lw 4 lc "black", $BITS matrix using 1:2:3 with rgbalpha pixels, \
$BITS matrix using 1:2:(sprintf("0x%08X",$3)) with labels center font ",12"
pause -1 "<cr> to continue"
set grid x y z vertical
set view 33, 46
splot $BITS matrix using 1:2:(1.0):3 with rgbalpha pixels
pause -1 "<cr> to continue"
reset
Back
|
FazBrowse Home
|
New Git URL