Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Recent Posts
42
3rd Party Plugins - (fb2k) / Re: foo_vis_text (Text Visualizer)
Last post by pqyt -
I haven't even begun to look at the colors in CUI yet. That API is so brutally broken and incomplete it is no fun to develop against. It's beyond me how it became so popular.
Well, it's old, and the person who created it wasn't even an adult when the first version was released. Largely the API is stuck as it is for compatibility reasons, but requests and suggestions are always welcome.

Dark mode is documented here: https://columns-ui-sdk.readthedocs.io/en/latest/dark-mode.html
@musicmusic , thx but that's not the problem. I already wrestled with it for foo_vis_spectrum_analyzer, including the colors. It's just overall weird. The fb2k api is not easy but it's more consistent.

But let's stick to the topic. We're boring the people looking for information on foo_vis_text.
43
3rd Party Plugins - (fb2k) / Re: foo_vis_text (Text Visualizer)
Last post by musicmusic -
I haven't even begun to look at the colors in CUI yet. That API is so brutally broken and incomplete it is no fun to develop against. It's beyond me how it became so popular.
Well, it's old, and the person who created it wasn't even an adult when the first version was released. Largely the API is stuck as it is for compatibility reasons, but requests and suggestions are always welcome.

Dark mode is also documented here: https://columns-ui-sdk.readthedocs.io/en/latest/dark-mode.html
44
3rd Party Plugins - (fb2k) / Re: foo_vis_text (Text Visualizer)
Last post by pqyt -
You have to be monumentally stupid to have a problem with the Columns UI api for retrieving colours.

Code: [Select]
//Default UI requires a GUID.
const COLORREF colour = m_callback->query_std_color(GUID);

//Columns UI requires an enum value
const COLORREF colour = cui::colours::helper().get_colour(ENUM_VALUE);

edit: added links...

DUI GUIDs
https://github.com/marc2k3/foobar2000-sdk/blob/7f047cf2e541dd2f756c023195ef95285947d201/foobar2000/SDK/ui_element.h#L84-L87

CUI enum
https://github.com/reupen/columns_ui-sdk/blob/164ab473464aaf2626544c9ee1dbb548a39282e5/columns_ui_appearance.h#L7-L13
Did you just call me stupid? Gotta work on your people skills, @marc2k3 , especially since you missed the point, again.
46
3rd Party Plugins - (fb2k) / Re: foo_vis_text (Text Visualizer)
Last post by marc2k3 -
You have to be monumentally stupid to have a problem with the Columns UI api for retrieving colours.

Code: [Select]
//Default UI requires a GUID.
const COLORREF colour = m_callback->query_std_color(GUID);

//Columns UI requires an enum value
const COLORREF colour = cui::colours::helper().get_colour(ENUM_VALUE);

edit: added links...

DUI GUIDs
https://github.com/marc2k3/foobar2000-sdk/blob/7f047cf2e541dd2f756c023195ef95285947d201/foobar2000/SDK/ui_element.h#L84-L87

CUI enum
https://github.com/reupen/columns_ui-sdk/blob/164ab473464aaf2626544c9ee1dbb548a39282e5/columns_ui_appearance.h#L7-L13


47
3rd Party Plugins - (fb2k) / Re: foo_vis_text (Text Visualizer)
Last post by Julero -
Another pqyt issue, this one is a bit silly, but when I change the Columns UI theme (I have it to do it dynamically when it detects a change in window size) the space where the plugin is stays blank for a couple of seconds and it looks kind of ugly. . How could I modify the color to make it a different color?
I haven't even begun to look at the colors in CUI yet. That API is so brutally broken and incomplete it is no fun to develop against. It's beyond me how it became so popular.

I think you found something that Foobar was really missing. That's why the commotion. :))

Foobar is a player that is certainly famous for being able to make quite nice layouts, in addition to hundreds of plugins for audio. But in FB the customization and design of the player interface is one of its strong points.

In your case you have found something that was missing like eating. Embed a browser (or small browser windows) within the interface itself, and with this you have opened Pandora's box for the immense range that this plugin can provide. Hundreds of animations, tools, vu meter

