Skip to content

Instantly share code, notes, and snippets.

View nezticle's full-sized avatar

Andy Nichols nezticle

View GitHub Profile
@nezticle
nezticle / fixExternalMonitorColors.md
Created March 4, 2024 07:40
macOS: Fix changed colors when using extended monitor

TL;DR: Disable True Tone

So the situation is that you have a macOS laptop (MBA, MBP) and you want to have 2 screens (the laptop screen as well as an external screen). If you just use the external screen with the laptop closed, the brightness and colors look a particular way (good). When you open the laptop lid and the configuration switches to extended mode, the colors on the external monitor become dulled and muted.

The reason for this is the "True Tone" feature. You need to disable it, by toggleing the "True Tone" feature to off in the Display Settings for the built-in screen (not the external one). When you do this, the external/extended monitor will go back to looking as it did before you opened the laptop.

@nezticle
nezticle / tildeOnMac.md
Last active March 15, 2024 09:26
How to get Tilde (~) to work correctly in macOS

This is to solve an issue where you use a non-apple european keyboard with the US keyboard layout in macOS where the Tilde key is in the wrong place.

This is the process for the Logitec MX Keys Mini

  • Connect the keyboard (bluetooth)
  • Make sure the keyboard is in PC mode (hold fn + p for 3 seconds)
  • Go through the keyboard wizard and at the end select the European ISO... layout
  • Switch the keyboard to Mac mode (hold fn + o for 3 seconds)
  • Tilde should work

If this doesn't work:

@nezticle
nezticle / 0001-DEBUG-Output-BackToFront-Sorting.patch
Created May 16, 2018 11:33
Debug Back To Front sorting in Qt3D
From 0e8ec609def938ba5dc816073605b66cc213c0b9 Mon Sep 17 00:00:00 2001
From: Andy Nichols <andy.nichols@qt.io>
Date: Wed, 16 May 2018 13:32:04 +0200
Subject: [PATCH] DEBUG: Output BackToFront Sorting
Obviously dont merge this...
Change-Id: I5227419e0692192ff153a0c272ab00f4994ad865
---
src/render/renderers/opengl/renderer/renderview.cpp | 15 ++++++++++++++-
@nezticle
nezticle / fixQualifiedLibraryPaths.sh
Last active February 23, 2017 17:34
Change absolute lib paths to relative ones (for creating sysroots)
#!/bin/bash
#This script is ugly, feel free to fix it
if [ "$#" -ne 2 ]; then
echo "usage ./cmd target-rootfs machine-eabi"
exit -1
fi
#passed args
ROOTFS=$1
import QtQuick 2.1
import QtQuick.Controls 1.0
import QtQuick.Window 2.0
ApplicationWindow {
title: qsTr("Key Event Viewer")
width: 640
height: 480
Text {
@nezticle
nezticle / gist:6154831
Created August 5, 2013 10:05
wayland xcomposite breakage
cd qwayland-xcomposite-egl/ && ( test -e Makefile || /home/nezticle/Code/Wayland/qt5/qtbase/bin/qmake /home/nezticle/Code/Wayland/qt5/qtwayland/src/plugins/platforms/qwayland-xcomposite-egl/qwayland-xcomposite-egl.pro CONFIG+=wayland-compositor -o Makefile ) && /usr/bin/make -f Makefile
make[4]: Entering directory `/home/nezticle/Code/Wayland/qt5/qtwayland/src/plugins/platforms/qwayland-xcomposite-egl'
g++ -c -pipe -g -fvisibility=hidden -fvisibility-inlines-hidden -std=c++0x -fno-exceptions -Wall -W -D_REENTRANT -fPIC -DQT_NO_XKB -DQT_WAYLAND_GL_SUPPORT -DQ_FONTCONFIGDATABASE -DQT_NO_EXCEPTIONS -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -DQT_PLUGIN -DQT_PLATFORMSUPPORT_LIB -DQT_DBUS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I/home/nezticle/Code/Wayland/qt5/qtbase/mkspecs/linux-g++ -I. -I../../../shared -I../wayland_common -I../xcomposite_share -I/home/nezticle/Code/Wayland/qt5/qtbase/include -I/home/nezticle/Code/Wayland/qt5/qtbase/include/libdrm -I/home/nezticle/Code/Wayland/qt5/qtbase/include -I/home/nezticle/Code/W
@nezticle
nezticle / greenisland.txt
Created January 3, 2013 11:09
Greenisland Output
EGL version: 1.4 (DRI2)
EGL vendor: Mesa Project
EGL client APIs: OpenGL OpenGL_ES2
EGL extensions: EGL_MESA_drm_image EGL_WL_bind_wayland_display EGL_KHR_image_base EGL_KHR_image_pixmap EGL_KHR_image EGL_KHR_gl_renderbuffer_image EGL_KHR_surfaceless_context EGL_KHR_create_context EGL_NOK_swap_region EGL_NOK_texture_from_pixmap EGL_NV_post_sub_buffer
GL version: OpenGL ES 2.0 Mesa 9.0.1 (git-0ac9029)
GLSL version: OpenGL ES GLSL ES 1.0.16
GL vendor: Intel Open Source Technology Center
GL renderer: Mesa DRI Intel(R) Sandybridge Mobile
GL extensions: GL_EXT_blend_minmax GL_EXT_multi_draw_arrays GL_EXT_texture_filter_anisotropic GL_EXT_texture_compression_dxt1 GL_EXT_texture_format_BGRA8888 GL_OES_compressed_ETC1_RGB8_texture GL_OES_depth24 GL_OES_element_index_uint GL_OES_fbo_render_mipmap GL_OES_mapbuffer GL_OES_rgb8_rgba8 GL_OES_standard_derivatives GL_OES_stencil8 GL_OES_texture_3D GL_OES_texture_npot GL_OES_EGL_image GL_OES_depth_texture GL_OES_packed_depth_stencil GL_EXT_texture_type_2_10_10_10_REV GL_A
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 333dc15..a08cd55 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -6,7 +6,7 @@ cmake_minimum_required(VERSION 2.8.9)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
# Instruct CMake to run moc automatically when needed
-set(CMAKE_INCLUDE_CURRENT_DIR ON)
+set(CMAKE_AUTOMOC ON)
@nezticle
nezticle / BuildRoot-RaspberryPi.diff
Last active December 10, 2015 05:48
Diff between BuildRoot 2012.11 and RaspberryPi-Buildroot project
diff --git a/README.md b/README.md
new file mode 100644
index 0000000..4bcccb9
--- /dev/null
+++ b/README.md
@@ -0,0 +1,72 @@
+# RaspberryPi-Buildroot (aka the Bsquask SDK) #
+
+The objective of this project is to provide an SDK and root file system for the Raspberry Pi that is lightweight and takes full advantage of the hardware available. The resulting image produced is small Linux distribution known as Bsquask.
+