Re: [Libav-user] Unable to link libavutil with libswscale !

2016-08-04 Thread ssshukla26
Yes will follow ffmpeg standards when submitting patch on ffmpeg-devel, this
was a rough patch submitted for discussion.

What I get from you response is that we didn't need any changes in
*libavutil* if we are able to provide correct *linesize[]* array ?

Please refer to this  repo
<https://github.com/ssshukla26/NV12Tile-To-NV12-Conversion>   which we have
used to implement *size[]* array inside *av_image_fill_pointers* function.

Can you please help us to put correct *AVPixFmtDescriptor.comp* values for
nv12_tiled format under *libavutil/pixdesc.c *, so that we can get actual
linesize[] array ?

For AV_PIX_FMT_NV12_TILED format we are right now only doing nv12_tiled to
yuv420p conversion, hence do we need to implement it as only input format ?





--
View this message in context: 
http://libav-users.943685.n4.nabble.com/Libav-user-Unable-to-link-libavutil-with-libswscale-tp4662334p4662399.html
Sent from the libav-users mailing list archive at Nabble.com.
___
Libav-user mailing list
Libav-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/libav-user


Re: [Libav-user] Unable to link libavutil with libswscale !

2016-08-02 Thread Carl Eugen Hoyos
Hi!

Sorry for the late answer!

Why are the functions that you put into libavutil/special_format.c not
in libswscale?
You should be able to provide a correct linesize[] array for the
actual input data,
then you should not need the functions in libavutil, or do I miss something?

> + [AV_PIX_FMT_NV12_TILED] = { 1, 1 },

I don't think you implemented nv12_tiled as output format, so this is wrong.

All new files need license headers, and please try to follow the FFmpeg coding
style, especially braces.

Carl Eugen
___
Libav-user mailing list
Libav-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/libav-user


Re: [Libav-user] Unable to link libavutil with libswscale !

2016-07-10 Thread ssshukla26
Attaching the patch. PFA.  0001-NV12-Tile-pixel-format-support-added.patch
<http://libav-users.943685.n4.nabble.com/file/n4662340/0001-NV12-Tile-pixel-format-support-added.patch>
  

I have just changed the file name *nv12tiledconversion.c* to
*nv12tiled2nv12.c*.

Note :- We are planning to upstream this patch when everything falls right
in its place.



--
View this message in context: 
http://libav-users.943685.n4.nabble.com/Libav-user-Unable-to-link-libavutil-with-libswscale-tp4662334p4662340.html
Sent from the libav-users mailing list archive at Nabble.com.
___
Libav-user mailing list
Libav-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/libav-user


Re: [Libav-user] Unable to link libavutil with libswscale !

2016-07-08 Thread Carl Eugen Hoyos
ssshukla26  writes:

> My question is how can I compile the ffmpeg libraries 
> *without including* special_format.o object reference 
> under libswscale Makefile ? 

Please provide the patch you have prepared so far so 
we can understand your issue more easily.

Thank you, Carl Eugen


___
Libav-user mailing list
Libav-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/libav-user


[Libav-user] Unable to link libavutil with libswscale !

2016-07-08 Thread ssshukla26
We are adding *nv12 tile* to *yuv420p* format conversion support in
*libswscale*. While adding the support we also found out that the size
calculation under *av_image_fill_pointers function* under
*libavutil/imgutils.c* file also needed to be changed. 

Hence we added support under *libavutil* by making two new files
*special_format.c* and *special_format.h*, and used it along with
*imgutils.c*. 

This special_format.h is consist of four functions namely,
nv12tile_calc_wTiles
nv12tile_calc_hTiles
nv12tile_calc_boundary_padding
nv12tile_calc_plane_size

We used this functions by including *special_format.h* inside
*nv12tileconversion.c* file (our conversion algo is placed in this file)
inside *libswscale* as follows. 
...
...
*#include "libavutil/special_format.h"*
...
...

But on compiling its giving the below errors.

---
libswscale/libswscale.so: undefined reference to `nv12tile_calc_wTiles'
libswscale/libswscale.so: undefined reference to `nv12tile_calc_plane_size'
libswscale/libswscale.so: undefined reference to `nv12tile_calc_hTiles'
collect2: error: ld returned 1 exit status
make: *** [ffplay_g] Error 1
make: *** Waiting for unfinished jobs
libswscale/libswscale.so: undefined reference to `nv12tile_calc_wTiles'
libswscale/libswscale.so: undefined reference to `nv12tile_calc_plane_size'
libswscale/libswscale.so: undefined reference to `nv12tile_calc_hTiles'
collect2: error: ld returned 1 exit status
make: *** [ffprobe_g] Error 1
libswscale/libswscale.so: undefined reference to `nv12tile_calc_wTiles'
libswscale/libswscale.so: undefined reference to `nv12tile_calc_plane_size'
libswscale/libswscale.so: undefined reference to `nv12tile_calc_hTiles'
collect2: error: ld returned 1 exit status
make: *** [ffserver_g] Error 1
libswscale/libswscale.so: undefined reference to `nv12tile_calc_wTiles'
libswscale/libswscale.so: undefined reference to `nv12tile_calc_plane_size'
libswscale/libswscale.so: undefined reference to `nv12tile_calc_hTiles'
collect2: error: ld returned 1 exit status
make: *** [ffmpeg_g] Error 1
---

To solve this we added the lines (in bold as show below) in *Makefile* under
*libswscale*,

---
include $(SUBDIR)../config.mak

NAME = swscale

HEADERS = swscale.h \
  version.h \

OBJS = alphablend.o \
   hscale.o \
   hscale_fast_bilinear.o   \
   gamma.o  \
   input.o  \
   options.o\
   output.o \
   rgb2rgb.o\
   slice.o  \
   swscale.o\
   swscale_unscaled.o   \
   utils.o  \
   yuv2rgb.o\
   vscale.o \
   nv12tiledconversion.o \
*   ./libavutil/special_format.o \*
   
OBJS-$(CONFIG_SHARED)+= log2_tab.o

# Windows resource file
SLIBOBJS-$(HAVE_GNU_WINDRES) += swscaleres.o

TESTPROGS = colorspace  \
swscale
---

My question is how can I compile the ffmpeg libraries *without including*
special_format.o object reference under libswscale Makefile ? 

The reason why am asking this questions is that I have seen many files under
libswscale using files from under libavutil and they are compiling fine, but
am not able to find out why we are facing this errors ! Please help.

*Note* :- configuration of ffmpeg is as show below.

export SDL_PATH=../sdl/

./configure  --enable-shared --enable-nonfree --enable-pic --enable-gpl
--extra-cflags="-I$SDL_PATH/include/SDL/" --extra-ldflags="-L$SDL_PATH/lib/
-lSDL"



--
View this message in context: 
http://libav-users.943685.n4.nabble.com/Libav-user-Unable-to-link-libavutil-with-libswscale-tp4662334.html
Sent from the libav-users mailing list archive at Nabble.com.
___
Libav-user mailing list
Libav-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/libav-user