And how easy it is to share the designs, since they are simple html (or html, css, and JS) files.

Don't be discouraged, if the way it is it's already great. With two or three more nonsense or small adjustments it would be completely finished.
48
3rd Party Plugins - (fb2k) / Re: JScript Panel script discussion/help
Last post by magnumforce2006 -
@marc2k3 you asked to please use this thread for requests, so here goes. Could I have something like the following image added to your "Track Info + Spectrogram Seekbar + Buttons" script? I'll also post the current settings I am using below:



Code: [Select]
// ==PREPROCESSOR==
// @name "Track Info + Spectrogram Seekbar + Buttons"
// @author "marc2003"
// @import "%fb2k_component_path%helpers.txt"
// @import "%fb2k_component_path%samples\js\lodash.min.js"
// @import "%fb2k_component_path%samples\js\common.js"
// @import "%fb2k_component_path%samples\js\panel.js"
// @import "%fb2k_component_path%samples\js\seekbar.js"
// ==/PREPROCESSOR==

/*
Most samples already require FontAwesome and it's used for the default buttons.
https://github.com/FortAwesome/Font-Awesome/blob/4.x/fonts/fontawesome-webfont.ttf?raw=true

The Segoe Fluent Icons font is already included with Windows 11. Windows 10 users can download it here:
https://download.microsoft.com/download/8/f/c/8fc7cbc3-177e-4a22-af48-2a85e1c5bffb/Segoe-Fluent-Icons.zip

If installed, you can right click the panel and change the button set.

---

Full ffmpeg setup instructions here: https://jscript-panel.github.io/gallery/spectrogram-seekbar/

If you edit the ffmeg_exe variable, directory separators must be escaped like "D:\\Audio\\Tools\\ffmpeg.exe"
If you edit the spectrogram_cache variable, you must make sure the folder already exists.
*/

var ffmpeg_exe = fb.ProfilePath + 'ffmpeg.exe';
var spectrogram_cache = folders.data + 'spectrogram_cache\\';

var colours = {
buttons : RGB(8, 255, 255),
background : RGB(30, 30, 30),
title : RGB(8, 255, 255),
artist : RGB(240, 240, 240),
time : RGB(240, 240, 240),
sac : RGB(196, 30, 35),
};

var tfo = {
artist : fb.TitleFormat('%artist%'),
title : fb.TitleFormat('%tracknumber% / %totaltracks% - %title%'),
playback_time : fb.TitleFormat('[%playback_time%]'),
length : fb.TitleFormat(' %length%  $ifequal(%LASTFM_LOVED_DB%,1,❤️,)' ),
};

//////////////////////////////////////////////////////////////

var panel = new _panel();
var seekbar = new _seekbar(0, 0, 0, 0, true);
var buttons = new _buttons();
var button_set_idx = 0;
var fluent_font = 'Segoe Fluent Icons';
var has_font = utils.CheckFont(fluent_font);
var bs = _scale(24);

var normal_font = CreateFontString('Segoe UI', 12);
var bold_font = CreateFontString('Segoe UI', 12, true);

window.MaxHeight = _scale(150);

var char_set = [chars, fluent_chars];

if (has_font) {
button_set_idx = window.GetProperty('2K3.BUTTON.SET', 0);
}

if (fb.IsPlaying) on_playback_new_track(fb.GetNowPlaying());
else on_item_focus_change();

