Changeset 8d0689823c4a3f12ec66bd9e00faeedf719e3159
- Timestamp:
- 02/28/08 03:32:23
(6 months ago)
- Author:
- Jean-Baptiste Kempf <jb@videolan.org>
- git-committer:
- Jean-Baptiste Kempf <jb@videolan.org> 1204165943 +0000
- git-parent:
[eb88f342e8e4c54a15f47b08569e5be130a5e237]
- git-author:
- Jean-Baptiste Kempf <jb@videolan.org> 1204165943 +0000
- Message:
Compile XvMC. Disabled the subtitles part for that. Commented a few things. This can't be good, but at least it compiles (not link yet).
-
Files:
-
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
| r0d0f59a |
r8d06898 |
|
| 431 | 431 | return VLC_EGENERIC; |
|---|
| 432 | 432 | } |
|---|
| | 433 | subpicture_t sub_pic; |
|---|
| 433 | 434 | sub_pic.p_sys = NULL; |
|---|
| 434 | 435 | p_vout->p_sys->last_date = 0; |
|---|
| … | … | |
| 598 | 599 | } |
|---|
| 599 | 600 | |
|---|
| | 601 | #if 0 |
|---|
| 600 | 602 | vlc_mutex_lock( &p_vout->lastsubtitle_lock ); |
|---|
| 601 | | |
|---|
| 602 | | if (p_vout->p_last_subtitle != NULL) |
|---|
| 603 | | { |
|---|
| 604 | | if( p_vout->p_sys->p_last_subtitle_save != p_vout->p_last_subtitle ) |
|---|
| | 603 | if (p_vout->p_sys->p_last_subtitle != NULL) |
|---|
| | 604 | { |
|---|
| | 605 | if( p_vout->p_sys->p_last_subtitle_save != p_vout->p_sys->p_last_subtitle ) |
|---|
| 605 | 606 | { |
|---|
| 606 | 607 | p_vout->p_sys->new_subpic = |
|---|
| … | … | |
| 756 | 757 | |
|---|
| 757 | 758 | vlc_mutex_unlock( &p_vout->lastsubtitle_lock ); |
|---|
| | 759 | #endif |
|---|
| 758 | 760 | xvmc_context_reader_unlock( &p_vout->p_sys->xvmc_lock ); |
|---|
| 759 | 761 | |
|---|
| … | … | |
| 966 | 968 | xvmc_context_reader_lock( &p_vout->p_sys->xvmc_lock ); |
|---|
| 967 | 969 | |
|---|
| 968 | | vlc_xxmc_t *xxmc = &p_picture->p_sys->xxmc_data; |
|---|
| | 970 | vlc_xxmc_t *xxmc = &p_pic->p_sys->xxmc_data; |
|---|
| 969 | 971 | if( !xxmc->decoded || |
|---|
| 970 | | !xxmc_xvmc_surface_valid( p_vout, p_picture->p_sys->xvmc_surf ) ) |
|---|
| | 972 | !xxmc_xvmc_surface_valid( p_vout, p_pic->p_sys->xvmc_surf ) ) |
|---|
| 971 | 973 | { |
|---|
| 972 | 974 | msg_Dbg( p_vout, "DisplayVideo decoded=%d\tsurfacevalid=%d", |
|---|
| 973 | 975 | xxmc->decoded, |
|---|
| 974 | | xxmc_xvmc_surface_valid( p_vout, p_picture->p_sys->xvmc_surf ) ); |
|---|
| | 976 | xxmc_xvmc_surface_valid( p_vout, p_pic->p_sys->xvmc_surf ) ); |
|---|
| 975 | 977 | vlc_mutex_unlock( &p_vout->p_sys->lock ); |
|---|
| 976 | 978 | xvmc_context_reader_unlock( &p_vout->p_sys->xvmc_lock ); |
|---|
| … | … | |
| 978 | 980 | } |
|---|
| 979 | 981 | |
|---|
| 980 | | src_width = p_vout->output.i_width; |
|---|
| 981 | | src_height = p_vout->output.i_height; |
|---|
| | 982 | int src_width = p_vout->output.i_width; |
|---|
| | 983 | int src_height = p_vout->output.i_height; |
|---|
| | 984 | int src_x, src_y; |
|---|
| 982 | 985 | |
|---|
| 983 | 986 | if( p_vout->p_sys->xvmc_crop_style == 1 ) |
|---|
| … | … | |
| 1008 | 1011 | } |
|---|
| 1009 | 1012 | |
|---|
| | 1013 | int first_field; |
|---|
| 1010 | 1014 | if( p_vout->p_sys->xvmc_deinterlace_method > 0 ) |
|---|
| 1011 | 1015 | { /* BOB DEINTERLACE */ |
|---|
| 1012 | | if( (p_picture->p_sys->nb_display == 0) || |
|---|
| | 1016 | if( (p_pic->p_sys->nb_display == 0) || |
|---|
| 1013 | 1017 | (p_vout->p_sys->xvmc_deinterlace_method == 1) ) |
|---|
| 1014 | 1018 | { |
|---|
| 1015 | | first_field = (p_picture->b_top_field_first) ? |
|---|
| | 1019 | first_field = (p_pic->b_top_field_first) ? |
|---|
| 1016 | 1020 | XVMC_BOTTOM_FIELD : XVMC_TOP_FIELD; |
|---|
| 1017 | 1021 | } |
|---|
| 1018 | 1022 | else |
|---|
| 1019 | 1023 | { |
|---|
| 1020 | | first_field = (p_picture->b_top_field_first) ? |
|---|
| | 1024 | first_field = (p_pic->b_top_field_first) ? |
|---|
| 1021 | 1025 | XVMC_TOP_FIELD : XVMC_BOTTOM_FIELD; |
|---|
| 1022 | 1026 | } |
|---|
| … | … | |
| 1028 | 1032 | |
|---|
| 1029 | 1033 | XVMCLOCKDISPLAY( p_vout->p_sys->p_display ); |
|---|
| 1030 | | XvMCFlushSurface( p_vout->p_sys->p_display, p_picture->p_sys->xvmc_surf ); |
|---|
| | 1034 | XvMCFlushSurface( p_vout->p_sys->p_display, p_pic->p_sys->xvmc_surf ); |
|---|
| 1031 | 1035 | /* XvMCSyncSurface(p_vout->p_sys->p_display, p_picture->p_sys->xvmc_surf); */ |
|---|
| 1032 | 1036 | XvMCPutSurface( p_vout->p_sys->p_display, |
|---|
| 1033 | | p_picture->p_sys->xvmc_surf, |
|---|
| | 1037 | p_pic->p_sys->xvmc_surf, |
|---|
| 1034 | 1038 | p_vout->p_sys->p_win->video_window, |
|---|
| 1035 | 1039 | src_x, |
|---|
| … | … | |
| 1046 | 1050 | if( p_vout->p_sys->xvmc_deinterlace_method == 2 ) |
|---|
| 1047 | 1051 | { /* BOB DEINTERLACE */ |
|---|
| 1048 | | if( p_picture->p_sys->nb_display == 0 )/* && ((t2-t1) < 15000)) */ |
|---|
| 1049 | | { |
|---|
| 1050 | | mtime_t last_date = p_picture->date; |
|---|
| | 1052 | if( p_pic->p_sys->nb_display == 0 )/* && ((t2-t1) < 15000)) */ |
|---|
| | 1053 | { |
|---|
| | 1054 | mtime_t last_date = p_pic->date; |
|---|
| 1051 | 1055 | |
|---|
| 1052 | 1056 | vlc_mutex_lock( &p_vout->picture_lock ); |
|---|
| 1053 | 1057 | if( !p_vout->p_sys->last_date ) |
|---|
| 1054 | 1058 | { |
|---|
| 1055 | | p_picture->date += 20000; |
|---|
| | 1059 | p_pic->date += 20000; |
|---|
| 1056 | 1060 | } |
|---|
| 1057 | 1061 | else |
|---|
| 1058 | 1062 | { |
|---|
| 1059 | | p_picture->date = ((3 * p_picture->date - |
|---|
| | 1063 | p_pic->date = ((3 * p_pic->date - |
|---|
| 1060 | 1064 | p_vout->p_sys->last_date) / 2 ); |
|---|
| 1061 | 1065 | } |
|---|
| 1062 | 1066 | p_vout->p_sys->last_date = last_date; |
|---|
| 1063 | | p_picture->b_force = 1; |
|---|
| 1064 | | p_picture->p_sys->nb_display = 1; |
|---|
| | 1067 | p_pic->b_force = 1; |
|---|
| | 1068 | p_pic->p_sys->nb_display = 1; |
|---|
| 1065 | 1069 | vlc_mutex_unlock( &p_vout->picture_lock ); |
|---|
| 1066 | 1070 | } |
|---|
| 1067 | 1071 | else |
|---|
| 1068 | 1072 | { |
|---|
| 1069 | | p_picture->p_sys->nb_display = 0; |
|---|
| 1070 | | p_picture->b_force = 0; |
|---|
| | 1073 | p_pic->p_sys->nb_display = 0; |
|---|
| | 1074 | p_pic->b_force = 0; |
|---|
| 1071 | 1075 | } |
|---|
| 1072 | 1076 | } |
|---|
| … | … | |
| 1903 | 1907 | p_pic->p_sys->xxmc_data.decoded = 0; |
|---|
| 1904 | 1908 | p_pic->p_sys->xxmc_data.proc_xxmc_update_frame = xxmc_do_update_frame; |
|---|
| 1905 | | p_pic->p_accel_data = &p_pic->p_sys->xxmc_data; |
|---|
| | 1909 | // p_pic->p_accel_data = &p_pic->p_sys->xxmc_data; |
|---|
| 1906 | 1910 | p_pic->p_sys->nb_display = 0; |
|---|
| 1907 | 1911 | #endif |
|---|
| … | … | |
| 3082 | 3086 | if( i_query == VOUT_REPARENT ) d = (Drawable)va_arg( args, int ); |
|---|
| 3083 | 3087 | if( !d ) |
|---|
| | 3088 | { |
|---|
| 3084 | 3089 | #ifdef MODULE_NAME_IS_xvmc |
|---|
| 3085 | 3090 | xvmc_context_reader_lock( &p_vout->p_sys->xvmc_lock ); |
|---|
| … | … | |
| 3089 | 3094 | DefaultRootWindow( p_vout->p_sys->p_display ), |
|---|
| 3090 | 3095 | 0, 0 ); |
|---|
| | 3096 | } |
|---|
| 3091 | 3097 | else |
|---|
| 3092 | 3098 | XReparentWindow( p_vout->p_sys->p_display, |
|---|
| rd2d8554 |
r8d06898 |
|
| 340 | 340 | int i_len, i_color; |
|---|
| 341 | 341 | uint16_t *p_source = NULL; |
|---|
| 342 | | |
|---|
| | 342 | #if 0 |
|---|
| 343 | 343 | if (!sub_img) |
|---|
| 344 | 344 | return; |
|---|
| … | … | |
| 469 | 469 | dst_y += dst_pitch; |
|---|
| 470 | 470 | } |
|---|
| | 471 | #endif |
|---|
| 471 | 472 | } |
|---|
| 472 | 473 | |
|---|