Einer der Besten von Xkcd aller Zeiten:

Fortunately, the charging one has been solved now that we’ve all standardized on mini-USB. Or is it micro-USB? Shit.

Leider ist der Eintrag nur auf Amerikanisches Englisch verfügbar. Der Inhalt wird unten in einer verfügbaren Sprache angezeigt. Klicken Sie auf den Link, um die aktuelle Sprache zu ändern.

After my apparently successful presentation at the VisGap 2020 workshop, collocated to the EuroVis/Eurographics 2020, in May, I was now invited to give a short Application Spotlight presentation and the IEEE VIS 2020. I am honored. And, I am looking forward to this opportunity.

Irgendwie konnte ich GetOpt noch nie leiden. GFlags überzeugt mich in einigen Aspekten auch nicht. Ist aber besser als selber irgendeinen CmdLine-Parser zusammenzustecken.

Ich habe mich bei dem Nuget-Paket auf die statische, thread-sicher Library beschränkt. Wenn ihr eine andere Variante braucht, dann könnt ihr natürlich gerne die AppVeyor-Artefakte herunterladen. Da sind praktisch alle dabei.

Wie üblich, Paket-Code ist frei: https://bitbucket.org/sgrottel_nuget/gflags_nuget

Die Community für native Libraries in Nugets scheint mir nicht sonderlich aktiv. Ich vermute die meisten Leute benutzen cmake, und müssen daher irgendeine zusätzliche Methode für die Paketverwaltung auf ihren Betriebssystemen nutzen, oder so. Wasweisich. Ich mag Nuget. Daher, ohne große Umschweife: hier ist mein neues Nuget-Paket für die LibYAML.

Und, wie üblich, der Paket-Code ist frei verfügbar: https://bitbucket.org/sgrottel_nuget/libyaml-nuget

Ich hatte eine schöne Gelegenheit mal wieder die akademische Welt heimzusuchen. Kollegen aus meiner alten Universitätszeit haben bei der diesjährigen großen Konferenz EGEV 2020 einen Workshop ausgerichtet, die  VisGap 2020 — The Gap between Visualization Research and Visualization Software (Die Lücke zwischen Visualisierungsforschung und (industrieller) Visualisierungssoftware). Und, sie hatten mich eingeladen eine Cap-Stone-Präsentation zu geben. Ich war sehr geehrt, und glücklicherweise hat auch meine Firma meiner Teilnahme zugestimmt.

In unserer augenblicklichen Situation mit COVID-19 fanden die Konferenz und die Workshops nicht wie geplant in Norrköping in Schweden statt. Stattdessen wurden die komplette Konferenz und alle Workshops in virtuelle Events umgewandelt. Als Ergebnis davon war die Teilnahme kostenlos. Und die Aufzeichnungen aller Sessions sind frei auf YouTube verfügbar. Wenn ihr also meinen Talk euch ansehen möchtet, dann seit gerne meine Gäste:

Leider ist der Eintrag nur auf Amerikanisches Englisch verfügbar. Der Inhalt wird unten in einer verfügbaren Sprache angezeigt. Klicken Sie auf den Link, um die aktuelle Sprache zu ändern.

Yes, I am still using AntTweakBar. As you might know, the development of AntTweakBar is discontinued. At some point in the future, I will switch. Currently, I consider imgui the best successor. But I haven’t had time to look into imgui. So, when I resurrected an old small tool of mine, it still used ATB, and I did not want to recode all of this. But out of „because-I-can,“ I decided  to update all dependencies to their newest versions. As a result the ATB integration with GLFW 3 did not work any longer. A couple of callback functions where changed between GLFW 2 and GLFW 3. I ended up rewriting my glue code between those two libraries.

Here it is, if any of you ever come across the same issue. First the callbacks:

