-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
TransformPipeline: Minor memory optimization and a prim sanity check
- Loading branch information
Showing
2 changed files
with
10 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
eaf5cc1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I noticed that
GE_CMD_PRIM
passes inu32 type = data >> 16;
directly as the prim type.This is then passed to PrimCompatible(), which directly indexes
indexedPrimitiveType[7]
.AddPrim()
supports the same 7 values as well.JPCSP supports a curious additional value: GE_PRIM_CONTINUE_PREVIOUS_PRIM = 7.
http://code.google.com/p/jpcsp/source/browse/trunk/src/jpcsp/graphics/VideoEngine.java#2167
Could that be the cause? Since we remember prevPrim_ it seems we're set up for that, if it's correct.
Anyway, the type should probably be & 7? or error if > 7?
-[Unknown]
eaf5cc1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should definitely & by 7 and perhaps log-report if value is outside that range.
That extra value seems easy to support, yes.