PS2SDK
PS2 Homebrew Libraries
|
Data Structures | |
struct | dma_tag_t |
struct | vif_code_t |
struct | packet2_t |
union | Mask |
struct | Mask.__unnamed69__ |
Enumerations | |
enum | Packet2Mode { P2_MODE_NORMAL = 0 , P2_MODE_CHAIN = 1 } |
enum | Packet2Type { P2_TYPE_NORMAL = 0x00000000 , P2_TYPE_UNCACHED = 0x20000000 , P2_TYPE_UNCACHED_ACCL = 0x30000000 , P2_TYPE_SPRAM = 0x70000000 } |
enum | DmaTagType { P2_DMA_TAG_REFE = 0 , P2_DMA_TAG_CNT = 1 , P2_DMA_TAG_NEXT = 2 , P2_DMA_TAG_REF = 3 , P2_DMA_TAG_REFS = 4 , P2_DMA_TAG_CALL = 5 , P2_DMA_TAG_RET = 6 , P2_DMA_TAG_END = 7 } |
enum | UnpackMode { P2_UNPACK_S_32 = 0x00 , P2_UNPACK_S_16 = 0x01 , P2_UNPACK_S_8 = 0x02 , P2_UNPACK_V2_32 = 0x04 , P2_UNPACK_V2_16 = 0x05 , P2_UNPACK_V2_8 = 0x06 , P2_UNPACK_V3_32 = 0x08 , P2_UNPACK_V3_16 = 0x09 , P2_UNPACK_V3_8 = 0x0A , P2_UNPACK_V4_32 = 0x0C , P2_UNPACK_V4_16 = 0x0D , P2_UNPACK_V4_8 = 0x0E , P2_UNPACK_V4_5 = 0x0F } |
enum | VIFOpcode { P2_VIF_NOP = 0 , P2_VIF_STCYCL = 1 , P2_VIF_OFFSET = 2 , P2_VIF_BASE = 3 , P2_VIF_ITOP = 4 , P2_VIF_STMOD = 5 , P2_VIF_MSKPATH3 = 6 , P2_VIF_MARK = 7 , P2_VIF_FLUSHE = 16 , P2_VIF_FLUSH = 17 , P2_VIF_FLUSHA = 19 , P2_VIF_MSCAL = 20 , P2_VIF_MSCNT = 23 , P2_VIF_MSCALF = 21 , P2_VIF_STMASK = 32 , P2_VIF_STROW = 48 , P2_VIF_STCOL = 49 , P2_VIF_MPG = 74 , P2_VIF_DIRECT = 80 , P2_VIF_DIRECTHL = 81 } |
Structures and enums used in libpacket2.
struct dma_tag_t |
Destination chain tag.
Definition at line 89 of file packet2_types.h.
struct vif_code_t |
VIFCode structure.
Definition at line 278 of file packet2_types.h.
struct packet2_t |
DMA data packet. Successor of standard packet.
Definition at line 300 of file packet2_types.h.
Public Member Functions | |
qword_t *base | __attribute__ ((aligned(64))) |
Data Fields | |
u16 | max_qwords_count |
enum Packet2Type | type |
enum Packet2Mode | mode |
u8 | tte |
qword_t * | next |
dma_tag_t * | tag_opened_at |
vif_code_t * | vif_code_opened_at |
qword_t *base packet2_t::__attribute__ | ( | (aligned(64)) | ) |
Start position of the buffer.
u16 packet2_t::max_qwords_count |
Maximum number of qwords which was defined in packet2_create().
Definition at line 303 of file packet2_types.h.
Referenced by packet2_add(), packet2_create(), packet2_create_from(), and packet2_reset().
enum Packet2Type packet2_t::type |
Type of packet's memory mapping.
Definition at line 305 of file packet2_types.h.
Referenced by packet2_create(), and packet2_create_from().
enum Packet2Mode packet2_t::mode |
Packet mode.
Definition at line 307 of file packet2_types.h.
Referenced by dma_channel_send_packet2(), packet2_create(), and packet2_create_from().
u8 packet2_t::tte |
Tag transfer enable. Effective only in chain mode. If >0 transfer tag is set during packet sending and add_dma_tag() (so also every open_tag()) will move buffer by DWORD, so remember to align memory!
Definition at line 315 of file packet2_types.h.
Referenced by dma_channel_send_packet2(), packet2_chain_add_dma_tag(), packet2_create(), and packet2_create_from().
qword_t* packet2_t::next |
Current position of the buffer.
Definition at line 319 of file packet2_types.h.
Referenced by dma_channel_send_packet2(), packet2_add(), packet2_add_float(), packet2_add_s32(), packet2_add_s64(), packet2_add_u32(), packet2_add_u64(), packet2_advance_next(), packet2_chain_add_dma_tag(), packet2_chain_call(), packet2_chain_close_tag(), packet2_chain_next(), packet2_chain_ref(), packet2_chain_refe(), packet2_chain_refs(), packet2_create(), packet2_create_from(), packet2_doesnt_have_even_number_of_quads(), packet2_get_qw_count(), packet2_pad128(), packet2_pad96(), packet2_print(), packet2_reset(), packet2_update(), packet2_vif_close_direct_auto(), packet2_vif_close_direct_manual(), packet2_vif_close_unpack_auto(), packet2_vif_close_unpack_manual(), packet2_vif_open_direct(), and packet2_vif_open_unpack().
dma_tag_t* packet2_t::tag_opened_at |
The buffer position where DMA tag was opened. NULL, if no dma tag is open.
Definition at line 324 of file packet2_types.h.
Referenced by packet2_chain_add_dma_tag(), packet2_chain_close_tag(), packet2_create(), packet2_is_dma_tag_opened(), and packet2_reset().
vif_code_t* packet2_t::vif_code_opened_at |
The buffer position where DIRECT/UNPACK was opened. NULL, if no DIRECT/UNPACK is open.
Definition at line 329 of file packet2_types.h.
Referenced by packet2_create(), packet2_is_vif_code_opened(), packet2_reset(), packet2_vif_close_direct_auto(), packet2_vif_close_direct_manual(), packet2_vif_close_unpack_auto(), packet2_vif_close_unpack_manual(), packet2_vif_open_direct(), and packet2_vif_open_unpack().
union Mask |
Mask, used in VIF's STMASK opcode.
Definition at line 333 of file packet2_types.h.
Data Fields | ||
---|---|---|
struct Mask.__unnamed69__ | __unnamed__ | |
unsigned int | m |
struct Mask.__unnamed69__ |
Definition at line 335 of file packet2_types.h.
enum Packet2Mode |
#include <ee/packet2/include/packet2_types.h>
Two modes are commonly used with the DMA Controller (DMAC): normal mode and chain mode. In normal mode, transfers are issued one at a time. In chain mode, a series of transfers are issued simultaneously by initiating a transfer that contains "DMA Tags", which in turn contains instructions for further transfers. You will probably use chain mode for the majority of your transfers.
Definition at line 31 of file packet2_types.h.
enum Packet2Type |
#include <ee/packet2/include/packet2_types.h>
Types of memory mapping.
Enumerator | |
---|---|
P2_TYPE_NORMAL | Normal. |
P2_TYPE_UNCACHED | Uncached. |
P2_TYPE_UNCACHED_ACCL | Uncached accelerated. |
P2_TYPE_SPRAM | Scratchpad memory. |
Definition at line 38 of file packet2_types.h.
enum DmaTagType |
#include <ee/packet2/include/packet2_types.h>
DMA tag types
Definition at line 51 of file packet2_types.h.
enum UnpackMode |
#include <ee/packet2/include/packet2_types.h>
Unpack modes. V2 = 2 dimensions, S = Single = 1 dimension _32 = 32 bits of data length.
Definition at line 131 of file packet2_types.h.
enum VIFOpcode |
#include <ee/packet2/include/packet2_types.h>
VIF opcodes.
Definition at line 149 of file packet2_types.h.