Functions or no functions for preset bladestyles?

If my bladestyle is different for each font I’m using, is there any benefit to using the functions for the bladestyles over just pasting the styles into the preset area on Fett’s configuration helper? Will it save me any board space or is that only if I’m using a function for multiple different presets? Hopefully that’s not too confusing of a question.

I think you mean the “using” statements in the CONFIG_STYLES section, right?
It does not affect board space.
Even if some or all styles are the same.

1 Like

Yes, that’s what I meant, glad you understood lol. Ok, thanks.

I use them because they keep my configs clean and tidy. I have a “myfettstyles.h” file with all my style definitions, which I call in the presets. This is especially beneficial for my blades with independently controlled facings (KRv1, tritium, and zig-zag), multiple accent pixels, and crystal chambers.

Example:

> { "JUANSITH DEPA PROFFIE", "tracks/Depa Bilaba.wav",
>      StylePtr<ControlCanon1>("0,65535,65535"),  //cyan main blade side 1
>      StylePtr<Canon1>("0,65535,65535"),   //main blade side 2
>      StylePtr<AccentBatteryMeter>(), //batterymeter  (chassis sides)
>      StylePtr<CCBatteryHeartbeat>(),  //batterymeter (chassis pommel)
>      StylePtr<White>(), //BT630
>      "1depa\nbilaba"},

The copyright and comments for each style are stored in my style file–and not cluttering up my config, which makes it much easier to edit and maintain.

2 Likes

This is the way.

One more part–here’s how I call the style file:

#ifdef CONFIG_STYLES
   #include "../styles/myFETTStyles.h"
   #include "../styles/myFETTBatteryStyles.h"
#endif

This loads the styles when needed.

1 Like