Current Server Time: 23:27 (Central Europe)

#apertus IRC Channel Logs

2020/02/28

Timezone: UTC


00:55
Bertl
off to bed now ... have a good one everyone!
00:55
Bertl
changed nick to: Bertl_zZ
02:47
futarisIRCcloud
joined the channel
06:07
BAndiT1983|away
changed nick to: BAndiT1983
06:08
BAndiT1983
metal_dent[m]: nice, but 1,9 for the small °, sounds like a lot, would've expected that the overall size of both images would be lower, as the area below ° would not be there, but will check later if i can replicate it
06:18
BAndiT1983
changed nick to: BAndiT1983|away
06:24
metal_dent[m]
BAndiT1983: okay. I'll also try to find some other way to reduce it further
06:47
Bertl_zZ
changed nick to: Bertl
06:47
Bertl
morning folks!
06:52
Bertl
metal_dent[m]: ignoring the grays, the orange ring is 14x14 pixel and the text fits into 214x64 so a black/white mask could be stored in 24 byte and 1712 bytes respectively without any compression
06:53
Bertl
actually 25 bytes :)
07:07
metal_dent[m]
Bertl: Hi, right now the ring is 8x7 and text is 124x39 but i've not added the black/white mask, I'll do that and check :)
07:16
Bertl
hmm, I was looking at the linked 320x240 image, you are probably using a different one ...
07:20
metal_dent[m]
yeah that was my original image but then I removed the extra spaces and sliced the image into two parts: ring and text
07:20
Bertl
but that shouldn't change the size of the features
07:21
Bertl
and checking with gimp, the orange ring gives 14x14 pixels
07:21
metal_dent[m]
ohh
07:21
Bertl
note thatn the image is not very suitable as a mask though, because it has alpha from antialiasing all over
07:22
Bertl
there should be an SVG/PDF version somewhere, which might be a better source to render without antialiasing
07:23
metal_dent[m]
so should i use the logo from this:
07:23
metal_dent[m]
https://www.apertus.org/logo
07:24
Bertl
note: this is just my input here, I'm not the maintainer for the task you're interested in
07:24
Bertl
https://github.com/apertus-open-source-cinema/apertus_multimedia/tree/master/apertus%C2%B0%20Corporate%20Identity/apertus%C2%B0%20Logo
07:25
Bertl
but as far as I know BAndiT1983, he doesn't have a problem with improvements :)
07:26
metal_dent[m]
okay then i'll use the logo from this :))
07:27
metal_dent[m]
one question: should i keep the ring orange as orange or convert to b/w ?
07:27
Bertl
you should be able to convert an SVG with imagemagick without antialiasing at a given resolution
07:27
Bertl
for the task it makes sense to separate the ring from the text and render both independent
07:28
Bertl
i.e. two b/w masks, one 'painted' in gray the other in orange
07:28
metal_dent[m]
okay, cool!
07:28
Bertl
you can also separate the parts in the SVG btw
07:29
Bertl
the colors make it easy to identify the parts there
07:29
Bertl
#c2bfbc = text, #f47248 = ring :)
07:29
metal_dent[m]
okay!
08:15
sebix
joined the channel
08:15
sebix
left the channel
08:15
sebix
joined the channel
08:24
aombk3
joined the channel
08:28
aombk2
left the channel
08:51
a13b
changed nick to: aleb
08:51
aleb
left the channel
08:51
aleb
joined the channel
09:04
Bertl
off for now ... bbl
09:04
Bertl
changed nick to: Bertl_oO
10:57
joe[m]
left the channel
10:58
hans[m]
left the channel
11:02
alexandros[m]
left the channel
11:06
toralf[m]
left the channel
11:06
mateo[m]
left the channel
11:06
pedro[m]
left the channel
11:06
WalterZimmermann
left the channel
11:06
aleksander[m]
left the channel
11:06
oscar[m]
left the channel
11:18
uberardy[m]
left the channel
14:08
illwieckz
left the channel
14:37
illwieckz
joined the channel
14:39
comradekingu
left the channel
14:47
comradekingu
joined the channel
16:14
gsalazar
joined the channel
16:39
sebix
left the channel
17:06
gsalazar
left the channel
17:38
shashwat
joined the channel
18:13
ashok_singh[m]
left the channel
18:13
RexOrMatrix[m]
left the channel
18:13
kunalghosh[m]
left the channel
18:13
aleb
left the channel
18:14
apurvanandan[m]
left the channel
18:14
BAndiT1983|away
changed nick to: BAndiT1983
18:20
shashwat
left the channel
18:27
BAndiT1983
Bertl_oO: thanks for support in the morning, have followed the logs, but not able to respond from work
18:28
ashok_singh[m]
joined the channel
18:29
Bertl_oO
BAndiT1983: you're welcome!
18:33
RexOrMatrix[m]
joined the channel
18:34
apurvanandan[m]
joined the channel
18:34
kunalghosh[m]
joined the channel
18:36
aleb
joined the channel
18:58
metal_dent[m]
> metal_dent: ignoring the grays, the orange ring is 14x14 pixel and the text fits into 214x64 so a black/white mask could be stored in 24 byte and 1712 bytes respectively without any compression
18:58
metal_dent[m]
Bertl : Hi sorry to bother 😅
18:58
metal_dent[m]
In this 1712 bytes = 214*64/8 so it means you're taking the bit depth as 1 ?
18:58
Bertl_oO
yes
18:59
Bertl_oO
for a b/w mask, 1 bit per pixel is enough
18:59
Bertl_oO
you might need a few more for alignment purposes, e.g. have a 16x14 mask instead of 14x14
19:00
metal_dent[m]
yes yes but in this image we want one colour for background and other (#c2bfbc) for the text, right?
19:01
Bertl_oO
does that make any difference?
19:01
Bertl_oO
(e.g. a '0' bit means background color and a '1' bit means foreground i.e. other color)
19:02
metal_dent[m]
yes i guess because if we'll put a black&white mask on it, it'll convert the text into white instead of gray
19:02
Bertl_oO
that is just a question how you interpret the mask
19:02
metal_dent[m]
> (e.g. a '0' bit means background color and a '1' bit means foreground i.e. other color)
19:02
metal_dent[m]
yes yes!!
19:02
Bertl_oO
you can assign almost arbitrary meanings to each bit in your paint routine
19:03
Bertl_oO
another option for example, would be: '0' do not paint anything, '1' paint with given color
19:03
Bertl_oO
(which is likely what you want when you add to an existing image)
19:03
metal_dent[m]
> you can assign almost arbitrary meanings to each bit in your paint routine
19:03
metal_dent[m]
yeah i was thinking of mapping the bits with the image colours in the draw function
19:08
BAndiT1983
it's not difficult, just bit shofting, more interesting part is to get the image into right format
19:09
BAndiT1983
0x00 would be 8 pixels of black and 0xFF will result in 8 white pixels
19:10
BAndiT1983
accordingly the bit patterns would represent different changes in the image
19:10
BAndiT1983
*shifting
19:11
metal_dent[m]
okay, i haven't properly implemented something like this but i'll look through some resources. Thank you!
19:12
BAndiT1983
ask questions, if something is not clear
19:13
metal_dent[m]
yes definitely, thanks again :)
19:14
BAndiT1983
no problem
20:34
metal_dent[m]
BAndiT1983: in ApertusLogo.h, how's the array size `uint8_t pixel_data[205 * 62 * 2 + 1];` calculated?
21:00
BAndiT1983
let me check
21:01
BAndiT1983
2 is for 2 bytes, as we use RGB565
21:01
BAndiT1983
have used online converter for the image to get the specific format
21:03
Bertl_oO
the +1 is definitely odd :)
21:03
metal_dent[m]
okay, so would it matter if for the new image array i change the format a bit?
21:03
BAndiT1983
it's only for enough space
21:03
Bertl_oO
hmm?
21:03
BAndiT1983
which format do you mean?
21:04
metal_dent[m]
> which format do you mean?
21:04
metal_dent[m]
.h file format
21:04
BAndiT1983
if you write the specs for it, then yes, but there are maybe already converters with general setup
21:04
metal_dent[m]
i converted the image into array using im
21:05
BAndiT1983
how does you array look like, could you pastebin it?
21:05
metal_dent[m]
sure!
21:08
BAndiT1983
but generally there is no real format required, only 2 variables for width and height and data array
21:08
BAndiT1983
you could also place width and height as first entries
21:08
metal_dent[m]
https://pastebin.com/y0g4Jjbu
21:09
metal_dent[m]
> https://pastebin.com/y0g4Jjbu
21:09
metal_dent[m]
this is only for the "Apertus" text not the ring
21:09
BAndiT1983
looks very similar to what i have also got
21:10
BAndiT1983
imagemagick doesn't add any size info like width and height
21:10
Bertl_oO
metal_dent[m]: pro-tipp, if you add /raw/, it is way simpler to digest, e.g. https://pastebin.com/raw/y0g4Jjbu
21:11
BAndiT1983
but it has GIF format at the top and it could be that there is compression involved, but we want to have uncompressed image
21:11
metal_dent[m]
> metal_dent: pro-tipp, if you add /raw/, it is way simpler to digest, e.g. https://pastebin.com/raw/y0g4Jjbu
21:11
metal_dent[m]
will keep in mind!
21:12
BAndiT1983
just compare this -> https://www.file-recovery.com/signatures/GIF.png
21:12
BAndiT1983
this is another decoder, but without array creation -> https://www.dcode.fr/binary-image
21:13
BAndiT1983
if oyu select reduced size, then it should become something we are targeting
21:13
metal_dent[m]
> this is another decoder, but without array creation -> https://www.dcode.fr/binary-image
21:13
metal_dent[m]
yes i saw this yesterday but doesn't convert into array
21:13
Bertl_oO
ImageMagick is a good and reproducible choice for the conversion
21:13
Bertl_oO
it is all a matter of getting the options right
21:14
BAndiT1983
data like this is the goal, but getting it into array is also important -> https://pastebin.com/raw/hrXyjSmc
21:15
BAndiT1983
even if it does not give an array, converting the output is rather simple
21:16
metal_dent[m]
> this is another decoder, but without array creation -> https://www.dcode.fr/binary-image
21:16
metal_dent[m]
so this is giving me the pixels in 0s and 1s
21:16
metal_dent[m]
I thought of reading my array by byte and then checking the bits in the function and deciding whether to paint or not
21:17
BAndiT1983
every 8 entries there are a byte, with a simple application, you could convert them to hex values and create an array
21:18
BAndiT1983
or maybe there are tools for it
21:18
Bertl_oO
please stick to ImageMagick :)
21:18
metal_dent[m]
but why convert in hexa when we need in binary for drawing? this will make it more simple i guess
21:19
Bertl_oO
wonders why everybody seems to favor gui tools even if they are twice the work ...
21:21
metal_dent[m]
> wonders why everybody seems to favor gui tools even if they are twice the work ...
21:21
metal_dent[m]
yes more work + gui tools sometimes add reduntant info or changes which increase the file size (i observed that in GIMP and Photoshop)
21:26
BAndiT1983
metal_dent[m]: hex values represent binary values, but in different format, you can also use decimal values, it doesn't matter much, what does matter is the storage of the pixels
21:26
BAndiT1983
don't know if imagemagick can convert to binary at all
21:27
Bertl_oO
convert apertus_logo.svg RGB:apertus_log.bin
21:27
BAndiT1983
and what about 1 and 0 binary?
21:27
Bertl_oO
that is not binary, that is ASCII
21:30
BAndiT1983
hope it can handle PBM -> https://en.wikipedia.org/wiki/Netpbm#File_formats
21:30
Bertl_oO
convert apertus_logo.svg pbm: | pnmnoraw
21:31
Bertl_oO
will give you ASCII 0/1 image
21:31
BAndiT1983
yep, at P1 format
21:32
BAndiT1983
SVG is ok, but to have the image already in right dimensions, it should be placed in empty 320x240 image and scaled to nice size first, then the image should be resized to content, GIMP supports this feature rather well
21:33
Bertl_oO
but that's the wrong way round
21:34
BAndiT1983
why?
21:34
Bertl_oO
SVG is vector graphics, so you do not want to convert it to bitmap and then scale
21:34
Bertl_oO
you want to first scale it, and then convert it to a bitmap
21:34
BAndiT1983
as far as i remember GIMP supports it, but it can also be done in inkscape
21:34
Bertl_oO
... or ImageMagick :)
21:35
BAndiT1983
in inkscape the advantage is, that it can directly export to PNG of certain size
21:35
BAndiT1983
you do it your way, but i prefer UI, as i need more overview, than just matrix style
21:36
Bertl_oO
and I presume you also build scripts to redo the process when something changes, right?
21:36
Bertl_oO
like for example Rex decides to pick a different font for the logo :)
21:37
BAndiT1983
it takes only few clicks to open the image in inkscape and export new version, then convert it to PBM
21:37
BAndiT1983
when the font changes, the image has to be placed properly on the display again, as kerning and whatnot changes with a new font
21:38
Bertl_oO
which would all be done with a proper script
21:38
Bertl_oO
and all you need to do is type 'make all'
21:39
Bertl_oO
but I know, GUI clicking is much more fun *G*
21:39
BAndiT1983
not placing, as the logo size can change or icon size, then it has to be placed manually first, according to padding, margin or other attributes
21:39
Bertl_oO
like for example centered on the screen with known resolution?
21:40
Bertl_oO
or maybe 25% below center line?
21:40
BAndiT1983
if the resolution is known, but when changes happen the resolution of the image needs probably adjustments
21:41
Bertl_oO
like?
21:42
BAndiT1983
if new font is introduced, new kerning is there, it's wider, so it needs new centering or it has to be more zoomed out or in
21:42
Bertl_oO
that's all something ImageMagick does for you
21:42
Bertl_oO
after all it knows all the sizes and how to scale/center stuff
21:45
Bertl_oO
for example:
21:45
Bertl_oO
convert apertus_logo.svg -scale 320x200 test.png
21:45
Bertl_oO
will give you an image which fits on 320x200 display
21:46
BAndiT1983
of course, imagemagick is helpful, no question, but when designing new dialogues we still need to create layouts in GIMP/Krita etc. and afterwards implement it in code
21:46
Bertl_oO
convert apertus_logo.svg -scale 320x200 -scale 75% test2.png
21:46
Bertl_oO
will scale it down to 75% on 320x200
21:46
Bertl_oO
now to get the real 320x200 image with centered text you do:
21:46
Bertl_oO
convert apertus_logo.svg -scale 320x200 -scale 75% -gravity center -extent 320x200 test3.png
21:47
Bertl_oO
but what if our display is actually 320x240 pixel?
21:47
Bertl_oO
quick just a few clicks with the GUI :)
21:47
Bertl_oO
convert apertus_logo.svg -scale 320x240 -scale 75% -gravity center -extent 320x240 test4.png
21:48
Bertl_oO
and most importantly, it doesn't really care about the apertus_logo.svg
21:48
Bertl_oO
change it, adjust it, it will still be fine afterwards
21:53
BAndiT1983
if the sizes and positions are known, then the build pipeline can create the images automatically, still it won't cancel out the manual work which is required for planning the screens and creating mock-ups to get the positions of elements, icons etc.
21:54
BAndiT1983
images should be 1:1 for the display, in other words no scaling will be done for painting, so it should already correspond to the required size on the display, icons on buttons are a bit easier to plan, as they should fit into the button and have some margin around, but logo consisting out of 2 parts requires additional planning
22:27
BAndiT1983
experimented a bit further, PBM P1 looks like what is required, but getting it into C array is not really possible or i lack the knowledge of imagemagick options
22:31
BAndiT1983
creating a tool to convert to C/C++ array from PBM P1 is very simple, but i won't give the details away yet
22:32
BAndiT1983
format description here -> http://netpbm.sourceforge.net/doc/pbm.html
22:36
metal_dent[m]
okay, i'll convert the image into PBM then into C array
22:37
BAndiT1983
will go off for today, but keep the questions coming ;)
22:37
BAndiT1983
good night
22:37
BAndiT1983
changed nick to: BAndiT1983|away
22:38
metal_dent[m]
yes, am also off to bed, will do this tomorrow. Good night!!
22:45
Bertl_oO
convert apertus_logo.svg -depth 1 MONO:- | xxd -i
22:49
Bertl_oO
convert apertus_logo.svg -define h:format=mono -depth 1 apertus_logo.h
22:55
Bertl_oO
convert apertus_logo.svg -define h:format=gray -monochrome -negate -depth 1 apertus_logo.h
23:17
sergio__[m]
joined the channel
23:39
metal_dent[m]
Bertl_oO : my image is already in monochromatic form (had used imagemagick ;) )
23:41
Bertl_oO
the idea is to have a simple and reproducible path from the 'original' to the C-header data
23:42
Bertl_oO
if you do that in several steps instead of one that is perfectly fine
23:42
Bertl_oO
just make sure to get the steps right :)
23:42
Bertl_oO
(and preferably have a makefile or script to reproduce them easily)
23:43
Bertl_oO
and back to bed now! :)
23:43
metal_dent[m]
> (and preferably have a makefile or script to reproduce them easily)
23:43
metal_dent[m]
You mean the whole conversion, right?
23:46
Bertl_oO
yes
23:48
Bertl_oO
off to bed now ... have a good one everyone!
23:48
sergio__[m]
hello guys!!, why are we using single frame buffer system? other than having no gpu is there any other reason?
23:48
Bertl_oO
changed nick to: Bertl_zZ
23:48
metal_dent[m]
Okay, will do that :)
23:48
sergio__[m]
and why is it mentioned in task to develop 2 bit depth array?I think creating 1 bit depth will be fine 1 for background other for displaying. is't it?
23:48
sergio__[m]
probably a bit late 😅
23:50
metal_dent[m]
@sergio__:matrix.org: you can look that the logs, Bertl and BAndiT1983 have explained that properly
23:50
metal_dent[m]
*at the
23:51
sergio__[m]
hey metal_dent about which part exactly?
23:51
metal_dent[m]
> and why is it mentioned in task to develop 2 bit depth array?I think creating 1 bit depth will be fine 1 for background other for displaying. is't it?
23:51
metal_dent[m]
This one
23:53
sergio__[m]
yes I read it and I think 1 bit depth will do fine!!! 🤔
23:54
sergio__[m]
left the channel
23:54
gsalazar
joined the channel