Making the 3D Fundamentals framework cross-platform

The Partridge Family were neither partridges nor a family. Discuss.
Post Reply
TheTask1337
Posts: 21
Joined: October 30th, 2014, 9:10 pm

Making the 3D Fundamentals framework cross-platform

Post by TheTask1337 » November 21st, 2017, 2:30 am

Hi,
I know many programmers prefer Windows for programming, but is there some easy way to make this run on Mac?
I don't know how difficult would this be to use with Metal and if there is any easy way to port it.

User avatar
chili
Site Admin
Posts: 3948
Joined: December 31st, 2011, 4:53 pm
Location: Japan
Contact:

Re: Making the 3D Fundamentals framework cross-platform

Post by chili » November 21st, 2017, 2:03 pm

It could be ported, would not even need metal. Could do with with SDL or similar even.
Chili

TheTask1337
Posts: 21
Joined: October 30th, 2014, 9:10 pm

Re: Making the 3D Fundamentals framework cross-platform

Post by TheTask1337 » November 21st, 2017, 4:53 pm

Is it something you plan on doing / would be willing to do for the series? I don't have enough space on my MacBook Pro to run Bootcamp. :cry:

albinopapa
Posts: 4373
Joined: February 28th, 2013, 3:23 am
Location: Oklahoma, United States

Re: Making the 3D Fundamentals framework cross-platform

Post by albinopapa » November 21st, 2017, 6:49 pm

You wouldn't need to run a virtual machine if you used SDL, SFML or GTK+, they're all cross-platform. I wanted to mention it yesterday, but wasn't sure if you were set on Metal or not. You can even look into xCode if you want a graphical IDE.

One thing to note though is when chili goes over hardware 3D stuffs, it will be using the Direct3D 11 API. Though I wouldn't complain if it was using the Vulkan API, :lol:.
If you think paging some data from disk into RAM is slow, try paging it into a simian cerebrum over a pair of optical nerves. - gameprogrammingpatterns.com

TheTask1337
Posts: 21
Joined: October 30th, 2014, 9:10 pm

Re: Making the 3D Fundamentals framework cross-platform

Post by TheTask1337 » November 21st, 2017, 8:10 pm

Okay so what you are basically saying is that if I manage to get a window handled by lets say SFML, all the rest of the framework should be pretty much good to go?

cameron
Posts: 794
Joined: June 26th, 2012, 5:38 pm
Location: USA

Re: Making the 3D Fundamentals framework cross-platform

Post by cameron » November 21st, 2017, 10:46 pm

1. First, you would have to switch over the window handling stuff like you said.
2. Next, you would have to switch all the internal d3d stuff over too (OpenGL maybe?)

Then... most of it would be working.

3. Finally, the xaudio2 stuff would need to be switched over to something else.

Perhaps I missed something; however, the point is that there would be much more work involved than switching over the window handling stuff to say sdl or sfml. I'm not saying that it isn't doable, it would just be a lot of work. Pretty much everything except the interfaces would have to be remade.
Computer too slow? Consider running a VM on your toaster.

User avatar
chili
Site Admin
Posts: 3948
Joined: December 31st, 2011, 4:53 pm
Location: Japan
Contact:

Re: Making the 3D Fundamentals framework cross-platform

Post by chili » November 22nd, 2017, 1:08 am

If you can replace the backend of putpixel with metal/sdl/sfml stuff then you will be good to go. Can also use sdl/sfml to handle window creation and input back-end. One annoying thing is you'll need to translate whatever constants those systems use to windows VK_ keyboard constants so that stuff will work. It's a bit of a project but not unreasonable.
Chili

Post Reply