buttons.update = function () {
var y = Math.round((panel.h - bs) / 2);
this.buttons.stop = new _button(panel.w - LM - (bs * 8), y, bs, bs, { char : char_set[button_set_idx].stop, colour:fb.StopAfterCurrent ? colours.sac : colours.buttons}, null, function () { fb.Stop(); }, 'Stop');
this.buttons.previous = new _button(panel.w - LM - (bs * 7), y, bs, bs, { char : char_set[button_set_idx].prev, colour:colours.buttons }, null, function () { fb.Prev(); }, 'Previous');
this.buttons.play = new _button(panel.w - LM - (bs * 6), y, bs, bs, { char : !fb.IsPlaying || fb.IsPaused ? char_set[button_set_idx].play : char_set[button_set_idx].pause, colour:colours.buttons}, null, function () { fb.PlayOrPause(); }, !fb.IsPlaying || fb.IsPaused ? 'Play' : 'Pause');
this.buttons.next = new _button(panel.w - LM - (bs * 5), y, bs, bs, { char : char_set[button_set_idx].next, colour:colours.buttons }, null, function () { fb.Next(); }, 'Next');
this.buttons.console = new _button(panel.w - LM - (bs * 3), y, bs, bs, {char : char_set[button_set_idx].console, colour:colours.buttons }, null, function () { fb.ShowConsole(); }, 'Console');
this.buttons.search = new _button(panel.w - LM - (bs * 2), y, bs, bs, { char : char_set[button_set_idx].search, colour:colours.buttons }, null, function () { fb.RunMainMenuCommand('Library/Search'); }, 'Library Search');
this.buttons.preferences = new _button(panel.w - LM - bs, y, bs, bs, { char : char_set[button_set_idx].preferences, colour:colours.buttons}, null, function () { fb.ShowPreferences(); }, 'Preferences');

if (button_set_idx == 1) {
this.change_font(fluent_font);
}
}

function on_item_focus_change() {
seekbar.item_focus_change();
}

function on_mouse_lbtn_down(x, y) {
seekbar.lbtn_down(x, y);
}

function on_mouse_lbtn_up(x, y) {
if (buttons.lbtn_up(x, y)) {
return;
}
if (seekbar.lbtn_up(x, y)) {
return;
}
fb.RunMainMenuCommand('View/Show now playing in playlist');
}

function on_mouse_leave() {
buttons.leave();
}

function on_mouse_move(x, y) {
if (buttons.move(x, y)) {
return;
}
seekbar.move(x, y);
}

function on_mouse_rbtn_up(x, y) {
if (seekbar.containsXY(x, y)) {
return panel.rbtn_up(x, y, seekbar);
}

if (buttons.buttons.stop.containsXY(x, y)) {
fb.StopAfterCurrent = !fb.StopAfterCurrent;
return true;
}

var menu = window.CreatePopupMenu();
var sub = window.CreatePopupMenu();
sub.AppendMenuItem(MF_STRING, 1, 'Original');
sub.AppendMenuItem(EnableMenuIf(has_font), 2, 'Fluent');
sub.CheckMenuRadioItem(1, 2, button_set_idx + 1);
sub.AppendTo(menu, MF_STRING, 'Buttons');
menu.AppendMenuSeparator();
menu.AppendMenuItem(MF_STRING, 3, 'Configure');

var idx = menu.TrackPopupMenu(x, y);
menu.Dispose();

switch (idx ) {
case 1:
case 2:
button_set_idx = idx - 1;
window.SetProperty('2K3.BUTTON.SET', button_set_idx);
buttons.update();
window.Repaint();
break;
case 3:
window.ShowConfigure();
break;
}

return true;
}

function on_mouse_wheel(s) {
if (seekbar.wheel(s)) {
return;
}
if (s == 1) {
fb.VolumeUp();
} else {
fb.VolumeDown();
}
}

