Welcome Dialog

Welcome to the Community!

We have a brand new look! Take a tour with us and explore the latest updates on Adobe Support Community.


Use header to define PiPL .r and .rrc

Participant ,
May 19, 2021 May 19, 2021

Copy link to clipboard

Copied

For reference, here are 2 threads with a similar issue - https://community.adobe.com/t5/after-effects/how-do-people-manage-versioning-their-pipls/m-p/1048407... and https://community.adobe.com/t5/after-effects/pipl-and-code-version-mismatch-warning/m-p/5531272#M136...

 

I have defined a header - VersionInfo.h with

#define	MAJOR_VERSION	1
#define	MINOR_VERSION	1
#define	BUG_VERSION		0
#define	STAGE_VERSION	PF_Stage_DEVELOP
#define	BUILD_VERSION	1
#define Product_MatchName "PRSY Blrs"
#define VENDOR_NAME "Prosya"
#define PRODUCT_NAME "Blurs"

#define RESOURCE_VERSION	MAJOR_VERSION * 524288 + MINOR_VERSION * 32768 + \
BUG_VERSION * 2048 + STAGE_VERSION * 512 + BUILD_VERSION

If I use these values inside ProductPiPL.r file I get compile errors.

#include "Win\VersionInfo.h"

/* [2] */
Name {PRODUCT_NAME},
/* [3] */
Category {VENDOR_NAME},
/* [8] */
AE_Effect_Version {RESOURCE_VERSION},
/* [12] */
AE_Effect_Match_Name {Product_MatchName},

1>ProductPiPL.r
1>ParseAEEffectVersion: CloseBrace Expected, line 7413
1>Microsoft (R) C/C++ Optimizing Compiler Version 19.28.29915 for x64
1>Copyright (C) Microsoft Corporation.  All rights reserved.
1>
1>ProductPiPL.rrc
1>c1 : fatal error C1083: Cannot open source file: 'D:\build\Product\x64\Release\ProductPiPL.rrc': No such file or directory
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Microsoft\VC\v160\Microsoft.CppCommon.targets(240,5): error MSB8066: Custom build for '..\ProductPiPL.r' exited with code 2.
1>Done building project "Product.vcxproj" -- FAILED.
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========

 

I use this inside the main effect in About() and GlobalSetup() and there are no compile issues

static PF_Err About(PF_InData* in_data, PF_OutData* out_data, PF_ParamDef* params[], 
PF_LayerDef* output) {

AEGP_SuiteHandler suites(in_data->pica_basicP);

suites.ANSICallbacksSuite1()->sprintf(out_data->return_msg,
"%s v%d.%d  - ©, %d, Company Pvt. Ltd.\nDescription.\n", PRODUCT_NAME, 
MAJOR_VERSION, MINOR_VERSION, getYear());
return PF_Err_NONE;
}

static PF_Err GlobalSetup(PF_InData* in_data, PF_OutData* out_data, 
PF_ParamDef* params[], PF_LayerDef* output) {
AEGP_SuiteHandler suites(in_data->pica_basicP);
out_data->my_version = PF_VERSION(MAJOR_VERSION, MINOR_VERSION,
		BUG_VERSION,STAGE_VERSION,BUILD_VERSION);

 

TOPICS
SDK

Views

81

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Participant , May 19, 2021 May 19, 2021
Got the answer from here - https://community.adobe.com/t5/after-effects/pipl-quot-version-mismatch-quot/td-p/11024001 I replaced#define RESOURCE_VERSION MAJOR_VERSION * 524288 + MINOR_VERSION * 32768 + BUG_VERSION * 2048 + STAGE_VERSION * 512 + BUILD_VERSIONWith#define RESOURCE_VERSION (MAJOR_VERSION << 19) + (MINOR_VERSION << 15) + (BUG_VERSION << 11) + BUILD_VERSION

Likes

Translate

Translate
Participant ,
May 19, 2021 May 19, 2021

Copy link to clipboard

Copied

LATEST

Got the answer from here - https://community.adobe.com/t5/after-effects/pipl-quot-version-mismatch-quot/td-p/11024001

 

I replaced

#define RESOURCE_VERSION MAJOR_VERSION * 524288 + MINOR_VERSION * 32768 + BUG_VERSION * 2048 + STAGE_VERSION * 512 + BUILD_VERSION

With

#define RESOURCE_VERSION (MAJOR_VERSION << 19) + (MINOR_VERSION << 15) + (BUG_VERSION << 11) + BUILD_VERSION

 

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines