Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • videolan/vlc
  • chouquette/vlc
  • bakiewicz.marek122/vlc
  • devnexen/vlc
  • rohanrajpal/vlc
  • blurrrb/vlc
  • gsoc/gsoc2019/darkapex/vlc
  • b1ue/vlc
  • fkuehne/vlc
  • magsoft/vlc
  • chub/vlc
  • cramiro9/vlc
  • robUx4/vlc
  • rom1v/vlc
  • akshayaky/vlc
  • tmk907/vlc
  • akymaster/vlc
  • govind.sharma/vlc
  • psilokos/vlc
  • xjbeta/vlc
  • jahan/vlc
  • 1480c1/vlc
  • amanchande/vlc
  • aaqib/vlc
  • rist/vlc
  • apol/vlc
  • mindfreeze/vlc
  • alexandre-janniaux/vlc
  • sandsmark/vlc
  • jagannatharjun/vlc
  • gsoc/gsoc2020/matiaslgonzalez/vlc
  • gsoc/gsoc2020/jagannatharjun/vlc
  • mstorsjo/vlc
  • gsoc/gsoc2020/vedenta/vlc
  • gsoc/gsoc2020/arnav-ishaan/vlc
  • gsoc/gsoc2020/andreduong/vlc
  • fuzun/vlc
  • gsoc/gsoc2020/vatsin/vlc
  • gsoc/gsoc2020/sagid/vlc
  • yaron/vlc
  • Phoenix/vlc
  • Garf/vlc
  • ePiratWorkarounds/vlc
  • tguillem/vlc
  • jnqnfe/vlc
  • mdc/vlc
  • Vedaa/vlc
  • rasa/vlc
  • quink/vlc
  • yealo/vlc
  • aleksey_ak/vlc
  • ePirat/vlc
  • ilya.yanok/vlc
  • asenat/vlc
  • m/vlc
  • bunjee/vlc
  • BLumia/vlc
  • sagudev/vlc
  • hamedmonji30/vlc
  • nullgemm/vlc
  • DivyamAhuja/vlc
  • thesamesam/vlc
  • dag7/vlc
  • snehil101/vlc
  • haasn/vlc
  • jbk/vlc
  • ValZapod/vlc
  • mfkl/vlc
  • WangChuan/vlc
  • core1024/vlc
  • GhostVaibhav/vlc
  • dfuhrmann/vlc
  • davide.prade/vlc
  • tmatth/vlc
  • Courmisch/vlc
  • zouya/vlc
  • hpi/vlc
  • EwoutH/vlc
  • aleung27/vlc
  • hengwu0/vlc
  • saladin/vlc
  • ashuio/vlc
  • richselwood/vlc
  • verma16Ayush/vlc
  • chemicalflash/vlc
  • PoignardAzur/vlc
  • huangjieNT/vlc
  • Blake-Haydon/vlc
  • AnuthaDev/vlc
  • gsoc/gsoc2021/mpd/vlc
  • nicolas_lequec/vlc
  • sambassaly/vlc
  • thresh/vlc
  • bonniegong/vlc
  • myaashish/vlc
  • stavros.vagionitis/vlc
  • ileoo/vlc
  • louis-santucci/vlc
  • cchristiansen/vlc
  • sabyasachi07/vlc
  • AbduAmeen/vlc
  • ashishb0410/vlc
  • urbanhusky/vlc
  • davidepietrasanta/vlc
  • riksleutelstad/vlc
  • jeremyVignelles/vlc
  • komh/vlc
  • iamjithinjohn/vlc
  • JohannesKauffmann/vlc2
  • kunglao/vlc
  • natzberg/vlc
  • jill/vlc
  • cwendling/vlc
  • adufou/vlc
  • ErwanAirone/vlc
  • HasinduDilshan10/vlc
  • vagrantc/vlc
  • rafiv/macos-bigsur-icon
  • Aymeriic/vlc
  • saranshg20/vlc
  • metzlove24/vlc
  • linkfanel/vlc
  • Ds886/vlc
  • metehan-arslan/vlc
  • Skantes/vlc
  • kgsandundananjaya96/vlc
  • mitchcapper/vlc
  • advaitgupta/vlc
  • StefanBruens/vlc
  • ratajs/vlc
  • T.M.F.B.3761/vlc
  • m222059/vlc
  • casemerrick/vlc
  • joshuaword2alt/vlc
  • sjwaddy/vlc
  • dima/vlc
  • Ybalrid/vlc
  • umxprime/vlc
  • eschmidt/vlc
  • vannieuwenhuysenmichelle/vlc
  • badcf00d/vlc
  • wesinator/vlc
  • louis/vlc
  • xqq/vlc
  • EmperorYP7/vlc
  • NicoLiam/vlc
  • loveleen/vlc
  • rofferom/vlc
  • rbultje/vlc
  • TheUnamed/vlc
  • pratiksharma341/vlc
  • Saurab17/vlc
  • purist.coder/vlc
  • Shuicheng/vlc
  • mdrrubel292/vlc
  • silverbleu00/vlc
  • metif12/vlc
  • asher-m/vlc
  • jeffk/vlc
  • Brandonbr1/vlc
  • beautyyuyanli/vlc
  • rego21/vlc
  • muyangren907/vlc
  • collectionbylawrencejason/vlc
  • evelez/vlc
  • GSMgeeth/vlc
  • Oneric/vlc
  • TJ5/vlc
  • XuanTung95/vlc
  • darrenjenny21/vlc
  • Trenly/vlc
  • RockyTDR/vlc
  • mjakubowski/vlc
  • caprica/vlc
  • ForteFrankie/vlc
  • seannamiller19/vlc
  • junlon2006/vlc
  • kiwiren6666/vlc
  • iuseiphonexs/vlc
  • fenngtun/vlc
  • Rajdutt999/vlc
  • typx/vlc
  • leon.vitanos/vlc
  • robertogarci0938/vlc
  • gsoc/gsoc2022/luc65r/vlc-mpd
  • skeller/vlc
  • MCJack123/vlc
  • luc65r/vlc-mpd
  • popov895/vlc
  • claucambra/vlc
  • brad/vlc
  • matthewmurua88/vlc
  • Tomas8874/vlc
  • philenotfound/vlc
  • makita-do3/vlc
  • LZXCorp/vlc
  • mar0x/vlc
  • senojetkennedy0102/vlc
  • shaneb243/vlc
  • ahmadbader/vlc
  • rajduttcse26/vlc-audio-filters
  • Juniorzito8415/vlc
  • achernyakov/vlc
  • lucasjetgroup/vlc
  • pupdoggy666/vlc
  • gmde9363/vlc
  • alexnwayne/vlc
  • bahareebrahimi781/vlc
  • hamad633666/vlc
  • umghof3112/vlc
  • joe0199771874/vlc
  • Octocats66666666/vlc
  • jjm_223/vlc
  • btech10110.19/vlc
  • sunnykfc028/vlc-audio-filters
  • loic/vlc
  • nguyenminhducmx1/vlc
  • JanekKrueger/vlc
  • bstubbington2/vlc
  • rcombs/vlc
  • Ordissimo/vlc
  • king7532/vlc
  • noobsauce101/vlc
  • schong0525/vlc
  • myQwil/vlc
  • apisbg91/vlc
  • geeboy0101017/vlc
  • kim.faughey/vlc
  • nurupo/vlc
  • yyusea/vlc
  • 0711235879.khco/vlc
  • ialo/vlc
  • iloveyeye2/vlc
  • gdtdftdqtd/vlc
  • leandroconsiglio/vlc
  • AndyHTML2012/vlc
  • ncz/vlc
  • lucenticus/vlc
  • knr1931/vlc
  • kjoonlee/vlc
  • chandrakant100/vlc-qt
  • johge42/vlc
  • polter/vlc
  • hexchain/vlc
  • Tushwrld/vlc
  • mztea928/vlc
  • jbelloncastro/vlc
  • alvinhochun/vlc
  • ghostpiratecrow/vlc
  • ujjwaltwitx/vlc
  • alexsonarin06/vlc
  • adrianbon76/vlc
  • altsod/vlc
  • damien.lucas44/vlc
  • dmytrivtaisa/vlc
  • utk202/vlc
  • aaxhrj/vlc
  • thomas.hermes/vlc
  • structurenewworldorder/vlc
  • slomo/vlc
  • wantlamy/vlc
  • musc.o3cminc/vlc
  • thebarshablog/vlc
  • kerrick/vlc
  • kratos142518/vlc
  • leogps/vlc
  • vacantron/vlc
  • luna_koly/vlc
  • Ratio2/vlc
  • anuoshemohammad/vlc
  • apsun/vlc
  • aaa1115910/vlc
  • alimotmoyo/vlc
  • Ambossmann/vlc
  • Sam-LearnsToCode/vlc
  • Chilledheart/vlc
  • Labnann/vlc
  • ktcoooot1/vlc
  • mohit-marathe/vlc
  • johnddx/vlc
  • manstabuk/vlc
  • Omar-ahmed314/vlc
  • vineethkm/vlc
  • 9Enemi86/vlc
  • radoslav.m.panteleev/vlc
  • ashishami2002/vlc
  • Corbax/vlc
  • firnasahmed/vlc
  • pelayarmalam4/vlc
  • c0ff330k/vlc
  • shikhindahikar/vlc
  • l342723951/vlc
  • christianschwandner/vlc
  • douniwan5788/vlc
  • 7damian7/vlc
  • ferdnyc/vlc
  • f.ales1/vlc
  • pandagby/vlc
  • BaaBaa/vlc
  • jewe37/vlc
  • w00drow/vlc
  • russelltg/vlc
  • ironicallygod/vlc
  • soumyaDghosh/vlc
  • linzihao1999/vlc
  • deyayush6/vlc
  • mibi88/vlc
  • newabdallah10/vlc
  • jhorbincolombia/vlc
  • rimvihaqueshupto/vlc
  • andrewkhon98/vlc
  • fab78/vlc
  • lapaz17/vlc
  • amanna13/vlc
  • mdakram28/vlc
  • 07jw1980/vlc
  • sohamgupta/vlc
  • Eson-Jia1/vlc
  • Sumou/vlc
  • vikram-kangotra/vlc
  • chalice191/vlc
  • olivercalder/vlc
  • aaasg4001/vlc
  • zipdox/vlc
  • kwizart/vlc
  • Dragon-S/vlc
  • jdemeule/vlc
  • gabriel_lt/vlc
  • locutusofborg/vlc
  • sammirata/vlc-librist
  • another/vlc
  • Benjamin_Loison/vlc
  • ahmedmoselhi/vlc
  • petergaal/vlc
  • huynhsontung/vlc
  • dariusmihut/vlc
  • tvermaashutosh/vlc
  • buti/vlc
  • Niram7777/vlc
  • rohan-here/vlc
  • balaji-sivasakthi/vlc
  • rlindner81/vlc
  • Kakadus/vlc
  • djain/vlc
  • ABBurmeister/vlc
  • craighuggins/vlc
  • orbea/vlc
  • maxos/vlc
  • aakarshmj/vlc
  • kblaschke/vlc
  • ankitm/vlc
  • advait-0/vlc
  • mohak2003/vlc
  • yselkowitz/vlc
  • AZM999/vlc-azm
  • andrey.turkin/vlc
  • Disha-Baghel/vlc
  • nowrep/vlc
  • Apeng/vlc
  • Choucroute_melba/vlc
  • autra/vlc
  • eclipseo/vlc
  • fhuber/vlc
  • olafhering/vlc
  • sdasda7777/vlc
  • 1div0/vlc
  • skosnits/vlc-extended-playlist-support
  • dnicolson/vlc
  • Timshel/vlc
  • octopols/vlc
  • MangalK/vlc
  • nima64/vlc
  • misawai/vlc
  • Alexander-Wilms/vlc
  • Maxime2/vlc-fork-for-visualizer
  • ww/vlc
  • jeske/vlc
  • sgross-emlix/vlc
  • morenonatural/vlc
  • freakingLovesVLC/vlc
  • borisgolovnev/vlc
  • mpromonet/vlc
  • diogo.simao-marques/vlc
  • masstock/vlc
  • pratikpatel8982/vlc
  • hugok79/vlc
  • longervision/vlc
  • abhiudaysurya/vlc
  • rishabhgarg/vlc
  • tumic/vlc
  • cart/vlc
  • shubham442/vlc
  • Aditya692005/vlc
  • sammirata/vlc4
  • syrykh/vlc
  • Vvorcun/macos-new-icon
  • AyaanshC/vlc
  • nasso/vlc
  • Quark/vlc
  • sebastinas/vlc
  • rhstone/vlc
  • talregev/vlc
  • Managor/vlc
