Remove mprintf_at() usage

This function is stubbed and does nothing.
This commit is contained in:
Azamat H. Hackimov 2024-09-23 02:10:35 +03:00
parent 21576c86a5
commit c3b1225c6e
15 changed files with 0 additions and 41 deletions

View File

@ -163,7 +163,6 @@ int Debug_MessageBox(int type, const char *title, const char *str);
// these functions deal with debug spew support
void Debug_ConsolePrintf(int n, const char *format, ...);
void Debug_ConsolePrintfAt(int n, int row, int col, const char *format, ...);
// DEBUGGING MACROS
// Break into the debugger, if this feature was enabled in Debug_init()

View File

@ -63,5 +63,3 @@ void Debug_ConsolePrintf(int n, const char *format, ...) {
printf("%s", Mono_buffer);
}
}
void Debug_ConsolePrintfAt(int n, int row, int col, const char *format, ...) {}

View File

@ -75,10 +75,8 @@
// Prints a formatted string to the debug window
#define mprintf(...) Debug_ConsolePrintf(__VA_ARGS__)
// Prints a formatted string on window n at row, col.
#define mprintf_at(...) Debug_ConsolePrintfAt(__VA_ARGS__)
#else // ifdef _DEBUG
// DAJ defined in target headers
#define mprintf(...)
#define mprintf_at(...)
#endif // ifdef _DEBUG
#endif

View File

@ -48,6 +48,4 @@ void Debug_ConsolePrintf(int n, const char *format, ...) {
}
}
void Debug_ConsolePrintfAt(int n, int row, int col, const char *format, ...) {}
#endif

View File

