forums.ps2dev.org Forum Index forums.ps2dev.org
Homebrew PS2, PSP & PS3 Development Discussions
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

misc dev questions

 
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PS2 Development
View previous topic :: View next topic  
Author Message
DracoLacertae



Joined: 13 Jul 2004
Posts: 22
Location: Berkeley, CA

PostPosted: Tue Feb 08, 2005 3:35 am    Post subject: misc dev questions Reply with quote

I've had the ps2linux kit for quite a while, and want to get myself more into native development. I've been working in a game engine project on the PC, which I want to port over to the ps2, and am considering native mode over linux. Before I start, I have a few questions:

-I've got the latest ps2gl (0.3.1) and got it working in linux fine. I want to use ps2gl in native mode, and see a version on this site that's a bit older. I'm wondering, has anyone here used 0.3.1 with the native ps2dev tools, and if so, how well does it work?

-Memory protection: The heart of my engine is a bytecode interpreter. It runs at ok speed in linux (it just does game scripting), but I think I should write it as a recompiling interpreter. How strict is the memory protection with the native mode kernel? I need to be able to have pages of memory enabled for writing, and then change the permission to enable execution. If possible, I would like +rwx at the same time.

-File access: On the linux version, I just store everything on the linux partition. On the native version, I will have to keep everything on the host filesystem or a memory card. I've seen some hard drive drvers on this site. Do the libraries here only deal with the sony gaming filesystem (i think it's called APA), or can it read from the linux ext2 filesystems?

Thanks!
Back to top
View user's profile Send private message Visit poster's website
Drakonite
Site Admin


Joined: 17 Jan 2004
Posts: 989

PostPosted: Tue Feb 08, 2005 7:42 am    Post subject: Re: misc dev questions Reply with quote

DracoLacertae wrote:

-File access: On the linux version, I just store everything on the linux partition. On the native version, I will have to keep everything on the host filesystem or a memory card. I've seen some hard drive drvers on this site. Do the libraries here only deal with the sony gaming filesystem (i think it's called APA), or can it read from the linux ext2 filesystems?

It currently only deals with APA/PFS.
_________________
Shoot Pixels Not People!
Makeshift Development
Back to top
View user's profile Send private message Visit poster's website
rinco



Joined: 21 Jan 2005
Posts: 255
Location: Canberra, Australia

PostPosted: Tue Feb 08, 2005 10:54 am    Post subject: Reply with quote

what is a recompiling interpreter?...

Your search - "recompiling interpreter" - did not match any documents.
Back to top
View user's profile Send private message
Oobles
Site Admin


Joined: 17 Jan 2004
Posts: 362
Location: Melbourne, Australia

PostPosted: Tue Feb 08, 2005 11:43 am    Post subject: Reply with quote

I'm not sure I'm right, but feeling like responding anyway.. I think a recompiling interpreter is where byte code is rewritten into mips instructions when loaded. So the initial load of the byte code is slow, but following that all the code is run natively. Similar to JVM hotspot compiler. There's probably a more common name for this technique.
Back to top
View user's profile Send private message Visit poster's website Yahoo Messenger MSN Messenger
ooPo
Site Admin


Joined: 17 Jan 2004
Posts: 2032
Location: Canada

PostPosted: Tue Feb 08, 2005 1:35 pm    Post subject: Reply with quote

dynamic recompiling?
Back to top
View user's profile Send private message Visit poster's website
Guest






PostPosted: Tue Feb 08, 2005 2:10 pm    Post subject: Re: misc dev questions Reply with quote

DracoLacertae wrote:

How strict is the memory protection with the native mode kernel? I need to be able to have pages of memory enabled for writing, and then change the permission to enable execution. If possible, I would like +rwx at the same time.


I think you have the Linux kit, no ?

Check out the EE Core User's manual. Read the sections on memory address spaces (mapping and segments) and the TLB organization.

This will answer your question better than any response you will get here.

In short, and at least my understanding is, the native kernel doesn't do anything more complicated with memory mapping than is described in the manual.

It is up to you whether you want to run things in kernel mode or user mode.
Back to top
DracoLacertae



Joined: 13 Jul 2004
Posts: 22
Location: Berkeley, CA

