You can tell LilyPond not to use black note heads
(credit Bertrand Bordage):
But in the example given there are some black noteheads as well. I think the best solution would be to just override the notehead:
whiteHeadOn = {
\override NoteHead #'stencil = #ly:text-interface::print
\override NoteHead #'text = #(markup #:musicglyph "noteheads.s1" ) }
whiteHeadOff = {
\revert NoteHead #'stencil
\revert NoteHead #'text
}
\relative c'' {
c4 d \whiteHeadOn e8 f g a | \whiteHeadOff b c b a g4 f
}