diff --git a/impeller/toolkit/glvk/trampoline.cc b/impeller/toolkit/glvk/trampoline.cc index 83ac20a14bbb8..eda8595a0c5e1 100644 --- a/impeller/toolkit/glvk/trampoline.cc +++ b/impeller/toolkit/glvk/trampoline.cc @@ -272,12 +272,12 @@ bool Trampoline::BlitTextureOpenGLToVulkan( gl.BufferData(GL_ARRAY_BUFFER, sizeof(kVertData), kVertData, GL_STATIC_DRAW); gl.EnableVertexAttribArray(kAttributeIndexPosition); gl.EnableVertexAttribArray(kAttributeIndexTexCoord); - gl.VertexAttribPointer(kAttributeIndexPosition, 2, GL_FLOAT, GL_FALSE, - sizeof(VertexData), - (void*)offsetof(VertexData, position)); - gl.VertexAttribPointer(kAttributeIndexTexCoord, 2, GL_FLOAT, GL_FALSE, - sizeof(VertexData), - (void*)offsetof(VertexData, tex_coord)); + gl.VertexAttribPointer( + kAttributeIndexPosition, 2, GL_FLOAT, GL_FALSE, sizeof(VertexData), + reinterpret_cast(offsetof(VertexData, position))); + gl.VertexAttribPointer( + kAttributeIndexTexCoord, 2, GL_FLOAT, GL_FALSE, sizeof(VertexData), + reinterpret_cast(offsetof(VertexData, tex_coord))); gl.ActiveTexture(GL_TEXTURE0); gl.BindTexture(src_texture.target, src_texture.texture); diff --git a/shell/platform/android/image_external_texture_gl_skia.cc b/shell/platform/android/image_external_texture_gl_skia.cc index 3d9d6adb34ddb..cc2799f407de1 100644 --- a/shell/platform/android/image_external_texture_gl_skia.cc +++ b/shell/platform/android/image_external_texture_gl_skia.cc @@ -36,7 +36,7 @@ void ImageExternalTextureGLSkia::BindImageToTexture( } glBindTexture(GL_TEXTURE_EXTERNAL_OES, tex); glEGLImageTargetTexture2DOES(GL_TEXTURE_EXTERNAL_OES, - (GLeglImageOES)image.get().image); + static_cast(image.get().image)); } sk_sp ImageExternalTextureGLSkia::CreateDlImage( diff --git a/shell/platform/android/platform_view_android_jni_impl.cc b/shell/platform/android/platform_view_android_jni_impl.cc index 7ad6f075115e0..8977d21ffb0cd 100644 --- a/shell/platform/android/platform_view_android_jni_impl.cc +++ b/shell/platform/android/platform_view_android_jni_impl.cc @@ -1358,11 +1358,11 @@ double PlatformViewAndroidJNIImpl::FlutterViewGetScaledFontSize( return -3; } - const jfloat scaledSize = - env->CallFloatMethod(java_object.obj(), g_get_scaled_font_size_method, - (jfloat)font_size, (jint)configuration_id); + const jfloat scaledSize = env->CallFloatMethod( + java_object.obj(), g_get_scaled_font_size_method, + static_cast(font_size), static_cast(configuration_id)); FML_CHECK(fml::jni::CheckException(env)); - return (double)scaledSize; + return static_cast(scaledSize); } void PlatformViewAndroidJNIImpl::FlutterViewUpdateSemantics( diff --git a/shell/platform/linux/fl_renderer.cc b/shell/platform/linux/fl_renderer.cc index 90b3c4d95cc06..600dab0665bc2 100644 --- a/shell/platform/linux/fl_renderer.cc +++ b/shell/platform/linux/fl_renderer.cc @@ -324,9 +324,9 @@ static void fl_renderer_init(FlRenderer* self) { fl_renderer_get_instance_private(self)); priv->views = g_hash_table_new_full(g_direct_hash, g_direct_equal, nullptr, free_weak_ref); - priv->framebuffers_by_view_id = - g_hash_table_new_full(g_direct_hash, g_direct_equal, nullptr, - (GDestroyNotify)g_ptr_array_unref); + priv->framebuffers_by_view_id = g_hash_table_new_full( + g_direct_hash, g_direct_equal, nullptr, + reinterpret_cast(g_ptr_array_unref)); } void fl_renderer_set_engine(FlRenderer* self, FlEngine* engine) { diff --git a/shell/platform/linux/testing/fl_mock_binary_messenger.cc b/shell/platform/linux/testing/fl_mock_binary_messenger.cc index a2d37b71580db..93e21fbdb6819 100644 --- a/shell/platform/linux/testing/fl_mock_binary_messenger.cc +++ b/shell/platform/linux/testing/fl_mock_binary_messenger.cc @@ -320,19 +320,22 @@ static void fl_mock_binary_messenger_iface_init( } static void fl_mock_binary_messenger_init(FlMockBinaryMessenger* self) { - self->handlers = g_hash_table_new_full(g_str_hash, g_str_equal, g_free, - (GDestroyNotify)handler_free); + self->handlers = + g_hash_table_new_full(g_str_hash, g_str_equal, g_free, + reinterpret_cast(handler_free)); self->mock_channels = g_hash_table_new_full( - g_str_hash, g_str_equal, g_free, (GDestroyNotify)mock_channel_free); - self->mock_message_channels = - g_hash_table_new_full(g_str_hash, g_str_equal, g_free, - (GDestroyNotify)mock_message_channel_free); - self->mock_method_channels = - g_hash_table_new_full(g_str_hash, g_str_equal, g_free, - (GDestroyNotify)mock_method_channel_free); + g_str_hash, g_str_equal, g_free, + reinterpret_cast(mock_channel_free)); + self->mock_message_channels = g_hash_table_new_full( + g_str_hash, g_str_equal, g_free, + reinterpret_cast(mock_message_channel_free)); + self->mock_method_channels = g_hash_table_new_full( + g_str_hash, g_str_equal, g_free, + reinterpret_cast(mock_method_channel_free)); self->mock_error_channels = g_hash_table_new_full( - g_str_hash, g_str_equal, g_free, (GDestroyNotify)mock_error_channel_free); + g_str_hash, g_str_equal, g_free, + reinterpret_cast(mock_error_channel_free)); } FlMockBinaryMessenger* fl_mock_binary_messenger_new() {