function on_paint(gr) {
gr.Clear(colours.background);
gr.FillRectangle(seekbar.x, seekbar.y, seekbar.w, seekbar.h, colours.seekbar_background);
seekbar.paint(gr);
DrawRectangle(gr, seekbar.x, seekbar.y, seekbar.w, seekbar.h, seekbar.properties.marker_colour.value);
buttons.paint(gr);

if (fb.IsPlaying) {
gr.WriteText(tfo.title.Eval(), bold_font, colours.title, 10, 0, seekbar.x - _scale(60), panel.h * 0.6, DWRITE_TEXT_ALIGNMENT_LEADING, DWRITE_PARAGRAPH_ALIGNMENT_CENTER, DWRITE_WORD_WRAPPING_NO_WRAP, DWRITE_TRIMMING_GRANULARITY_CHARACTER);
gr.WriteText(tfo.artist.Eval(), normal_font, colours.artist, 10, panel.h * 0.3, seekbar.x - _scale(60), panel.h * 0.7, DWRITE_TEXT_ALIGNMENT_LEADING, DWRITE_PARAGRAPH_ALIGNMENT_CENTER, DWRITE_WORD_WRAPPING_NO_WRAP, DWRITE_TRIMMING_GRANULARITY_CHARACTER);
gr.WriteText(tfo.playback_time.Eval(), normal_font, colours.time, seekbar.x - _scale(66), 0, _scale(60), panel.h, DWRITE_TEXT_ALIGNMENT_TRAILING, DWRITE_PARAGRAPH_ALIGNMENT_CENTER);
gr.WriteText(tfo.length.Eval(), normal_font, colours.time, seekbar.x + seekbar.w + _scale(6), 0, _scale(60), panel.h, DWRITE_TEXT_ALIGNMENT_LEADING, DWRITE_PARAGRAPH_ALIGNMENT_CENTER);
}
}

function on_playback_dynamic_info_track(type) {
if (type == 0) window.Repaint();
}

function on_playback_edited() {
window.Repaint();
}

function on_playback_new_track(metadb) {
seekbar.playback_new_track(metadb);
}

function on_playback_pause() {
buttons.update();
window.Repaint();
}

function on_playback_seek() {
seekbar.playback_seek();
}

function on_playback_starting() {
buttons.update();
window.Repaint();
}

function on_playback_stop(reason) {
seekbar.playback_stop(reason);
buttons.update();
window.Repaint();
}

function on_playback_time() {
window.RepaintRect(panel.h, 0, seekbar.x - panel.h, panel.h);
}

function on_playlist_stop_after_current_changed() {
buttons.update();
window.Repaint();
}

function on_playlist_switch() {
seekbar.item_focus_change();
}

function on_run_cmd_async_done(task_id) {
seekbar.run_cmd_async_done(task_id);
}

function on_size() {
panel.size();
seekbar.x = _scale(300);
seekbar.y = _scale(5);
seekbar.w = panel.w - seekbar.x - _scale(280);
seekbar.h = panel.h - (seekbar.y * 2);
buttons.update();
}
49
3rd Party Plugins - (fb2k) / Re: foo_vis_text (Text Visualizer)
Last post by pqyt -
Another pqyt issue, this one is a bit silly, but when I change the Columns UI theme (I have it to do it dynamically when it detects a change in window size) the space where the plugin is stays blank for a couple of seconds and it looks kind of ugly. . How could I modify the color to make it a different color?
I haven't even begun to look at the colors in CUI yet. That API is so brutally broken and incomplete it is no fun to develop against. It's beyond me how it became so popular.
50
Support - (fb2k) / Re: Converter: Copy other files
Last post by vimage -
Sorry, one other question. When looking at the console log, it appears to log an error: "Copying: [invalid location]". Can this be ignored? I do not see any other errors and it reports success at the end. It is set to create multi-track files. This is the log:
Code: [Select]
Converting: "Redaction\01 Good Times.flac"
Copying: [invalid location]
Destination: "Redaction\1974 - Phoebe Snow\Phoebe Snow.png"
Destination: "Redaction\1974 - Phoebe Snow\Phoebe Snow.flac"
CLI encoder: flac.exe
Destination file: Redaction\1974 - Phoebe Snow\Phoebe Snow.flac
Encoder stream format: 44100Hz / 2ch / 16bps
Command line: flac.exe --force --silent --verify --no-seektable --no-padding --padding=2097152 -4 - -o "Phoebe Snow.flac"
Working folder: Redaction\1974 - Phoebe Snow\
Copied OK
Converting: "Redaction\02 Harpo's Blues.flac"
Converting: "Redaction\03 Poetry Man.flac"
Encoder process still running, waiting...
Encoder process terminated cleanly.
Track converted successfully.

Thank you.