View Single Post
Old 16 December 2019, 16:58   #7
chb
Registered User

 
Join Date: Dec 2014
Location: germany
Posts: 250
WARNING, NOT TESTED
Maybe you could left-shift your source by one pixel, then use exclusive fill with FCI set to 1:
Code:
00100
00010
00001
00000
00000

Shift:
01000
00100
00010
00000
00000
(set mask registers accordingly)
Now you need the ones at the beginning of the empty lines, which is a bit tricky, as you have shifted your source. One way to tackle that could be to use a second, non-shifted (empty) source buffer where you put the ones and use an OR-minterm (that gives you unfortunately a slightly slower blitt and needs additional memory):
Code:
Shifted buffer:
01000
00100
00010
00000
00000

non-shifted ones buffer:
00000
00000
00000
00001
00001

ORed together:
01000
00100
00010
00001
00001

Exclusive fill with FCI set:
00111
00011
00001
00000
00000
I think there shouldn't be any problems with pixels on the very left, because they would result in completely filled lines, and that's what is supposed to happen. But as said, nothing tested, I may be completely wrong.
chb is offline  
 
Page generated in 0.04242 seconds with 11 queries