1 /* 2 * Copyright 2011-2023, Haiku, Inc. All Rights Reserved. 3 * Distributed under the terms of the MIT License. 4 * 5 * Authors: 6 * Alexander von Gluck, kallisti5@unixzen.com 7 */ 8 9 10 #include <KernelExport.h> 11 #include <stdio.h> 12 13 #include "video_configuration.h" 14 15 16 const char* 17 get_connector_name(uint32 connector) 18 { 19 switch (connector) { 20 case VIDEO_CONNECTOR_VGA: 21 return "VGA"; 22 case VIDEO_CONNECTOR_DVII: 23 return "DVI-I (Digital and Analog)"; 24 case VIDEO_CONNECTOR_DVID: 25 return "DVI-D (Digital Only)"; 26 case VIDEO_CONNECTOR_DVIA: 27 return "DVI-A (Analog Only)"; 28 case VIDEO_CONNECTOR_COMPOSITE: 29 return "Composite"; 30 case VIDEO_CONNECTOR_SVIDEO: 31 return "S-Video"; 32 case VIDEO_CONNECTOR_LVDS: 33 return "LVDS Panel"; 34 case VIDEO_CONNECTOR_COMPONENT: 35 return "Component"; 36 case VIDEO_CONNECTOR_9DIN: 37 return "9-Pin DIN"; 38 case VIDEO_CONNECTOR_DP: 39 return "DisplayPort"; 40 case VIDEO_CONNECTOR_EDP: 41 return "Embedded DisplayPort"; 42 case VIDEO_CONNECTOR_HDMIA: 43 return "HDMI A"; 44 case VIDEO_CONNECTOR_HDMIB: 45 return "HDMI B"; 46 case VIDEO_CONNECTOR_TV: 47 return "TV"; 48 case VIDEO_CONNECTOR_USBC: 49 return "USB C"; 50 case VIDEO_CONNECTOR_UNKNOWN: 51 return "Unknown"; 52 } 53 return "Undefined"; 54 } 55 56 57 const char* 58 get_encoder_name(uint32 encoder) 59 { 60 switch (encoder) { 61 case VIDEO_ENCODER_NONE: 62 return "None"; 63 case VIDEO_ENCODER_DAC: 64 return "DAC"; 65 case VIDEO_ENCODER_TMDS: 66 return "TMDS"; 67 case VIDEO_ENCODER_LVDS: 68 return "LVDS"; 69 case VIDEO_ENCODER_TVDAC: 70 return "TV DAC"; 71 } 72 return "Undefined"; 73 } 74