@ -1169,9 +1169,6 @@ float sdlgameController::get_axis_value(int8_t controller, uint8_t axis, ct_form
m_frame_time = 0.005f; // to trap potential errors.
normalizer = ctldev->normalizer[axis] * m_frame_time;
nullzone = MOUSE_DEADZONE;
if (axis == CT_X_AXIS) {
// mprintf_at(4, 4, 0, "m_dX:%03d normal:%03.2f", (int)axisval, normalizer);
}
} else {
normalizer = ctldev->normalizer[axis];

View File

@ -1562,11 +1562,9 @@ void CMainFrame::OnActivateApp(BOOL bActive, HTASK hTask) {
if (bActive) {
theApp.resume();
mprintf_at(2,0,0, "App Active ");
}
else {
theApp.pause();
mprintf_at(2,0,0, "App Inactive");
}
((oeLnxApplication *)Descent)->run_handler(this->m_hWnd, WM_ACTIVATEAPP, (unsigned)bActive, 0);

View File

@ -1788,8 +1788,6 @@ void CTerrainDialog::OnTerrainOcclusion() {
int end_x = dest_x * OCCLUSION_SIZE;
int dest_occlusion_index = dest_z * OCCLUSION_SIZE + dest_x;
mprintf_at(2, 5, 0, "Count=%7d", count++);
if (dest_occlusion_index == src_occlusion_index) {
// This is us!
int occ_byte = dest_occlusion_index / 8;

View File

@ -1772,7 +1772,6 @@ void DoTerrainDynamicTable() {
for (j = 0; j < Terrain_sky.num_satellites; j++) {
raynum++;
mprintf_at(2, 4, 0, "Ray=%d ", raynum);
if (gp.y > pos.y)
continue;
@ -1804,8 +1803,6 @@ void ComputeTerrainSpeedTable() {
pos.y = (Terrain_seg[tseg].y) + .001;
raynum++;
if ((raynum % 1000) == 0)
mprintf_at(2, 4, 0, "Ray=%d ", raynum);
for (j = 0; j < Terrain_sky.num_satellites; j++)
TerrainLightSpeedup[j][tseg] = ShootRayForTerrainLight(&pos, &Terrain_sky.satellite_vectors[j], tseg);
@ -2279,7 +2276,6 @@ Dynamic lighting takes a long time)","Question",MB_YESNO))==IDYES) do_dynamic=1;
for (j=0;j<Terrain_sky.num_satellites;j++)
{
raynum++;
mprintf_at(2,4,0,"Ray=%d ",raynum);
int answer1,answer2;
answer1=ShootRayForTerrainLight (&pos1,&Terrain_sky.satellite_vectors[j],tseg);

View File

@ -75,7 +75,6 @@ void RenderTexFrame(grViewport *my_viewport) {
newtime = time(NULL);
if (newtime != oldtime) {
mprintf_at(1, 2, 0, "%d FPS ", framecount);
oldtime = newtime;
framecount = 0;
}

View File

@ -1031,11 +1031,6 @@ void CalculateFormFactorsRaycast() {
for (t = 0; t < dest_num_elements; t++) {
rad_element *dest_element = &dest_surf->elements[t];
if ((raycount % 1000) == 0) {
mprintf_at(2, 4, 0, "Ray=%d ", raycount);
mprintf_at(2, 5, 0, "Ignore=%d ", Rays_ignored);
}
raycount++;
if (ignore)
@ -1104,8 +1099,5 @@ void CalculateFormFactorsRaycast() {
if (rad_MaxSurface->surface_type == ST_ROOM && Calculate_specular_lighting)
CheckToUpdateSpecularFace(dest_surf, &Current_max_specular_color, NULL);
// mprintf_at(2,4,0,"Ray=%d ",raycount);
// mprintf_at(2,5,0,"Ignore=%d ",Rays_ignored);
}
}

View File

@ -361,9 +361,6 @@ void EndHemicubeDrawing(int face) {
EndEditorFrame();
mprintf_at(2, 4, 0, "CTF=%d ", Cracks_this_frame);
mprintf_at(2, 5, 0, "CTS=%d ", Cracks_this_side);
if (Show_rad_progress) {
int i, t;
int key;

View File

@ -277,8 +277,6 @@ void UpdateUnsentValues() {
else
rad_Convergence = 0.0;
mprintf_at(2, 3, 0, "Left=%f ", rad_Convergence);
if (timer_GetTime() - last_report_time > 10.0) {
mprintf(0, "Percentage left=%f\n", rad_Convergence);
last_report_time = timer_GetTime();
@ -312,7 +310,6 @@ void CalculateRadiosity() {
rad_DoneCalculating = 1;
break;
}
mprintf_at(2, 2, 0, "Lightcount=%d ", rad_StepCount);
DoRadiosityIteration();

View File

@ -1861,11 +1861,6 @@ void opengl_Flip() {
RTP_INCRVALUE(texture_uploads, OpenGL_uploads);
RTP_INCRVALUE(polys_drawn, OpenGL_polys_drawn);
mprintf_at(1, 1, 0, "Uploads=%d Polys=%d Verts=%d ", OpenGL_uploads, OpenGL_polys_drawn,
OpenGL_verts_processed);
mprintf_at(1, 2, 0, "Sets= 0:%d 1:%d 2:%d 3:%d ", OpenGL_sets_this_frame[0], OpenGL_sets_this_frame[1],
OpenGL_sets_this_frame[2], OpenGL_sets_this_frame[3]);
mprintf_at(1, 3, 0, "Sets= 4:%d 5:%d ", OpenGL_sets_this_frame[4], OpenGL_sets_this_frame[5]);
for (i = 0; i < 10; i++)
OpenGL_sets_this_frame[i] = 0;
#endif

View File

@ -1427,7 +1427,6 @@ void nw_WorkReliable(uint8_t *data, int len, network_address *naddr) {
qsort(sort_ping, MAX_PING_HISTORY, sizeof(float), nw_PingCompare);
rsocket->mean_ping = ((sort_ping[MAX_PING_HISTORY / 2] + sort_ping[(MAX_PING_HISTORY / 2) + 1])) / 2;
// mprintf_at(2,i+1,0,"Ping: %f ",rsocket->mean_ping);
}
rsocket->ping_pos++;
if (rsocket->ping_pos >= MAX_PING_HISTORY) {
@ -2382,7 +2381,6 @@ int nw_SendWithID(uint8_t id, uint8_t *data, int len, network_address *who_to) {
int my_comp_ratio = (float) ((float)Uncompressed_outgoing_data_len/(float)Compressed_outgoing_data_len);
mprintf_at(2,1,0,"Compression: %d%% ",my_comp_ratio);
*/
if (!Sockets_initted) {
LOG_ERROR << "Network ==> Socket not inited in nw_Send";

View File

@ -480,7 +480,6 @@ void ui_DoCursor() {
u0 = (float)(UI_MOUSE_HOTX - UI_input.mx) / (float)cur_w;
if (UI_input.my < UI_MOUSE_HOTY)
v0 = (float)(UI_MOUSE_HOTY - UI_input.my) / (float)cur_h;
// mprintf_at(1,5,30,"mx=%d my=%d ", UI_input.mx,UI_input.my);
rend_DrawScaledBitmap(UI_input.mx - UI_MOUSE_HOTX, UI_input.my - UI_MOUSE_HOTY,
UI_input.mx + (int)((float)cur_w * u1) - UI_MOUSE_HOTX,
UI_input.my + (int)((float)cur_h * v1) - UI_MOUSE_HOTY, UI_cursor_bm, u0, v0, u1, v1);