static void keyCallback(GLFWwindow* window, int key, int scancode, int action, int mods)
{
#ifdef HAS_ANTTWEAK_BAR
  if (action == GLFW_PRESS || action == GLFW_REPEAT)
  {
    int twMod = 0;
    bool ctrl;
    if (mods & GLFW_MOD_SHIFT) twMod |= TW_KMOD_SHIFT;
    if (ctrl = (mods & GLFW_MOD_CONTROL)) twMod |= TW_KMOD_CTRL;
    if (mods & GLFW_MOD_ALT) twMod |= TW_KMOD_ALT;

    int twKey = 0;
    switch (key)
    {
    case GLFW_KEY_BACKSPACE: twKey = TW_KEY_BACKSPACE; break;
    case GLFW_KEY_TAB: twKey = TW_KEY_TAB; break;
    //case GLFW_KEY_???: twKey = TW_KEY_CLEAR; break;
    case GLFW_KEY_ENTER: twKey = TW_KEY_RETURN; break;
    case GLFW_KEY_PAUSE: twKey = TW_KEY_PAUSE; break;
    case GLFW_KEY_ESCAPE: twKey = TW_KEY_ESCAPE; break;
    case GLFW_KEY_SPACE: twKey = TW_KEY_SPACE; break;
    case GLFW_KEY_DELETE: twKey = TW_KEY_DELETE; break;
    case GLFW_KEY_UP: twKey = TW_KEY_UP; break;
    case GLFW_KEY_DOWN: twKey = TW_KEY_DOWN; break;
    case GLFW_KEY_RIGHT: twKey = TW_KEY_RIGHT; break;
    case GLFW_KEY_LEFT: twKey = TW_KEY_LEFT; break;
    case GLFW_KEY_INSERT: twKey = TW_KEY_INSERT; break;
    case GLFW_KEY_HOME: twKey = TW_KEY_HOME; break;
    case GLFW_KEY_END: twKey = TW_KEY_END; break;
    case GLFW_KEY_PAGE_UP: twKey = TW_KEY_PAGE_UP; break;
    case GLFW_KEY_PAGE_DOWN: twKey = TW_KEY_PAGE_DOWN; break;
    case GLFW_KEY_F1: twKey = TW_KEY_F1; break;
    case GLFW_KEY_F2: twKey = TW_KEY_F2; break;
    case GLFW_KEY_F3: twKey = TW_KEY_F3; break;
    case GLFW_KEY_F4: twKey = TW_KEY_F4; break;
    case GLFW_KEY_F5: twKey = TW_KEY_F5; break;
    case GLFW_KEY_F6: twKey = TW_KEY_F6; break;
    case GLFW_KEY_F7: twKey = TW_KEY_F7; break;
    case GLFW_KEY_F8: twKey = TW_KEY_F8; break;
    case GLFW_KEY_F9: twKey = TW_KEY_F9; break;
    case GLFW_KEY_F10: twKey = TW_KEY_F10; break;
    case GLFW_KEY_F11: twKey = TW_KEY_F11; break;
    case GLFW_KEY_F12: twKey = TW_KEY_F12; break;
    case GLFW_KEY_F13: twKey = TW_KEY_F13; break;
    case GLFW_KEY_F14: twKey = TW_KEY_F14; break;
    case GLFW_KEY_F15: twKey = TW_KEY_F15; break;
    }
    if (twKey == 0 && ctrl && key < 128)
    {
      twKey = key;
    }
    if (twKey != 0)
    {
      if (::TwKeyPressed(twKey, twMod)) return;
    }
  }
#endif
}

static void charCallback(GLFWwindow* window, unsigned int key)
{
#ifdef HAS_ANTTWEAK_BAR
  if (::TwKeyPressed(key, 0)) return;
#endif
}

static void mousebuttonCallback(GLFWwindow* window, int button, int action, int mods)
{
#ifdef HAS_ANTTWEAK_BAR
  if (::TwEventMouseButtonGLFW(button, action)) return;
#endif
}

static void mousePosCallback(GLFWwindow* window, double xpos, double ypos)
{
#ifdef HAS_ANTTWEAK_BAR
  if (::TwEventMousePosGLFW((int)xpos, (int)ypos)) return;
#endif
}

static void mouseScrollCallback(GLFWwindow* window, double xoffset, double yoffset)
{
#ifdef HAS_ANTTWEAK_BAR
  static double pos = 0;
  pos += yoffset;
  if (::TwEventMouseWheelGLFW((int)pos)) return;
#endif
}

static void resizeCallback(GLFWwindow* window, int width, int height)
{
#ifdef HAS_ANTTWEAK_BAR
  ::TwWindowSize(width, height);
#endif
}

Of course, you can omit the #ifdefs if you don’t care. Add your own codes to the functions after ATB has been handled.

Then, it’s just your typical initialization of GLFW callbacks:

::glfwSetKeyCallback(window, keyCallback);
::glfwSetCharCallback(window, charCallback);
::glfwSetMouseButtonCallback(window, mousebuttonCallback);
::glfwSetCursorPosCallback(window, mousePosCallback);
::glfwSetScrollCallback(window, mouseScrollCallback);
::glfwSetWindowSizeCallback(window, resizeCallback);

Even the powerful, tart Granny Smith cultivar is proving ineffective against new Gran-negative doctors.

Ja, albern. Aber ich hab so gelacht. Tatsächlich, während ich diesen Post hier schreibe und den Strip wieder lesen … ich kicher die ganze Zeit. Bescheuert. Und gleichzeitig vielleicht eine der bösesten Satiere seit langem.