Question about function

Dear After Effects community, I'm doing something wrong. I started with the example of skeleton and changed to what I thought, I want it to do, however, it does not work. I changed the "MySimpleGainFunc8" and "MySimpleGainFunc16" to look like this:

() MySimpleGainFunc16

void * Conref.

A_long xL,

A_long yL,

PF_Pixel16 * inP,

PF_Pixel16 * output)

{

PF_Err err = PF_Err_NONE

TempR PF_FpLong = 0;

PF_FpLong tempG = 0;

PF_FpLong TempB = 0;

Output->alpha = inP->alpha;

Output->Red ->Red + tempR inP = * 0.5;

Output->Green = inP->Green + tempG * 0.5;

Output->Blue = inP->Blue + tempB * 0.5;

tempR = inP->Red + tempR * 0.5;

tempG = inP->Green + tempG * 0.5;

tempB = inP->Blue + tempB * 0.5;

return err;

}

Now, what I want to do, it's for each image, the color of each pixel in the previous image should be averaged with the color of each respective pixel in the active frame. The function that I put in place now does not seem to work properly. When I apply the effect to a composition, nothing happens at all. Can someone please help me try to understand where I'm wrong. Thanks in advance!

I find it difficult to follow what exactly is happening there, but it seems that you are a little confused as to how the functions are defined, and where should things go exactly.

In your header file (formerly skeleton.h):

-Set your RenderData structure:

struct RenderData {}

PF_EffectWorld * prev_frame_world;

};

(It is noted here that you can put what you want in this struct - everything you may need to access in your function iterate).

In your main file (formerly skeleton.cpp):

-Set your sampler of pixel outside any other function:

Inline PF_Pixel * sampleIntegral32 (PF_EffectWorld & def, int x, int y) {}

return ((char*) def.data (PF_Pixel *) + (y * def.rowbytes) + (x * sizeof (PF_Pixel)));

}

(Note that I used 'inline' rather than 'static' - this will give you a hint to the compiler to Inline the contents of the service where you call SampleIntegral32 directly, but you can use static, if you want. For some reason, you had declared it as static PF_Err, which returns a PF_Err, rather than the PF_Pixel *)

-Your iterator or several functions:

() MySimpleGainFunc8

void * Conref.

A_long xL,

A_long yL,

PF_Pixel8 * inP;

PF_Pixel8 * output)

{

PF_Err err = PF_Err_NONE;

RenderData * render_data = reinterpret_cast(prevframe);

PF_Pixel * p_prev_frame = sampleIntegral32 (render_data-> prev_frame_world, xL, yL);

Output-> alpha = (inP-> alpha) + p_prev_frame-> alpha * 0.5; I think that's what you wanted to do, no?

etc...

return err;

}

-Your function of rendering:

