Q

Home » holodeck » Creator’s Journal: Holodeck Management System Progress

Creator’s Journal: Holodeck Management System Progress

Enter your email address to follow this blog and receive notifications of new posts by email.

Join 45 other followers

I forgot how frustrating Visual C++ an be to work with.

The last time I have really programmed with it was at Intel, Corporation, in Chandler, Arizona – around 2002ish.

Even then. It wasn’t ‘hard core’ programming.

The real last hard core programming I did in Visual C++ was way back in 1993 at U-Haul doing the payroll systems.

Since then I have learned why I get headaches when I program with such intensive code. Since I am messing with the energy and fabric of reality as I am doing this – something I didn’t know I was doing before which quite likely led to my insanity numerous times over – now it’s changed. I know why I’m feeling the way I am.

Messing with computer code in energy is akin to messing with your own mind with a network cable attached to the back of your head.


So I started the creation of ‘classes’ to handle abstracting the primitive drawing of GL code to reusable objects.

The primary goal was mostly met today, with an exception of segmented disk where the segments aren’t drawing properly.

But I encountered this annoying fucking error which plagued me for a good couple hours:

Error    2    error LNK2001: unresolved external symbol “public: virtual void __thiscall IGLPrimitive::Draw(void)” (?Draw@IGLPrimitive@@UAEXXZ)    GLPrimitives.obj    

So what I ended up doing is taking all the base primitive objects I could draw – a cone, a sphere, a cube, a disk, and a cylinder, and creating ‘classes’ around each one of these.

Each one of these classes inherits from the GLPrimitive object to reinforce the standardization of drawing objects on the screen.

Which is where this error was coming from.

I had created a REAL simplistic GLPrimitive class of which I just wanted to make sure I remembered my inheritance syntax:

GLPrimitive

From there I created an inherited class based on the GLPrimitive:

GLSphereClass

And from there I placed the code to handle drawing the sphere primitive once the sphere was constructed:

GLSphere

Compiled just fine.

THEN I went to place the code in the main loop to actually draw the sphere itself if the right ‘case’ came around:

MainCase

Now this is the working code, but the problem was simple syntactical issues: I had not placed the GLSphere:: in front of the Draw function.

I mean. This is really simple stuff, right, seeing as I USED to work with this all the time. This goes to show HOW much a person can forget in 20 years time…

In any case. I managed a successful class conversion, here’s the hierarchy so far:

ROMMIE

And here’s the output leveraging the Earth Bitmap as a base texture for each of the primitives:

The 3D Cube:

EarthCube

The 3D Cone:

EarthCone

The 3D Cylinder:

EarthCylinder

The 3D Disk:

EarthDisk

The 3D Globe – redone in C++ (still needs work to fix the texture wrapping):

EarthSphere

And the currently very broken 3D segmented disk:

EarthSegmentedDisk


 

TODO Tomorrow:

1) Fix the 3D Sphere’s texture wrapping
2) Fix the 3D segmented sphere
3) Create a texture class
4) Add in positional and rotational methods into the base class
4) Find textures of Venus, Jupiter, Saturn, Mars, Neptune, and Uranus to use in addition to Earth’s texture.
5) Test out memory and the positional, rotational, and texture code by creating a whole boatload of 3D objects with different textures in different locations

This is what a homeless does for fun,…

That’s it for today…..

 

Enter your email address to follow this blog and receive notifications of new posts by email.