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 

get_pixel?

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



Joined: 03 Dec 2004
Posts: 728
Location: Germany

PostPosted: Mon Dec 06, 2004 9:11 am    Post subject: get_pixel? Reply with quote

I've seen some put_pixel functions, but how to write a get_pixel? It should be possible, because at http://cvs.ps2dev.org/altimit/ee/altimitPAD.cpp?rev=HEAD there is a commented screenshot include.

I've found the description how to do it somewhere on the internet and I understand all, like setting the FINISH and BUSDIR register, but what is the "Host I/F" and how can I read from it?
Back to top
View user's profile Send private message
Guest






PostPosted: Mon Dec 06, 2004 9:57 am    Post subject: Reply with quote

Ahh....one of the most complex areas I think of the EE architecture. :)

It is easier to understand if you have a Linux Kit and read both the GS Users manual and the source code to the GS video driver, particularly the gsstoreimage() (not sure thats the name) function.

Basically, the frame buffer isn't set up for easy reading from host (EE). You have to specify a region in GS memory, switch transfer directions of both the GIF and the VIF1, and initiate the actual transfer. If I remember correct, you read the transfer data from VIF1 FIFO. (Might sound confusing because you would normally write to the VIF1 FIFO, not many realize there is a reason for reading as well, since the transfer occurs along PATH2).

I haven't even begun to describe the process in detail, but gave you the basics. I did a more comprehensive writeup in www.playstation2-linux.com forums some years back but it seems impossible to do any meaningful searches on forum posts there. If I find it I will let you know.
Back to top
Shine



Joined: 03 Dec 2004
Posts: 728
Location: Germany

PostPosted: Mon Dec 06, 2004 11:57 am    Post subject: Reply with quote

gorim wrote:
Ahh....one of the most complex areas I think of the EE architecture. :)


Yes, it is not so easy. I wanted it for screenshots, so I checked out the whole ps2dev CVS and did a fulltext search, and there is already such a function:

http://cvs.ps2dev.org/ps2sdk/ee/debug/src/screenshot.c?rev=HEAD

I've integrated it in the starsimulation and created a little animation:

http://www.frank-buss.de/ps2/index.html
Back to top
View user's profile Send private message
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