diff --git a/testsuite/docs-examples-cpp/ref/out-arm.txt b/testsuite/docs-examples-cpp/ref/out-arm.txt new file mode 100644 index 0000000000..1de718a808 --- /dev/null +++ b/testsuite/docs-examples-cpp/ref/out-arm.txt @@ -0,0 +1,112 @@ +example_output_error1 +error: Uninitialized input image +example_output_error2 +error: Uninitialized input image +example_zero +example_fill +example_checker +example_noise1 +example_noise2 +example_point +example_lines +example_box +example_text1 +example_text2 +example_channels +example_channel_append +example_copy +example_crop +example_cut +example_paste +example_rotate_n +example_flip_flop_transpose +example_reorient +example_circular_shift +example_rotate +example_resize +example_resample +example_fit +example_warp +example_make_texture +zero1.exr : 512 x 512, 3 channel, half openexr + SHA-1: 95823C334FCE55968E8D2827CCD1CF77CEE19ABD +zero2.exr : 256 x 256, 4 channel, half openexr + SHA-1: 6A521E1D2A632C26E53B83D2CC4B0EDECFC1E68C +zero3.exr : 256 x 256, 4 channel, half openexr + SHA-1: 1254F2956229777B721576B94A6A944ECB806A37 +zero4.exr : 256 x 256, 4 channel, half openexr + SHA-1: 36EB49C5102703693C078717CE82AE05D4904680 +fill.exr : 640 x 480, 3 channel, half openexr + SHA-1: 1BBCA1D5966D02554C13C1FAEF01F6E6E6169356 +checker.exr : 640 x 480, 3 channel, half openexr + SHA-1: 64508259AE242B593B906C848A2D69C443A3FBFD +noise1.exr : 256 x 256, 3 channel, half openexr + SHA-1: 66FF64DDAFDDE290031C20FAA208A193908EE9D4 +noise2.exr : 256 x 256, 3 channel, half openexr + SHA-1: 06011F9D59106096F4742A3DAB458D506A08E34C +noise3.exr : 512 x 384, 3 channel, half openexr + SHA-1: 95EDBCA9953281CE63A3E18C7C04BCCB07CB4C8A +noise4.exr : 512 x 384, 3 channel, half openexr + SHA-1: 43BC1FDFA1F18635B635A57D71DB08BB347CBD46 +blue-noise.exr : 256 x 256, 4 channel, half openexr + SHA-1: 5A0A51D1AD3F34633B781AFF9B90E59996C31AD0 +point.exr : 640 x 480, 4 channel, half openexr + SHA-1: 56E2BDBE03826F203132BD9E80AF44450307BDCE +lines.exr : 640 x 480, 4 channel, half openexr + SHA-1: 177C4C5C61ACDD54F198A45E52836DE897C4CE96 +box.exr : 640 x 480, 4 channel, half openexr + SHA-1: 984273B0A06E54873E24A732651490117E40410C +text1.exr : 640 x 480, 3 channel, half openexr + SHA-1: 1CF68F9B099A30EFF06850CEFBEDD3C2F861A654 +text2.exr : 640 x 480, 3 channel, half openexr + SHA-1: 00C96AE28FD12752AD1968D3D07EE30F1F218D76 +channels-rgba.exr : 256 x 256, 4 channel, half openexr + SHA-1: C823E3701152B4B3C20DD79EA8A20CF4293F4B71 +channels-rgb.exr : 256 x 256, 3 channel, half openexr + SHA-1: 4074B050432CE7C664CEC4546A46E74F9A310CDC +channels-brga.exr : 256 x 256, 4 channel, half openexr + SHA-1: 04E09E64C61CEA1634D26FB2E6C733875D163671 +channels-alpha.exr : 256 x 256, 1 channel, half openexr + SHA-1: 99C332E70F321F0EA47C0F70AF8B0E3E6524F91F +channel-append.exr : 640 x 480, 5 channel, half openexr + SHA-1: E6A50C80C051F0F587FCB68B515B50E4DC3E9359 +copy.exr : 256 x 256, 4 channel, float openexr + SHA-1: 7044589C8B904DAF6A2BA3246224E97DD460AC93 +crop.exr : 200 x 100, 4 channel, half openexr + SHA-1: 4DA3918566D087A9D2D9E93B2A7BABE971FE6BBD +cut.exr : 200 x 100, 4 channel, half openexr + SHA-1: 4DA3918566D087A9D2D9E93B2A7BABE971FE6BBD +paste.exr : 256 x 256, 4 channel, half openexr + SHA-1: 67A4C36DEAED98A5A8ABA5F0E0EDE697345DC22A +rotate-90.exr : 256 x 256, 4 channel, half openexr + SHA-1: AFFAEA876E8E7760226B017B0A89A3549B7A5895 +rotate-180.exr : 256 x 256, 4 channel, half openexr + SHA-1: A5E42C5F18177DA146EC7E4567E4AE3AE2816C3C +rotate-270.exr : 256 x 256, 4 channel, half openexr + SHA-1: 46C803894186457376A0C590768C9DB4877737BB +flip.exr : 256 x 256, 4 channel, half openexr + SHA-1: A9EB9A8762BCD8DD161C00B01E2DF39E5C91B0D4 +flop.exr : 256 x 256, 4 channel, half openexr + SHA-1: 7C10717DB4F2E21F0B4F6D5404C660CA8B504F5E +rotate-45.tif : 256 x 256, 4 channel, uint8 tiff + SHA-1: E2E41264B7BD250C3AACF9F6161A0FA86B22FA57 +resize.tif : 320 x 240, 4 channel, uint8 tiff + SHA-1: 6FD1A7A97729CD6D51A22ADE0709CC4DFDC3C826 +resample.exr : 320 x 240, 4 channel, half openexr + SHA-1: 16FC7DCFE01DC312593B00B9F90D71BAF3D52450 +fit.tif : 240 x 240, 4 channel, uint8 tiff + SHA-1: 5474A93DED5F9F44E561B70A53F509677961AB34 +warp.exr : 256 x 256, 4 channel, half openexr + SHA-1: 7EA7EB6798E051B5F4EB3722498371E55869BC91 +transpose.exr : 256 x 256, 4 channel, half openexr + SHA-1: FAD57FB60460383D3D2D24B346F35A44846CCC39 +reorient.exr : 256 x 256, 4 channel, half openexr + SHA-1: 46C803894186457376A0C590768C9DB4877737BB +cshift.exr : 256 x 256, 4 channel, half openexr + SHA-1: 000F95FDC44D4DBDA8B4041C2506149C7AE28ACA +texture.exr : 256 x 256, 3 channel, half openexr (+mipmap) + SHA-1: 4074B050432CE7C664CEC4546A46E74F9A310CDC +Comparing "simple.tif" and "ref/simple.tif" +PASS +Comparing "scanlines.tif" and "ref/scanlines.tif" +PASS diff --git a/testsuite/docs-examples-cpp/ref/out.txt b/testsuite/docs-examples-cpp/ref/out.txt index e85770e361..a4518b73d6 100644 --- a/testsuite/docs-examples-cpp/ref/out.txt +++ b/testsuite/docs-examples-cpp/ref/out.txt @@ -1,37 +1,65 @@ +example_output_error1 error: Uninitialized input image +example_output_error2 error: Uninitialized input image -zero1.exr : 512 x 512, 3 channel, float openexr - SHA-1: 1E5F8DEF40BB0CB0F7156B9C2BAB9EFB49CFB699 +example_zero +example_fill +example_checker +example_noise1 +example_noise2 +example_point +example_lines +example_box +example_text1 +example_text2 +example_channels +example_channel_append +example_copy +example_crop +example_cut +example_paste +example_rotate_n +example_flip_flop_transpose +example_reorient +example_circular_shift +example_rotate +example_resize +example_resample +example_fit +example_warp +example_make_texture +zero1.exr : 512 x 512, 3 channel, half openexr + SHA-1: 95823C334FCE55968E8D2827CCD1CF77CEE19ABD zero2.exr : 256 x 256, 4 channel, half openexr SHA-1: 6A521E1D2A632C26E53B83D2CC4B0EDECFC1E68C zero3.exr : 256 x 256, 4 channel, half openexr SHA-1: 1254F2956229777B721576B94A6A944ECB806A37 zero4.exr : 256 x 256, 4 channel, half openexr SHA-1: 36EB49C5102703693C078717CE82AE05D4904680 -fill.exr : 640 x 480, 3 channel, float openexr - SHA-1: D517EA07CB6DB931AE4BF6D9E9957EEF9228734E -checker.exr : 640 x 480, 3 channel, float openexr - SHA-1: 87A4424581AAFCE31E6D1134E5025B620B48BBB3 -noise1.exr : 256 x 256, 3 channel, float openexr - SHA-1: 9E9278C8F5460068363D36DBD395FA59CA5986DC -noise2.exr : 256 x 256, 3 channel, float openexr - SHA-1: 0A75E8EF38846D8DC5D8BA997EB54F7A36058288 +fill.exr : 640 x 480, 3 channel, half openexr + SHA-1: 1BBCA1D5966D02554C13C1FAEF01F6E6E6169356 +checker.exr : 640 x 480, 3 channel, half openexr + SHA-1: 64508259AE242B593B906C848A2D69C443A3FBFD +noise1.exr : 256 x 256, 3 channel, half openexr + SHA-1: 66FF64DDAFDDE290031C20FAA208A193908EE9D4 +noise2.exr : 256 x 256, 3 channel, half openexr + SHA-1: 06011F9D59106096F4742A3DAB458D506A08E34C noise3.exr : 512 x 384, 3 channel, half openexr SHA-1: 95EDBCA9953281CE63A3E18C7C04BCCB07CB4C8A noise4.exr : 512 x 384, 3 channel, half openexr SHA-1: 43BC1FDFA1F18635B635A57D71DB08BB347CBD46 -blue-noise.exr : 256 x 256, 4 channel, float openexr - SHA-1: 36F448FE29C9DE6CFA65FC0BFCF4178DC66581C4 -point.exr : 640 x 480, 4 channel, float openexr - SHA-1: A2AC7CC98AB44798EEEA76C253DE44F6E49FFB8D -lines.exr : 640 x 480, 4 channel, float openexr - SHA-1: 69C0317F92256FD30415D1FE12419DC1C514D818 -box.exr : 640 x 480, 4 channel, float openexr - SHA-1: 6CBE5E98B145C5975CB930A91BAEE981C30E6B32 -text1.exr : 640 x 480, 3 channel, float openexr - SHA-1: 014ECFC5EBF07F77DF24A592F43BC7CB101534AE -text2.exr : 640 x 480, 3 channel, float openexr - SHA-1: 53359E96A286F909A89ACC99A67A9ED3BADC4A7A +blue-noise.exr : 256 x 256, 4 channel, half openexr + SHA-1: 5A0A51D1AD3F34633B781AFF9B90E59996C31AD0 +point.exr : 640 x 480, 4 channel, half openexr + SHA-1: 56E2BDBE03826F203132BD9E80AF44450307BDCE +lines.exr : 640 x 480, 4 channel, half openexr + SHA-1: 177C4C5C61ACDD54F198A45E52836DE897C4CE96 +box.exr : 640 x 480, 4 channel, half openexr + SHA-1: 984273B0A06E54873E24A732651490117E40410C +text1.exr : 640 x 480, 3 channel, half openexr + SHA-1: 1CF68F9B099A30EFF06850CEFBEDD3C2F861A654 +text2.exr : 640 x 480, 3 channel, half openexr + SHA-1: 00C96AE28FD12752AD1968D3D07EE30F1F218D76 channels-rgba.exr : 256 x 256, 4 channel, half openexr SHA-1: C823E3701152B4B3C20DD79EA8A20CF4293F4B71 channels-rgb.exr : 256 x 256, 3 channel, half openexr @@ -40,8 +68,8 @@ channels-brga.exr : 256 x 256, 4 channel, half openexr SHA-1: 04E09E64C61CEA1634D26FB2E6C733875D163671 channels-alpha.exr : 256 x 256, 1 channel, half openexr SHA-1: 99C332E70F321F0EA47C0F70AF8B0E3E6524F91F -channel-append.exr : 640 x 480, 5 channel, float openexr - SHA-1: F7ECA3179B1ABD2C45141DCEF0C17ECFE7E5A91F +channel-append.exr : 640 x 480, 5 channel, half openexr + SHA-1: E6A50C80C051F0F587FCB68B515B50E4DC3E9359 copy.exr : 256 x 256, 4 channel, float openexr SHA-1: 7044589C8B904DAF6A2BA3246224E97DD460AC93 crop.exr : 200 x 100, 4 channel, half openexr @@ -60,8 +88,18 @@ flip.exr : 256 x 256, 4 channel, half openexr SHA-1: A9EB9A8762BCD8DD161C00B01E2DF39E5C91B0D4 flop.exr : 256 x 256, 4 channel, half openexr SHA-1: 7C10717DB4F2E21F0B4F6D5404C660CA8B504F5E -transpose.exr : 256 x 256, 4 channel, float openexr - SHA-1: 2E0E9151C138EA26A331AA4C1FB39DA70815D4F7 +rotate-45.tif : 256 x 256, 4 channel, uint8 tiff + SHA-1: 2D4AECFD398F9E0AA0051888D0EE7CDC1E438A5A +resize.tif : 320 x 240, 4 channel, uint8 tiff + SHA-1: 6FD1A7A97729CD6D51A22ADE0709CC4DFDC3C826 +resample.exr : 320 x 240, 4 channel, half openexr + SHA-1: 5C0CC0A293FCD30B2AE44A0BED7D27DB9B8C8E50 +fit.tif : 240 x 240, 4 channel, uint8 tiff + SHA-1: AC77B6A4BFF3E42EB207CFDADEE6BCED4653D2B4 +warp.exr : 256 x 256, 4 channel, half openexr + SHA-1: EEB460766F07B47C647D630B568F25FFEEBF5A62 +transpose.exr : 256 x 256, 4 channel, half openexr + SHA-1: FAD57FB60460383D3D2D24B346F35A44846CCC39 reorient.exr : 256 x 256, 4 channel, half openexr SHA-1: 46C803894186457376A0C590768C9DB4877737BB cshift.exr : 256 x 256, 4 channel, half openexr diff --git a/testsuite/docs-examples-cpp/run.py b/testsuite/docs-examples-cpp/run.py index 8ea8692ebb..d63b8cd668 100755 --- a/testsuite/docs-examples-cpp/run.py +++ b/testsuite/docs-examples-cpp/run.py @@ -24,7 +24,10 @@ command += run_app(prefix + "docs-examples-" + chapter) # hashes merely check that the images don't change, but saves us the space -# of checking in a full copy of the image if it's not needed. +# of checking in a full copy of the image if it's not needed. This is not +# suitable if the image may change slightly from platform to platform or +# with different versions of dependencies, for that we should use the +# full reference image comparison with appropriate thresholds. hashes = [ # Outputs from the ImageBufAlgo chapter: "zero1.exr", @@ -57,6 +60,11 @@ "rotate-270.exr", "flip.exr", "flop.exr", + "rotate-45.tif", + "resize.tif", + "resample.exr", + "fit.tif", + "warp.exr", "transpose.exr", "reorient.exr", "cshift.exr", @@ -72,6 +80,10 @@ "simple.tif", "scanlines.tif", # Outputs from the ImageInput chapter: + # Outputs from the ImageBuf chapter: + + # Outputs from the ImageBufAlgo chapter: + # ... etc ... other chapters ... # Last, we have the out.txt that captures console output of the test diff --git a/testsuite/docs-examples-cpp/src/docs-examples-imagebufalgo.cpp b/testsuite/docs-examples-cpp/src/docs-examples-imagebufalgo.cpp index 9501cd97b1..8004e70369 100644 --- a/testsuite/docs-examples-cpp/src/docs-examples-imagebufalgo.cpp +++ b/testsuite/docs-examples-cpp/src/docs-examples-imagebufalgo.cpp @@ -56,6 +56,7 @@ void example_output_error1() // END-imagebufalgo-output-error1 } + void example_output_error2() { print("example_output_error2\n"); @@ -103,6 +104,7 @@ void example_zero() C.write("zero4.exr", TypeHalf); } + void example_fill() { print("example_fill\n"); @@ -121,6 +123,7 @@ void example_fill() A.write("fill.exr", TypeHalf); } + void example_checker() { print("example_checker\n"); @@ -137,6 +140,7 @@ void example_checker() A.write("checker.exr", TypeHalf); } + void example_noise1() { print("example_noise1\n"); @@ -166,6 +170,7 @@ void example_noise1() D.write("noise4.exr", TypeHalf); } + void example_noise2() { print("example_noise2\n"); @@ -176,6 +181,7 @@ void example_noise2() A.write("blue-noise.exr", TypeHalf); } + void example_point() { print("example_point\n"); @@ -188,6 +194,7 @@ void example_point() A.write("point.exr", TypeHalf); } + void example_lines() { print("example_lines\n"); @@ -201,6 +208,7 @@ void example_lines() A.write("lines.exr", TypeHalf); } + void example_box() { print("example_box\n"); @@ -215,6 +223,7 @@ void example_box() A.write("box.exr", TypeHalf); } + void example_text1() { print("example_text1\n"); @@ -238,6 +247,7 @@ void example_text1() ImgB.write("text2.exr", TypeHalf); } + void example_text2() { print("example_text2\n"); @@ -255,6 +265,7 @@ void example_text2() // END-imagebufalgo-text2 } + // Section: Image transformation and data movement void example_channels() @@ -289,6 +300,7 @@ void example_channels() BRGA.write("channels-brga.exr"); } + void example_channel_append() { print("example_channel_append\n"); @@ -302,6 +314,7 @@ void example_channel_append() RGBAZ.write("channel-append.exr", TypeHalf); } + void example_copy() { print("example_copy\n"); @@ -314,6 +327,7 @@ void example_copy() B.write("copy.exr"); } + void example_crop() { print("example_crop\n"); @@ -327,6 +341,7 @@ void example_crop() B.write("crop.exr"); } + void example_cut() { print("example_cut\n"); @@ -340,6 +355,7 @@ void example_cut() B.write("cut.exr"); } + void example_paste() { print("example_paste\n"); @@ -353,6 +369,7 @@ void example_paste() Bg.write("paste.exr"); } + void example_rotate_n() { print("example_rotate_n\n"); @@ -368,6 +385,7 @@ void example_rotate_n() R270.write("rotate-270.exr"); } + void example_flip_flop_transpose() { print("example_flip_flop_transpose\n"); @@ -383,6 +401,7 @@ void example_flip_flop_transpose() B3.write("transpose.exr"); } + void example_reorient() { print("example_reorient\n"); @@ -398,16 +417,18 @@ void example_reorient() A.write("reorient.exr"); } + void example_circular_shift() { print("example_circular_shift\n"); // BEGIN-imagebufalgo-cshift ImageBuf A("grid.exr"); ImageBuf B = ImageBufAlgo::circular_shift(A, 70, 30); - B.write("cshift.exr"); // END-imagebufalgo-cshift + B.write("cshift.exr"); } + void example_rotate() { print("example_rotate\n"); @@ -415,19 +436,23 @@ void example_rotate() ImageBuf Src ("grid.exr"); ImageBuf Dst = ImageBufAlgo::rotate (Src, 45.0); // END-imagebufalgo-rotate-angle + Dst.write("rotate-45.tif", TypeUInt8); } + void example_resize() { print("example_resize\n"); // BEGIN-imagebufalgo-resize // Resize the image to 640x480, using the default filter ImageBuf Src("grid.exr"); - ROI roi(0, 640, 0, 480, 0, 1, /*chans:*/ 0, Src.nchannels()); + ROI roi(0, 320, 0, 240, 0, 1, /*chans:*/ 0, Src.nchannels()); ImageBuf Dst = ImageBufAlgo::resize(Src, {}, roi); // END-imagebufalgo-resize + Dst.write("resize.tif", TypeUInt8); } + void example_resample() { print("example_resample\n"); @@ -437,19 +462,23 @@ void example_resample() ROI roi(0, 320, 0, 240, 0, 1, /*chans:*/ 0, Src.nchannels()); ImageBuf Dst = ImageBufAlgo::resample(Src, true, roi); // END-imagebufalgo-resample + Dst.write("resample.exr"); } + void example_fit() { print("example_fit\n"); // BEGIN-imagebufalgo-fit // Resize to fit into a max of 640x480, preserving the aspect ratio ImageBuf Src("grid.exr"); - ROI roi(0, 640, 0, 480, 0, 1, /*chans:*/ 0, Src.nchannels()); + ROI roi(0, 320, 0, 240, 0, 1, /*chans:*/ 0, Src.nchannels()); ImageBuf Dst = ImageBufAlgo::fit(Src, {}, roi); // END-imagebufalgo-fit + Dst.write("fit.tif", TypeUInt8); } + void example_warp() { print("example_warp\n"); @@ -460,6 +489,7 @@ void example_warp() ImageBuf Src("grid.exr"); ImageBuf Dst = ImageBufAlgo::warp(Src, M, { { "filtername", "lanczos3" } }); // END-imagebufalgo-warp + Dst.write("warp.exr"); } diff --git a/testsuite/docs-examples-python/ref/out-arm.txt b/testsuite/docs-examples-python/ref/out-arm.txt new file mode 100644 index 0000000000..39d2584e0e --- /dev/null +++ b/testsuite/docs-examples-python/ref/out-arm.txt @@ -0,0 +1,113 @@ +example1 +example_output_error1 +error: Uninitialized input image +example_output_error2 +error: Uninitialized input image +example_zero +example_fill +example_checker +example_noise1 +example_noise2 +example_point +example_lines +example_box +example_text1 +example_text2 +example_channels +example_channel_append +example_copy +example_crop +example_cut +example_paste +example_rotate_n +example_flip_flop_transpose +example_reorient +example_circular_shift +example_rotate +example_resize +example_resample +example_fit +example_warp +example_make_texture +zero1.exr : 512 x 512, 3 channel, half openexr + SHA-1: 95823C334FCE55968E8D2827CCD1CF77CEE19ABD +zero2.exr : 256 x 256, 4 channel, half openexr + SHA-1: 6A521E1D2A632C26E53B83D2CC4B0EDECFC1E68C +zero3.exr : 256 x 256, 4 channel, half openexr + SHA-1: 1254F2956229777B721576B94A6A944ECB806A37 +zero4.exr : 256 x 256, 4 channel, half openexr + SHA-1: 36EB49C5102703693C078717CE82AE05D4904680 +fill.exr : 640 x 480, 3 channel, half openexr + SHA-1: 1BBCA1D5966D02554C13C1FAEF01F6E6E6169356 +checker.exr : 640 x 480, 3 channel, half openexr + SHA-1: 64508259AE242B593B906C848A2D69C443A3FBFD +noise1.exr : 256 x 256, 3 channel, half openexr + SHA-1: 66FF64DDAFDDE290031C20FAA208A193908EE9D4 +noise2.exr : 256 x 256, 3 channel, half openexr + SHA-1: 06011F9D59106096F4742A3DAB458D506A08E34C +noise3.exr : 512 x 384, 3 channel, half openexr + SHA-1: 95EDBCA9953281CE63A3E18C7C04BCCB07CB4C8A +noise4.exr : 512 x 384, 3 channel, half openexr + SHA-1: 43BC1FDFA1F18635B635A57D71DB08BB347CBD46 +blue-noise.exr : 256 x 256, 4 channel, half openexr + SHA-1: 5A0A51D1AD3F34633B781AFF9B90E59996C31AD0 +point.exr : 640 x 480, 4 channel, half openexr + SHA-1: 56E2BDBE03826F203132BD9E80AF44450307BDCE +lines.exr : 640 x 480, 4 channel, half openexr + SHA-1: 177C4C5C61ACDD54F198A45E52836DE897C4CE96 +box.exr : 640 x 480, 4 channel, half openexr + SHA-1: 984273B0A06E54873E24A732651490117E40410C +text1.exr : 640 x 480, 3 channel, half openexr + SHA-1: 1CF68F9B099A30EFF06850CEFBEDD3C2F861A654 +text2.exr : 640 x 480, 3 channel, half openexr + SHA-1: 00C96AE28FD12752AD1968D3D07EE30F1F218D76 +channels-rgba.exr : 256 x 256, 4 channel, half openexr + SHA-1: C823E3701152B4B3C20DD79EA8A20CF4293F4B71 +channels-rgb.exr : 256 x 256, 3 channel, half openexr + SHA-1: 4074B050432CE7C664CEC4546A46E74F9A310CDC +channels-brga.exr : 256 x 256, 4 channel, half openexr + SHA-1: 04E09E64C61CEA1634D26FB2E6C733875D163671 +channels-alpha.exr : 256 x 256, 1 channel, half openexr + SHA-1: 99C332E70F321F0EA47C0F70AF8B0E3E6524F91F +channel-append.exr : 640 x 480, 5 channel, half openexr + SHA-1: E6A50C80C051F0F587FCB68B515B50E4DC3E9359 +copy.exr : 256 x 256, 4 channel, half openexr + SHA-1: C823E3701152B4B3C20DD79EA8A20CF4293F4B71 +crop.exr : 200 x 100, 4 channel, half openexr + SHA-1: 4DA3918566D087A9D2D9E93B2A7BABE971FE6BBD +cut.exr : 200 x 100, 4 channel, half openexr + SHA-1: 4DA3918566D087A9D2D9E93B2A7BABE971FE6BBD +paste.exr : 256 x 256, 4 channel, half openexr + SHA-1: 67A4C36DEAED98A5A8ABA5F0E0EDE697345DC22A +rotate-90.exr : 256 x 256, 4 channel, half openexr + SHA-1: AFFAEA876E8E7760226B017B0A89A3549B7A5895 +rotate-180.exr : 256 x 256, 4 channel, half openexr + SHA-1: A5E42C5F18177DA146EC7E4567E4AE3AE2816C3C +rotate-270.exr : 256 x 256, 4 channel, half openexr + SHA-1: 46C803894186457376A0C590768C9DB4877737BB +flip.exr : 256 x 256, 4 channel, half openexr + SHA-1: A9EB9A8762BCD8DD161C00B01E2DF39E5C91B0D4 +flop.exr : 256 x 256, 4 channel, half openexr + SHA-1: 7C10717DB4F2E21F0B4F6D5404C660CA8B504F5E +rotate-45.tif : 256 x 256, 4 channel, uint8 tiff + SHA-1: E2E41264B7BD250C3AACF9F6161A0FA86B22FA57 +resize.tif : 320 x 240, 4 channel, uint8 tiff + SHA-1: 6FD1A7A97729CD6D51A22ADE0709CC4DFDC3C826 +resample.exr : 320 x 240, 4 channel, half openexr + SHA-1: 16FC7DCFE01DC312593B00B9F90D71BAF3D52450 +fit.tif : 240 x 240, 4 channel, uint8 tiff + SHA-1: 5474A93DED5F9F44E561B70A53F509677961AB34 +warp.exr : 256 x 256, 4 channel, half openexr + SHA-1: 7EA7EB6798E051B5F4EB3722498371E55869BC91 +transpose.exr : 256 x 256, 4 channel, half openexr + SHA-1: FAD57FB60460383D3D2D24B346F35A44846CCC39 +reorient.exr : 256 x 256, 4 channel, half openexr + SHA-1: 46C803894186457376A0C590768C9DB4877737BB +cshift.exr : 256 x 256, 4 channel, half openexr + SHA-1: 000F95FDC44D4DBDA8B4041C2506149C7AE28ACA +texture.exr : 256 x 256, 3 channel, half openexr (+mipmap) + SHA-1: 4074B050432CE7C664CEC4546A46E74F9A310CDC +Comparing "simple.tif" and "../docs-examples-cpp/ref/simple.tif" +PASS +Comparing "scanlines.tif" and "../docs-examples-cpp/ref/scanlines.tif" +PASS diff --git a/testsuite/docs-examples-python/ref/out.txt b/testsuite/docs-examples-python/ref/out.txt index e85770e361..b45d96794c 100644 --- a/testsuite/docs-examples-python/ref/out.txt +++ b/testsuite/docs-examples-python/ref/out.txt @@ -1,37 +1,66 @@ +example1 +example_output_error1 error: Uninitialized input image +example_output_error2 error: Uninitialized input image -zero1.exr : 512 x 512, 3 channel, float openexr - SHA-1: 1E5F8DEF40BB0CB0F7156B9C2BAB9EFB49CFB699 +example_zero +example_fill +example_checker +example_noise1 +example_noise2 +example_point +example_lines +example_box +example_text1 +example_text2 +example_channels +example_channel_append +example_copy +example_crop +example_cut +example_paste +example_rotate_n +example_flip_flop_transpose +example_reorient +example_circular_shift +example_rotate +example_resize +example_resample +example_fit +example_warp +example_make_texture +zero1.exr : 512 x 512, 3 channel, half openexr + SHA-1: 95823C334FCE55968E8D2827CCD1CF77CEE19ABD zero2.exr : 256 x 256, 4 channel, half openexr SHA-1: 6A521E1D2A632C26E53B83D2CC4B0EDECFC1E68C zero3.exr : 256 x 256, 4 channel, half openexr SHA-1: 1254F2956229777B721576B94A6A944ECB806A37 zero4.exr : 256 x 256, 4 channel, half openexr SHA-1: 36EB49C5102703693C078717CE82AE05D4904680 -fill.exr : 640 x 480, 3 channel, float openexr - SHA-1: D517EA07CB6DB931AE4BF6D9E9957EEF9228734E -checker.exr : 640 x 480, 3 channel, float openexr - SHA-1: 87A4424581AAFCE31E6D1134E5025B620B48BBB3 -noise1.exr : 256 x 256, 3 channel, float openexr - SHA-1: 9E9278C8F5460068363D36DBD395FA59CA5986DC -noise2.exr : 256 x 256, 3 channel, float openexr - SHA-1: 0A75E8EF38846D8DC5D8BA997EB54F7A36058288 +fill.exr : 640 x 480, 3 channel, half openexr + SHA-1: 1BBCA1D5966D02554C13C1FAEF01F6E6E6169356 +checker.exr : 640 x 480, 3 channel, half openexr + SHA-1: 64508259AE242B593B906C848A2D69C443A3FBFD +noise1.exr : 256 x 256, 3 channel, half openexr + SHA-1: 66FF64DDAFDDE290031C20FAA208A193908EE9D4 +noise2.exr : 256 x 256, 3 channel, half openexr + SHA-1: 06011F9D59106096F4742A3DAB458D506A08E34C noise3.exr : 512 x 384, 3 channel, half openexr SHA-1: 95EDBCA9953281CE63A3E18C7C04BCCB07CB4C8A noise4.exr : 512 x 384, 3 channel, half openexr SHA-1: 43BC1FDFA1F18635B635A57D71DB08BB347CBD46 -blue-noise.exr : 256 x 256, 4 channel, float openexr - SHA-1: 36F448FE29C9DE6CFA65FC0BFCF4178DC66581C4 -point.exr : 640 x 480, 4 channel, float openexr - SHA-1: A2AC7CC98AB44798EEEA76C253DE44F6E49FFB8D -lines.exr : 640 x 480, 4 channel, float openexr - SHA-1: 69C0317F92256FD30415D1FE12419DC1C514D818 -box.exr : 640 x 480, 4 channel, float openexr - SHA-1: 6CBE5E98B145C5975CB930A91BAEE981C30E6B32 -text1.exr : 640 x 480, 3 channel, float openexr - SHA-1: 014ECFC5EBF07F77DF24A592F43BC7CB101534AE -text2.exr : 640 x 480, 3 channel, float openexr - SHA-1: 53359E96A286F909A89ACC99A67A9ED3BADC4A7A +blue-noise.exr : 256 x 256, 4 channel, half openexr + SHA-1: 5A0A51D1AD3F34633B781AFF9B90E59996C31AD0 +point.exr : 640 x 480, 4 channel, half openexr + SHA-1: 56E2BDBE03826F203132BD9E80AF44450307BDCE +lines.exr : 640 x 480, 4 channel, half openexr + SHA-1: 177C4C5C61ACDD54F198A45E52836DE897C4CE96 +box.exr : 640 x 480, 4 channel, half openexr + SHA-1: 984273B0A06E54873E24A732651490117E40410C +text1.exr : 640 x 480, 3 channel, half openexr + SHA-1: 1CF68F9B099A30EFF06850CEFBEDD3C2F861A654 +text2.exr : 640 x 480, 3 channel, half openexr + SHA-1: 00C96AE28FD12752AD1968D3D07EE30F1F218D76 channels-rgba.exr : 256 x 256, 4 channel, half openexr SHA-1: C823E3701152B4B3C20DD79EA8A20CF4293F4B71 channels-rgb.exr : 256 x 256, 3 channel, half openexr @@ -40,10 +69,10 @@ channels-brga.exr : 256 x 256, 4 channel, half openexr SHA-1: 04E09E64C61CEA1634D26FB2E6C733875D163671 channels-alpha.exr : 256 x 256, 1 channel, half openexr SHA-1: 99C332E70F321F0EA47C0F70AF8B0E3E6524F91F -channel-append.exr : 640 x 480, 5 channel, float openexr - SHA-1: F7ECA3179B1ABD2C45141DCEF0C17ECFE7E5A91F -copy.exr : 256 x 256, 4 channel, float openexr - SHA-1: 7044589C8B904DAF6A2BA3246224E97DD460AC93 +channel-append.exr : 640 x 480, 5 channel, half openexr + SHA-1: E6A50C80C051F0F587FCB68B515B50E4DC3E9359 +copy.exr : 256 x 256, 4 channel, half openexr + SHA-1: C823E3701152B4B3C20DD79EA8A20CF4293F4B71 crop.exr : 200 x 100, 4 channel, half openexr SHA-1: 4DA3918566D087A9D2D9E93B2A7BABE971FE6BBD cut.exr : 200 x 100, 4 channel, half openexr @@ -60,15 +89,25 @@ flip.exr : 256 x 256, 4 channel, half openexr SHA-1: A9EB9A8762BCD8DD161C00B01E2DF39E5C91B0D4 flop.exr : 256 x 256, 4 channel, half openexr SHA-1: 7C10717DB4F2E21F0B4F6D5404C660CA8B504F5E -transpose.exr : 256 x 256, 4 channel, float openexr - SHA-1: 2E0E9151C138EA26A331AA4C1FB39DA70815D4F7 +rotate-45.tif : 256 x 256, 4 channel, uint8 tiff + SHA-1: 2D4AECFD398F9E0AA0051888D0EE7CDC1E438A5A +resize.tif : 320 x 240, 4 channel, uint8 tiff + SHA-1: 6FD1A7A97729CD6D51A22ADE0709CC4DFDC3C826 +resample.exr : 320 x 240, 4 channel, half openexr + SHA-1: 5C0CC0A293FCD30B2AE44A0BED7D27DB9B8C8E50 +fit.tif : 240 x 240, 4 channel, uint8 tiff + SHA-1: AC77B6A4BFF3E42EB207CFDADEE6BCED4653D2B4 +warp.exr : 256 x 256, 4 channel, half openexr + SHA-1: EEB460766F07B47C647D630B568F25FFEEBF5A62 +transpose.exr : 256 x 256, 4 channel, half openexr + SHA-1: FAD57FB60460383D3D2D24B346F35A44846CCC39 reorient.exr : 256 x 256, 4 channel, half openexr SHA-1: 46C803894186457376A0C590768C9DB4877737BB cshift.exr : 256 x 256, 4 channel, half openexr SHA-1: 000F95FDC44D4DBDA8B4041C2506149C7AE28ACA texture.exr : 256 x 256, 3 channel, half openexr (+mipmap) SHA-1: 4074B050432CE7C664CEC4546A46E74F9A310CDC -Comparing "simple.tif" and "ref/simple.tif" +Comparing "simple.tif" and "../docs-examples-cpp/ref/simple.tif" PASS -Comparing "scanlines.tif" and "ref/scanlines.tif" +Comparing "scanlines.tif" and "../docs-examples-cpp/ref/scanlines.tif" PASS diff --git a/testsuite/docs-examples-python/ref/scanlines.tif b/testsuite/docs-examples-python/ref/scanlines.tif deleted file mode 100644 index a1d410fbec..0000000000 Binary files a/testsuite/docs-examples-python/ref/scanlines.tif and /dev/null differ diff --git a/testsuite/docs-examples-python/ref/simple.tif b/testsuite/docs-examples-python/ref/simple.tif deleted file mode 100644 index a1d410fbec..0000000000 Binary files a/testsuite/docs-examples-python/ref/simple.tif and /dev/null differ diff --git a/testsuite/docs-examples-python/run.py b/testsuite/docs-examples-python/run.py index 3a2db7478f..2595b3f9a6 100755 --- a/testsuite/docs-examples-python/run.py +++ b/testsuite/docs-examples-python/run.py @@ -6,6 +6,10 @@ redirect = " >> out.txt 2>&1 " +# To avoid duplicating example images between the C++ and Python tests, +# they all live with the C++ ones. +refdirlist += [ "../docs-examples-cpp/ref" ] + # Prep: command += run_app("cmake -E copy " + test_source_dir + "/../common/grid-small.exr grid.exr") command += run_app("cmake -E copy " + test_source_dir + "/../common/tahoe-small.tif tahoe.tif") @@ -16,7 +20,10 @@ command += pythonbin + " src/docs-examples-" + chapter + ".py " + redirect + " ;" # hashes merely check that the images don't change, but saves us the space -# of checking in a full copy of the image if it's not needed. +# of checking in a full copy of the image if it's not needed. This is not +# suitable if the image may change slightly from platform to platform or +# with different versions of dependencies, for that we should use the +# full reference image comparison with appropriate thresholds. hashes = [ # Outputs from the ImageBufAlgo chapter: "zero1.exr", @@ -49,6 +56,11 @@ "rotate-270.exr", "flip.exr", "flop.exr", + "rotate-45.tif", + "resize.tif", + "resample.exr", + "fit.tif", + "warp.exr", "transpose.exr", "reorient.exr", "cshift.exr", @@ -64,10 +76,13 @@ "simple.tif", "scanlines.tif", # Outputs from the ImageInput chapter: + # Outputs from the ImageBuf chapter: + + # Outputs from the ImageBufAlgo chapter: + # ... etc ... other chapters ... # Last, we have the out.txt that captures console output of the test # programs. "out.txt" ] - diff --git a/testsuite/docs-examples-python/src/docs-examples-imagebufalgo.py b/testsuite/docs-examples-python/src/docs-examples-imagebufalgo.py index 47998219af..dda5d32558 100644 --- a/testsuite/docs-examples-python/src/docs-examples-imagebufalgo.py +++ b/testsuite/docs-examples-python/src/docs-examples-imagebufalgo.py @@ -21,6 +21,7 @@ def example1(): + print("example1") # # Example code fragment from the docs goes here. # @@ -40,6 +41,7 @@ def example1(): # Section: ImageBufAlgo common principles def example_output_error1(): + print("example_output_error1") fg = ImageBuf() bg = ImageBuf() @@ -52,6 +54,7 @@ def example_output_error1(): def example_output_error2(): + print("example_output_error2") fg = ImageBuf() bg = ImageBuf() @@ -67,6 +70,7 @@ def example_output_error2(): # Section: Pattern Generation def example_zero(): + print("example_zero") A = ImageBuf("grid.exr") B = ImageBuf("grid.exr") C = ImageBuf("grid.exr") @@ -88,13 +92,14 @@ def example_zero(): ImageBufAlgo.zero(C, ROI(0, 100, 0, 100)) # END-imagebufalgo-zero - zero.write("zero1.exr") - A.write("zero2.exr") - B.write("zero3.exr") - C.write("zero4.exr") + zero.write("zero1.exr", "half") + A.write("zero2.exr", "half") + B.write("zero3.exr", "half") + C.write("zero4.exr", "half") def example_fill(): + print("example_fill") # BEGIN-imagebufalgo-fill # Create a new 640x480 RGB image, with a top-to-bottom gradient # from red to pink @@ -107,10 +112,11 @@ def example_fill(): ImageBufAlgo.fill(A, red, ROI(50, 100, 75, 175)) # END-imagebufalgo-fill - A.write("fill.exr") + A.write("fill.exr", "half") def example_checker(): + print("example_checker") # BEGIN-imagebufalgo-checker # Create a new 640x480 RGB image, fill it with a two-toned gray # checkerboard, the checkers being 64x64 pixels each. @@ -121,10 +127,11 @@ def example_checker(): roi=ROI(0, 640, 0, 480, 0, 1, 0, 3)) # END-imagebufalgo-checker - A.write("checker.exr") + A.write("checker.exr", "half") def example_noise1(): + print("example_noise1") # BEGIN-imagebufalgo-noise1 # Create a new 256x256 field of grayscale white noise on [0,1) A = ImageBufAlgo.noise("uniform", A=0.0, B=1.0, mono=True, seed=1, @@ -143,31 +150,34 @@ def example_noise1(): ImageBufAlgo.noise(D, "salt", A=0.0, B=0.01, mono=True, seed=1) # END-imagebufalgo-noise1 - A.write("noise1.exr") - B.write("noise2.exr") - C.write("noise3.exr") - D.write("noise4.exr") + A.write("noise1.exr", "half") + B.write("noise2.exr", "half") + C.write("noise3.exr", "half") + D.write("noise4.exr", "half") def example_noise2(): + print("example_noise2") # BEGIN-imagebufalgo-noise2 A = ImageBufAlgo.bluenoise_image() # END-imagebufalgo-noise2 - A.write("blue-noise.exr") + A.write("blue-noise.exr", "half") def example_point(): + print("example_point") # BEGIN-imagebufalgo-point A = ImageBuf(ImageSpec(640, 480, 4, "float")) red = (1, 0, 0, 1) ImageBufAlgo.render_point(A, 50, 100, red) # END-imagebufalgo-point - A.write("point.exr") + A.write("point.exr", "half") def example_lines(): + print("example_lines") # BEGIN-imagebufalgo-lines A = ImageBuf(ImageSpec(640, 480, 4, "float")) red = (1, 0, 0, 1) @@ -175,10 +185,11 @@ def example_lines(): ImageBufAlgo.render_line(A, 250, 20, 100, 190, red, True) # END-imagebufalgo-lines - A.write("lines.exr") + A.write("lines.exr", "half") def example_box(): + print("example_box") # BEGIN-imagebufalgo-box A = ImageBuf(ImageSpec(640, 480, 4, "float")) cyan = (0, 1, 1, 1) @@ -187,10 +198,11 @@ def example_box(): ImageBufAlgo.render_box(A, 100, 50, 180, 140, yellow_transparent, fill=True) # END-imagebufalgo-box - A.write("box.exr") + A.write("box.exr", "half") def example_text1(): + print("example_text1") ImgA = ImageBufAlgo.zero(ROI(0, 640, 0, 480, 0, 1, 0, 3)) ImgB = ImageBufAlgo.zero(ROI(0, 640, 0, 480, 0, 1, 0, 3)) @@ -206,11 +218,12 @@ def example_text1(): alignx="center", aligny="center") # END-imagebufalgo-text1 - ImgA.write("text1.exr") - ImgB.write("text2.exr") + ImgA.write("text1.exr", "half") + ImgB.write("text2.exr", "half") def example_text2(): + print("example_text2") # BEGIN-imagebufalgo-text2 # Render text centered in the image, using text_size to find out # the size we will need and adjusting the coordinates. @@ -227,6 +240,7 @@ def example_text2(): # Section: Image transformation and data movement def example_channels(): + print("example_channels") RGBA = ImageBuf("grid.exr") BRGA = ImageBuf() @@ -250,13 +264,14 @@ def example_channels(): newchannelnames=("", "", "", "A")) # END-imagebufalgo-channels - RGBA.write("channels-rgba.exr") - RGB.write("channels-rgb.exr") - Alpha.write("channels-alpha.exr") - BRGA.write("channels-brga.exr") + RGBA.write("channels-rgba.exr", "half") + RGB.write("channels-rgb.exr", "half") + Alpha.write("channels-alpha.exr", "half") + BRGA.write("channels-brga.exr", "half") def example_channel_append(): + print("example_channel_append") Z = ImageBuf(ImageSpec(640, 480, 1, "float")) # BEGIN-imagebufalgo-channel-append @@ -264,20 +279,22 @@ def example_channel_append(): RGBAZ = ImageBufAlgo.channel_append(RGBA, Z) # END-imagebufalgo-channel-append - RGBAZ.write("channel-append.exr") + RGBAZ.write("channel-append.exr", "half") def example_copy(): + print("example_copy") # BEGIN-imagebufalgo-copy # Set B to be a copy of A, but converted to float A = ImageBuf("grid.exr") B = ImageBufAlgo.copy(A, convert="float") # END-imagebufalgo-copy - B.write("copy.exr") + B.write("copy.exr", "half") def example_crop(): + print("example_crop") # BEGIN-imagebufalgo-crop # Set B to be a 200x100 region of A starting at (50,50), trimming # the exterior away but leaving that region in its original position. @@ -285,10 +302,11 @@ def example_crop(): B = ImageBufAlgo.crop(A, ROI(50, 250, 50, 150)) # END-imagebufalgo-crop - B.write("crop.exr") + B.write("crop.exr", "half") def example_cut(): + print("example_cut") # BEGIN-imagebufalgo-cut # Set B to be a 200x100 region of A starting at (50,50), but # moved to the upper left corner so its new origin is (0,0). @@ -296,10 +314,11 @@ def example_cut(): B = ImageBufAlgo.cut(A, ROI(50, 250, 50, 150)) # END-imagebufalgo-cut - B.write("cut.exr") + B.write("cut.exr", "half") def example_paste(): + print("example_paste") # BEGIN-imagebufalgo-paste # Paste Fg on top of Bg, offset by (100,100) Bg = ImageBuf("grid.exr") @@ -307,10 +326,11 @@ def example_paste(): ImageBufAlgo.paste(Bg, 100, 100, 0, 0, Fg) # END-imagebufalgo-paste - Bg.write("paste.exr") + Bg.write("paste.exr", "half") def example_rotate_n(): + print("example_rotate_n") # BEGIN-imagebufalgo-rotate-n A = ImageBuf("grid.exr") R90 = ImageBufAlgo.rotate90(A) @@ -318,12 +338,13 @@ def example_rotate_n(): R270 = ImageBufAlgo.rotate270(A) # END-imagebufalgo-rotate-n - R90.write("rotate-90.exr") - R180.write("rotate-180.exr") - R270.write("rotate-270.exr") + R90.write("rotate-90.exr", "half") + R180.write("rotate-180.exr", "half") + R270.write("rotate-270.exr", "half") def example_flip_flop_transpose(): + print("example_flip_flop_transpose") # BEGIN-imagebufalgo-flip-flop-transpose A = ImageBuf("grid.exr") B1 = ImageBufAlgo.flip(A) @@ -331,67 +352,79 @@ def example_flip_flop_transpose(): B3 = ImageBufAlgo.transpose(A) # END-imagebufalgo-flip-flop-transpose - B1.write("flip.exr") - B2.write("flop.exr") - B3.write("transpose.exr") + B1.write("flip.exr", "half") + B2.write("flop.exr", "half") + B3.write("transpose.exr", "half") def example_reorient(): + print("example_reorient") tmp = ImageBuf("grid.exr") tmp.specmod().attribute("Orientation", 8) - tmp.write("grid-vertical.exr") + tmp.write("grid-vertical.exr", "half") # BEGIN-imagebufalgo-reorient A = ImageBuf("grid-vertical.exr") A = ImageBufAlgo.reorient(A) # END-imagebufalgo-reorient - A.write("reorient.exr") + A.write("reorient.exr", "half") def example_circular_shift(): + print("example_circular_shift") # BEGIN-imagebufalgo-cshift A = ImageBuf("grid.exr") B = ImageBufAlgo.circular_shift(A, 70, 30) # END-imagebufalgo-cshift - B.write("cshift.exr") + B.write("cshift.exr", "half") def example_rotate(): + print("example_rotate") # BEGIN-imagebufalgo-rotate-angle Src = ImageBuf("grid.exr") Dst = ImageBufAlgo.rotate(Src, 45.0) # END-imagebufalgo-rotate-angle + Dst.write("rotate-45.tif", "uint8") def example_resize(): + print("example_resize") # BEGIN-imagebufalgo-resize # Resize the image to 640x480, using the default filter Src = ImageBuf("grid.exr") - roi = ROI(0, 640, 0, 480, 0, 1, 0, Src.nchannels) + roi = ROI(0, 320, 0, 240, 0, 1, 0, Src.nchannels) Dst = ImageBufAlgo.resize(Src, roi=roi) # END-imagebufalgo-resize + Dst.write("resize.tif", "uint8") def example_resample(): + print("example_resample") + # BEGIN-imagebufalgo-resample # Resample quickly to 320x240, with default interpolation Src = ImageBuf("grid.exr") roi = ROI(0, 320, 0, 240, 0, 1, 0, Src.nchannels) Dst = ImageBufAlgo.resample(Src, roi=roi) # END-imagebufalgo-resample + Dst.write("resample.exr", "half") def example_fit(): + print("example_fit") # BEGIN-imagebufalgo-fit # Resize to fit into a max of 640x480, preserving the aspect ratio Src = ImageBuf("grid.exr") - roi = ROI(0, 640, 0, 480, 0, 1, 0, Src.nchannels) - Dst = ImageBufAlgo.fit(Src, "", 0, True, roi) + roi = ROI(0, 320, 0, 240, 0, 1, 0, Src.nchannels) + Dst = ImageBufAlgo.fit(Src, "", roi=roi) # END-imagebufalgo-fit + Dst.write("fit.tif", "uint8") def example_warp(): + print("example_warp") # BEGIN-imagebufalgo-warp M = (0.7071068, 0.7071068, 0, -0.7071068, 0.7071068, 0, @@ -399,6 +432,7 @@ def example_warp(): Src = ImageBuf("grid.exr") Dst = ImageBufAlgo.warp(Src, M, filtername="lanczos3") # END-imagebufalgo-warp + Dst.write("warp.exr", "half") # Section: Image Arithmetic @@ -422,6 +456,7 @@ def example_warp(): # Section: Import / export def example_make_texture(): + print("example_make_texture") # BEGIN-imagebufalgo-make-texture Input = ImageBuf("grid.exr") config = ImageSpec()