We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
https://github.com/SergeyMakeev/Goofy/blob/master/GoofyTC/goofy_tc.h#L1453
blRangeY.m128i_u8[0] is not available outside MSVC.
blRangeY.m128i_u8[0]
Possible replacement (and I am no expert in using processor intrinsics):
alignas(16) unsigned char m128i_u8[16]; _mm_storeu_si128((__m128i*)m128i_u8, blRangeY); const uint32_t block0a = etc1BrighnessRangeTocontrolByte[m128i_u8[0]] | ((baseColors.r0 << 3ull) & 0xFFFFFF);
Seems to work OK for me.
Some other things needed
#if defined(__GNUC__) || defined(__clang__) # define ALIGN(x) __attribute__ ((aligned(x))) # define goofy_inline __attribute__((always_inline)) inline # define goofy_restrict __restrict #elif defined(_MSC_VER) # define ALIGN(x) __declspec(align(x)) # define goofy_restrict __restrict # define goofy_inline __forceinline #else # error "Unknown compiler; can't define ALIGN" #endif // constants ALIGN(16) static const uint32_t gConstEight[4] = { 0x08080808, 0x08080808, 0x08080808, 0x08080808 }; ALIGN(16) static const uint32_t gConstSixteen[4] = { 0x10101010, 0x10101010, 0x10101010, 0x10101010 }; ALIGN(16) static const uint32_t gConstMaxInt[4] = { 0x7f7f7f7f, 0x7f7f7f7f, 0x7f7f7f7f, 0x7f7f7f7f };
Possibly also x86intrin.h instead of immintrin.h
x86intrin.h
immintrin.h
Also, the program completely fails if compressETC1 is not wrapped in #pragma optimize( "", off ).
#pragma optimize( "", off )
The text was updated successfully, but these errors were encountered:
Successfully merging a pull request may close this issue.
https://github.com/SergeyMakeev/Goofy/blob/master/GoofyTC/goofy_tc.h#L1453
blRangeY.m128i_u8[0]
is not available outside MSVC.Possible replacement (and I am no expert in using processor intrinsics):
Seems to work OK for me.
Some other things needed
Possibly also
x86intrin.h
instead ofimmintrin.h
Also, the program completely fails if compressETC1 is not wrapped in
#pragma optimize( "", off )
.The text was updated successfully, but these errors were encountered: