Jump to content

  • Log In with Google      Sign In   
  • Create Account


Member Since 06 Mar 2012
Offline Last Active Yesterday, 05:20 PM

Posts I've Made

In Topic: C++ : Extend class in dll

18 October 2016 - 02:07 PM

Look into virtual abstract base classes. The dll can return a pointer to a descendant in a factory function and the host can use it because it knows the base class. (EDIT: I see Wyrframe's link talks about them, so read that).
The main reason for this is to support dlls made in different languages and with different compilers than yours.
Do make sure you define calling conventions and data (struct) alignment. For calling conventions, cdecl and stdcall are good choices.

Is this, in fact, not what COM technology is all about? Although it includes additional features such as reference counting as well.

In Topic: Getting more curious and curious

06 October 2016 - 05:21 PM

This thing about being sidetracked happens to me with such strength and frequency that I follow a depth first tree-traversal algorithm and never get shit done. It's to the point that I just had to know how to code a simple win32 that just opens a window in pure assembly. Pure means none of that HLA thing with "invoke" or if-else blocks. It's push the args on the stack and call. It's compare EAX to some value and branch on condition.

In Topic: Best Way To Comment Code Without Cluttering

06 August 2016 - 06:08 AM

*I'm pretty much a minimalist in *this department. I kinda hate *when some third party library *has a class that looks like it's *hundreds and hundreds of lines *with most of them comments and *the odd method or property here *and there. And I demonstrated
*what I mean lol

In Topic: Did Something Wierd Just Happen?

03 August 2016 - 04:31 PM

Saw it too. Was worried the site would close down because it's no longer profitable or something. Sites come and go like that.

In Topic: How To Start Game Programming With C++

28 July 2016 - 08:16 AM

Rastertek.com is an excellent source to learn Direct3D 11 too, if you want to get an idea of how C++ subsystems work together.