403 results
Show changes
Commits on Source (16)
......@@ -349,7 +349,7 @@
#define VLC_CODEC_RGB12 VLC_FOURCC('R','V','1','2')
/* 15-bit RGB padded to 16 bits (using explicit masks) */
#define VLC_CODEC_RGB15 VLC_FOURCC('R','V','1','5')
/* 16-bit RGB (using explit masks) */
/* 16-bit RGB (using explicit masks) */
#define VLC_CODEC_RGB16 VLC_FOURCC('R','V','1','6')
/* 24-bit RGB (using explicit masks) */
#define VLC_CODEC_RGB24 VLC_FOURCC('R','V','2','4')
......
......@@ -81,7 +81,7 @@ struct access_sys_t
/* misc properties */
int i_width;
int i_height;
int i_chroma;
vlc_fourcc_t i_chroma;
vlc_tick_t i_start;
};
......
......@@ -68,7 +68,7 @@ static int OpenDevice( vlc_object_t *, access_sys_t *, std::string, bool );
static ComPtr<IBaseFilter> FindCaptureDevice( vlc_object_t *, std::string *,
std::list<std::string> *, bool );
static size_t EnumDeviceCaps( vlc_object_t *, ComPtr<IBaseFilter> &,
int, int, int, int, int, int,
vlc_fourcc_t, int, int, int, int, int,
AM_MEDIA_TYPE *mt, size_t, bool );
static bool ConnectFilters( vlc_object_t *, access_sys_t *,
ComPtr<IBaseFilter> &, ComPtr<CaptureFilter> & );
......@@ -299,7 +299,7 @@ struct dshow_stream_t
} header;
int i_fourcc;
vlc_fourcc_t i_fourcc;
es_out_id_t *p_es;
bool b_pts;
......@@ -622,37 +622,27 @@ static int CommonOpen( vlc_object_t *p_this, access_sys_t *p_sys,
return VLC_SUCCESS;
}
static void SetRGBMasks( vlc_fourcc_t i_fourcc, es_format_t *fmt )
static void SetRGBMasks( vlc_fourcc_t i_fourcc, video_format_t *fmt )
{
switch( i_fourcc )
{
case VLC_CODEC_RGB15:
fmt->video.i_rmask = 0x7c00;
fmt->video.i_gmask = 0x03e0;
fmt->video.i_bmask = 0x001f;
break;
case VLC_CODEC_RGB16:
fmt->video.i_rmask = 0xf800;
fmt->video.i_gmask = 0x07e0;
fmt->video.i_bmask = 0x001f;
break;
case VLC_CODEC_RGB24:
/* This is in BGR format */
fmt->video.i_bmask = 0x00ff0000;
fmt->video.i_gmask = 0x0000ff00;
fmt->video.i_rmask = 0x000000ff;
fmt->i_bmask = 0x00ff0000;
fmt->i_gmask = 0x0000ff00;
fmt->i_rmask = 0x000000ff;
break;
case VLC_CODEC_RGB32:
/* This is in BGRx format */
fmt->video.i_bmask = 0xff000000;
fmt->video.i_gmask = 0x00ff0000;
fmt->video.i_rmask = 0x0000ff00;
fmt->i_bmask = 0xff000000;
fmt->i_gmask = 0x00ff0000;
fmt->i_rmask = 0x0000ff00;
break;
default:
return;
}
fmt->video.i_chroma = i_fourcc;
video_format_FixRgb( &fmt->video );
fmt->i_chroma = i_fourcc;
video_format_FixRgb( fmt );
}
/*****************************************************************************
......@@ -733,7 +723,7 @@ static int DemuxOpen( vlc_object_t *p_this )
}
/* Setup rgb mask for RGB formats */
SetRGBMasks( p_stream->i_fourcc, &fmt );
SetRGBMasks( p_stream->i_fourcc, &fmt.video );
if( p_stream->header.video.AvgTimePerFrame )
{
......@@ -946,7 +936,7 @@ static bool ConnectFilters( vlc_object_t *p_this, access_sys_t *p_sys,
/*
* get fourcc priority from arbitrary preference, the higher the better
*/
static int GetFourCCPriority( int i_fourcc )
static int GetFourCCPriority( vlc_fourcc_t i_fourcc )
{
switch( i_fourcc )
{
......@@ -1317,7 +1307,7 @@ FindCaptureDevice( vlc_object_t *p_this, std::string *p_devicename,
}
static size_t EnumDeviceCaps( vlc_object_t *p_this, ComPtr<IBaseFilter> &p_filter,
int i_fourcc, int i_width, int i_height,
vlc_fourcc_t i_fourcc, int i_width, int i_height,
int i_channels, int i_samplespersec,
int i_bitspersample, AM_MEDIA_TYPE *mt,
size_t mt_max, bool b_audio )
......@@ -1385,7 +1375,7 @@ static size_t EnumDeviceCaps( vlc_object_t *p_this, ComPtr<IBaseFilter> &p_filte
{
if( SUCCEEDED(pSC->GetStreamCaps(i, &p_mt, static_cast<BYTE*>(pSCC))) )
{
int i_current_fourcc = GetFourCCFromMediaType( *p_mt );
vlc_fourcc_t i_current_fourcc = GetFourCCFromMediaType( *p_mt );
int i_current_priority = GetFourCCPriority(i_current_fourcc);
if( (i_fourcc && (i_current_fourcc != i_fourcc))
......@@ -1578,7 +1568,7 @@ static size_t EnumDeviceCaps( vlc_object_t *p_this, ComPtr<IBaseFilter> &p_filte
while( p_enummt->Next( 1, &p_mt, NULL ) == S_OK )
{
int i_current_fourcc = GetFourCCFromMediaType( *p_mt );
vlc_fourcc_t i_current_fourcc = GetFourCCFromMediaType( *p_mt );
if( !b_audio && i_current_fourcc && p_mt->majortype == MEDIATYPE_Video
&& p_mt->formattype == FORMAT_VideoInfo )
{
......
......@@ -95,9 +95,9 @@ HRESULT WINAPI CopyMediaType( AM_MEDIA_TYPE *pmtTarget,
return S_OK;
}
int GetFourCCFromMediaType( const AM_MEDIA_TYPE &media_type )
vlc_fourcc_t GetFourCCFromMediaType( const AM_MEDIA_TYPE &media_type )
{
int i_fourcc = 0;
vlc_fourcc_t i_fourcc = 0;
if( media_type.majortype == MEDIATYPE_Video )
{
......@@ -505,7 +505,7 @@ STDMETHODIMP CapturePin::QueryAccept( const AM_MEDIA_TYPE *pmt )
return S_FALSE;
}
int i_fourcc = GetFourCCFromMediaType(*pmt);
vlc_fourcc_t i_fourcc = GetFourCCFromMediaType(*pmt);
if( !i_fourcc )
{
msg_Dbg( p_input, "CapturePin::QueryAccept "
......
......@@ -40,7 +40,7 @@ void WINAPI FreeMediaType( AM_MEDIA_TYPE& mt );
HRESULT WINAPI CopyMediaType( AM_MEDIA_TYPE *pmtTarget,
const AM_MEDIA_TYPE *pmtSource );
int GetFourCCFromMediaType(const AM_MEDIA_TYPE &media_type);
vlc_fourcc_t GetFourCCFromMediaType(const AM_MEDIA_TYPE &media_type);
/****************************************************************************
* Declaration of our dummy directshow filter pin class
......
......@@ -519,7 +519,7 @@ static es_out_id_t *InitES (demux_t *demux, uint_fast16_t width,
{
demux_sys_t *p_sys = demux->p_sys;
const xcb_setup_t *setup = xcb_get_setup (p_sys->conn);
uint32_t chroma = 0;
vlc_fourcc_t chroma = 0;
for (const xcb_format_t *fmt = xcb_setup_pixmap_formats (setup),
*end = fmt + xcb_setup_pixmap_formats_length (setup);
......
......@@ -594,10 +594,10 @@ bool GetFfmpegCodec( enum es_format_category_e cat, vlc_fourcc_t i_fourcc,
vlc_fourcc_t GetVlcFourcc( enum AVCodecID i_ffmpeg_codec )
{
if( i_ffmpeg_codec == AV_CODEC_ID_RAWVIDEO )
return VLC_CODEC_UNKNOWN;
for( size_t i = 0; i < ARRAY_SIZE(video_codecs); i++ )
{
if( i_ffmpeg_codec == AV_CODEC_ID_RAWVIDEO )
return VLC_CODEC_UNKNOWN;
if( video_codecs[i].i_codec == i_ffmpeg_codec )
return video_codecs[i].i_fourcc;
}
......
......@@ -608,7 +608,7 @@ static int OpenEncoder( vlc_object_t *p_this )
config_ChainParse( p_enc, ENC_CFG_PREFIX, ppsz_enc_options, p_enc->p_cfg );
char *psz_tmp = var_GetString( p_enc, ENC_CFG_PREFIX "chroma-fmt" );
uint32_t i_codec;
vlc_fourcc_t i_codec;
if( !psz_tmp ) {
free(p_sys);
return VLC_ENOMEM;
......
......@@ -2273,7 +2273,8 @@ static void encode_object( encoder_t *p_enc, bs_t *s, subpicture_t *p_subpic )
bs_write( s, 2, 1 );
break;
default:
msg_Err( p_enc, "FOURCC %d not supported by encoder.", p_region->fmt.i_chroma );
msg_Err( p_enc, "FOURCC %4.4s not supported by encoder.",
(const char*)&p_region->fmt.i_chroma );
continue;
}
......
......@@ -1450,14 +1450,12 @@ static block_t *Encode( encoder_t *p_enc, picture_t *p_pic )
date_t date;
if( p_pic->format.i_chroma != p_enc->fmt_in.i_codec ) {
char chroma_in[5], chroma_out[5];
vlc_fourcc_to_char( p_pic->format.i_chroma, chroma_in );
chroma_in[4] = '\0';
chroma_out[4] = '\0';
vlc_fourcc_to_char( p_enc->fmt_in.i_codec, chroma_out );
msg_Warn( p_enc, "Resetting chroma from %s to %s", chroma_out, chroma_in );
msg_Warn( p_enc, "Resetting chroma from %4.4s to %4.4s",
(const char*)&p_enc->fmt_in.i_codec,
(const char*)&p_pic->format.i_chroma );
if( !SetEncChromaFormat( p_enc, p_pic->format.i_chroma ) ) {
msg_Err( p_enc, "Could not reset chroma format to %s", chroma_in );
msg_Err( p_enc, "Could not reset chroma format to %4.4s",
(const char*)&p_pic->format.i_chroma );
return NULL;
}
}
......
......@@ -740,13 +740,8 @@ void matroska_segment_c::ParseTrackEntry( const KaxTrackEntry *m )
ONLY_FMT(VIDEO);
if ( colourspace.ValidateSize() )
{
char clrspc[5];
vars.tk->fmt.i_codec = GetFOURCC( colourspace.GetBuffer() );
vlc_fourcc_to_char( vars.tk->fmt.i_codec, clrspc );
clrspc[4] = '\0';
debug( vars, "Colour Space=%s", clrspc );
debug( vars, "Colour Space=%4.4s", (const char*)&vars.tk->fmt.i_codec );
}
}
#if LIBMATROSKA_VERSION >= 0x010405
......
......@@ -239,7 +239,7 @@ static void Draw(BarGraph_t *b)
if (b->p_pic)
picture_Release(b->p_pic);
b->p_pic = picture_New(VLC_FOURCC('Y','U','V','A'), w, h, 1, 1);
b->p_pic = picture_New(VLC_CODEC_YUVA, w, h, 1, 1);
if (!b->p_pic)
return;
picture_t *p_pic = b->p_pic;
......
......@@ -132,11 +132,18 @@ const d3d_format_t *DxgiGetRenderFormatList(void)
void DxgiFormatMask(DXGI_FORMAT format, video_format_t *fmt)
{
if (format == DXGI_FORMAT_B8G8R8X8_UNORM || format == DXGI_FORMAT_B8G8R8A8_UNORM)
switch(format)
{
case DXGI_FORMAT_B8G8R8X8_UNORM:
fmt->i_rmask = 0x0000ff00;
fmt->i_gmask = 0x00ff0000;
fmt->i_bmask = 0xff000000;
break;
case DXGI_FORMAT_B5G6R5_UNORM:
fmt->i_bmask = 0xf800;
fmt->i_gmask = 0x07e0;
fmt->i_rmask = 0x001f;
break;
}
}
......
......@@ -256,11 +256,12 @@ static int Activate( filter_t *p_filter )
}
video_format_t vfmt;
video_format_Init( &vfmt, p_filter->fmt_out.video.i_chroma );
video_format_Copy( &vfmt, &p_filter->fmt_out.video );
if( !vfmt.i_rmask || !vfmt.i_gmask || !vfmt.i_bmask )
{
msg_Warn( p_filter, "source did not set proper target RGB masks, using default" );
video_format_FixRgb( &vfmt );
video_format_FixRgb( &vfmt );
}
SetYUV( p_filter, &vfmt );
video_format_Clean( &vfmt );
#endif
......
......@@ -1632,8 +1632,9 @@ static int Direct3D9Open(vout_display_t *vd, video_format_t *fmt, vlc_video_cont
msg_Dbg(vd, "found input surface format %s for source %4.4s", d3dfmt->name, (const char *)&vd->source->i_chroma);
bool force_dxva_hd = var_InheritBool(vd, "direct3d9-dxvahd");
if (force_dxva_hd || (dst_format && vd->source->color_range != COLOR_RANGE_FULL && dst_format->rmask && !d3dfmt->rmask &&
sys->d3d9_device->d3ddev.identifier.VendorId == GPU_MANUFACTURER_NVIDIA))
if (force_dxva_hd || (dst_format && vd->source->color_range != COLOR_RANGE_FULL &&
sys->d3d9_device->d3ddev.identifier.VendorId == GPU_MANUFACTURER_NVIDIA) &&
!vlc_fourcc_IsYUV(dst_format->fourcc) && vlc_fourcc_IsYUV(d3dfmt->fourcc))
{
// NVIDIA bug, YUV to RGB internal conversion in StretchRect always converts from limited to limited range
msg_Dbg(vd, "init DXVA-HD processor from %s to %s", d3dfmt->name, dst_format?dst_format->name:"unknown");
......