Lypheo / vs-placebo

libplacebo-based debanding, scaling and color mapping plugin for VapourSynth
GNU Lesser General Public License v2.1
73 stars 13 forks source link

Shader compiling errors #42

Open Amaraldo opened 1 year ago

Amaraldo commented 1 year ago

Trying to run the awsmfunc.MapDolbyVision function returns shader errors. I recently built libplacebo from the latest git version and rebuilt vs-placebo to be sure but the same errors persist. Perhaps the issue is specific to M1 Mac systems?

ffmpeg output [mvk-error] VK_ERROR_INITIALIZATION_FAILED: Shader library compile failed (Error code 3): program_source:9:51: error: use of undeclared identifier '_16_tmp'; did you mean '_15_tmp'? constant float _33 = is_function_constant_defined(_16_tmp) ? _16_tmp : 1.0; ^~~~~~~ _15_tmp /System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/31001/Libraries/lib/clang/31001.720/include/metal/metal_types:159:78: note: expanded from macro 'is_function_constant_defined' #define is_function_constant_defined(c) __metal_is_function_constant_defined(c) ^ program_source:6:16: note: '_15_tmp' declared here constant float _15_tmp [[function_constant(1)]]; ^ program_source:9:62: error: use of undeclared identifier '_16_tmp'; did you mean '_15_tmp'? constant float _33 = is_function_constant_defined(_16_tmp) ? _16_tmp : 1.0; ^~~~~~~ _15_tmp program_source:6:16: note: '_15_tmp' declared here constant float _15_tmp [[function_constant(1)]]; ^ . [mvk-error] VK_ERROR_INVALID_SHADER_NV: Fragment shader function could not be compiled into pipeline. See previous logged error. vk_recreate_pipelines(vk, pass, has_spec, VK_NULL_HANDLE, pipe): VK_ERROR_INVALID_SHADER_NV (../src/vulkan/gpu_pass.c:586) vertex shader source: [ 1] #version 450 [ 2] #extension GL_KHR_shader_subgroup_basic : enable [ 3] #extension GL_KHR_shader_subgroup_vote : enable [ 4] #extension GL_KHR_shader_subgroup_arithmetic : enable [ 5] #extension GL_KHR_shader_subgroup_ballot : enable [ 6] #extension GL_KHR_shader_subgroup_shuffle : enable [ 7] #extension GL_KHR_shader_subgroup_clustered : enable [ 8] #extension GL_KHR_shader_subgroup_quad : enable [ 9] #extension GL_ARB_texture_gather : enable [ 10] layout(constant_id=0) const float _4_const = 1; [ 11] layout(constant_id=1) const float _8004_const = 1; [ 12] layout(binding=0) uniform sampler2D _2_src_tex; [ 13] layout(binding=1) uniform sampler2D _8002_src_tex; [ 14] layout(location=0) in vec2 _7_va; [ 15] layout(location=0) out vec2 _3_tex_coord; [ 16] layout(location=1) in vec2 _8_va; [ 17] layout(location=1) out vec2 _8003_tex_coord; [ 18] layout(location=2) in vec2 _9_va; [ 19] void main() { [ 20] _3_tex_coord = _7_va; [ 21] _8003_tex_coord = _8_va; [ 22] vec2 va_pos = _9_va; [ 23] gl_Position = vec4(va_pos, 0.0, 1.0); [ 24] } fragment shader source: [ 1] #version 450 [ 2] #extension GL_KHR_shader_subgroup_basic : enable [ 3] #extension GL_KHR_shader_subgroup_vote : enable [ 4] #extension GL_KHR_shader_subgroup_arithmetic : enable [ 5] #extension GL_KHR_shader_subgroup_ballot : enable [ 6] #extension GL_KHR_shader_subgroup_shuffle : enable [ 7] #extension GL_KHR_shader_subgroup_clustered : enable [ 8] #extension GL_KHR_shader_subgroup_quad : enable [ 9] #extension GL_ARB_texture_gather : enable [ 10] layout(constant_id=0) const float _4_const = 1; [ 11] layout(constant_id=1) const float _8004_const = 1; [ 12] layout(binding=0) uniform sampler2D _2_src_tex; [ 13] layout(binding=1) uniform sampler2D _8002_src_tex; [ 14] layout(location=0) in vec2 _3_tex_coord; [ 15] layout(location=1) in vec2 _8003_tex_coord; [ 16] layout(location=0) out vec4 out_color; [ 17] [ 18] vec4 _8001_main() { [ 19] // pl_shader_sample_direct [ 20] vec4 color = vec4(_8004_const) * textureLod(_8002_src_tex, _8003_tex_coord, 0.0); [ 21] return color; [ 22] } [ 23] [ 24] vec4 _1_main() { [ 25] // pl_shader_sample_direct [ 26] vec4 color = vec4(_4_const) * textureLod(_2_src_tex, _3_tex_coord, 0.0); [ 27] { [ 28] vec4 tmp = _8001_main(); [ 29] color[1] = tmp[0]; [ 30] } [ 31] return color; [ 32] } [ 33] [ 34] void main() { [ 35] out_color = _1_main(); [ 36] } Backtrace: # 0 1 libplacebo.278.dylib 0x000000010792e078 pl_pass_create + 1520 # 1 2 libplacebo.278.dylib 0x00000001079233d4 finalize_pass + 5936 # 2 3 libplacebo.278.dylib 0x00000001079218a0 pl_dispatch_finish + 980 # 3 4 libplacebo.278.dylib 0x000000010793b7ec _img_tex + 124 # 4 5 libplacebo.278.dylib 0x00000001079361c4 pass_read_image + 2460 # 5 6 libplacebo.278.dylib 0x000000010793421c pl_render_image + 372 # 6 7 libvs_placebo.dylib 0x00000001070f5e1c vspl_tonemap_filter + 684 # 7 8 libvs_placebo.dylib 0x00000001070f7194 VSPlaceboTMGetFrame + 2524 # 8 9 libvapoursynth.dylib 0x0000000101a85464 _ZN6VSNode16getFrameInternalEiiP14VSFrameContext + 156 # 9 10 libvapoursynth.dylib 0x0000000101a969e4 _ZN12VSThreadPool8runTasksERNSt3__16atomicIbEE + 736 # 10 11 libvapoursynth.dylib 0x0000000101a98490 _ZNSt3__1L14__thread_proxyINS_5tupleIJNS_10unique_ptrINS_15__thread_structENS_14default_deleteIS3_EEEEPFvP12VSThreadPoolRNS_6atomicIbEEES8_NS_17reference_wrapperISA_EEEEEEEPvSH_ + 48 # 11 12 libsystem_pthread.dylib 0x0000000187b8bfa8 _pthread_start + 148 # 12 13 libsystem_pthread.dylib 0x0000000187b86da0 thread_start + 8 Failed creating render pass for dispatch Failed dispatching intermediate pass! Failed dispatching plane merging shader, disabling FBOs! Failed rendering image! [mvk-error] VK_ERROR_INITIALIZATION_FAILED: Shader library compile failed (Error code 3): program_source:15:51: error: use of undeclared identifier '_20_tmp'; did you mean '_19_tmp'? constant float _61 = is_function_constant_defined(_20_tmp) ? _20_tmp : 1.0; ^~~~~~~ _19_tmp /System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/31001/Libraries/lib/clang/31001.720/include/metal/metal_types:159:78: note: expanded from macro 'is_function_constant_defined' #define is_function_constant_defined(c) __metal_is_function_constant_defined(c) ^ program_source:6:16: note: '_19_tmp' declared here constant float _19_tmp [[function_constant(2)]]; ^ program_source:15:62: error: use of undeclared identifier '_20_tmp' constant float _61 = is_function_constant_defined(_20_tmp) ? _20_tmp : 1.0; ^ . [mvk-error] VK_ERROR_INVALID_SHADER_NV: Fragment shader function could not be compiled into pipeline. See previous logged error. vk_recreate_pipelines(vk, pass, has_spec, VK_NULL_HANDLE, pipe): VK_ERROR_INVALID_SHADER_NV (../src/vulkan/gpu_pass.c:586) vertex shader source: [ 1] #version 450 [ 2] #extension GL_KHR_shader_subgroup_basic : enable [ 3] #extension GL_KHR_shader_subgroup_vote : enable [ 4] #extension GL_KHR_shader_subgroup_arithmetic : enable [ 5] #extension GL_KHR_shader_subgroup_ballot : enable [ 6] #extension GL_KHR_shader_subgroup_shuffle : enable [ 7] #extension GL_KHR_shader_subgroup_clustered : enable [ 8] #extension GL_KHR_shader_subgroup_quad : enable [ 9] #extension GL_ARB_texture_gather : enable [ 10] layout(std430, push_constant) uniform PushC { [ 11] layout(offset=0) float _7_lo; [ 12] layout(offset=4) float _8_hi; [ 13] layout(offset=16) vec4 _9_coeffs; [ 14] layout(offset=32) float _b_lo; [ 15] layout(offset=36) float _c_hi; [ 16] layout(offset=48) vec4 _d_coeffs; [ 17] layout(offset=64) float _f_lo; [ 18] layout(offset=68) float _10_hi; [ 19] layout(offset=80) vec3 _12_cmat_c; [ 20] layout(offset=92) float _17_const; [ 21] layout(offset=96) vec3 _28_cmat_c; [ 22] layout(offset=108) float _5_pivots[7]; [ 23] layout(offset=144) vec4 _6_coeffs[8]; [ 24] layout(offset=272) vec4 _a_mmr[6]; [ 25] layout(offset=368) vec4 _e_mmr[6]; [ 26] layout(offset=464) mat3 _11_cmat; [ 27] layout(offset=512) mat3 _13_lms2rgb; [ 28] layout(offset=560) mat3 _14_mat; [ 29] layout(offset=608) mat3 _15_mat; [ 30] layout(offset=656) mat3 _18_mat; [ 31] layout(offset=704) mat3 _26_mat; [ 32] layout(offset=752) mat3 _27_cmat; [ 33] }; [ 34] layout(constant_id=0) const float _2_const = 1; [ 35] layout(constant_id=1) const float _3_const = 1; [ 36] layout(constant_id=2) const float _8004_const = 1; [ 37] layout(constant_id=3) const float _4004_const = 1; [ 38] layout(constant_id=4) const float _c004_const = 1; [ 39] layout(constant_id=5) const float _4_const = 1; [ 40] layout(constant_id=6) const float _16_const = 1; [ 41] layout(constant_id=7) const float _1c_const = 1; [ 42] layout(constant_id=8) const float _1d_const = 1; [ 43] layout(constant_id=9) const float _1f_const = 1; [ 44] layout(constant_id=10) const float _20_const = 1; [ 45] layout(constant_id=11) const float _22_const = 1; [ 46] layout(constant_id=12) const float _23_const = 1; [ 47] layout(constant_id=13) const float _24_const = 1; [ 48] layout(constant_id=14) const float _25_const = 1; [ 49] layout(constant_id=15) const float _29_const = 1; [ 50] layout(binding=0) uniform sampler2D _8002_src_tex; [ 51] layout(binding=1) uniform sampler2D _4002_src_tex; [ 52] layout(binding=2) uniform sampler2D _c002_src_tex; [ 53] layout(binding=3) uniform sampler3D _1a_weights; [ 54] layout(location=0) in vec2 _2d_va; [ 55] layout(location=0) out vec2 _8003_tex_coord; [ 56] layout(location=1) in vec2 _2e_va; [ 57] layout(location=1) out vec2 _4003_tex_coord; [ 58] layout(location=2) in vec2 _2f_va; [ 59] layout(location=2) out vec2 _c003_tex_coord; [ 60] layout(location=3) in vec2 _30_va; [ 61] void main() { [ 62] _8003_tex_coord = _2d_va; [ 63] _4003_tex_coord = _2e_va; [ 64] _c003_tex_coord = _2f_va; [ 65] vec2 va_pos = _30_va; [ 66] gl_Position = vec4(va_pos, 0.0, 1.0); [ 67] } fragment shader source: [ 1] #version 450 [ 2] #extension GL_KHR_shader_subgroup_basic : enable [ 3] #extension GL_KHR_shader_subgroup_vote : enable [ 4] #extension GL_KHR_shader_subgroup_arithmetic : enable [ 5] #extension GL_KHR_shader_subgroup_ballot : enable [ 6] #extension GL_KHR_shader_subgroup_shuffle : enable [ 7] #extension GL_KHR_shader_subgroup_clustered : enable [ 8] #extension GL_KHR_shader_subgroup_quad : enable [ 9] #extension GL_ARB_texture_gather : enable [ 10] layout(std430, push_constant) uniform PushC { [ 11] layout(offset=0) float _7_lo; [ 12] layout(offset=4) float _8_hi; [ 13] layout(offset=16) vec4 _9_coeffs; [ 14] layout(offset=32) float _b_lo; [ 15] layout(offset=36) float _c_hi; [ 16] layout(offset=48) vec4 _d_coeffs; [ 17] layout(offset=64) float _f_lo; [ 18] layout(offset=68) float _10_hi; [ 19] layout(offset=80) vec3 _12_cmat_c; [ 20] layout(offset=92) float _17_const; [ 21] layout(offset=96) vec3 _28_cmat_c; [ 22] layout(offset=108) float _5_pivots[7]; [ 23] layout(offset=144) vec4 _6_coeffs[8]; [ 24] layout(offset=272) vec4 _a_mmr[6]; [ 25] layout(offset=368) vec4 _e_mmr[6]; [ 26] layout(offset=464) mat3 _11_cmat; [ 27] layout(offset=512) mat3 _13_lms2rgb; [ 28] layout(offset=560) mat3 _14_mat; [ 29] layout(offset=608) mat3 _15_mat; [ 30] layout(offset=656) mat3 _18_mat; [ 31] layout(offset=704) mat3 _26_mat; [ 32] layout(offset=752) mat3 _27_cmat; [ 33] }; [ 34] layout(constant_id=0) const float _2_const = 1; [ 35] layout(constant_id=1) const float _3_const = 1; [ 36] layout(constant_id=2) const float _8004_const = 1; [ 37] layout(constant_id=3) const float _4004_const = 1; [ 38] layout(constant_id=4) const float _c004_const = 1; [ 39] layout(constant_id=5) const float _4_const = 1; [ 40] layout(constant_id=6) const float _16_const = 1; [ 41] layout(constant_id=7) const float _1c_const = 1; [ 42] layout(constant_id=8) const float _1d_const = 1; [ 43] layout(constant_id=9) const float _1f_const = 1; [ 44] layout(constant_id=10) const float _20_const = 1; [ 45] layout(constant_id=11) const float _22_const = 1; [ 46] layout(constant_id=12) const float _23_const = 1; [ 47] layout(constant_id=13) const float _24_const = 1; [ 48] layout(constant_id=14) const float _25_const = 1; [ 49] layout(constant_id=15) const float _29_const = 1; [ 50] layout(binding=0) uniform sampler2D _8002_src_tex; [ 51] layout(binding=1) uniform sampler2D _4002_src_tex; [ 52] layout(binding=2) uniform sampler2D _c002_src_tex; [ 53] layout(binding=3) uniform sampler3D _1a_weights; [ 54] layout(location=0) in vec2 _8003_tex_coord; [ 55] layout(location=1) in vec2 _4003_tex_coord; [ 56] layout(location=2) in vec2 _c003_tex_coord; [ 57] layout(location=0) out vec4 out_color; [ 58] [ 59] vec4 _8001_main() { [ 60] // pl_shader_sample_direct [ 61] vec4 color = vec4(_8004_const) * textureLod(_8002_src_tex, _8003_tex_coord, 0.0); [ 62] return color; [ 63] } [ 64] [ 65] vec4 _4001_main() { [ 66] // pl_shader_sample_direct [ 67] vec4 color = vec4(_4004_const) * textureLod(_4002_src_tex, _4003_tex_coord, 0.0); [ 68] return color; [ 69] } [ 70] [ 71] vec4 _c001_main() { [ 72] // pl_shader_sample_direct [ 73] vec4 color = vec4(_c004_const) * textureLod(_c002_src_tex, _c003_tex_coord, 0.0); [ 74] return color; [ 75] } [ 76] [ 77] #define _1b_LUT_SCALE(x) (_1c_const * (x) + _1d_const) [ 78] #define _1e_LUT_SCALE(x) (_1f_const * (x) + _20_const) [ 79] #define _21_LUT_SCALE(x) (_22_const * (x) + _23_const) [ 80] #define _19_lut(pos) (textureLod(_1a_weights, vec3(\ [ 81] _1b_LUT_SCALE(vec3(pos).x)\ [ 82] ,_1e_LUT_SCALE(vec3(pos).y)\ [ 83] ,_21_LUT_SCALE(vec3(pos).z)\ [ 84] ), 0.0).xyzw) [ 85] vec4 _1_main() { [ 86] vec4 color = vec4(_2_const, vec2(_3_const), 1.0); [ 87] // pass_read_image [ 88] { [ 89] vec4 tmp; [ 90] tmp = _8001_main(); [ 91] color[0] = tmp[0]; [ 92] tmp = _4001_main(); [ 93] color[1] = tmp[0]; [ 94] tmp = _c001_main(); [ 95] color[2] = tmp[0]; [ 96] } [ 97] // pl_shader_decode_color [ 98] { [ 99] color.rgb *= vec3(_4_const); [100] // pl_shader_reshape [101] { [102] vec3 sig; [103] vec4 coeffs; [104] float s; [105] sig = clamp(color.rgb, 0.0, 1.0); [106] s = sig[0]; [107] #define test(i) bvec4(s >= _5_pivots[i]) [108] #define coef(i) _6_coeffs[i] [109] coeffs = mix(mix(mix(coef(0), coef(1), test(0)), [110] mix(coef(2), coef(3), test(2)), [111] test(1)), [112] mix(mix(coef(4), coef(5), test(4)), [113] mix(coef(6), coef(7), test(6)), [114] test(5)), [115] test(3)); [116] #undef test [117] #undef coef [118] s = (coeffs.z * s + coeffs.y) * s + coeffs.x; [119] color[0] = clamp(s, _7_lo, _8_hi); [120] s = sig[1]; [121] coeffs = _9_coeffs; [122] { [123] const uint mmr_idx = 0u; [124] vec4 sigX; [125] s = coeffs.x; [126] sigX.xyz = sig.xxy * sig.yzz; [127] sigX.w = sigX.x * sig.z; [128] s += dot(_a_mmr[mmr_idx + 0].xyz, sig); [129] s += dot(_a_mmr[mmr_idx + 1], sigX); [130] vec3 sig2 = sig * sig; [131] vec4 sigX2 = sigX * sigX; [132] s += dot(_a_mmr[mmr_idx + 2].xyz, sig2); [133] s += dot(_a_mmr[mmr_idx + 3], sigX2); [134] s += dot(_a_mmr[mmr_idx + 4].xyz, sig2 * sig); [135] s += dot(_a_mmr[mmr_idx + 5], sigX2 * sigX); [136] } [137] color[1] = clamp(s, _b_lo, _c_hi); [138] s = sig[2]; [139] coeffs = _d_coeffs; [140] { [141] const uint mmr_idx = 0u; [142] vec4 sigX; [143] s = coeffs.x; [144] sigX.xyz = sig.xxy * sig.yzz; [145] sigX.w = sigX.x * sig.z; [146] s += dot(_e_mmr[mmr_idx + 0].xyz, sig); [147] s += dot(_e_mmr[mmr_idx + 1], sigX); [148] vec3 sig2 = sig * sig; [149] vec4 sigX2 = sigX * sigX; [150] s += dot(_e_mmr[mmr_idx + 2].xyz, sig2); [151] s += dot(_e_mmr[mmr_idx + 3], sigX2); [152] s += dot(_e_mmr[mmr_idx + 4].xyz, sig2 * sig); [153] s += dot(_e_mmr[mmr_idx + 5], sigX2 * sigX); [154] } [155] color[2] = clamp(s, _f_lo, _10_hi); [156] } [157] color.rgb = _11_cmat * color.rgb + _12_cmat_c; [158] color.rgb = pow(max(color.rgb, 0.0), vec3(1.0/78.84375000000000000000)); [159] color.rgb = max(color.rgb - vec3(0.83593750000000000000), 0.0) [160] / (vec3(18.85156250000000000000) - vec3(18.68750000000000000000) * color.rgb); [161] color.rgb = pow(color.rgb, vec3(1.0/0.15930175781250000000)); [162] color.rgb = _13_lms2rgb * color.rgb; [163] color.rgb = pow(max(color.rgb, 0.0), vec3(0.15930175781250000000)); [164] color.rgb = (vec3(0.83593750000000000000) + vec3(18.85156250000000000000) * color.rgb) [165] / (vec3(1.0) + vec3(18.68750000000000000000) * color.rgb); [166] color.rgb = pow(color.rgb, vec3(78.84375000000000000000)); [167] } [168] // pl_shader_color_map [169] { [170] // pl_shader_linearize [171] color.rgb = max(color.rgb, 0.0); [172] color.rgb = pow(color.rgb, vec3(1.0/78.84375000000000000000)); [173] color.rgb = max(color.rgb - vec3(0.83593750000000000000), 0.0) [174] / (vec3(18.85156250000000000000) - vec3(18.68750000000000000000) * color.rgb); [175] color.rgb = pow(color.rgb, vec3(1.0/0.15930175781250000000)); [176] color.rgb *= vec3(49.26108374384236298501); [177] vec3 clipped = clamp(color.rgb, _16_const, _17_const); [178] vec3 lms = _18_mat * clipped; [179] vec3 lmspq = 0.02030000090599060058 * lms; [180] lmspq = pow(max(lmspq, 0.0), vec3(0.15930175781250000000)); [181] lmspq = (vec3(0.83593750000000000000) + 18.85156250000000000000 * lmspq) [182] / (vec3(1.0) + 18.68750000000000000000 * lmspq); [183] lmspq = pow(lmspq, vec3(78.84375000000000000000)); [184] vec3 ipt = _14_mat * lmspq; [185] vec3 idx; [186] idx.x = _24_const * ipt.x + _25_const; [187] idx.y = 2.0 * length(ipt.yz); [188] idx.z = 0.15915494309189533814 * atan(ipt.z, ipt.y) + 0.5; [189] ipt = _19_lut(idx).xyz; [190] lmspq = _15_mat * ipt; [191] lms = pow(max(lmspq, 0.0), vec3(1.0/78.84375000000000000000)); [192] lms = max(lms - vec3(0.83593750000000000000), 0.0) [193] / (vec3(18.85156250000000000000) - 18.68750000000000000000 * lms); [194] lms = pow(lms, vec3(1.0/0.15930175781250000000)); [195] lms *= 49.26108551025390625000; [196] color.rgb = _26_mat * lms; [197] // pl_shader_delinearize [198] color.rgb = max(color.rgb, 0.0); [199] color.rgb *= vec3(1.0/49.26108551025390625000); [200] color.rgb = pow(color.rgb, vec3(0.15930175781250000000)); [201] color.rgb = (vec3(0.83593750000000000000) + vec3(18.85156250000000000000) * color.rgb) [202] / (vec3(1.0) + vec3(18.68750000000000000000) * color.rgb); [203] color.rgb = pow(color.rgb, vec3(78.84375000000000000000)); [204] } [205] // pl_shader_encode_color [206] { [207] color.rgb = _27_cmat * color.rgb + _28_cmat_c; [208] color.rgb *= vec3(color.a); [209] } [210] color *= vec4(1.0 / _29_const); [211] vec4 _2a_orig_color = color; [212] color = vec4(0.0, 0.0, 0.0, 1.0); [213] color[0] = _2a_orig_color[0]; [214] color[1] = _2a_orig_color[1]; [215] color[2] = _2a_orig_color[2]; [216] return color; [217] } [218] [219] void main() { [220] out_color = _1_main(); [221] } Backtrace: #0 1 libplacebo.278.dylib 0x000000010792e078 pl_pass_create + 1520 # 1 2 libplacebo.278.dylib 0x00000001079233d4 finalize_pass + 5936 # 2 3 libplacebo.278.dylib 0x00000001079218a0 pl_dispatch_finish + 980 # 3 4 libplacebo.278.dylib 0x00000001079389f0 pass_output_target + 3548 # 4 5 libplacebo.278.dylib 0x000000010793423c pl_render_image + 404 # 5 6 libvs_placebo.dylib 0x00000001070f5e1c vspl_tonemap_filter + 684 # 6 7 libvs_placebo.dylib 0x00000001070f7194 VSPlaceboTMGetFrame + 2524 # 7 8 libvapoursynth.dylib 0x0000000101a85464 _ZN6VSNode16getFrameInternalEiiP14VSFrameContext + 156 # 8 9 libvapoursynth.dylib 0x0000000101a969e4 _ZN12VSThreadPool8runTasksERNSt3__16atomicIbEE + 736 # 9 10 libvapoursynth.dylib 0x0000000101a98490 _ZNSt3__1L14__thread_proxyINS_5tupleIJNS_10unique_ptrINS_15__thread_structENS_14default_deleteIS3_EEEEPFvP12VSThreadPoolRNS_6atomicIbEEES8_NS_17reference_wrapperISA_EEEEEEEPvSH_ + 48 # 10 11 libsystem_pthread.dylib 0x0000000187b8bfa8 _pthread_start + 148 # 11 12 libsystem_pthread.dylib 0x0000000187b86da0 thread_start + 8 Failed creating render pass for dispatch Failed rendering image! ... Failed rendering image! Input #0, yuv4mpegpipe, from 'pipe:': Duration: N/A, start: 0.000000, bitrate: N/A Stream #0:0: Video: rawvideo (Y3[11][12] / 0xC0B3359), yuv420p12le(progressive), 3840x2160, 23.33 fps, 23.33 tbr, 23.33 tbn Stream mapping: Stream #0:0 -> #0:0 (rawvideo (native) -> hevc (libx265)) x265 [info]: HEVC encoder version 3.4+31-6722fce1f x265 [info]: build info [Mac OS X][clang 13.0.0][32 bit][noasm] 12bit x265 [info]: using cpu capabilities: none! x265 [warning]: halving the quality when psy-rd is enabled for 444 input. Setting cbQpOffset = 6 and crQpOffset = 6 x265 [info]: Main 4:4:4 12 profile, Level-5 (Main tier) x265 [info]: Thread pool created using 10 threads x265 [info]: Slices : 1 x265 [info]: frame threads / pool features : 3 / wpp(68 rows) x265 [info]: Coding QT: max CU size, min CU size : 32 / 16 x265 [info]: Residual QT: max TU size, max depth : 32 / 1 inter / 1 intra x265 [info]: ME / range / subpel / merge : dia / 57 / 0 / 2 x265 [info]: Cb/Cr QP Offset : 6 / 6 x265 [info]: Lookahead / bframes / badapt : 5 / 3 / 0 x265 [info]: b-pyramid / weightp / weightb : 1 / 0 / 0 x265 [info]: References / ref-limit cu / depth : 1 / off / off x265 [info]: AQ: mode / str / qg-size / cu-tree : 1 / 0.0 / 32 / 1 x265 [info]: Rate Control / qCompress : CRF-0.0 / 0.60 x265 [info]: tools: rd=2 psy-rd=2.00 early-skip rskip mode=1 tmvp fast-intra x265 [info]: tools: strong-intra-smoothing lslices=8 deblock Output #0, matroska, to 'test.mkv': Metadata: encoder : Lavf60.3.100 Stream #0:0: Video: hevc, yuv444p12le(tv, progressive), 3840x2160, q=2-31, 23.33 fps, 1k tbn Metadata: encoder : Lavc60.3.100 libx265 Side data: cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: N/A Output 219 frames in 67.35 seconds (3.25 fps)e=00:00:08.48 bitrate=9638.1kbits/s speed=0.182x frame= 219 fps=4.3 q=7.0 Lsize= 16408kB time=00:00:09.25 bitrate=14520.1kbits/s speed=0.181x video:16403kB audio:0kB subtitle:0kB other streams:0kB global headers:2kB muxing overhead: 0.028249% x265 [info]: frame I: 1, Avg QP:4.94 kb/s: 964.88 x265 [info]: frame P: 55, Avg QP:4.53 kb/s: 29503.19 x265 [info]: frame B: 163, Avg QP:6.67 kb/s: 9273.66 x265 [info]: consecutive B-frames: 1.8% 1.8% 0.0% 96.4% encoded 219 frames in 51.12s (4.28 fps), 14316.20 kb/s, Avg QP:6.12`

The output video is a pure green image with hints of the EL on top. Any help would be appreciated.

quietvoid commented 1 year ago

It's very likely a Mac issue, yes.

Amaraldo commented 1 year ago

What exactly does the placebo.tonemap function do with respect to Dolby Vision? Does it change the transfer function and colourspace?

quietvoid commented 1 year ago

What exactly does the placebo.tonemap function do with respect to Dolby Vision? Does it change the transfer function and colourspace?

It processes the image with the Dolby Vision RPU metadata.

Amaraldo commented 1 year ago

Is there any way around the shader issues I'm encountering?

quietvoid commented 1 year ago

I have no idea.