PF_EffectWorld is exactly the same as PF_LayerDef. You withdraw your OK setting (even if the parameter ID "SKELETON_GAIN" is probably a cursor rather than the input layer. You can use 0 (zero) here, as the first parameter is always the PF_EffectWorld of entry, but read on, the first param is the enum SKELETON_INPUT, so we will use.

PrevFrame PF_ParamDef = {};

ERR (PF_CHECKOUT_PARAM (in_data,

SKELETON_INPUT,

in_data-> current_time - (1 * in_data-> time_step), / / I think it's a good...

-> time_step in_data,

in_data-> time_scale,

& prevframe));

When you go wrong here is that you are trying to make a PF_ParamDef to a PF_EffectWorld in your render data. You must point the layer data instead:

RenderData render_data;

render_data.prev_frame_world = & prevframe.u.ld;     Point your def of layer prev_frame_world pointer in the union

ERR (suites. Iterate8Suite1()-> iterate (in_data,

0, / / basic course

output-> height, / / final course. Use linesL if you set as on the skeleton model

& params [SKELETON_INPUT]-> u.ld, / / src

NULL, / / area - null for all pixels

(void *) & render_data, / / Conref - your custom data pointer

MySimpleGainFunc8, / / function pixel pointer

output));

Check in this setting!

Err2 (PF_CHECKIN_PARAM (in_data & prevframe));

And it should work I think! It's not tested, but the basics are there.

Tags: After Effects

Similar Questions

  • Question about functions in pipeline

    Version: Oracle Database 11 g Enterprise Edition Release 11.2.0.2.0 - 64 bit Production

    Hello

    I have a Pipelined function is used in a 4.1.1.00.23 APEX application. The function should return an array object to use in the WHERE clause of the query. So far, all of the values used in the function have been digital. Now, I have alphanumeric values and I get an error 'Character of digital Conversion'.

    A Pipelined can only use digital data?

    The function of reference is:

    FUNCTION to CREATE or REPLACE get_list (p_string in VARCHAR2
    , p_delimiter IN VARCHAR2 DEFAULT ':'
    )
    RETURN vc_array_1
    PIPELINED

    IS

    l_array wwv_flow_global.vc_arr2; -Creates a table type.

    BEGIN

    l_array: = APEX_UTIL.string_to_table (p_string, p_delimiter); -API to separate a delimited string colon by in a table.

    BECAUSE me IN l_array. FIRST... l_array. LAST
    LOOP
    LINE (TRIM (l_array (i)));
    END LOOP;

    RETURN;

    END;

    I thought that, given that the parameters are of type VARCHAR2 passing a valid value could be used. Apparently, I'm wrong?

    The WHERE clause that is used is in the format:

    ...

    WHERE < column_name > IN (SELECT * FROM TABLE (get_list (: P127_BASELINE_INIT_NAME)))

    ...

    If only the digital data can be used, how to use alpha-numeric values?

    Thank you

    Joe

    Stako, Anton and Jason thanks for your help!

    While I was waiting for my company to get the security put in place so that I could use sqlplus I was talking about this problem with another developer and it turns out that the function had NOTHING to do with this problem.

    It was all the me. The values passed into the function is from a Select list that allows multiple selectable values and this is whence the colon delimited string.

    IF no value is selected, it is a default value that can be used to not limit the number of rows in the WHERE clause. I used a 0 (zero) as a return value, so as the data type of the column is VARCHAR2 he compared a numeric character; where the error.

    The "bug" has been corrected and of course no error!

    Thank you all again!

    Thank you

    Joe

  • Question about function keys and cards Flash on my Satellite A210 - 10 c

    Hi people,

    I reinstall Vista without the recovery CD and now the FN keys work, but not all. That is, I can't lock the Touchpad and the FlashCards also didn't come down, if I press a FN key.
    The user darksys tell about it (http://forums.computers.toshiba-europe.com/forums/click.jspa?searchID=172641&messageID=100112) it is useful to install the Flash memory card Support utility that is not available on the European download Site. So I downloaded it from the Canadian Site, but during the Installation it tells me I have an invalid Nummber Serial? !!
    I have a satellite A-210-10 c (model Nummber: PSAEGE-xyz). So I think the installation tells me I have an invalid series because it's for another series of model.

    Its boring, the drafting of a text, and then suddenly the mouse jump lent else because I press the button by mistake...

    So I hope that someone could help.

    So long...

    Hello

    Check the support site of Toshiba Europe again to see if there is ever a version for VAP. I have a A200 and there was a problem with VAP installed in the recovery image.

    I deleted it from the system and installed the latest version of the Toshiba support page. Now, by pressing the key of KN, flash cards appear very fast and I can use al of them without any problem.

    Also check the touchpad settings. There must be also the option to disable touchpad.

  • Question about function table in pipeline

    I did an object:
    CREATE TYPE FML_DAT_ITEMS_OBJ AS OBJECT ("F0"      varchar2(4000), ...
    Then I did an object table:
    create or replace type fml_dat_items_ftab is table of FML_DAT_ITEMS_OBJ
    Everything is fine!

    Now, I want to do the function pipeline:
    create or replace 
    FUNCTION get_fml_items_dat (pfml_nr in number) return fml_dat_items_ftab pipelined as
      
       out_rec FML_DAT_ITEMS_OBJ := FML_DAT_ITEMS_OBJ() ;
       
      begin
         select item_dat into out_rec."F0" from fml_dat_items where fml_nr = pfml_nr and item_nr=   0.00;
         pipe row (????); -- HOW can I pipe the object to the function result set?
    Published by: Walter on 14.05.2013 05:29

    Hello

    Try this:

    create or replace type FML_DAT_ITEMS_OBJ AS OBJECT
    (
    f_name varchar2(20)
    ,l_name varchar2(20)
    )
    ;
    
    create or replace type fml_dat_items_ftab as table of FML_DAT_ITEMS_OBJ
    ;
    
    select
      *
    
    from
      table(fml_dat_items_ftab(FML_DAT_ITEMS_OBJ('peter', 'zwan')
                              ,FML_DAT_ITEMS_OBJ('peter', 'zwan')
                              )
            )
    ;
    F_NAME               L_NAME
    -------------------- --------------------
    peter                zwan
    peter                zwan                 
    
    create or replace
    FUNCTION get_fml_items_dat (pfml_nr in number) return fml_dat_items_ftab pipelined as
    
    --   out_rec FML_DAT_ITEMS_OBJ := FML_DAT_ITEMS_OBJ() ;
      out_rec FML_DAT_ITEMS_OBJ ;
    begin
       select FML_DAT_ITEMS_OBJ('peter', 'zwan') into out_rec from dual;
    
      for i in 1 .. pfml_nr loop
        pipe row (out_rec);
      end loop;
    
    end get_fml_items_dat;
    /
    
    select
      *
    from
      table(get_fml_items_dat(2))
    ;
    
    F_NAME               L_NAME
    -------------------- --------------------
    peter                zwan
    peter                zwan                 
    

    Hope this helps,

    Kind regards

    Peter

  • question about function in one of the CC of economics programs

    At work, I use a PC and at home, I use an Imac. When I work on my PC, for example Illustrator and use the Save as function to keep the old file and create a new version with the last correction. As soon as I clicked on save as and name the new file that I find myself with the new file in the window of my illustrator. So that I can continue to work on the new file without overwriting the original. However on my Imac I always find myself with the original, and the new version is stored whenever I taped. Several times I clicked Save I think I work in a new file and then lost my original CD. How can I change the settings so that when I choose to save as the new file replaces the Moose and Moose is stored safely? I consulted a few other mac owners and none have the same setting. Anyone know if this is a setting that I can change?

    Thank you!

    Looks like you're confusing 'Save a Copy' and 'record under. At least on Mac 'Save a Copy' leave the original file open while 'record under"let the newly named file open.

  • Question about functionality

    One of my requirements is to create. PNG files with transparent backgrounds incorporating images imported with deleted circles usung the Tools eraser and brush. Is this possible using elements? If this is not the case, what product (s) of the suite, Adobe will provide this feature? Thanks in advance

    Yes it can. You use the "Save for Web" feature, select PNG (8 or 24 bit) and check the box 'transparency '. There are a variety of tools that can be used to remove the background, including a conveniently called "gum background."

    See you soon,.
    --
    Neale
    Insanity is hereditary, get you your children

    If this post or by post from another user solves the original problem, please mark as correct and/or useful messages accordingly. This helps other users with similar trouble getting answers to their questions more quickly. Thank you.

  • Question about 'functions of confidence. "

    Ref: "JavaScript for Acrobat QAnywhere," pp. 32-143-145.

    I need to let my JavaScript is running in a privileged context to allow this.mailForm (.) run without user intervention.  The reference above p. 144 tells me how to "mark a function as being approved." This is for me a script for a 'trustedNewDoc' function to put in a .js file that she "can be run of anywhere", but "cannot normally be executed by a mouse event."

    Please tell me How to attach this .js to my PDF file.

    (I know HTML, I can attach a file with the line .js):
    < script type = "text/javascript" src = "config.js" > < / script >
    "(but I don't know how to do it with a PDF document on my website)."

    It loads to the predetermined location when Acrobat/Reader is open. For more information, see: http://acrobatusers.com/tutorials/2006/folder_level_scripts/

  • Question about function. Pretty simple id assume

    Scene 1: Part 1, I have 2movie clips. Say MC1 and MC2.

    On the frame, I have the function:

    function my_func()

    {_root. MC2.nextFrame (); }

    then, inside MC1, I my_func();

    What is the problem, how to operate.

    inside MC1, you must use:

    _parent. My_Func();

  • question about functions on a calendar...

    Hi, if the following code is from the first image of a chronology:

    stage.addEventListener (MouseEvent.MOUSE_MOVE, message_follow);

    function message_follow(Event:MouseEvent):void {}

    follow_cursor_mc.x = 475;

    follow_cursor_mc.y = parent.ymouse + 80;

    updateAfterEvent();

    }

    This.following_cursor_mc. Visible = false;

    However, the clip "follow_cursor_mc" is only available in 10 to 20 frames... each of these frameworks has: a unique content, navigation between the other controls frames from 10 to 20, a "stop(); action and finally the code to make the visible follow_cursor_mc, "this.follow_cursor_mc.visible = true;"
    The thing is, the follow-up of the cursor should be visible on the images of 10 to 20.  But, where the follow_cursor_mc of film clip must be placed?  On the first frame of the movie - even if it's just remains invisible until the frames 10-20?
    Where should I put this follow_cursor_mc and the above code referring to it?
    If the clip in one of the frames to nine - albeit invisible - is not otherwise ineffective?  Not bad will load on the first image... could just start on frame 10, and cover all the way to 20... with the above code is placed on the framework one?
    If (listener and function) code is repeated on each picture between 10 and 20, duplicate error messages are thrown.
    I'm just not sure where to put this code and its music video accompanying it.
    Thank you...

    The object must exist when the code exists.  The object might have only one key image and expand some length of executives, rather than having several keyframes for that.  If you would like this invisible object in frames 1-9, then just set its visible property to zero for this range of cells.  Then set it to visible in frame 10 and assign it this code there as well.

  • question about function cont

    Hi all
    table rg_types / / DESC
    LIDER number (5),
    SERIAL_N number (8).
    CODE_T number (3)
    Number TYPE_I (1),
    SHIPMENT_NUM number 4
    No p.k on table or a unique index.
    TYPE_I can contain the values vary [0-5].
    for each leader can be sug_i [0-5].
    Select * from rg_type by SHIPMENR_NUM, TYPE_I, LIDER
    LIDER SERIAL_N CODE_T TYPE_I SHIPMENT_NUM
    11 956307 1 0 564
    11 956308 1 0 564
    11 956309 1 1 564
    400 956310 3 0 564
    500 956311 1 2 564
    600 956312 1 5 564
    600 956313 1 5 564
    200 956314 1 0 565
    400 956315 3 4 565
    700 956316 1 5 565
    .
    Note that not all of the lider appear in every shipment_num, every doe'nt lider must also has all the type_i all shipment_num (could be, but need not be)
    I need to run a query that will show all the lider how
    many types of each type (0-5)
    spomething like that
    TYPE_I
    0 1 2 4 5 LIDER
    ___________________________________________________________
    11-2-1
    1 200
    400 1 1
    1 500
    2 600
    1 700
    Help, please
    Thanks in advance
    Naama

    Lack of expression is the expression of the column before you leave (sorry, my mistake) finished with a comma

    select lider,
           max(decode(type_i,0,the_count)) count_0,
           max(decode(type_i,1,the_count)) count_1,
           max(decode(type_i,2,the_count)) count_2,
           max(decode(type_i,3,the_count)) count_3,
           max(decode(type_i,4,the_count)) count_4,
           max(decode(type_i,5,the_count)) count_5  /* a comma was left here by mistake */
      from (select lider,type_i,count(*) the_count
              from rg_type
             group by lider,type_i
           )
     group by lider
     order by lider
    

    the subselect Gets the counties you are looking for and your problem could be solved already
    but
    you want to type_i County of each leader appear as a column line that lider (bringing rows of columns is called pivoting)
    to get there you first

    select lider,
           decode(type_i,0,the_count) count_0,
           decode(type_i,1,the_count) count_1,
           decode(type_i,2,the_count) count_2,
           decode(type_i,3,the_count) count_3,
           decode(type_i,4,the_count) count_4,
           decode(type_i,5,the_count) count_5
      from (select lider,type_i,count(*) the_count
              from rg_type
             group by lider,type_i
           )
     order by lider
    

    and then use max to get rid of all these null values getting a single line for each value of lider

    Concerning

    Etbin

    p.s. I have not access database error of free detailed examples

  • Ask questions about the functionality of EA8500 MU-MIMO

    Dear Linksys

    I bought EA8500, and it arrived today.

    I have two questions about the functionality of MU-MIMO of EA8500 AP.

    1. I want to compare the performance between SU-MIMO and MU-MIMO, but there is no option to control this feature in the router admin page. Is that one of the possible ways?

    2 EA8500 supports 1733 Mbps wireless speed, but it resembles the speed of 1 Gbps ethernet cable.

    This router supports really speed 1 Gbps ethernet? or y at - it an option to support more throughput as the aggregation of links?

    Thank you

    Hi, hyeonu. For your first query, it is not possible because there is no option to disable the feature of MU-MIMO on your Linksys EA8500 router. In addition, with regard to your second, you can get a higher throughput of 1 Gbps since this is the maximum capacity of your ethernet connection.

  • Question about DISCHARGE (expr, 1016) function

    Hello

    I have a question about the DUMP function, specifically the DUMP (expr, 1016). What character set is the function of report? The only logical answer seems to me the characters of data. The http://download.oracle.com/docs/cd/E11882_01/server.112/e17118/functions055.htm#SQLRF00635 docs it says: "by default, the return value contains no character set information. To retrieve the name of character of expr, add 1000 to all the values of previous format. "For example, a return_fmt of 1008 returns the result in octal * and provides the character set name of expr.*.

    I ask this question because a client complains that there a database with database EE8MSWIN1250 (obtained from DATABASE_PROPERTIES) characters and when I asked him to run a SELECT that could empty the contents of a column, he gave me this result:
    select dump(some_col, 1016) from some_table;
    
    Typ=1 Len=8 CharacterSet=AL32UTF8: c5,bd,c5,a0,54,45,53,54
    Now I can't imagine how the data can be stored in the AL32UTF8 character set if the characters of the database are EE8MSWIN1250. This scenario is still possible? I tried in vain to reproduce on my test database.

    I don't know if the column is defined with the characters of database or the national database characterset, but even if it was a NVARCHAR2, the dump function could not return AL32UTF8 since he is not a national character set.

    If anyone has an explanation, I will be very grateful.

    Thanks in advance and best regards,
    Swear

    1. to help with the confusion about the DUMP function: index realizes that the DUMP function can be performed in the remote database. Oracle tries to push as many functions as possible and semantically correct on the remote site. Therefore, it sends the statement of simple table on the remote site after stripping the DB link. In this case, the DUMP function sees the character set of the remote database and creates the resulting string of information. This string of AL32UTF8 to EE8MSWIN1250, as described in the note, but as all the characters in the string of information are pure ASCII, some codes are actually changed.

    Things get more interesting if you start to combine the tables of local and remote databases. For example, the following query is will normally return the character of local database defined for the two columns:

    select dump(xx,1016),dump(yy,1016) from (select x.dummy xx, y.dummy yy from dual x, dual@dblink y);
    

    This is because the first dual@dblink is transported to the local site and the join is performed here with application of DUMP.

    The following query returns the set for two columns of characters in remote database:

    select dump(xx,1016),dump(yy,1016) from (select x.dummy xx, y.dummy yy from dual@dblink x, dual@dblink y);
    

    This is because all the tables are remote and the entire query is sent to the remote database and y.

    The following query returns the remote character set thus:

    select dump(xx,1016),dump(yy,1016) from (select /*+driving_site(y)*/ x.dummy xx, y.dummy yy from dual x, dual@dblink y);
    

    Here, the DRIVING_SITE hint asks the database to perform the join in the database of the table, for example dual@dblink.

    2. to answer your question:

    Your understanding of the way of conversion is generally correct, but conclusions are not quite correct. In the scenario [client EE8ISO8859P2, EE8MSWIN1250 local database, remote database AL32UTF8], Eastern and Central European characters will work correctly, but the other characters to the remote database will not be (for example, French, Greek, Chinese). It is, I think, quite clear and is usually not a major problem, as usually only compatible languages EE8 are interesting for an EE8ISO8859P2 customer. However, in the scenario [customer AL32UTF8, EE8MSWIN1250 local database, remote database AL32UTF8], the problem becomes more visible. Having a taking customer support Unicode, you can recover some data French or Greeks of the remote database but you will fail as all of these characters will be "killed" by the conversion of distance at the local level (link DB conversion).

    EE8ISO8859P2 is also for the same group of languages, such as EE8MSWIN1250, indeed, but it lacks some interesting characters. The most important of them is the symbol of the Euro. Others are "' quotes, long dashes, TM symbol, and a few other less frequently used punctuation. Therefore, always define a database as EE8MSWIN1250, even if you run some clients (Unix) with EE8ISO8859P2. Do not run Windows with EE8ISO8859P2 clients, except for purposes of loading/generation of special file.

    -Sergiusz

  • Question about to_date() function?

    Hello
    I have a question about the to_date() function.
    I am aware that for the to_date() function, we should give the format of the input string.
    My current settings for the NLS_DATE_FORMAT parameter in the NLS_SESSION_PARAMETERS table is "DD-MON-YY."
    Then, when I give
    SELECT TO_DATE('15-DEC-2008','DD/MM/YY') it should error out because the format is not same as the format of the input string('DD-MON-YY').
    But this isn't any error out.why?
    Also please tell me if the format of SYSDATE is taken NLS_SESSION_PARAMETERS table or another table.

    Please take a look at Unexpected result with to_date

  • I have a question about the functionality of Oracle Identity Manager...?

    Hi friends
    I have a question about the features of Oracle Identity Manager.
    Here's my question:
    Self-management is possible network passwords (reset / unlock) with Oracle Identity Manager 9.1.0.2

    Very grateful.

    What Kevin suggested this means that you are managing accounts and their password by IOM. If your condition is the same then follow:

    Re: error during password reset using the self-service portal

  • Question about "Windows 8.1 DG to Windows 7 Pro 64-bit" and Windows product key

    I have acquired a recnet ThinkPad T450 fdrom a retialer online (NCIX) and I hav ea a few questions about the installed Windows operating system.

    Before I just go further, HRE are some information about my particular system.

    Lenovo ThinkPad T450

    Model: 20BV00BUS

    CPU: Intel Core i5-4300U

    RAM: 4 GB

    Under the product description, it was stated "Windows 8.1 DG Windows 7 Pro 64." My understnading, the ThiknPad has been installed with Windows 8.1, but downgraded to Windows 7. There is also a Windows 8 Pro badge sticker at the bottom of the matchine.

    Is it possible, at the end of the user/consumer, to alter the functioning ti repressive back Windows 8.1?

    Can I create a recovery with Windows 8.1 disk?

    A separate but related matter relates to the Windows product key.

    I noticed the Ultrabook do not come with a sticker / label with the Windows product key (i.e. COST). Some quick research indicated that the Windows key is programmed into the BIOS.

    This indeed true (I wish an audit)?

    The key is visible in some way (for when you need to reinstall the operating system. I have not tried to enter the BIOS at the moment)?

    Thank you for taking the time to consider my question.

    Kind regards

    Victor L.

    Hi Victor,

    I'm in the same boat as you type, but want to keep the facilities of Windows 7 rather than pass them to 8. Just like you, I buy our Lenovo from different retailers and they come with windows 7 installed through the Windows 8 lower upgrade program.

    We had one or two laptops come with a recovery media (for windows 8/8.1 only) but have noticed that all laptops now come with no physical media or codes for the recovery. WIN8 stickers, you described is more came with the license key on the sticker (it comes to stop you using the same license again and again, microsoft will get more money if you buy another license etc.). I also saw that the key is essentially located in the BIOS but were not able to test what we use any of windows 8. I use it even at home!

    To answer your question, you can get a recovery of Lenovo for Windows 8 media!

    Go to the following link: https://support.lenovo.com/us/en/lenovorecovery

    (It help you understand why this method is used on this page as well)

    Select Start,

    Please have your serial number of your laptop, (to find it go to this link: https://support.lenovo.com/us/en/find-product-name)

    If you qualify (which you will very probably) Lenovo will ship for free, recovery disks give it a go, took me 2 minutes.

    I hope this helps.

    Best regards, Max.

Maybe you are looking for