Skip to content

Commit 74676db

Browse files
committed
chg: add auto-sync, remove all manual syncs
1 parent 2dc3d6b commit 74676db

34 files changed

Lines changed: 23 additions & 86 deletions

File tree

examples/03_objects/main.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -172,8 +172,6 @@ int main()
172172
t3d_matrix_pop(1);
173173

174174
// ======== Draw (2D) ======== //
175-
rdpq_sync_pipe();
176-
177175
int totalTris = 0;
178176
for(int i=0; i<actorCount; ++i) {
179177
totalTris += triangleCount[(i*3) % 2];

examples/04_dynamic/main.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,6 @@ int main()
194194
t3d_matrix_pop(1);
195195

196196
// ======== Draw (2D) ======== //
197-
rdpq_sync_pipe();
198197
rdpq_text_printf(NULL, FONT_BUILTIN_DEBUG_MONO, 16.0f, 20.0f, "[A] Scroll: %c\n", scrollEnabled ? 'Y' : '-');
199198
rdpq_text_printf(NULL, FONT_BUILTIN_DEBUG_MONO, 16.0f, 32.0f, "[B] Transf: %c\n", transformEnabled ? 'Y' : '-');
200199
rdpq_text_printf(NULL, FONT_BUILTIN_DEBUG_MONO, 220.0f, 20.0f, "FPS: %.4f\n", display_get_fps());

examples/05_splitscreen/main.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,6 @@ int main()
178178
}
179179

180180
// ======== Draw (2D) ======== //
181-
rdpq_sync_pipe();
182181
rdpq_set_scissor(0, 0, sizeX, sizeY);
183182
rdpq_set_mode_standard();
184183
rdpq_set_mode_fill(RGBA32(0, 0, 0, 0xFF));
@@ -190,7 +189,7 @@ int main()
190189
// minimap
191190
rdpq_set_mode_standard();
192191
rdpq_mode_alphacompare(128);
193-
rdpq_sync_load();
192+
194193
rdpq_sprite_blit(spriteMinimap,
195194
display_get_width()/2 - 29,
196195
display_get_height()/2 - 29,

examples/06_offscreen/main.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ void dynamic_tex_cb(void* userData, const T3DMaterial* material, rdpq_texparms_t
1616
if(tile != TILE0)return; // this callback can happen 2 times per mesh, you are allowed to skip calls
1717

1818
surface_t *offscreenSurf = (surface_t*)userData;
19-
rdpq_sync_tile();
2019

2120
int sHalf = OFFSCREEN_SIZE / 2;
2221
int sFull = OFFSCREEN_SIZE;
@@ -166,7 +165,6 @@ int main()
166165
rspq_block_run(dplBox);
167166
t3d_matrix_pop(1);
168167

169-
rdpq_sync_pipe();
170168
rdpq_text_printf(NULL, FONT_BUILTIN_DEBUG_MONO, 16, 14, "%.1f FPS\n", display_get_fps());
171169
}
172170

examples/07_skeleton/main.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,6 @@ int main()
190190
t3d_matrix_pop(1);
191191

192192
// ======== Draw (UI) ======== //
193-
rdpq_sync_pipe();
194193

195194
// Bone View
196195
float posX = 12;

examples/08_animation/main.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,6 @@ int main()
210210
float posX = 16;
211211
float posY = 24;
212212

213-
rdpq_sync_pipe();
214213
rdpq_text_printf(NULL, FONT_BUILTIN_DEBUG_MONO, posX, posY, "[A] Attack: %d", isAttack);
215214

216215
posY = 216;

examples/09_anim_viewer/main.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,6 @@ int main()
212212
float posX = 16;
213213
float posY = 20;
214214

215-
rdpq_sync_pipe();
216215
rdpq_text_printf(NULL, FONT_BUILTIN_DEBUG_MONO, posX, posY, STYLE(STYLE_TITLE) "[L/R] Model: %d/%d", modelIdx+1, MODEL_COUNT);
217216
posY += 10;
218217
rdpq_text_printf(NULL, FONT_BUILTIN_DEBUG_MONO, posX, posY, STYLE(STYLE_TITLE) "[C] Animations:");

examples/10_flipbook_tex/main.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ void dynamic_tex_cb(void* userData, const T3DMaterial* material, rdpq_texparms_t
2020
// 'userData' is a value you can pass into 't3d_model_draw_custom', this can be any value or struct you want...
2121
surface_t* surface = (surface_t*)userData; // ...in this case it is a surface pointer
2222

23-
rdpq_sync_tile();
2423
rdpq_mode_tlut(TLUT_NONE);
2524
rdpq_tex_upload(TILE0, surface, NULL);
2625
}

examples/12_uv_gen/main.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,6 @@ int main()
147147
t3d_matrix_pop(1);
148148

149149
// ======== 2D ======== //
150-
rdpq_sync_pipe();
151150

152151
rdpq_textparms_t texParam = {
153152
.width = display_get_width(),

examples/13_cel_shading/main.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -269,8 +269,6 @@ int main()
269269
t3d_matrix_pop(1);
270270

271271
// ======== 2D ======== //
272-
rdpq_sync_pipe();
273-
274272
rdpq_textparms_t texParam = {
275273
.width = display_get_width(),
276274
.align = ALIGN_CENTER,

0 commit comments

Comments
 (0)