Game Development Community

AviBitmapCtrl and SDL clarifications needed

by Robert Blanchet Jr. · in Torque Game Engine · 04/12/2002 (9:46 am) · 4 replies

Hey,
I'm going through the AviBitmapCtrl Gui code today and I'm wondering about a few references to some SDL objects.

In the MPG portion of the header file for the AviBitmapCtrl there are a few references made to some SDL objects such as SDL_Surface and SDL_mutex. However the Torque Engine doesn't seem to be linking to the SDL libraries anywhere.

I guess what I'm wondering is, are there plans to use SDL within the engine? And if so, is the use primarily for Avi and MPG playback or are the plans more extensive then that?

Edit: Correction. SDL is being linked within the engine however it is only for the Linux systems. So does this suggest that the AVI and MPG will be used through SDL and the Windows platform through some other means?

#1
04/12/2002 (1:39 pm)
SDL is available on both mac and windows also...wouldnt it be best to use SDL for all the platforms?

Here is the website if you want to check it out - Simple DirectMedia Layer

-Tim aka Spock
#2
04/12/2002 (6:31 pm)
I'm the one who added SDL support the the linux platform.
SDL is good for the linux port, but I don't think there is a lot of value in making the other platform layers use it, since they are already working well.

My guess is that the SDL references in this AviGuiBitmap control are legacy stuff from the Tribes 2 codebase. Linux T2 probably used SMPEG (a video/audio playback library based on SDL), so thats where these references come from. SMPEG is a pretty cool application, but it was authored and maintained by Loki so who knows what is happening with it now.

In any case, yes the linux platform is the only build linking with SDL right now. If you want to link SDL on the other platforms (and contribute that code back to the engine), you should get approval from the GG guys. SDL's LGPL licensing imposes some irritating but not insurmountable restrictions.
#3
04/12/2002 (8:16 pm)
Thanks for the help guys.
I've been looking at it here and there all day and I don't see why the avi and mpg playback can't be wrapped through Platform:: some how. Using different systems for each Linux: SDL, Windows: Windows libraries, and Mac OS: mac libraries.

I'll be looking this all weekend. See what I can do.
#4
04/12/2002 (9:46 pm)
Wrapping the avi/mp3 stuff with the platform would be a good way to do it. I'm sure a lot of people would like to see this feature in the engine!