Irrlicht on Sega Dreamcast... has anyone done or seen this?

Discuss about anything related to the Irrlicht Engine, or read announcements about any significant features or usage changes.
pheadbaq

Irrlicht on Sega Dreamcast... has anyone done or seen this?

Post by pheadbaq »

Hello all,

I'm pretty n00b to the 3D/game programming scene so forgive me if I make some incorrect assumptions here. First of all, I've been researching/doing limited testing on several 3D engines of late (Crystal Space, Ogre, Irrlicht) and Irrlicht looks the easiest to me (kudos to the developer for making it that way).

I've also been toying with Dreamcast programming and found out that there is at least 1 API for it that attempts to mimic the official OpenGL API (KGL-X: http://www.renate-hat.onlinehome.de/til ... /tools.htm). Does anyone know of or have plans to create an OpenGL driver for Irrlicht that uses the Dreamcast's OpenGL API? How about the steps that would be involved to do such a thing?

One reason I'm looking at this is because my Dreamcast has more powerful 3D hardware than my PC, plus I think it'd be cool to be able to code something in Irrlicht that could be easily ported to a console.

Thanks in advance for any insight you may offer :D
Noldo
Posts: 15
Joined: Sat Dec 27, 2003 3:11 pm
Location: Lappeenranta,Finland

Post by Noldo »

Sounds interesting.

You should propably start by finding out which part of the OpenGL isn't implemented in KGL-X and then try to find out if it is possible to make Irrlicht work without those features. If the answer is no then you would proceed with filling in the gaps you found by developping Irrlicht or KGL-X.
keless
Posts: 805
Joined: Mon Dec 15, 2003 10:37 pm
Location: Los Angeles, California, USA

Post by keless »

you would also need to check for basic sub-system differences--

is it Little Endian or Big Endian?
is it based on an x86 CPU, or do you need a special compiler?
does it support threading?
etc
a screen cap is worth 0x100000 DWORDS
pheadbaq
Posts: 33
Joined: Wed Dec 31, 2003 4:41 pm
Contact:

Post by pheadbaq »

Good question keless, I hadn't considered those factors before. I think your first two questions are pretty much tied together in my mind. Please correct me if I'm wrong, but I wouldn't think Little or Big Endian would matter as long as I used the same compiler for the different cpus would it? From what I understand, I could write a program in C, then compile and run it on x86 (using gcc), SH4 (using sh-gcc), and ARM (using arm-gcc) without modifying the code.

I'm sure that's probably a bit oversimplified, but if the C primitive types are the same on a C compiler for an x86, an SH4, and an ARM, shouldn't it work like that? Oh and yes the DC does support threading from what I understand.

By the way, here's the link to the DCs open source OS (not from SEGA of course :wink: ). One of you is probably better able to understand all of it's low-level features than I am.

http://gamedev.allusion.net/softprj/kos/
keless
Posts: 805
Joined: Mon Dec 15, 2003 10:37 pm
Location: Los Angeles, California, USA

Post by keless »

*-Endian doesnt matter so much for the binary executable. It matters more in the loading of resources such as .BSP files.

you definately have to recompile code for different platforms (such as x86 vs. ARM). however, you generally dont need to change the code much (or usually at all) to get it to work on either one (if your library supports both). KGL supports both, but that still means you'll have to compile binaries for PC and compile for DC seperately. (you'll have to have a compiler that can perform both output types, or have 2 different compilers)

the KOS does seem to have image libraries, if a rather "spartan" coverage of libc. If you want to make a game with this, you're definately going to have to get your hands dirty with console programming, no bones about it. If you havent already made a game or two on your PC, you'll be in over your head.

you may also want to have had some EE classes, or at least an OS class, before tackling this, but thats just my opinion.

anyhow, its not going to be a simple walk in the park, and it will require involved knowledge of the Irrlicht engine code, DC hardware, and the K-OS
a screen cap is worth 0x100000 DWORDS
A128

Post by A128 »

I work on Dreamcast driver with irrlicht 0.10.....I am not sure if it makes sense....the GUI stuff will be not part of the dreamcast irrlicht. the textures muste be A1R5G5B5 and A4R4G4B4 and R5G6B5......I compiled it with a NULL,DC device....and the lib has 1,7MB....which I find very large for the console .

I am not sure if there will any release , anyway check

http://a128.ch9de

from time to time
Guest

Post by Guest »

http://a128.ch9.de

is the page...where some can find the latest OpenGL Dreamcast lib and maybe someday irrlicht 0.10 for this console.
omaremad
Competition winner
Posts: 1027
Joined: Fri Jul 15, 2005 11:30 pm
Location: Cairo,Egypt

Post by omaremad »

the main things u should look for when devloping for consoles is:

-ram
-colors supported
-does it include a floating piont processor(dont use floats if it doesnt have one really slow)
-btw some homebrew devlibs only allow the excutable to be loaded (they have no file systems) so all the engine and the media have to fit in the ram
since every thing is loaded at once
btw the loading problems can be solved by compiling the media as an obj then linking it in at the end
like this

//nds makefile//

Code: Select all

#---------------------------------------------------------------------------------
# no real need to edit anything past this point unless you need to add additional
# rules for different file extensions
#---------------------------------------------------------------------------------
ifneq ($(BUILD),$(notdir $(CURDIR)))
#---------------------------------------------------------------------------------
 
export OUTPUT	:=	$(CURDIR)/$(TARGET)
 
export VPATH	:=	$(foreach dir,$(SOURCES),$(CURDIR)/$(dir))
 
