mirror of
https://github.com/brunoherbelin/vimix.git
synced 2025-12-05 15:30:00 +01:00
Compilation fix OSX
Pedantic warning CLang for 64bits compiler.
This commit is contained in:
@@ -49,10 +49,10 @@ unsigned long IpEndpointName::GetHostByName( const char *s )
|
||||
|
||||
void IpEndpointName::AddressAsString( char *s ) const
|
||||
{
|
||||
if( address == ANY_ADDRESS ){
|
||||
std::sprintf( s, "<any>" );
|
||||
if( address == ANY_ADDRESS ){
|
||||
std::snprintf( s, IpEndpointName::ADDRESS_STRING_LENGTH, "<any>" );
|
||||
}else{
|
||||
std::sprintf( s, "%d.%d.%d.%d",
|
||||
std::snprintf( s, IpEndpointName::ADDRESS_STRING_LENGTH, "%d.%d.%d.%d",
|
||||
(int)((address >> 24) & 0xFF),
|
||||
(int)((address >> 16) & 0xFF),
|
||||
(int)((address >> 8) & 0xFF),
|
||||
@@ -65,9 +65,9 @@ void IpEndpointName::AddressAndPortAsString( char *s ) const
|
||||
{
|
||||
if( port == ANY_PORT ){
|
||||
if( address == ANY_ADDRESS ){
|
||||
std::sprintf( s, "<any>:<any>" );
|
||||
std::snprintf( s, IpEndpointName::ADDRESS_AND_PORT_STRING_LENGTH, "<any>:<any>" );
|
||||
}else{
|
||||
std::sprintf( s, "%d.%d.%d.%d:<any>",
|
||||
std::snprintf( s, IpEndpointName::ADDRESS_AND_PORT_STRING_LENGTH, "%d.%d.%d.%d:<any>",
|
||||
(int)((address >> 24) & 0xFF),
|
||||
(int)((address >> 16) & 0xFF),
|
||||
(int)((address >> 8) & 0xFF),
|
||||
@@ -75,9 +75,9 @@ void IpEndpointName::AddressAndPortAsString( char *s ) const
|
||||
}
|
||||
}else{
|
||||
if( address == ANY_ADDRESS ){
|
||||
std::sprintf( s, "<any>:%d", port );
|
||||
std::snprintf( s, IpEndpointName::ADDRESS_AND_PORT_STRING_LENGTH, "<any>:%d", port );
|
||||
}else{
|
||||
std::sprintf( s, "%d.%d.%d.%d:%d",
|
||||
std::snprintf( s, IpEndpointName::ADDRESS_AND_PORT_STRING_LENGTH, "%d.%d.%d.%d:%d",
|
||||
(int)((address >> 24) & 0xFF),
|
||||
(int)((address >> 16) & 0xFF),
|
||||
(int)((address >> 8) & 0xFF),
|
||||
|
||||
@@ -1275,7 +1275,12 @@ void Control::keyboardCalback(GLFWwindow* w, int key, int, int action, int mods)
|
||||
}
|
||||
Control::manager().input_access_.unlock();
|
||||
}
|
||||
#if defined(APPLE)
|
||||
else if ( w != Rendering::manager().mainWindow().window() &&
|
||||
key == GLFW_KEY_F && action == GLFW_PRESS && mods == GLFW_MOD_SUPER )
|
||||
#else
|
||||
else if ( key == GLFW_KEY_F && action == GLFW_PRESS && mods == GLFW_MOD_CONTROL )
|
||||
#endif
|
||||
{
|
||||
Rendering::manager().window(w)->toggleFullscreen();
|
||||
}
|
||||
|
||||
@@ -1023,7 +1023,7 @@ void ImGuiToolkit::RenderTimelineBPM (ImVec2 min_bbox, ImVec2 max_bbox, double t
|
||||
{
|
||||
// beat count label
|
||||
guint64 ticklabel = tick / time_beat;
|
||||
ImFormatString(text_buf, IM_ARRAYSIZE(text_buf), "%ld", ticklabel);
|
||||
ImFormatString(text_buf, IM_ARRAYSIZE(text_buf), "%lu", (unsigned long) ticklabel);
|
||||
ImVec2 label_size = ImGui::CalcTextSize(text_buf, NULL);
|
||||
ImVec2 mini = ImVec2( pos.x - label_size.x / 2.f, pos.y);
|
||||
ImVec2 maxi = ImVec2( pos.x + label_size.x / 2.f, pos.y);
|
||||
|
||||
@@ -20,7 +20,6 @@
|
||||
#include <glm/gtc/type_ptr.hpp>
|
||||
#include <glm/gtc/matrix_access.hpp>
|
||||
#include <glm/gtc/matrix_transform.hpp>
|
||||
#include <glm/gtx/string_cast.hpp>
|
||||
#include <glm/gtx/vector_angle.hpp>
|
||||
|
||||
#include "Decorations.h"
|
||||
|
||||
@@ -29,7 +29,6 @@
|
||||
|
||||
#include <glm/gtc/type_ptr.hpp>
|
||||
#define GLM_ENABLE_EXPERIMENTAL
|
||||
#include <glm/gtx/string_cast.hpp>
|
||||
|
||||
#include "Resource.h"
|
||||
#include "Log.h"
|
||||
|
||||
@@ -299,7 +299,7 @@ void TimerMetronomeWindow::Render()
|
||||
ImGuiToolkit::PushFont(ImGuiToolkit::FONT_BOLD);
|
||||
|
||||
guint64 lap = (time_-start_time_hand_)/duration_hand_;
|
||||
snprintf(text_buf, 24, "%ld turn%s", lap, lap > 1 ? "s" : " " );
|
||||
snprintf(text_buf, 24, "%lu turn%s", (unsigned long) lap, lap > 1 ? "s" : " " );
|
||||
label_size = ImGui::CalcTextSize(text_buf, NULL);
|
||||
ImGui::SetCursorScreenPos(circle_center + ImVec2(0.f, circle_radius * -0.7f) - label_size/2);
|
||||
ImGui::Text("%s", text_buf);
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
#define WINDOW_TOOLBOX_DIST_TO_BORDER 10.f
|
||||
|
||||
#include <iostream>
|
||||
#include <sstream>
|
||||
#include <iomanip>
|
||||
#include <sstream>
|
||||
#include <fstream>
|
||||
@@ -3545,7 +3546,7 @@ void Navigator::RenderNewPannel()
|
||||
ImGui::Text("Codec :");ImGui::SameLine(150);
|
||||
ImGui::Text("%s", VideoRecorder::profile_name[ _video_recorder.profile() ] );
|
||||
ImGui::Text("Frames :");ImGui::SameLine(150);
|
||||
ImGui::Text("%ld / %ld", _video_recorder.numFrames(), _video_recorder.files().size() );
|
||||
ImGui::Text("%lu / %lu", (unsigned long)_video_recorder.numFrames(), _video_recorder.files().size() );
|
||||
|
||||
ImGui::Spacing();
|
||||
ImGui::ProgressBar(_video_recorder.progress());
|
||||
|
||||
Reference in New Issue
Block a user