PostPosted: Wed Feb 09, 2005 7:05 am    Post subject: Reply with quote

Thanks for the info. Yes, I do have the linux kit. In fact I find using reload1 to be a very clean and easy way to boot programs (Thanks mrbrown) Since the libraries only access APA, I will probably read all the files off of host.

I'm going to try messing around with ps2gl compiled in native mode tonight, and see if I can do anything with it. I'll probably end up back on this forum asking for help. :-) (That is if I have time after my HW. Being a student really sucks for your independent projects; they tend to suffer.)

Oh, the dynamic recompiling is exactly right: I don't know where I got 'recompiling interpreter.' from.
Back to top
View user's profile Send private message Visit poster's website
Oobles
Site Admin


Joined: 17 Jan 2004
Posts: 362
Location: Melbourne, Australia

PostPosted: Wed Feb 09, 2005 11:18 am    Post subject: Reply with quote

You might find it easier using dreamGL instead of the linux code. From what I remember of ps2gl it doesn't conform very well to the openGL spec. You also might find it easier than porting the ps2gl code.
Back to top
View user's profile Send private message Visit poster's website Yahoo Messenger MSN Messenger
DracoLacertae



Joined: 13 Jul 2004
Posts: 22
Location: Berkeley, CA

PostPosted: Wed Feb 09, 2005 1:00 pm    Post subject: Reply with quote

I looked through the DreamGL headers, and couldn't find any blending functions. If dreamGL had fog and alpha blending, it would be practically perfect for what I need. It doesn't seem to have texture coordinate generation, but I can do this myself. Also, does DreamGL support different texture formats? I will quickly use up all the GS ram if I can only use 32bit.

Is ps2gl ready to use 'out of the box,' with ps2dev? I've looked, and the 'uber makefile' has support in it for native mode. Is this leftover from older versions when sony first made it, or does it still work? Has anyone here sucessfully used ps2gl (0.3.1) outside of ps2linux?

I also looked at gslib, and it seems to have most of what I need in terms of rendering primitives, except it doesn't do the 3d math for me. So I'm thinking of taking the 3d math and matrix handling functions from dreamgl and putting them with the primitive drawing and texture functions of gslib. Does this sound like a reasonable idea, or am I shooting myself in the foot?

Also, are there any other graphics libraries for the ps2, that do the 3d matrix/tranform/clipping/projection for you?
Back to top
View user's profile Send private message Visit poster's website
Drakonite
Site Admin


Joined: 17 Jan 2004
Posts: 989

PostPosted: Wed Feb 09, 2005 1:50 pm    Post subject: Reply with quote

DracoLacertae wrote:

Also, are there any other graphics libraries for the ps2, that do the 3d matrix/tranform/clipping/projection for you?

The PS2 libaries typically don't do those sorts of things for you, largely because it's much more effecient to write your own vu code to do it.
_________________
Shoot Pixels Not People!
Makeshift Development
Back to top
View user's profile Send private message Visit poster's website
mharris



Joined: 25 Jan 2004
Posts: 155
Location: Annapolis, MD, USA

PostPosted: Fri Feb 11, 2005 11:50 am    Post subject: Re: misc dev questions Reply with quote

Drakonite wrote:
It currently only deals with APA/PFS.

I actually got about 75% of the way with an ext2fs driver for ps2sdk. It's read-only, and there are many many missing features.

I don't know what state it's in right now, this was a couple months ago and it's been relegated to my ever-growing pile of semi-finished projects.
Back to top
View user's profile Send private message AIM Address
DracoLacertae



Joined: 13 Jul 2004
Posts: 22
Location: Berkeley, CA

PostPosted: Fri Feb 11, 2005 6:42 pm    Post subject: Reply with quote

Quote:
it's been relegated to my ever-growing pile of semi-finished projects.


Haha, sounds like what happens to most of my projects. For me school has mostly been a vicous time-sucking vampire.

This weekend I'll mess around with some ps2 graphics stuff: play around with dreamgl, gskit, and the vu's.

Thanks everyone. Hopefully I can at least get the 2D path of my engine running well enough on the ps2 that I can release something to the public.
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PS2 Development All times are GMT + 10 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group