• Activity
  • Votes
  • Comments
  • New
  • All activity
    1. What programming/technical projects have you been working on?

      This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's...

      This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's interesting about it? Are you having trouble with anything?

      10 votes
    2. Is there an updated NixOS guide for first timers?

      I want to finally try NixOS and build a desktop OS from the ground up with sway, iwd, waybar, foot terminal, cmus, etc. I'm not a developer, but I'm a seasoned Linux user. Used Gentoo for years,...

      I want to finally try NixOS and build a desktop OS from the ground up with sway, iwd, waybar, foot terminal, cmus, etc.

      I'm not a developer, but I'm a seasoned Linux user. Used Gentoo for years, Void Linux and now I'm on OpenSUSE TW.

      I'm finding all sorts of guides and it seems confusing. In the past there wasn't any mention of home-manager and flakes, now it seems there are these things. Those are all things I need to care about? Is it all configured in one file?

      9 votes
    3. Fortnightly Programming Q&A Thread

      General Programming Q&A thread! Ask any questions about programming, answer the questions of other users, or post suggestions for future threads. Don't forget to format your code using the triple...

      General Programming Q&A thread! Ask any questions about programming, answer the questions of other users, or post suggestions for future threads.

      Don't forget to format your code using the triple backticks or tildes:

      Here is my schema:
      
      ```sql
      CREATE TABLE article_to_warehouse (
        article_id   INTEGER
      , warehouse_id INTEGER
      )
      ;
      ```
      
      How do I add a `UNIQUE` constraint?
      
      2 votes
    4. What programming/technical projects have you been working on?

      This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's...

      This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's interesting about it? Are you having trouble with anything?

      13 votes
    5. Help with finding out more about an obsure c++ graphics library

      I recently started classes again a little over a week ago. One of the classes I am taking is Computer science 2. One of the things it includes is openGL based graphics programming. They have us...

      I recently started classes again a little over a week ago. One of the classes I am taking is Computer science 2. One of the things it includes is openGL based graphics programming. They have us using glut, which is not bad in it self. However what they do is provide us a wrapper library for glut. In the form of a header named "graph1.h" and a precompiled library. Which goes by various names, such as "graphLib1.lib", "graphLib2010.lib", "graphLib2022.lib", "graphicLib2015.lib", etc. It's provided in the form of Windows flavored x86, Macos flavored x86_64 and arm. However, no forms for Linux. While I have been using Windows and VS Studio for classes so far, I strongly prefer my current Linux based tool chain. (text editor, build system, debugger). I have tried cross compiling with mingw-w64, but it fails when I try to link it. I would very much like to use it natively. To do this I would need either the library or the sources to compile it myself. That is what I would really like to find.

      Here is more about the library it self. It is based off of BMPLoader, a small library for loading bitmaps as openGL textures. It also inherits its license from BMPLoader too, because it is a derivative of BMPLoader. (GPLv2; and has been distributed). When you unpack the library there are 3 object files, BMPLoader.o, loadPNG.o, and example2.o. (.o/.obj) I have found traces of it online, however they all link back to my University, University of Central Arkansas. I have also found evidence of it being used at GSU too, but it is from one of the professors that is now here at UCA. (They even provided a pdf on using it, I hashed them and they were the same). Here is a copy of the header graph1.h.

      graph1.h
      /*BMPLoader - loads Microsoft .bmp format
          Copyright (C) 2006  Chris Backhouse
      
          This program is free software; you can redistribute it and/or modify
          it under the terms of the GNU General Public License as published by
          the Free Software Foundation; either version 2 of the License, or
          (at your option) any later version.
      
          This program is distributed in the hope that it will be useful,
          but WITHOUT ANY WARRANTY; without even the implied warranty of
          MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
          GNU General Public License for more details.
      
          You should have received a copy of the GNU General Public License along
          with this program; if not, write to the Free Software Foundation, Inc.,
          51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
      
      
        cjbackhouse@hotmail.com 		www.backhouse.tk
        
        I would appreciate it if anyone using this in something cool would tell me
        so I can see where it ends up.
      
        Takes a filename, returns an array of RGB pixel data
        Loads:
        24bit bitmaps
        256 colour bitmaps
        16 colour bitmaps
        2 colour bitmaps  (Thanks to Charles Rabier)
      
        This code is designed for use in openGL programs, so bitmaps not correctly padded will not
        load properly, I believe this only applies to: 
        256cols if width is not a multiple of 4
        16cols if width is not a multiple of 8
        2cols if width is not a multiple of 32
      
        Sample code:
      
      	BMPClass bmp;
      	BMPLoad(fname,bmp);
      	glTexImage2D(GL_TEXTURE_2D,0,3,bmp.width,bmp.height,0,GL_RGB,GL_UNSIGNED_BYTE,bmp.bytes);
      */
      #include <windows.h>
      #include <gl/glut.h>
      #include <iostream>
      #include <cstring>
      #include <string>
      #define endg "_endg_"
      
      
      #ifndef BMPLOADER_H
      #define BMPLOADER_H
      
      #include <iostream>
      #include <cstring>
      
      using namespace std;
      
      typedef unsigned char BYTE;
      
      class BMPClass
      {
      public:
      	BMPClass();
      	~BMPClass();
      	BYTE& pixel(int x,int y,int c);
      	void allocateMem();
      	int width,height;
      	BYTE* bytes;			//OpenGL formatted pixels
      };
      
      #define BMPError char
      #define BMPNOTABITMAP 'b'	//Possible error flags
      #define BMPNOOPEN 'o'
      #define BMPFILEERROR 'f'
      #define BMPBADINT 'i'
      #define BMPNOERROR '\0'
      #define BMPUNKNOWNFORMAT 'u'
      
      //Loads the bmp in fname, and puts the data in bmp
      BMPError BMPLoad(string fname,BMPClass& bmp);
      
      //Translates my error codes into English	
      std::string TranslateBMPError(BMPError err);	
      
      //Load and select in OpenGL
      BMPError BMPLoadGL(string fname);
      
      struct Precision
      {
        int precision;
        bool precisionFlag;
      };
      
      struct GraphColor
      {
        int r;
        int g;
        int b;
      };
      
      class Gout
      {
        private:
          int x;
          int y;
          int r;
          int g;
          int b;
          int precision;
          bool precisionFlag;
      
      
        public:
          Gout() { r= 0; g=255; b= 0; precisionFlag = false; };
          void setX(int x) { this->x = x;}
          void setY(int y) { this->y = y;}
          int getX() { return x;}
          int getY() { return y;}
          void setR(int r) {this->r = r;}
          void setG(int g) {this->g = g;}
          void setB(int b) {this->b = b;}
          int getR() {return r;}
          int getG() { return g;}
          int getB() {return b;}
          void setPrecisionFlag(bool flag) { precisionFlag = flag;}
          bool getPrecisionFlag() {return precisionFlag;}
          void setPrecision(int precision) {this->precision = precision;}
          int  getPrecision() {return precision;}
          friend Gout& operator<<(Gout& g, int int_val);
          friend Gout& operator<<(Gout& g, double int_val);
          friend Gout& operator<<(Gout& g, char* char_val);
          friend Gout& operator<<(Gout& g, string string_val);
         
      };
      
      extern Gout gout;
      
      struct Point
      {
        int x;
        int y;
      };
      
      
      
      struct GraphObject
      {
        char* str;
        int id;
        int no_points;
        Point* points;
        double* colors;
        int radius;
        int no_objects;
        BMPClass* bmp;
        int remove;
        int width;
        int height;
        int del;
        BYTE* bytes; //PNG BYTES
      };
      
      void reshape(int w, int h);
      void display(void);
      void init(char* title);
      int drawPoint(int x, int y);
      int drawCircle(int radius, int x, int y);
      void drawMyCircle( int Radius, int numPoints, int x, int y );
      int drawLine(int x1, int y1, int x2, int y2, int width);
      int drawRect(int x1, int y1, int width, int height);
      void displayGraphics();
      int displayBMP(char* fn,int x, int y);
      int displayBMP(string fn, int x, int y);
      int displayPNG(string fn, int x, int y);
      int displayPNG(char* fn, int x, int y);
      int displayText(char* str, int x, int y, int r, int g, int b);
      void clearGraphics();
      void setColor(int obj_no, int r, int g, int b);
      GraphColor setColor(int r, int g, int b);
      void timerColor(int value);
      void moveObject(int obj_no, int x, int y);
      void processSpecialKeys(int key, int x, int y);
      DWORD WINAPI display1(LPVOID lpParam);
      void processMouse(int button, int state, int x, int y);
      void removeObject(int id);
      void clearText();
      void GRAPH_SS();
      bool up();
      bool down();
      bool left();
      bool right();
      bool leftMouse(int&x, int&y);
      bool rightMouse(int&x, int&y);
      bool middleMouse(int&x, int&y);
      Gout& operator<<(Gout& g, int int_val);
      Gout& operator<<(Gout& g, double int_val);
      Gout& operator<<(Gout& g, char* char_val);
      Gout& operator<<(Gout& g, char char_val);
      Gout& operator<<(Gout& g, Gout&(*pt2Func)(int x, int y));
      Gout& operator<<(Gout& g, Gout&(*pt2Func)(int r, int g, int b));
      Gout& operator<<(Gout& g, Point a);
      Gout& operator<<(Gout& g, GraphColor gc);
      Gout& operator<<(Gout& g, Precision p);
      Gout& operator<<(Gout& g, Gout&(*pt2Func)(int precision));
      Precision setPrecision(int precision);
      Point setPos(int x, int y);
      void getPos(int obj_no, Point points[], int& no_points);
      bool mouseDragged(int& x, int& y);
      void processMouseDragged(int x, int y);
      void replaceObject(int orig_obj, int new_obj);
      void closeGraphics();
      
      #endif
      

      Right now I am of the opinion that it is a in-house "hackjob". That is how it feels with the GPLed BMPLoader glued together with other graphics functions. In an attempt to not have to use new literature or new style libraries with the new ".net 2008" style ide, as they were likely transitioning out of a codewarrior environment, and before that a borland environment.

      So far, I have asked our computer science club about it. The main thing I was told was that the professor just wants us to use windows. That I can understand, but I still want to see how far I can go. I have also tried sending an email about it to the professor, but all I got sent was a link to the glut downloads. I did reply back asking about the graphlib sources too, but I haven't heard anything back yet. I don't want to push too hard, I still have a whole semester ahead of me. So now I am asking here on tildes. I understand if nothing can be found, but at least information and experiences can be collected.

      11 votes
    6. [SOLVED] Help needed with a uBlock Origin filter rule

      Hi With this LITE site ---> https://lite.duckduckgo.com/lite/ There isn't the Dark Theme that's available for original duckduckgo site. I found a "My filters" rule on the web. Add these two lines...

      Hi
      With this LITE site ---> https://lite.duckduckgo.com/lite/
      There isn't the Dark Theme that's available for original duckduckgo site.

      I found a "My filters" rule on the web.

      Add these two lines to My filters

      lite.duckduckgo.com##html:style(color: rgb(141, 141, 141) !important; background: none repeat scroll 0 0 rgb(48, 48, 48) !important; font-family: 'Helvetica Neue','Segoe UI', Arial, sans-serif;)

      lite.duckduckgo.com##a:style(color: rgb(201, 201, 201) !important;)

      When the rule is used the search homepage looks reasonable.
      And the search results...
      The black background is not very black, not as black as Tildes black theme.
      I can live with that.

      But the red text under each result is very muddy.
      Can that be improved?
      Make it brighter Crimson or even Orange would look better.

      11 votes
    7. What programming/technical projects have you been working on?

      This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's...

      This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's interesting about it? Are you having trouble with anything?

      13 votes
    8. What programming/technical projects have you been working on?

      This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's...

      This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's interesting about it? Are you having trouble with anything?

      50 votes
    9. What programming/technical projects have you been working on?

      This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's...

      This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's interesting about it? Are you having trouble with anything?

      18 votes
    10. What programming/technical projects have you been working on?

      This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's...

      This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's interesting about it? Are you having trouble with anything?

      20 votes
    11. Fortnightly Programming Q&A Thread

      General Programming Q&A thread! Ask any questions about programming, answer the questions of other users, or post suggestions for future threads. Don't forget to format your code using the triple...

      General Programming Q&A thread! Ask any questions about programming, answer the questions of other users, or post suggestions for future threads.

      Don't forget to format your code using the triple backticks or tildes:

      Here is my schema:
      
      ```sql
      CREATE TABLE article_to_warehouse (
        article_id   INTEGER
      , warehouse_id INTEGER
      )
      ;
      ```
      
      How do I add a `UNIQUE` constraint?
      
      4 votes
    12. What is your framework for back of the envelope/ MVP style software design?

      I suspect many don’t write anything down and do this largely by intuition/experience but I want to tease out some ideas. when it comes to describing and designing a system from a blank piece of...

      I suspect many don’t write anything down and do this largely by intuition/experience but I want to tease out some ideas.

      when it comes to describing and designing a system from a blank piece of paper, what are the parameters you think of?

      I’m thinking napkin sketch level of software design.

      So things like:
      Number of users, are they concurrent users, what load dimensions there are (disk IO, network IO etc.), target platform (everything is a web app these days), how do you design/visualise the data model?

      Any decisions or constraints that impact what and how you build a proof of concept / MVP? How do you document this? How do you test it against the finished software?

      7 votes
    13. Fortnightly Programming Q&A Thread

      General Programming Q&A thread! Ask any questions about programming, answer the questions of other users, or post suggestions for future threads. Don't forget to format your code using the triple...

      General Programming Q&A thread! Ask any questions about programming, answer the questions of other users, or post suggestions for future threads.

      Don't forget to format your code using the triple backticks or tildes:

      Here is my schema:
      
      ```sql
      CREATE TABLE article_to_warehouse (
        article_id   INTEGER
      , warehouse_id INTEGER
      )
      ;
      ```
      
      How do I add a `UNIQUE` constraint?
      
      2 votes
    14. What programming/technical projects have you been working on?

      This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's...

      This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's interesting about it? Are you having trouble with anything?

      20 votes
    15. App or workflow suggestion for viewing and selecting photos on PC

      As an amateur photographer, I'm looking for recommendations to improve my process for reviewing and selecting the best photos from my albums. Currently, it goes something like this: (after I copy...

      As an amateur photographer, I'm looking for recommendations to improve my process for reviewing and selecting the best photos from my albums.

      Currently, it goes something like this:

      • (after I copy the photos to my PC) I open the folder containing the album
      • I open the first photo and start looking at the pictures using the default photo viewing app
      • I note mentally, on paper, or in a digital notepad the names of the files that I like the most
      • manually select the files that I noted down

      My ideal workflow would be something like:

      • open the folder, open first photo, look through them all
      • each time I see a picture that I like, hit space or some other simple shortcut, which adds the picture to the current selection
      • after I am done viewing, I have all the files that I want already selected to do with as I please

      I have tried multiple apps over the years but I haven't come across anything that had something similar, or I was too stupid to figure out how to do it. The workflow I described is using windows/linux, on macOS it's even more cumbersome (since one needs to select all photos in a folder before previewing them).

      Do you have any recommendations for an app that has functionality like this, or if not, on how I can make my workflow better?

      Thanks

      5 votes
    16. Is there a userscript/stylesheet or browser plugin to hide the excerpts from news articles?

      I am not sure if there is a proper name for these—frequently, a news article will be broken up by large-type excerpts of one or two sentences from the very article I'm already reading. I find this...

      I am not sure if there is a proper name for these—frequently, a news article will be broken up by large-type excerpts of one or two sentences from the very article I'm already reading. I find this obnoxious. Has anybody made a tool to hide them?

      15 votes
    17. Tips for buying + reading ebooks that are synced without using kindle/play books?

      Hey! I’ve been trying lately to get rid of big platforms from my life. One part of it is that I usually buy ebooks/audiobooks from apple, Amazon or google, however I’m then also forced to use...

      Hey! I’ve been trying lately to get rid of big platforms from my life. One part of it is that I usually buy ebooks/audiobooks from apple, Amazon or google, however I’m then also forced to use their reading app, which is a vendor lock-in I’m not comfortable with.

      I know there are plenty of ebook readers out there, but I’m trying to find

      1. A store where I can buy ebooks that can be opened in a ebook reader of my choice.
      2. A way to then sync my progress between phone and laptop. I have nextcloud setup, so if I can make use of that then it’s perfect.

      Anyone here got any tips?

      22 votes
    18. How do I install MAME and then add a particular arcade video game to play?

      So... a friend did this for me a long time ago, but I've replaced my computer since then, and I don't know how to do it for myself. I know how to find the MAME executable. I don't know whether I...

      So... a friend did this for me a long time ago, but I've replaced my computer since then, and I don't know how to do it for myself.

      I know how to find the MAME executable. I don't know whether I need to download the .exe file or the .zip file, but I assume the .exe file is the better option.

      I know how to run an executable file, and I'm assuming it installs itself.

      I know how to find a copy of the antique video game I want.

      However...

      The .zip file I download for the game contains a lot of files with names like "a26-13.109" - and I don't know what I'm supposed to do with those, to get them inside the MAME and make the game playable.

      I'm running Windows 10 on a 64-bit operating system, if that's relevant.

      Is anyone feeling charitable and willing to help someone who's not computer literate to do this?

      12 votes
    19. Looking for recommendations on a portable, high performance laptop

      I used to work in IT but left the field in 2018, so I'm not as up to date as I used to be on things. I'm looking for a new laptop to use for work (primarily word processing and web browsing),...

      I used to work in IT but left the field in 2018, so I'm not as up to date as I used to be on things. I'm looking for a new laptop to use for work (primarily word processing and web browsing), ideally something portable with a good sized screen (larger than 13"). I've had a Dell G5 for the last five years because I thought I'd do more gaming on it when I bought it, but it's largely just been a heavy brick in my backpack on travel.

      Back in the mid 2010s, I recommended Lenovos to everyone who would listen, but I fell out of love with them toward the end of my IT career when the build quality seemed to be rapidly declining. I haven't really touched them recently, but my dad loves his Lenovo Ideapad Pro.

      Honestly, something similar to a Dell Latitude might be what I'm looking for, but I'm open to any recommendations. I need a responsive keyboard and clickable trackpad. Bonus points if there's somehow a laptop out there that has a nub!

      ETA: Not looking for a macbook -- will be running Windows!

      31 votes