Current Server Time: 14:00 (Central Europe)

#apertus IRC Channel Logs

2020/02/28

Timezone: UTC


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