export CC		:=	$(PREFIX)gcc
export CXX		:=	$(PREFIX)g++
export AR		:=	$(PREFIX)ar
export OBJCOPY	:=	$(PREFIX)objcopy
#---------------------------------------------------------------------------------
# use CXX for linking C++ projects, CC for standard C
#---------------------------------------------------------------------------------
export LD		:=	$(CXX)
#export LD		:=	$(CC)
 
CFILES		:=	$(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.c)))
CPPFILES	:=	$(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.cpp)))
SFILES		:=	$(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.s)))
PCXFILES	:=	$(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.pcx)))
BINFILES	:=	$(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.bin)))
PALFILES	:=	$(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.pal)))
RAWFILES	:=	$(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.raw)))
MAPFILES	:=	$(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.map)))
 
export OFILES	:=	$(MAPFILES:.map=.o) $(RAWFILES:.raw=.o) $(PALFILES:.pal=.o) $(BINFILES:.bin=.o) $(PCXFILES:.pcx=.o)\
					$(CPPFILES:.cpp=.o) $(CFILES:.c=.o) $(SFILES:.s=.o)
 
export INCLUDE	:=	$(foreach dir,$(INCLUDES),-I$(CURDIR)/$(dir)) \
					$(foreach dir,$(LIBDIRS),-I$(dir)/include) \
					$(foreach dir,$(LIBDIRS),-I$(dir)/include/NDS) \
					-I$(CURDIR)/$(BUILD)
 
export LIBPATHS	:=	$(foreach dir,$(LIBDIRS),-L$(dir)/lib)
 
.PHONY: $(BUILD) clean export
 
#---------------------------------------------------------------------------------
$(BUILD):
	@[ -d $@ ] || mkdir -p $@
	@make --no-print-directory -C $(BUILD) -f $(CURDIR)/Makefile
 
#---------------------------------------------------------------------------------
clean:
	@echo clean ...$(TARGET)
	@rm -fr $(BUILD) *.elf *.*ds*
Guest

Post by Guest »

And for those mortals among us, who just want to get their 3D- Realtime content on the Dreamcast their is still Quake1 engine. A bit old but well documented and funking fast. Irrlicht on DC would be a nice toy, but let's face it: DC does not get produced anymore. It was a better console, thats why it had to die.
Guest

Post by Guest »

omaremad wrote:the main things u should look for when devloping for consoles is:

-ram
-colors supported
-does it include a floating piont processor(dont use floats if it doesnt have one really slow)
-btw some homebrew devlibs only allow the excutable to be loaded (they have no file systems) so all the engine and the media have to fit in the ram
since every thing is loaded at once
btw the loading problems can be solved by compiling the media as an obj then linking it in at the end
like this
[/code]
Hm, I guess you did not know the Dreamcast hardware potentials....

ram: 8MB textures/16MB code
colors: ARGB4444, ARGB1555, RGB565, ARGB8888 (not usefull)
SH4 has floating points (very fast) and it has dot4,sqrt,cos,1/sqrt and 4x4 matrix multiplication in hardware

the dreamcast has a very powerfull homwbrew library names KOS with (of course) mayn filesystems....
Guest

Post by Guest »

I started looking into porting Irrlicht to the DC and found that the compilers had awful support for C++ - I abandonned the idea soon after I realised this.
omaremad
Competition winner
Posts: 1027
Joined: Fri Jul 15, 2005 11:30 pm
Location: Cairo,Egypt

Post by omaremad »

You could use structures instead of classes
had awful support for C++ - I abandonned the idea soon after I realised this.
i meant some hombrew dev libs dont have filessystems so u would have to convert a sprite to raw pixels and put it in a c++ array so it gets compiled with the code

howver u can use a home made file system called "gbfs"
bob

Post by bob »

I don't really see the poin though. Dreamcast is dead lol..
Guest

Post by Guest »

You are repeating me Bob. Yes DC does not get produced anymore, but it is such a versatile Console and so powerful that there is certainly a strong temptation to port Irrlicht. By the way its not completly out of biz as they still produce Laptop!-DC's in Asia, hmm kinda inoficially.

Apart from that lots of ppl still have some which they use for:

VCD, Audio, MP3, Virus-free Internet surfing, tiny Webservers, very portable playing device, works with TV AND VGA, Emulator for older consoles, Gameboy-Emu, Head to head racing via serial cable (Ferrari F355) needs two consoles....

And it fits in your daypack easily...

Please port Irrlicht.
pheadbaq
Posts: 33
Joined: Wed Dec 31, 2003 4:41 pm
Contact:

4 year-old post... sheesh!

Post by pheadbaq »

Can't believe it's been nearly 4 years since I posted that, lol. Anyway, just thought I'd update with these links as a way to wrap things up, and also just in case anyone interested in Dreamcast engine programming/porting comes looking:

KOS Dev libraries: http://gamedev.allusion.net/softprj/kos/

KGL-X OpenGL look-alike api and driver for DC (derived from KGL, KOS' OpenGL api): http://www.dreamcast-scene.com/index.php/Main/KGL-X

Holly 3D Engine (built on KOS): http://a128.atspace.com/holly3d/index.html


The Holly 3D page hasn't been updated in over a year from what I can tell, but it looks like he was pretty close to finishing the engine (97%). I still keep up with Dreamcast development from time to time, although since the original post I've realized I'm better suited to building things on top of a pre-exsiting engine, as opposed to trying to create/port one... quicker results that way ;)

Irrlicht's come a long way, great work guys!
Pronunciation: 'feedback' ;)
Post Reply