Noise Cancellation for Remote Communication

Noise Cancellation for Remote Communication

In the wake of the past few years, virtual meetings have changed the way we communicate. However, we have generally embraced remote communication without considering how remote communication differs from the in-person or phone communication we’ve traditionally used. While turning on cameras and speaking face to face gives us more connection, and embracing a slower and more formal discussion style can make the meeting more enjoyable, the most essential communication still happens through audio. As the audio quality we use…

Read More Read More

PreProcessor Overloading

PreProcessor Overloading

While it is simple to overload methods in C++, the preprocessor doesn’t work the same way. To define overloaded methods in the preprocessor, we need to define a method for each number of arguments we want to overload. Option 1: https://stackoverflow.com/questions/11761703/overloading-macro-on-number-of-arguments However, this method is not the most portable, and sometimes doesn’t work with MSVC, so a better approach is using the solution from rextester ONP80107. Option 2: However, this solution doesn’t work out of the box on Windows, as…

Read More Read More

Debug Tools

Debug Tools

When working with STL containers, smart pointers, and boost signals, it is nice to debug directly into your own code without making side trips into container internals. These configs also provide custom object views which make debugging easier in MSVC. To Use You need to reference these files from your project or copy them into <user>\Documents\Visual Studio ####\Visualizers. If you copy them, you must copy the files directly, VS will not recognize any files in subfolders. VS will usually detect…

Read More Read More

Invoker

Invoker

Some code, including direct UI updates, needs to run directly on the main application thread. When application code becomes increasingly parallelized, we need a simple, easy pattern to invoke back to the main thread which can be used directly across our applications. The standard way to invoke in MFC would be to create a new WM_USER message and handler for every method which needs to be invoked. This works, but gets very clunky when creating a large number of invokes….

Read More Read More

Leaky Destructors

Leaky Destructors

When dealing with inheritance, it is possible that the destructors for our objects may never be called if the class has virtual functions, but the base class has a non-virtual destructor. This leads to our derived classes being inadvertently leaky as we leak any memory allocated within the derived class. A detailed description of this bug is available in a Microsoft DevBlog writeup available at: C4265, Part 1 C4265, Part 2 Since this error is not always easy to detect…

Read More Read More

SourceTree Password Change

SourceTree Password Change

When updating your repository password, SourceTree doesn’t completely remove the old password. It will continually try both the new and old passwords automatically in the background when trying to authenticate with your repository. To use only your new password, you need to manually remove the old password from: And double check SourceTree’s application settings in:

BiDirectional Pimpl Pattern

BiDirectional Pimpl Pattern

While the Pimpl pattern is commonly used to hide implementation and private methods and variables from public interfaces, the common implementations often require a large amount of boilerplate code. This can make it hard to introduce this pattern into a large existing class. If we use bi-directional friend references with the private implementation, we can easily add a small private implementation into an existing class, allowing for better design patterns and performance optimizations to be gently introduced into existing code….

Read More Read More

Canon MP Navigator “Scan Failed”

Canon MP Navigator “Scan Failed”

When trying to connect older Canon printers to newer version of Windows, drivers are often only updated to Windows 8.1 before deprecation. With the same driver model between Windows 10 and 8.1, these drivers are installable and work for printing on Windows 10. However, when trying to scan with MP Navigator, they often give a “Scan failed” error. To enable both printing and scanning on Windows 10 through MP Navigator: Install the latest installable drivers (Windows 8 or Newer) from…

Read More Read More