I see that PACKET_SIZE is sized in varying degrees in different sources, thus the resultant PACKET object defined can be sometimes very large or small.
I've noticed this issue because I tried to load an image with a defined PACKET object too small; everything crashed for no apparent reason; it was not easy to narrow down the culprit to an excessively small PACKET allocation.
Is there a rule of thumb to estimate how much this PACKET should be?
Thanks
GPU packets size
-
Verified
- Extreme PSXDEV User
- Posts: 131
- Joined: Jul 17, 2013
I wondered about the same thing a while ago: http://www.psxdev.net/forum/viewtopic.php?f=51&t=391
Though, nobody could give an exhaustive explanation
Your best bet is to increase values until they fit to your project(for how clunky it sounds), or maybe it's explained somewhere in psyq's documentation... i should dig a bit deeper about this
Though, nobody could give an exhaustive explanation

Your best bet is to increase values until they fit to your project(for how clunky it sounds), or maybe it's explained somewhere in psyq's documentation... i should dig a bit deeper about this
Thanks for pointing me to your thread, it was interesting nonethelessYagotzirck wrote:I wondered about the same thing a while ago: http://www.psxdev.net/forum/viewtopic.php?f=51&t=391
Though, nobody could give an exhaustive explanation
-
Administrator Verified
- Admin / PSXDEV
- Posts: 2691
- Joined: Dec 31, 2012
- I am a: Shadow
- PlayStation Model: H2000/5502
Read LIBOVR46.PDF, Packet Preparation Function (Packet Buffer). Page 163.
LIBOVR46.PDF
I usually keep it at 2048. So, 2048 bytes are set aside for use under GsSetWorkBase.
If your program is really simple, then you can even drop it as low as 300 bytes.
PACKET is a unsigned char, so just print it out and see what it contains
LIBOVR46.PDF
LIBGS.HThe packet creation area is set by the GsSetWorkBase() function.
Packets increase and decrease depending on the type and number of polygons (flat/gouraud, with/without
texture). Only a rough estimate can be made of how much area should be maintained. If the area of an
actual packet is smaller than the packet created, it will destroy the area behind the packet area.
Code: Select all
/*
* $PSLibId: Run-time Library Release 4.6$
*/
/*
* libgs.h: Graphic Library Header
*
*
* Version 1.** Apr, 8, 1994
*
* Copyright (C) 1993 by Sony Corporation All rights Reserved
*/
...
/*** packet peripheral pointer ***/
typedef unsigned char PACKET;
If your program is really simple, then you can even drop it as low as 300 bytes.
PACKET is a unsigned char, so just print it out and see what it contains

Development Console: SCPH-5502 with 8MB RAM, MM3 Modchip, PAL 60 Colour Modification (for NTSC), PSIO Switch Board, DB-9 breakout headers for both RGB and Serial output and an Xplorer with CAETLA 0.34.
PlayStation Development PC: Windows 98 SE, Pentium 3 at 400MHz, 128MB SDRAM, DTL-H2000, DTL-H2010, DTL-H201A, DTL-S2020 (with 4GB SCSI-2 HDD), 21" Sony G420, CD-R burner, 3.25" and 5.25" Floppy Diskette Drives, ZIP 100 Diskette Drive and an IBM Model M keyboard.
PlayStation Development PC: Windows 98 SE, Pentium 3 at 400MHz, 128MB SDRAM, DTL-H2000, DTL-H2010, DTL-H201A, DTL-S2020 (with 4GB SCSI-2 HDD), 21" Sony G420, CD-R burner, 3.25" and 5.25" Floppy Diskette Drives, ZIP 100 Diskette Drive and an IBM Model M keyboard.
Who is online
Users browsing this forum: No registered users and 5 guests