This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Syntax: x264 [options] -o outfile infile [widthxheight] | |
Infile can be raw YUV 4:2:0 (in which case resolution is required), | |
or YUV4MPEG 4:2:0 (*.y4m), | |
or Avisynth if compiled with support (no). | |
or libav* formats if compiled with lavf support (no) or ffms support (no). | |
Outfile type is selected by filename: | |
.264 -> Raw bytestream | |
.mkv -> Matroska | |
.flv -> Flash Video |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static void CopyTo<T, TProperties>(this T source, T target, Expression<Func<T, TProperties>> expression) | |
{ | |
MemberExpression? memberExpression = expression.Body as MemberExpression; | |
if (memberExpression is null) | |
return; | |
List<MemberExpression> listMemberExpression = new([memberExpression]);//child to parent | |
while (true) | |
{ | |
MemberExpression? child_memberExpression = memberExpression?.Expression as MemberExpression; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <mono/jit/jit.h> | |
#include <mono/metadata/assembly.h> | |
#pragma comment(lib, "mono-2.0.lib") | |
int main(int argc, char* argv[]) | |
{ | |
mono_set_dirs("C:\\Program Files (x86)\\Mono\\lib", | |
"C:\\Program Files (x86)\\Mono\\etc"); | |
MonoDomain *domain; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys | |
import os | |
import numpy as np | |
import argparse | |
from modules.utils.paths import (WHISPER_MODELS_DIR, DIARIZATION_MODELS_DIR, OUTPUT_DIR, DEFAULT_PARAMETERS_CONFIG_PATH, | |
UVR_MODELS_DIR) | |
from modules.uvr.music_separator import MusicSeparator | |
parser = argparse.ArgumentParser() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ChromeDriverService? _service = null; | |
public int? ChromeProcessId | |
{ | |
get | |
{ | |
ProcessHelper processHelper = new ProcessHelper((uint)_service!.ProcessId); | |
foreach (var child in processHelper.ChildrensProcess) | |
{ | |
ProcessHelper.Win32_Process? win32_Process = child.Query_Win32_Process(); | |
if (win32_Process?.Name?.Contains("chrome", StringComparison.OrdinalIgnoreCase) == true) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
try | |
{ | |
VideoTextVM.RenderWorkStatus = RenderWorkStatus.Working; | |
if (string.IsNullOrWhiteSpace(VideoOutputConfigure.SaveDir)) | |
throw new InvalidOperationException("Chưa chọn thư mục đầu ra"); | |
Directory.CreateDirectory(VideoTextVM.TmpDir); | |
FFmpegArg ffmpegArg = new FFmpegArg().OverWriteOutput().VSync(VSyncMethod.cfr); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class WrapperStream : Stream | |
{ | |
readonly HttpResponseMessage _httpResponseMessage; | |
readonly Stream _stream; | |
public WrapperStream(HttpResponseMessage httpResponseMessage, Stream stream) | |
{ | |
this._httpResponseMessage = httpResponseMessage; | |
this._stream = stream; | |
} | |
public override bool CanRead => _stream.CanRead; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Text; | |
using System.Drawing; | |
using System.Runtime.InteropServices; | |
namespace Spazzarama.ScreenCapture | |
{ | |
public static class Direct3DCapture | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static class DeepCopyExtension | |
{ | |
public static T CloneByJson<T>(this T obj, JsonSerializerSettings? jsonSerializerSettings = null) | |
{ | |
return JsonConvert.DeserializeObject<T>(JsonConvert.SerializeObject(obj, jsonSerializerSettings), jsonSerializerSettings)!; | |
} | |
public static object? CloneByJson(this object obj, Type type, JsonSerializerSettings? jsonSerializerSettings = null) | |
{ | |
return JsonConvert.DeserializeObject(JsonConvert.SerializeObject(obj, jsonSerializerSettings), type, jsonSerializerSettings)!; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<Window x:Class="Yuv.YuvColorSpaceWindow" | |
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | |
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | |
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | |
mc:Ignorable="d" | |
Title="YuvColorSpace" Height="470" Width="450"> | |
<Grid> | |
<Rectangle > | |
<Rectangle.Fill> |
NewerOlder